]> git.proxmox.com Git - grub2.git/blame - ChangeLog
2009-11-25 Felix Zielcke <fzielcke@z-51.de>
[grub2.git] / ChangeLog
CommitLineData
6f61ed55
FZ
12009-11-25 Felix Zielcke <fzielcke@z-51.de>
2
3 * util/grub.d/10_linux.in (linux_entry): Quote the arguments to
4 printf and print a newline after the menuentry header line.
5 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
6
f022876b
FZ
72009-11-25 Felix Zielcke <fzielcke@z-51.de>
8
9 autoconf >= 2.60 support $(localedir).
10
11 * INSTALL: Note that autoconf 2.60 is required.
12 * configure.ac (AC_PREREQ): Bump to 2.60.
13 * util/grub.d/10_kfreebsd.in (TEXTDOMAINDIR): Set to lowercased @localedir@.
14 * util/grub.d/10_linux.in (TEXTDOMAINDIR): Likewise.
15
6717926e
YB
162009-11-25 Yves Blusseau <yves.blusseau@zetam.org>
17
18 * configure.ac: move the call to AM_GNU_GETTEXT to avoid warnings when
19 aclocal is run.
20
08806a54
RM
212009-11-25 Robert Millan <rmh.grub@aybabtu.com>
22
23 * normal/main.c (grub_normal_read_line): Fix off-by-one
24 buffer overflow.
25
13b33fba
RM
262009-11-25 Robert Millan <rmh.grub@aybabtu.com>
27
28 * normal/main.c (grub_normal_execute): Replace "parser.sh" with
29 "parser.grub" in grub_command_execute() call.
30
4a8572e9
CPE
312009-11-24 Carles Pina i Estany <carles@pina.cat>
32
33 * conf/i386-coreboot.rmk (kernel_img_HEADERS): Add i18n.h.
34 * conf/i386-efi.rmk: Likewise.
35 * conf/i386-ieee1275.rmk: Likewise.
36 * conf/i386-pc.rmk: Likewise.
37 * conf/powerpc-ieee1275.rmk: Likewise.
38 * conf/sparc64-ieee1275.rmk: Likewise.
39 * conf/x86_64-efi.rmk: Likewise.
40 * gettext/gettex.c: Include <grub/i18n.h>.
41 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): Move from
42 here ...
43 * include/grub/i18n.h: ... to here
44 * include/grub/i18n.h: ... to here.
45 * kern/misc.c: Include <grub/i18n.h>
46 (grub_gettext_dummy): Move above user.
47
bee48093
FZ
482009-11-24 Felix Zielcke <fzielcke@z-51.de>
49
50 * util/Makefile.in (install-local): Convert a `for' into a normal
51 shell expansion.
52
a031e91c
RM
532009-11-24 Robert Millan <rmh.grub@aybabtu.com>
54
55 * autogen.sh: Add automake call.
56 * config.guess: Remove.
57 * config.sub: Likewise.
58 * install-sh: Likewise.
59
26bec39d
FZ
602009-11-24 Felix Zielcke <fzielcke@z-51.de>
61
62 * util/Makefile.in (install-local): Fix the use of $lang shell variable.
63
8e2532fd
FZ
642009-11-24 Felix Zielcke <fzielcke@z-51.de>
65
66 * util/Makefile.in (install-local): Convert a make `$(foreach)'
67 function to a normal shell `for'.
68
fefa1b7d
FZ
692009-11-24 Felix Zielcke <fzielcke@z-51.de>
70
71 * conf/i386-coreboot.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
72
4501250b
FZ
732009-11-24 Felix Zielcke <fzielcke@z-51.de>
74
75 * util/grub-mkrelpath.c: New file.
76 * conf/common.rmk (bin_UTILITIES): Add grub-mkrelpath.
77 (grub_mkrelpath_SOURCES): New variable.
78 * include/grub/util/misc.h: New function prototype.
79 * util/misc.c (make_system_path_relative_to_its_root): New function.
80
81 * util/grub-mkconfig_lib.in (bindir): New variable.
82 (grub_mkrelpath): Likewise.
83 (make_system_path_relative_to_its_root): Use grub-mkrelpath.
84
85 * util/probe.c (probe): Make the file path relative to its root.
86 Change a info message to use the GRUB path. Enable again the
87 check if we can read the file with GRUB facilities.
88
89 * util/i386/pc/grub-setup.c (setup): Make core.img path relative
90 to its root.
91
11d9778b
FZ
922009-11-24 Felix Zielcke <fzielcke@z-51.de>
93
94 * Makefile.in: Don't include GRUB_CONTRIB makefiles with emu
95 platform.
96
4465287d
FZ
972009-11-24 Felix Zielcke <fzielcke@z-51.de>
98
99 * util/getroot.c (grub_util_get_dev_abstraction): Properly use
100 strncmp().
101
62b47f22
FZ
1022009-11-24 Felix Zielcke <fzielcke@z-51.de>
103
104 * util/getroot.c (grub_util_is_dmraid): New function.
105 (grub_util_get_dev_abstraction): Treat dmraid and multipath
106 devices as normal ones, not as LVM.
107
1eafb9b9 1082009-11-23 Carles Pina i Estany <carles@pina.cat>
c3ea6bd4
CPE
109
110 * conf/common.rmk: Add grub-gettext_lib target and updates
111 lib_DATA and CLEANFILES. Adds gettext.mod SOURCES, CFLAGS,
112 LDFLAGS.
113 * gettext/gettext.c: New file. (Reads mo files).
114 * include/grub/file.h (grub_file_pread): New prototype.
115 * include/grub/i18n.h (_): New prototype.
116 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): New
117 prototypes.
118 * kern/misc.c (grub_gettext_dummy): New function.
119 * normal/menu_text.c: Include <grub/i18n.h>.
120 * normal/menu_text.c (print_timeout): Gettexttize string.
121 * normal/menu_text.c (print_message): Gettexttize string.
c3ea6bd4
CPE
122 * util/grub.d/00_header.in: Define locale_dir and lang. insmod
123 gettext module and defines locale_dir and lang in grub.cfg.
124 * NEWS: Add gettext support.
125
0fdb2568
RM
1262009-11-23 Robert Millan <rmh.grub@aybabtu.com>
127
128 * util/hostdisk.c: Include `<grub/i18n.h>'.
129 (find_grub_drive): Use ARRAY_SIZE for map size calculation.
130 (make_device_name): Rewrite using asprintf.
131 (convert_system_partition_to_system_disk): Replace 0 with NULL.
132 (find_system_device): If a device is not found, generate one just
133 by reusing the OS path name.
134 (read_device_map): Make it permissible for device.map not to exist.
135
f515aa62
RM
1362009-11-23 Robert Millan <rmh.grub@aybabtu.com>
137
138 * script/sh/execute.c: Move from here ...
139 * script/execute.c: ... to here. Update all users.
140 * script/sh/function.c: Move from here ...
141 * script/function.c: ... to here. Update all users.
142 * script/sh/lexer.c: Move from here ...
143 * script/lexer.c: ... to here. Update all users.
144 * script/sh/main.c: Move from here ...
145 * script/main.c: ... to here. Update all users.
146 * script/sh/parser.y: Move from here ...
147 * script/parser.y: ... to here. Update all users.
148 * script/sh/script.c: Move from here ...
149 * script/script.c: ... to here. Update all users.
150
f84b481b
RM
1512009-11-23 Robert Millan <rmh.grub@aybabtu.com>
152
153 * configure.ac: Detect all `emu' platforms. Define
154 GRUB_MACHINE_* macros in TARGET_CFLAGS. Remove
155 --enable-grub-emu logic. Disable include/grub/machine
156 symlink on `emu' platforms.
157
158 * genkernsyms.sh.in: Use @TARGET_CFLAGS@ during symbol generation.
159 * gensymlist.sh.in: Likewise.
160
161 * include/grub/i386/coreboot/machine.h: Remove file.
162 * include/grub/i386/efi/machine.h: Likewise.
163 * include/grub/i386/ieee1275/machine.h: Likewise.
164 * include/grub/i386/pc/machine.h: Likewise.
165 * include/grub/i386/qemu/machine.h: Likewise.
166 * include/grub/powerpc/ieee1275/machine.h: Likewise.
167 * include/grub/sparc64/ieee1275/machine.h: Likewise.
168 * include/grub/x86_64/efi/machine.h: Likewise.
169
170 * commands/acpi.c: Remove `<grub/machine/machine.h>'.
171 * commands/halt.c: Likewise.
172 * commands/reboot.c: Likewise.
173 * include/grub/autoefi.h: Likewise.
174 * include/grub/i386/at_keyboard.h: Likewise.
175 * include/grub/i386/kernel.h: Likewise.
176 * include/grub/i386/loader.h: Likewise.
177 * include/grub/i386/pc/memory.h: Likewise.
178 * kern/dl.c: Likewise.
179 * kern/i386/coreboot/init.c: Likewise.
180 * loader/i386/bsd.c: Likewise.
181 * loader/i386/linux.c: Likewise.
182 * loader/multiboot_loader.c: Likewise.
183 * term/i386/pc/serial.c: Likewise.
184 * term/usb_keyboard.c: Likewise.
185
186 * include/grub/time.h [!GRUB_MACHINE_EMU]: Remove
187 `<grub/machine/machine.h>'
188 [!GRUB_MACHINE_EMU] (GRUB_TICKS_PER_SECOND): New macro.
189 * util/misc.c: Remove `<grub/machine/machine.h>' and
190 `<grub/machine/time.h>'.
191
192 * Makefile.in (enable_grub_emu): Remove variable.
193 Include $(srcdir)/conf/any-emu.mk for the `emu' platform.
194
195 * conf/any-emu.rmk: New file.
196 * conf/common.rmk (grub_emu_init.lst, grub_emu_init.h)
197 (grub_emu_init.c): Move from here ...
198 * conf/any-emu.rmk: ... to here.
199
200 * conf/i386-coreboot.rmk (sbin_UTILITIES): Remove `grub-emu'.
201 (grub_emu_SOURCES, grub_emu_LDFLAGS): Move from here ...
202 * conf/any-emu.rmk: ... to here.
203
4efeab03
RM
2042009-11-23 Robert Millan <rmh.grub@aybabtu.com>
205
206 * include/grub/parser.h (grub_parser_register): Document need
207 of `name' parameter.
208 * normal/main.c (grub_normal_read_line): Simplify prompt string.
209 * script/sh/main.c (grub_sh_parser, GRUB_MOD_INIT(sh)): Rename
210 "sh" to "grub".
211
ea1dd8bf
RM
2122009-11-23 Robert Millan <rmh.grub@aybabtu.com>
213
214 * Makefile.in ($(srcdir)/po/$(PACKAGE).pot): Pass --keyword=N_ to
215 `$(XGETTEXT)'.
216 * include/grub/i18n.h (N_): New macro.
217 * util/mkisofs/mkisofs.h: Likewise.
218 * util/mkisofs/mkisofs.c (ld_options): Wrap all translatable strings
219 around N_().
220 (usage): Use gettext() to translate help strings when printing them.
221
0c140626
RM
2222009-11-23 Robert Millan <rmh.grub@aybabtu.com>
223
224 Based on patch from Bean
225 (http://lists.gnu.org/archive/html/grub-devel/2009-08/msg00384.html)
226
227 * video/efi_fb.c: New file.
228 * conf/i386-efi.rmk (pkglib_MODULES): Add `efi_fb.mod'.
229 (efi_fb_mod_SOURCES, efi_fb_mod_CFLAGS, efi_fb_mod_LDFLAGS): New
230 variables.
231 * conf/x86_64-efi.rmk: Likewise.
232
87d58298
RM
2332009-11-22 Robert Millan <rmh.grub@aybabtu.com>
234
235 * util/i386/pc/grub-mkimage.c: Ungettextize grub_util_info() strings.
236 * util/i386/pc/grub-setup.c: Likewise.
237
994cc3a3
ST
2382009-11-21 Samuel Thibault <samuel.thibault@ens-lyon.org>
239
240 * util/getroot.c [__GNU__]: Include <hurd.h>, <hurd/lookup.h>, and
241 <hurd/fs.h>
242 [__GNU__] (grub_guess_root_device): Call file_name_lookup and
243 file_get_storage_info to implement grub_guess_root_device.
244
26a61d6a
FZ
2452009-11-21 Felix Zielcke <fzielcke@z-51.de>
246
247 * Makefile.in (target): Use make's builtin $(shell) function
248 instead of calling directly $(SHELL) to create the locale directories,
249 inside the $(foreach) function.
250
74ff1dd5
FZ
2512009-11-21 Felix Zielcke <fzielcke@z-51.de>
252
253 * util/grub-mkrescue.in: Print an error and usage if output option
254 has not been given.
255
0b787d0e
FZ
2562009-11-21 Felix Zielcke <fzielcke@z-51.de>
257
258 Patch from Loïc Minier <loic.minier@ubuntu.com>.
259 * util/grub.d/30_os-prober.in: Cope with Linux entries where
260 root and /boot are on different devices.
261
1164b270
RM
2622009-11-21 Robert Millan <rmh.grub@aybabtu.com>
263
264 Fix build for srcdir != objdir.
265
266 * Makefile.in (po/$(PACKAGE).pot): Rename to ...
267 ($(srcdir)/po/$(PACKAGE).pot): ... this. Run $(XGETTEXT) from
268 $(srcdir).
269 ($(foreach lang, $(LINGUAS), po/$(lang).po)): Rename to ...
270 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po): ... this. Use $^
271 reference for input.
272
13774a2f
RM
2732009-11-21 Robert Millan <rmh.grub@aybabtu.com>
274
275 * util/grub-mkrescue.in: Use source directory direcly (without copiing
276 or hardlinking it). Remove -J option, Joliet is not compatible with
277 multiple source directories.
278
efda854e
RM
2792009-11-21 Carles Pina i Estany <carles@pina.cat>
2802009-11-21 Robert Millan <rmh.grub@aybabtu.com>
281
282 * util/grub-mkrescue.in: Recognize `--override-directory' option.
283 (process_input_dir): New function. Process an arbitrary input
284 directory.
285 Misc adjustments to support both "override mode" and system-wide mode.
286
6c09890c
FZ
2872009-11-20 Felix Zielcke <fzielcke@z-51.de>
288
289 * configure.ac (UNIFONT_BDF): Rename to ...
290 (FONT_SOURCE): ... this. Update all users.
291
a797824f
FZ
2922009-11-20 Felix Zielcke <fzielcke@z-51.de>
293
294 * configure.ac: Add `/usr/share/fonts/X11/misc/unifont.pcf.gz'
295 to the list of unifont files to look for.
296
cd4f42b0
RM
2972009-11-19 Robert Millan <rmh.grub@aybabtu.com>
298
299 Patch from Joe Auricchio <jauricchio@gmail.com>
300 * commands/minicmd.c (grub_mini_cmd_clear): New function.
301 (GRUB_MOD_INIT(minicmd)): Register grub_mini_cmd_clear().
302 (GRUB_MOD_FINI(minicmd)): Unregister grub_mini_cmd_clear().
303
393c783d
FZ
3042009-11-19 Felix Zielcke <fzielcke@z-51.de>
305
306 * Makefile.in (install-local): Add a missing backslash.
307
b2f1e327
FZ
3082009-11-19 Felix Zielcke <fzielcke@z-51.de>
309
310 * include/grub/x86_64/io.h: New file.
311
f577f7a0
RM
3122009-11-19 Robert Millan <rmh.grub@aybabtu.com>
313
314 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `gnulib/progname.c'.
315 * util/i386/pc/grub-setup.c: Include `<grub/i18n.h>'.
316 Include `"progname.h"'.
317 (main): Initialize gettext.
318 * util/i386/pc/grub-setup.c: Gettexttize.
319 * util/i386/pc/grub-mkimage.c: Likewise.
320
321 * Makefile.in (po/*.po): Redefine as ...
322 ($(foreach lang, $(LINGUAS), po/$(lang).po)): ... this.
323
c37943b6
RM
3242009-11-19 Robert Millan <rmh.grub@aybabtu.com>
325
326 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/progname.c'.
327 * util/mkisofs/mkisofs.c: Include `"progname.h"'.
328 (program_name): Remove.
329 (main): Initialize gettext support.
6323f705
RM
330 * util/mkisofs/mkisofs.h: Include `<locale.h>'.
331 Include `<libintl.h>'.
332 (_): New macro.
c37943b6
RM
333
334 * util/mkisofs/eltorito.c: Gettexttize.
335 * util/mkisofs/joliet.c: Likewise.
336 * util/mkisofs/mkisofs.c: Likewise.
c37943b6
RM
337 * util/mkisofs/multi.c: Likewise.
338 * util/mkisofs/rock.c: Likewise.
339 * util/mkisofs/tree.c: Likewise.
340 * util/mkisofs/write.c: Likewise.
341
5ce77c6e
RM
3422009-11-18 Robert Millan <rmh.grub@aybabtu.com>
343
344 * util/mkisofs/eltorito.c: Fix minor mistake in license text.
345 * util/mkisofs/iso9660.h: Likewise.
346 * util/mkisofs/joliet.c: Likewise.
347 * util/mkisofs/mkisofs.c: Likewise.
348 * util/mkisofs/mkisofs.h: Likewise.
349 * util/mkisofs/rock.c: Likewise.
350 * util/mkisofs/tree.c: Likewise.
351 * util/mkisofs/write.c: Likewise.
352
353 * util/mkisofs/eltorito.c (rcsid): Remove.
354 * util/mkisofs/hash.c: Likewise.
355 * util/mkisofs/joliet.c: Likewise.
356 * util/mkisofs/name.c: Likewise.
357 * util/mkisofs/rock.c: Likewise.
358 * util/mkisofs/tree.c: Likewise.
359 * util/mkisofs/write.c: Likewise.
360
1dabbc77
RM
3612009-11-18 Robert Millan <rmh.grub@aybabtu.com>
362
363 * util/mkisofs/match.c: Rewrite from scratch, using a linked list
364 instead of static allocation.
365 * util/mkisofs/match.h: Likewise.
366
633877cb
RM
3672009-11-18 Robert Millan <rmh.grub@aybabtu.com>
368
633877cb
RM
369 * Makefile.in (po/$(PACKAGE).pot): Process `po/POTFILES-shell' for
370 translatable Shell files.
371
af1c0c85
RM
3722009-11-18 Robert Millan <rmh.grub@aybabtu.com>
373
374 * Makefile.in ($(srcdir)/aclocal.m4): New target.
375
769ae37b
RM
3762009-11-17 Robert Millan <rmh.grub@aybabtu.com>
377
378 * INSTALL: Document Automake is needed for bootstrap.
769ae37b
RM
379 * util/grub.d/10_kfreebsd.in (bindir): New variable.
380 Add gettext initialization.
381 (kfreebsd_entry): Make menuentry output translatable.
382
3832009-11-17 Robert Millan <rmh.grub@aybabtu.com>
384
385 * Makefile.in (XGETTEXT, MSGMERGE, MSGFMT): New variables.
386 (po/$(PACKAGE).pot): Replace `xgettext' with `$(XGETTEXT)'.
387 (po/*.po): Replace `msgmerge' with `$(MSGMERGE)'.
388 (po/%.mo): Replace `msgfmt' with `$(MSGFMT)'.
389 (LINGUAS): Auto-generate using `po/LINGUAS'.
769ae37b
RM
390
3912009-11-17 Robert Millan <rmh.grub@aybabtu.com>
392
393 * configure.ac: Call AM_GNU_GETTEXT() (defines localedir, among
394 other things).
395 * Makefile.in (CPPFLAGS): Add `-DLOCALEDIR=\"$(localedir)\"'.
396 * util/i386/pc/grub-mkimage.c (main): Issue setlocale() and
397 bindtextdomain() calls for gettext initialization.
398
3992009-11-17 Robert Millan <rmh.grub@aybabtu.com>
400
401 * gnulib/progname.c: New file (imported from Gnulib).
402 * gnulib/progname.h: Likewise.
403 * conf/i386-pc.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
404 * util/i386/pc/grub-mkimage.c: Include `"progname.h"'.
405 (usage): Replace `progname' with `program_name'.
406 (main): Use set_program_name() for program name initialization.
407
4082009-11-17 Robert Millan <rmh.grub@aybabtu.com>
409
410 * conf/common.rmk (grub_mkisofs_CFLAGS): Move `-I$(srcdir)/gnulib'
411 from here ...
412 * Makefile.in (CPPFLAGS): ... to here.
413
4142009-11-16 Robert Millan <rmh.grub@aybabtu.com>
415
416 * aclocal.m4: Move from here ...
417 * acinclude.m4: ... to here.
418 * autogen.sh: Add call to `aclocal'.
419 * configure.ac: Add AM_INIT_AUTOMAKE() after AC_INIT() call.
420
4212009-11-16 Robert Millan <rmh.grub@aybabtu.com>
422
423 * Makefile.in (CLEANFILES): Add `po/*.mo'.
424 (LINGUAS): New variable.
425 (all-local): Add `$(foreach lang, $(LINGUAS), po/$(lang).mo)'.
426 (install-local): Install MO files.
427 (po/$(PACKAGE).pot, po/*.po, po/%.mo): New rules.
428 * include/grub/i18n.h: New file.
769ae37b
RM
429 * util/grub.d/10_linux.in (bindir): New variable.
430 Add gettext initialization.
431 (linux_entry): Make menuentry output translatable.
432 * util/i386/pc/grub-mkimage.c: Include `<grub/i18n.h>'.
433 (usage): Make --help output translatable.
434 (main): Initialize gettext.
435
02c0a6ad
RM
4362009-11-17 Robert Millan <rmh.grub@aybabtu.com>
437
438 * import_gcry.py: New file (written by Vladimir with minor
439 adjustments).
440 * autogen.sh: Use import_gcry.py to auto-generate GRUB-ified
441 ciphers.
442 * INSTALL: Document that Python is required for bootstrap.
443
4442009-11-17 Robert Millan <rmh.grub@aybabtu.com>
445
446 Import ciphers from libgcrypt 1.4.4.
447
448 * lib/libgcrypt/cipher/ChangeLog
449 * lib/libgcrypt/cipher/ac.c
450 * lib/libgcrypt/cipher/arcfour.c
451 * lib/libgcrypt/cipher/bithelp.h
452 * lib/libgcrypt/cipher/blowfish.c
453 * lib/libgcrypt/cipher/camellia-glue.c
454 * lib/libgcrypt/cipher/camellia.c
455 * lib/libgcrypt/cipher/camellia.h
456 * lib/libgcrypt/cipher/cast5.c
457 * lib/libgcrypt/cipher/cipher.c
458 * lib/libgcrypt/cipher/crc.c
459 * lib/libgcrypt/cipher/des.c
460 * lib/libgcrypt/cipher/dsa.c
461 * lib/libgcrypt/cipher/ecc.c
462 * lib/libgcrypt/cipher/elgamal.c
463 * lib/libgcrypt/cipher/hash-common.c
464 * lib/libgcrypt/cipher/hash-common.h
465 * lib/libgcrypt/cipher/hmac-tests.c
466 * lib/libgcrypt/cipher/md.c
467 * lib/libgcrypt/cipher/md4.c
468 * lib/libgcrypt/cipher/md5.c
469 * lib/libgcrypt/cipher/primegen.c
470 * lib/libgcrypt/cipher/pubkey.c
471 * lib/libgcrypt/cipher/rfc2268.c
472 * lib/libgcrypt/cipher/rijndael-tables.h
473 * lib/libgcrypt/cipher/rijndael.c
474 * lib/libgcrypt/cipher/rmd.h
475 * lib/libgcrypt/cipher/rmd160.c
476 * lib/libgcrypt/cipher/rsa.c
477 * lib/libgcrypt/cipher/seed.c
478 * lib/libgcrypt/cipher/serpent.c
479 * lib/libgcrypt/cipher/sha1.c
480 * lib/libgcrypt/cipher/sha256.c
481 * lib/libgcrypt/cipher/sha512.c
482 * lib/libgcrypt/cipher/tiger.c
483 * lib/libgcrypt/cipher/twofish.c
484 * lib/libgcrypt/cipher/whirlpool.c
485
af2f93ac
RM
4862009-11-16 Robert Millan <rmh.grub@aybabtu.com>
487
488 Fix build for systems without error().
489
490 * gnulib/error.c: New file (imported from Gnulib).
491 * gnulib/error.h: Likewise.
492 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/error.c'.
493 * util/mkisofs/mkisofs.c (program_name): Remove `static' qualifier
494 (this variable is now used by error()).
495
73fb3dd5
FZ
4962009-11-16 Felix Zielcke <fzielcke@z-51.de>
497
814f5e96
FZ
498 * util/mkisofs/name.c (iso9660_file_length): Use isascii macro
499 instead of relying that char is signed.
73fb3dd5 500
a691ca33
VS
5012009-11-16 Vladimir Serbinenko <phcoder@gmail.com>
502
503 * fs/i386/pc/pxe.c (grub_pxefs_open): Correctly handle PXE choosing
504 blocksize different from specified.
505 (grub_pxefs_read): Likewise.
506
2af8f0f4
FZ
5072009-11-16 Felix Zielcke <fzielcke@z-51.de>
508
509 Enable ata.mod on x86_64-efi, i386-efi and i386-ieee1275.
510
511 * disk/ata.c (grub_ata_dumpinfo): Add a cast.
512 (grub_ata_readwrite): Likewise. Update 2 format strings.
513 (grub_atapi_read): Likewise.
514
515 * conf/i386-coreboot.rmk (pkglib_MODULES): Move `ata.mod' from here ...
516 * conf/i386.rmk (pkglib_MODULES): ... to here ...
517 * conf/x86_64-efi.rmk (pkglib_MODULES): ... and here.
518 * conf/i386-coreboot.rmk (ata_mod_SOURCES, ata_mod_CFLAGS)
519 (ata_mod_LDFLAGS): Move from here ...
520 * conf/i386.rmk: ... to here ...
521 * conf/x86_64-efi.rmk: ... and here.
522 * conf/i386-pc.rmk (pkglib_MODULES): Remove `ata.mod'
523 (ata_mod_SOURCES, ata_mod_CFLAGS, ata_mod_LDFLAGS): Remove.
524
83bdecaf
RM
5252009-11-16 Robert Millan <rmh.grub@aybabtu.com>
526
527 Relicense multiboot.h, with RMS' blessing.
528
529 * include/multiboot.h: Change to X11 license.
530
fd6fd3d7
RM
5312009-11-15 Robert Millan <rmh.grub@aybabtu.com>
532
533 Support --version in grub-mkisofs.
534
535 * util/mkisofs/mkisofs.c (rcsid): Remove variable.
536 (OPTION_VERSION): New macro.
537 (ld_options): Recognize --version.
538 (usage): Move `program_name' from here ...
539 (program_name): ... to here. Add `static' qualifier.
540 (main): Recognize `OPTION_VERSION'.
541
16a88c49
FZ
5422009-11-15 Felix Zielcke <fzielcke@z-51.de>
543
544 * Makefile.in (TARGET_CPPFLAGS): Replace `-isystem=$(srcdir)/include'
545 with `-nostdinc -isystem $(shell $(TARGET_CC) -print-file-name=include)'.
546
a4158476
RM
5472009-11-14 Robert Millan <rmh.grub@aybabtu.com>
548
549 Fix help2man generation for mkisofs.
550
551 * util/mkisofs/mkisofs.c (ld_options): Recognize --help.
552 (usage): Send output to stdout (rather than stderr).
553
fc2208b0
RM
5542009-11-14 Robert Millan <rmh.grub@aybabtu.com>
555
556 * conf/i386-coreboot.rmk (grub_mkrescue_SOURCES): Replace
557 `util/i386/coreboot/grub-mkrescue.in' with `util/grub-mkrescue.in'.
558 * conf/i386-pc.rmk (grub_mkrescue_SOURCES): Replace
559 `util/i386/pc/grub-mkrescue.in' with `util/grub-mkrescue.in'.
560 (bin_SCRIPTS): Add `grub-mkfloppy'.
561 (grub_mkfloppy_SOURCES): New variable.
562
563 * util/grub-mkrescue.in: New file.
564 * util/i386/pc/grub-mkfloppy.in: New file.
565
566 * util/i386/coreboot/grub-mkrescue.in: Remove.
567 * util/i386/pc/grub-mkrescue.in: Remove.
568
8d0edf4a
RM
5692009-11-13 Robert Millan <rmh.grub@aybabtu.com>
570
571 * include/grub/multiboot.h (struct grub_multiboot_header): Move
572 from here ...
573 * include/multiboot.h (struct multiboot_header): ... to here. Update
574 all users.
575 * include/grub/multiboot.h (struct grub_multiboot_info): Move
576 from here ...
577 * include/multiboot.h (struct multiboot_info): ... to here. Update
578 all users.
579 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): Move
580 from here ...
581 * include/multiboot.h (struct multiboot_mmap_entry): ... to here.
582 Update all users.
583 * include/grub/multiboot.h (struct grub_mod_list): Move
584 from here ...
585 * include/multiboot.h (struct multiboot_mod_list): ... to here.
586 Update all users.
587
a73f5969
RM
5882009-11-13 Robert Millan <rmh.grub@aybabtu.com>
589
590 * include/multiboot2.h (multiboot_word): Rename from this ...
591 (multiboot2_word): ... to this. Update all users.
592 (multiboot_header): Rename from this ...
593 (multiboot2_header): ... to this. Update all users.
594 (multiboot_tag_header): Rename from this ...
595 (multiboot2_tag_header): ... to this. Update all users.
596 (multiboot_tag_start): Rename from this ...
597 (multiboot2_tag_start): ... to this. Update all users.
598 (multiboot_tag_name): Rename from this ...
599 (multiboot2_tag_name): ... to this. Update all users.
600 (multiboot_tag_module): Rename from this ...
601 (multiboot2_tag_module): ... to this. Update all users.
602 (multiboot_tag_memory): Rename from this ...
603 (multiboot2_tag_memory): ... to this. Update all users.
604 (multiboot_tag_unused): Rename from this ...
605 (multiboot2_tag_unused): ... to this. Update all users.
606 (multiboot_tag_end): Rename from this ...
607 (multiboot2_tag_end): ... to this. Update all users.
608
1c8927f0
RM
6092009-11-13 Robert Millan <rmh.grub@aybabtu.com>
610
611 Disable Multiboot2 in i386-ieee1275. It didn't actually work, and on
612 this platform we should support Multiboot1 first.
613
614 * conf/i386-ieee1275.rmk (pkglib_MODULES): Remove `multiboot.mod'.
615 (multiboot_mod_SOURCES, multiboot_mod_CFLAGS)
616 (multiboot_mod_LDFLAGS, multiboot_mod_ASFLAGS): Remove.
617
6e1e0d89
RM
6182009-11-12 Robert Millan <rmh.grub@aybabtu.com>
619
620 * util/mkisofs/eltorito.c (init_boot_catalog): Handle return code
621 of write calls (converting them to fwrite() if they aren't already).
622 (get_torito_desc): Likewise.
623 * util/mkisofs/rock.c (generate_rock_ridge_attributes): Likewise.
624
7f2b34d8
RM
6252009-11-12 Robert Millan <rmh.grub@aybabtu.com>
626
627 * util/i386/pc/grub-install.in: Move from here ...
628 * util/grub-install.in: ... to here. Update all users.
629
c0ef3311
CW
6302009-11-11 Colin Watson <cjwatson@ubuntu.com>
631
632 * util/powerpc/ieee1275/grub-mkrescue.in: Fix --version output.
633
e1f240ff
RM
6342009-11-11 Robert Millan <rmh.grub@aybabtu.com>
635
636 Support for El Torito without floppy emulation.
637
638 * util/mkisofs/eltorito.c: Include `<errno.h>'.
639 (init_boot_catalog): Improve error handling.
640 (get_torito_desc): Don't use floppy emulation unless requested by
641 user. Patch boot information table when requested via
642 `-boot-info-table'.
643 * util/mkisofs/iso9660.h (struct eltorito_boot_info): New struct.
644 * util/mkisofs/mkisofs.c (use_eltorito_emul_floppy)
645 (use_boot_info_table): New variables.
646 (OPTION_BOOT_INFO_TABLE, OPTION_NO_EMUL_BOOT)
647 (OPTION_ELTORITO_EMUL_FLOPPY): New macros.
648 (ld_options): Handle `-boot-info-table', `-no-emul-boot' and
649 `--eltorito-emul-floppy'.
650 (main): Handle `OPTION_BOOT_INFO_TABLE', `OPTION_NO_EMUL_BOOT'
651 and `OPTION_ELTORITO_EMUL_FLOPPY'.
652 * util/mkisofs/mkisofs.h (use_eltorito_emul_floppy)
653 (use_boot_info_table, get_731): New prototypes.
654 * util/mkisofs/write.c (get_731): New function.
655
af7d4de5
FZ
6562009-11-11 Felix Zielcke <fzielcke@z-51.de>
657
658 Fix the generation of the man page.
659
660 * util/pc/i386/grub-install.in: Source
661 `${libdir}/grub/grub-mkconfig_lib' after options have been parsed.
662
2c55dbc0
RM
6632009-11-11 Robert Millan <rmh.grub@aybabtu.com>
664
665 Large file support for grub-mkisofs.
666
667 * conf/common.rmk (grub_mkisofs_CFLAGS): Add `-D_FILE_OFFSET_BITS=64'.
668 * util/mkisofs/mkisofs.c (next_extent, last_extent)
669 (session_start): Upgrade type to `uint64_t'. Update all users.
670 * util/mkisofs/mkisofs.h: Include `<stdint.h>'.
671 (struct directory_entry): Upgrade type of `starting_block' and
672 `size' to `uint64_t'. Update all users.
673 (struct deferred): Remove unused structure.
674 (xfwrite): Upgrade type of `count' and `size' to `uint64_t'.
675 Update all users.
676 * util/mkisofs/tree.c (stat_filter, lstat_filter): Return -1 when
677 file is larger than `UINT32_MAX'.
678 * util/mkisofs/write.c (xfwrite): Upgrade type of `count' and
679 `size' to `uint64_t'. Update all users. Fix handling of fwrite()
680 return value.
681 (struct deferred_write): Upgrade type of `extent' and `size' to
682 `uint64_t'. Update all users.
683 (last_extent_written): Upgrade type to `uint64_t'. Update all
684 users.
685 (write_one_file): Upgrade type of `count' and `size' to `uint64_t'.
686 Update all users. Upgrade type of `remain' to `int64_t' and
687 `use' to `size_t'. Use error() to handle fread() errors.
688 (write_files): Rely on write_one_file() rather than calling
689 xfwrite() directly.
690
6a9cead5
FZ
6912009-11-09 Felix Zielcke <fzielcke@z-51.de>
692
693 * util/mkisofs/mkisofs.c (ld_options): Fix a spelling mistake.
694
4825d790
RM
6952009-11-09 Robert Millan <rmh.grub@aybabtu.com>
696
697 * util/mkisofs/fnmatch.c: Remove.
698 * util/mkisofs/getopt1.c: Likewise.
699 * util/mkisofs/getopt.c: Likewise.
700 * conf/common.rmk (grub_mkisofs_SOURCES): Replace
701 `util/mkisofs/fnmatch.c', `util/mkisofs/getopt1.c' and
702 `util/mkisofs/getopt.c' with `gnulib/fnmatch.c',
703 `gnulib/getopt1.c' and `gnulib/getopt.c'.
704 (grub_mkisofs_CFLAGS): Add `-I$(srcdir)/gnulib'.
705
706 * configure.ac: Detect `mingw32msvc' host_os.
707 Check for lstat(), getuid() and getgid().
708
709 * util/mkisofs/joliet.c: Include `<stdint.h>'. Replace all
710 instances of `u_char' with `uint8_t'.
711
712 * util/mkisofs/mkisofs.h: Include `<sys/stat.h>'.
713 [!HAVE_GETUID] (getuid): New function (stub).
714 [!HAVE_GETGID] (getgid): Likewise.
715 [!HAVE_LSTAT] (lstat): Likewise.
716 [!S_IROTH] (S_IROTH): New macro (dummy).
717 [!S_IRGRP] (S_IRGRP): Likewise.
718
84b860d8
RM
7192009-11-09 Robert Millan <rmh.grub@aybabtu.com>
720
721 * gnulib/fnmatch_loop.c (EXT): Fix warning (signed and unsigned type in
722 conditional expression).
723
66e9b712
RM
7242009-11-09 Robert Millan <rmh.grub@aybabtu.com>
725
726 Import from Gnulib.
727
728 * gnulib/fnmatch.c: New file.
729 * gnulib/fnmatch.h: Likewise.
730 * gnulib/fnmatch_loop.c: Likewise.
731 * gnulib/getopt.c: Likewise.
732 * gnulib/getopt.h: Likewise.
733 * gnulib/getopt1.c: Likewise.
734 * gnulib/getopt_int.h: Likewise.
735 * gnulib/gettext.h: Likewise.
736
34f4a5b0
RM
7372009-11-09 Robert Millan <rmh.grub@aybabtu.com>
738
739 * normal/dyncmd.c (read_command_list): Replace `0' with `NULL'.
740 * normal/handler.c (read_handler_list): Likewise.
741
ac451143
RM
7422009-11-09 Robert Millan <rmh.grub@aybabtu.com>
743
744 Misc cleanup.
745
746 * kern/command.c (grub_register_command_prio): Use
747 grub_zalloc() instead of explicitly zeroing data.
748 * kern/list.c: Include `<grub/mm.h>'.
749 (grub_named_list_find): Replace `0' with `NULL'.
750 * normal/autofs.c (struct grub_fs_module_list): Remove ad-hoc type.
751 (fs_module_list): Change type to `grub_named_list_t'. Update all
752 users.
753 * normal/dyncmd.c (read_command_list): Add space between function
754 call and parenthesis.
755 * normal/handler.c (read_handler_list): Likewise.
756
4089b167
RM
7572009-11-09 Robert Millan <rmh.grub@aybabtu.com>
758
759 * normal/auth.c (punishment_delay): Moved from here ...
760 (grub_auth_strcmp): ... to here (inside function).
761
325f5037
RM
7622009-11-09 Robert Millan <rmh.grub@aybabtu.com>
763
764 * include/grub/list.h (struct grub_named_list): Remove `const'
765 qualifier from `name'.
766 (struct grub_prio_list): Likewise.
767
7aea29a3
RM
7682009-11-09 Robert Millan <rmh.grub@aybabtu.com>
769
770 * normal/auth.c: Include `<grub/time.h>'.
771 (grub_auth_strcmp): Replace `strcmp' with `grub_strcmp'.
772
3fd6f044
RM
7732009-11-09 Robert Millan <rmh.grub@aybabtu.com>
774
775 * normal/auth.c (punishment_delay): New variable.
776 (grub_auth_strcmp): Rewrite using grub_get_time_ms ().
777 (grub_auth_check_authentication): Punish failed login attempts with
778 an incremental (2^N) delay.
779
a4cd68e4
RM
7802009-11-09 Robert Millan <rmh.grub@aybabtu.com>
781
782 * conf/common.rmk (grub_mkisofs_CFLAGS): Prefix include
783 path with $(srcdir).
784
7ad12f43
VS
7852009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
786
787 * normal/auth.c (grub_auth_strcmp): Fixed incorrect variable usage.
788
c1129f03
RM
7892009-11-09 Robert Millan <rmh.grub@aybabtu.com>
790
791 * util/i386/coreboot/grub-mkrescue.in: New file.
792 * conf/i386-coreboot.rmk (bin_SCRIPTS, grub_mkrescue_SOURCES): New
793 variables.
794
795 * conf/common.rmk (bin_UTILITIES): Add `grub-mkisofs'.
796 (grub_mkisofs_SOURCES, grub_mkisofs_CFLAGS): New variables.
797 * configure.ac: Add header and function checks to satisfy grub-mkisofs
798 requirements.
799 * util/mkisofs/defaults.h: New file.
800 * util/mkisofs/eltorito.c: Likewise.
801 * util/mkisofs/exclude.h: Likewise.
802 * util/mkisofs/fnmatch.c: Likewise.
803 * util/mkisofs/getopt.c: Likewise.
804 * util/mkisofs/getopt1.c: Likewise.
805 * util/mkisofs/hash.c: Likewise.
806 * util/mkisofs/include/fctldefs.h: Likewise.
807 * util/mkisofs/include/mconfig.h: Likewise.
808 * util/mkisofs/include/prototyp.h: Likewise.
809 * util/mkisofs/include/statdefs.h: Likewise.
810 * util/mkisofs/iso9660.h: Likewise.
811 * util/mkisofs/joliet.c: Likewise.
812 * util/mkisofs/match.c: Likewise.
813 * util/mkisofs/match.h: Likewise.
814 * util/mkisofs/mkisofs.c: Likewise.
815 * util/mkisofs/mkisofs.h: Likewise.
816 * util/mkisofs/multi.c: Likewise.
817 * util/mkisofs/name.c: Likewise.
818 * util/mkisofs/rock.c: Likewise.
819 * util/mkisofs/tree.c: Likewise.
820 * util/mkisofs/write.c: Likewise.
821
ec8bb77d
VS
8222009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
823
824 * normal/auth.c (grub_auth_strcmp): Fix bug which resulted in function
825 being insecure.
826
3716b12c
RM
8272009-11-08 Robert Millan <rmh.grub@aybabtu.com>
828
829 * util/i386/pc/grub-mkrescue.in: Fix miss-identification as
830 `grub-mkimage' (and use $0 when possible).
831
b97b7b91
RM
8322009-11-08 Robert Millan <rmh.grub@aybabtu.com>
833
834 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve
835 error message for excessively large memory map.
836
04114812
RM
8372009-11-08 Robert Millan <rmh.grub@aybabtu.com>
838
839 * autogen.sh: Use `sh gendistlist.sh' to avoid reliing on
840 executable bit.
841
e4eb2373
RM
8422009-11-08 Robert Millan <rmh.grub@aybabtu.com>
843
844 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve error
845 message for coreboot users.
846
c926e1d5 8472009-11-07 Robert Millan <rmh.grub@aybabtu.com>
848
849 Fix build with GNU gold.
850
851 * conf/i386-pc.rmk (boot_img_LDFLAGS, pxeboot_img_LDFLAGS)
852 (diskboot_img_LDFLAGS, lnxboot_img_LDFLAGS)
853 (cdboot_img_LDFLAGS): Prepend `0x' qualifier to hexadecimal
854 link addresses.
855 * aclocal.m4: Likewise.
856
86e5b1db 8572009-11-04 Felix Zielcke <fzielcke@z-51.de>
858
859 * configure.ac (AC_PREREQ): Bump to 2.59d.
860 * INSTALL: Make it more clear when Autoconf and Ruby are
861 needed and when to run `./autogen.sh'.
862
246cd78f 8632009-11-03 Samuel Thibault <samuel.thibault@ens-lyon.org>
864
865 * util/grub.d/30_os-prober.in: Restore default behavior for unsupported
866 OSes.
867
4f9dfb37 8682009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
869
870 * util/grub.d/30_os-prober.in: Add GNU/Hurd support
871
b82bd5e1 8722009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
873
874 * util/grub.d/10_hurd.in: Drop /dev/ prefix from root device path before
875 giving it to GNU Mach.
876
ff1a9bca 8772009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
878
879 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Subtract 1 from
880 GNU partition number to get internal GRUB partition number.
881
61697d9c 8822009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
883
884 * util/grub.d/10_hurd.in: Call prepare_grub_to_access_device
885 ${GRUB_DEVICE_BOOT} before loading /boot kernel.
886
a50569e1 8872009-11-01 Robert Millan <rmh.grub@aybabtu.com>
888
889 Based on patch from BVK Chaitanya <bvk.groups@gmail.com>
890 * kern/misc.c (grub_strchr, grub_strrchr): Fix to handle c == '\0'
891 case.
892
5b153867 8932009-11-01 Felix Zielcke <fzielcke@z-51.de>
894
895 * Makefile.in (TARGET_CPPFLAGS): Add `-I$(srcdir)/include'.
896
d9e2cd70 8972009-10-30 Robert Millan <rmh.grub@aybabtu.com>
898
899 Fix build problem.
900
901 * Makefile.in (TARGET_CPPFLAGS): Replace `-nostdinc' with
902 `-isystem=$(srcdir)/include'.
903
805111a4 9042009-10-30 Robert Millan <rmh.grub@aybabtu.com>
905
906 * util/i386/pc/grub-install.in: Remove hint that device.map should be
907 checked (grub-install doesn't currently rely on it).
908
fa6e945f 9092009-10-29 Robert Millan <rmh.grub@aybabtu.com>
910
911 Revert SVN r2660.
912
913 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): Moved from here ...
914 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
915 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): ... and here.
916 * conf/i386-ieee1275.rmk: Likewise.
917 * conf/i386-pc.rmk: Likewise.
918 * conf/powerpc-ieee1275.rmk: Likewise.
919 * conf/sparc64-ieee1275.rmk: Likewise.
920 * conf/x86_64-efi.rmk: Likewise.
921
cee15086 9222009-10-28 Robert Millan <rmh.grub@aybabtu.com>
923
924 * Makefile.in (TARGET_CPPFLAGS): Add `-nostdinc'.
925
95b9239e 9262009-10-28 Robert Millan <rmh.grub@aybabtu.com>
927
928 * include/grub/misc.h: Stop checking for APPLE_CC.
929
2ed19dfd 9302009-10-28 Robert Millan <rmh.grub@aybabtu.com>
931
932 * kern/i386/coreboot/init.c (grub_exit): Reimplement in a way that
933 doesn't cause an infinite call loop.
934
fdcdde19 9352009-10-28 Felix Zielcke <fzielcke@z-51.de>
936
937 * commands/acpi.c (grub_cmd_acpi): Fix the out of memory error
938 strings.
939
cefabfe1 9402009-10-26 Robert Millan <rmh.grub@aybabtu.com>
941
942 * autogen.sh: Support addition of external modules via `GRUB_CONTRIB'
943 variable.
944 * Makefile.in: Likewise.
945
ed96ab6d 9462009-10-26 Robert Millan <rmh.grub@aybabtu.com>
947
948 * gendistlist.sh: Simplify .svn check. Skip .bzr as well.
949
0579b753 9502009-10-26 Robert Millan <rmh.grub@aybabtu.com>
951
952 * Makefile.in (RMKFILES): Rewrite using $(wildcard).
953
478df409 9542009-10-26 Robert Millan <rmh.grub@aybabtu.com>
955
956 * disk/scsi.c: Remove `<grub/machine/kernel.h>' (not needed).
957
083d1679 9582009-10-26 Robert Millan <rmh.grub@aybabtu.com>
959
960 * gensymlist.sh.in (COMPILE_TIME_ASSERT): Copy macro declaration
961 from here ...
962 * include/grub/misc.h (COMPILE_TIME_ASSERT): ... to here.
963
5947ae32 9642009-10-26 Robert Millan <rmh.grub@aybabtu.com>
965
966 * Makefile.in (docs/grub.info): Use make syntax to ignore errors
967 in $(MAKEINFO) invocation. This makes it clear in output that
968 errors are being ignored.
969
94180ff6 9702009-10-26 Robert Millan <rmh.grub@aybabtu.com>
971
972 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): Moved
973 from here ...
974 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
975 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): Remove.
976 * conf/i386-ieee1275.rmk: Likewise.
977 * conf/i386-pc.rmk: Likewise.
978 * conf/powerpc-ieee1275.rmk: Likewise.
979 * conf/sparc64-ieee1275.rmk: Likewise.
980 * conf/x86_64-efi.rmk: Likewise.
981
9031b03a 9822009-10-26 Colin Watson <cjwatson@ubuntu.com>
983
984 * util/grub-editenv.c (main): If only a command is given, use
985 DEFAULT_DIRECTORY "/" GRUB_ENVBLK_DEFCFG as a default file name.
986 (usage): FILENAME is now optional and has a default.
987
e4f6809b 9882009-10-26 Colin Watson <cjwatson@ubuntu.com>
989
990 Improve grub-mkconfig performance when there are several menu
991 entries on a single filesystem.
992
993 * util/grub.d/10_linux.in (linux_entry): Cache the output of
994 prepare_grub_to_access_device.
995 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
996 * util/grub.d/30_os-prober.in: Likewise.
997
67937d4d 9982009-10-26 Robert Millan <rmh.grub@aybabtu.com>
999
1000 * util/grub.d/10_freebsd.in: Remove.
1001 * util/grub.d/10_kfreebsd.in: New file (based on 10_linux.in).
1002 * configure.ac: Set host_kernel=kfreebsd for FreeBSD and GNU/kFreeBSD.
1003
ee3756cc 10042009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1005
5c35048e 1006 * docs/grub.cfg: Fix example usage of *BSD loaders.
ee3756cc 1007
4dea1c6f 10082009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1009
1010 * util/i386/pc/grub-setup.c (setup): Add missing parameter to
1011 grub_util_error() call.
1012
042484d7 10132009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1014
1015 * include/grub/fs.h [GRUB_UTIL] (struct grub_fs): Add
1016 `reserved_first_sector' member.
1017 * fs/ext2.c [GRUB_UTIL] (grub_ext2_fs): Initialize
1018 `reserved_first_sector' to 1.
1019 * fs/fat.c [GRUB_UTIL] (grub_fat_fs): Likewise.
1020 * fs/ntfs.c [GRUB_UTIL] (grub_ntfs_fs): Likewise.
1021 * fs/hfsplus.c [GRUB_UTIL] (grub_hfsplus_fs): Likewise.
1022 * util/i386/pc/grub-setup.c (setup): Add safety check that probes for
1023 filesystems which begin at first sector.
1024 (options): New option --skip-fs-probe.
1025 (main): Handle --skip-fs-probe and pass it to setup().
1026
d64448a7 10272009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1028
1029 * include/grub/misc.h: Fix wrong evaluation of APPLE_CC.
1030 (memset): Fix function prototype.
1031
508d42ec 10322009-10-25 Robert Millan <rmh.grub@aybabtu.com>
10332009-10-25 Vasily Averin <vvs@parallels.com>
1034
1035 * fs/ext2.c (grub_ext2_iterate_dir): Avoid infinite loop when
1036 `dirent.direntlen == 0'.
1037
b240e30c 10382009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1039
1040 * fs/cpio.c [MODE_USTAR]: Initialize `tar' module instead of
1041 `cpio'.
1042 [! MODE_USTAR]: Initialize `cpio' module instead of `tar'.
1043
346e7fbe 10442009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1045
1046 * configure.ac: Check for `__ashldi3', `__ashrdi3', `__lshrdi3',
1047 `__trampoline_setup' and `__ucmpdi2'.
1048 * include/grub/powerpc/libgcc.h: Only export symbols for functions
1049 that libgcc provides.
1050
cdb308b0 10512009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1052
1053 * include/grub/powerpc/libgcc.h (memset): Remove function prototype.
1054 * include/grub/sparc64/libgcc.h (memset): Likewise.
1055 * include/grub/misc.h (memset, memcmp): New function prototypes.
1056
fb26abc2 10572009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1058
1059 * fs/cpio.c [MODE_USTAR]: Finish `tar' module instead of
1060 `cpio'.
1061 [! MODE_USTAR]: Finish `cpio' module instead of `tar'.
1062
f6693890 10632009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1064
1065 Patch from Samuel Thibault <samuel.thibault@ens-lyon.org>
1066 * docs/grub.cfg: Compensate for recent change in multiboot
1067 loader (since 2009-08-14 it won't pass filename to payload).
1068 * util/grub.d/10_hurd.in: Likewise.
1069
0933cdc0 10702009-10-21 Felix Zielcke <fzielcke@z-51.de>
1071
1072 * config.guess: Update to latest version from config git
1073 repository.
1074 * config.sub: Likewise.
1075
3b2fe8c2 10762009-10-20 Robert Millan <rmh.grub@aybabtu.com>
1077
1078 Fix build on sparc64.
1079
1080 * configure.ac: Perform checks for libgcc symbols before
1081 adding `-nostdlib' to LDFLAGS.
1082
46695a62 10832009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1084
1085 Let user specify OpenBSD root device.
1086
1087 * loader/i386/bsd.c (openbsd_root): New variable.
1088 (openbsd_opts): New option 'root'.
1089 (OPENBSD_ROOT_ARG): New macro.
1090 (grub_openbsd_boot): Use 'openbsd_root'.
1091 (grub_cmd_openbsd): Fill 'openbsd_root'.
1092
d2b6b7fc 10932009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1094
1095 * NEWS: Misc adjustments.
1096
421bd7ac 10972009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1098
1099 * NEWS: Mentioned XNU, ACPI, gptsync, password and parttool.
1100
f1d29d87 11012009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1102
1103 * configure.ac: Bump version to 1.97.
1104
6f3cd880 11052009-10-16 Colin Watson <cjwatson@ubuntu.com>
1106
1107 * configure.ac (TARGET_CFLAGS): Add -mno-mmx -mno-sse -mno-sse2
1108 -mno-3dnow on x86 architectures. Some toolchains enable these
1109 features by default, but they rely on registers that aren't enabled
1110 in GRUB. Thanks to Vladimir Serbinenko for the suggestion.
1111
035f7122 11122009-10-15 Robert Millan <rmh.grub@aybabtu.com>
1113
1114 Make entry text a bit more readable.
1115
1116 * util/grub.d/10_linux.in: Add `with' before `Linux'.
1117
44998e58 11182009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1119
1120 * loader/i386/pc/xnu.c (grub_xnu_set_video): Fix loading splash image.
1121
cd2851b3 11222009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1123
1124 * commands/xnu_uuid.c (grub_cmd_xnu_uuid): Remove duplicated bitwise
1125 operations.
1126
c6f3b249 11272009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1128
1129 * configure.ac: Add missing dollar.
1130
6b5886ba 11312009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1132
1133 Revert 2009-06-10 Pavel Roskin <proski@gnu.org>
1134
1135 * configure.ac: Put checks for __bswapsi2 and __bswapdi2.
1136 * include/grub/powerpc/libgcc.h: Don't use weak attribute for all
1137 exports.
1138 * include/grub/sparc64/libgcc.h: Likewise. Use
1139 preprocessor conditionals.
1140
e9d66f6d 11412009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1142
1143 * conf/common.rmk (grub-dumpbios): Remove rule.
1144 (sbin_SCRIPTS, CLEANFILES): Remove `grub-dumpbios'.
1145 * util/grub-dumpbios.in: Remove file.
1146
9155bc17 11472009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1148
1149 Refer to kernel of FreeBSD "kFreeBSD" to avoid confusion between
1150 the Operating System (FreeBSD) and its kernel (kernel of FreeBSD).
1151
1152 * loader/i386/bsd.c (grub_freebsd_boot): Read kernel environment
1153 from "kFreeBSD" namespace (rather than "FreeBSD"). Update all
1154 users.
1155
1156 (GRUB_MOD_INIT (bsd)): Rename "freebsd" command to "kfreebsd",
1157 "openbsd" to "kopenbsd", "netbsd" to "knetbsd", "freebsd_loadenv"
1158 to "kfreebsd_loadenv", "freebsd_module" to "kfreebsd_module",
1159 and "freebsd_module_elf" to "kfreebsd_module_elf". Update all
1160 users.
1161
bf7f7a18 11622009-10-12 Robert Millan <rmh.grub@aybabtu.com>
1163
1164 * term/tparm.c: Switch to GPLv3.
1165
86564c26 11662009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1167
1168 * include/grub/i386/cpuid.h: Add header protection.
1169
5c936493 11702009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1171
1172 Fail gracefuly when attempting to load 64-bit kFreeBSD on IA32 CPU.
1173
1174 * include/grub/i386/cpuid.h: New file.
1175 * commands/i386/cpuid.c: Include `<grub/i386/cpuid.h>'.
1176 (has_longmode): Rename to ...
1177 (grub_cpuid_has_longmode): ... this. Update all users. Remove
1178 `static' attribute.
1179 * loader/i386/bsd.c: Include `<grub/i386/cpuid.h>'.
1180 (grub_bsd_load_elf): Fail if load of 64-bit kernel was requested
1181 on a CPU that doesn't implement AMD64 instruction set.
1182
186e7cf2 11832009-10-06 Colin Watson <cjwatson@ubuntu.com>
1184
1185 * Makefile.in (docs/stamp-vti): Depend on configure.ac as well, so
1186 that version.texi is rebuilt on version number changes.
1187
83b65c4a 11882009-10-06 Colin Watson <cjwatson@ubuntu.com>
1189
1190 * Makefile.in: Don't set info_INFOS unless makeinfo was found.
1191 Fixes bug #27602.
1192
d244281c 11932009-10-06 Colin Watson <cjwatson@ubuntu.com>
1194
1195 * util/i386/pc/grub-install.in: Source
1196 ${libdir}/grub/grub-mkconfig_lib before option processing, in order
1197 that the --grub-probe option will work.
1198 * util/sparc64/ieee1275/grub-install.in: Likewise.
1199
da25306d 12002009-10-05 Robert Millan <rmh.grub@aybabtu.com>
1201
1202 * configure.ac: Bump version to 1.97~beta4.
1203
e8ee83c0 12042009-10-03 Robert Millan <rmh.grub@aybabtu.com>
1205
1206 Resync grub-mkdevicemap in x86_64-efi.
1207
1208 * conf/x86_64-efi.rmk (sbin_UTILITIES): Enable `grub-mkdevicemap'.
1209 (grub_mkdevicemap_SOURCES): Add missing `util/deviceiter.c' and
1210 `util/devicemap.c'.
1211
50dcabcf 12122009-10-01 Colin Watson <cjwatson@ubuntu.com>
1213
1214 * util/grub-editenv.c (create_envblk_file): Write new block with a
1215 .new suffix and then rename it into place, to ensure atomic
1216 creation.
1217
0e51c3a7 12182009-09-28 Robert Millan <rmh.grub@aybabtu.com>
1219
1220 Do not automatically install headers.
1221
1222 * Makefile.in (include_DATA): Remove. Update all users.
1223
31299a95 12242009-09-26 Robert Millan <rmh.grub@aybabtu.com>
1225
1226 * conf/common.rmk (pkglib_MODULES): Remove `lua.mod'.
1227 (lua_mod_SOURCES, lua_mod_CFLAGS, lua_mod_LDFLAGS): Remove.
1228
1229 * util/osdetect.lua: Remove.
1230 * script/lua/lauxlib.c: Likewise.
1231 * script/lua/ldebug.c: Likewise.
1232 * script/lua/grub_main.c: Likewise.
1233 * script/lua/lauxlib.h: Likewise.
1234 * script/lua/ldebug.h: Likewise.
1235 * script/lua/ltablib.c: Likewise.
1236 * script/lua/liolib.c: Likewise.
1237 * script/lua/lstrlib.c: Likewise.
1238 * script/lua/lualib.h: Likewise.
1239 * script/lua/ldo.c: Likewise.
1240 * script/lua/ldump.c: Likewise.
1241 * script/lua/ldo.h: Likewise.
1242 * script/lua/loslib.c: Likewise.
1243 * script/lua/lundump.c: Likewise.
1244 * script/lua/grub_lib.c: Likewise.
1245 * script/lua/ldblib.c: Likewise.
1246 * script/lua/lundump.h: Likewise.
1247 * script/lua/lmem.c: Likewise.
1248 * script/lua/grub_lib.h: Likewise.
1249 * script/lua/lmathlib.c: Likewise.
1250 * script/lua/lstate.c: Likewise.
1251 * script/lua/ltm.c: Likewise.
1252 * script/lua/lvm.c: Likewise.
1253 * script/lua/lmem.h: Likewise.
1254 * script/lua/lstate.h: Likewise.
1255 * script/lua/ltm.h: Likewise.
1256 * script/lua/ltable.c: Likewise.
1257 * script/lua/lvm.h: Likewise.
1258 * script/lua/llex.c: Likewise.
1259 * script/lua/lgc.c: Likewise.
1260 * script/lua/grub_lua.h: Likewise.
1261 * script/lua/loadlib.c: Likewise.
1262 * script/lua/lfunc.c: Likewise.
1263 * script/lua/lopcodes.c: Likewise.
1264 * script/lua/lparser.c: Likewise.
1265 * script/lua/ltable.h: Likewise.
1266 * script/lua/llex.h: Likewise.
1267 * script/lua/lgc.h: Likewise.
1268 * script/lua/lfunc.h: Likewise.
1269 * script/lua/lbaselib.c: Likewise.
1270 * script/lua/lopcodes.h: Likewise.
1271 * script/lua/lparser.h: Likewise.
1272 * script/lua/lzio.c: Likewise.
1273 * script/lua/linit.c: Likewise.
1274 * script/lua/lobject.c: Likewise.
1275 * script/lua/llimits.h: Likewise.
1276 * script/lua/lstring.c: Likewise.
1277 * script/lua/lzio.h: Likewise.
1278 * script/lua/lapi.c: Likewise.
1279 * script/lua/lcode.c: Likewise.
1280 * script/lua/lua.h: Likewise.
1281 * script/lua/lobject.h: Likewise.
1282 * script/lua/lstring.h: Likewise.
1283 * script/lua/lapi.h: Likewise.
1284 * script/lua/lcode.h: Likewise.
1285 * script/lua/luaconf.h: Likewise.
1286
cb8a2c38 12872009-09-26 Colin Watson <cjwatson@ubuntu.com>
1288
1289 * docs/grub.texi (Command-line and menu entry commands): Document
1290 date and echo commands.
1291
6b9b6276 12922009-09-24 Pavel Roskin <proski@gnu.org>
1293
1294 * include/grub/kernel.h (struct grub_module_header): Remove
1295 `grub_module_header_types'. Make `type' unsigned. Make `size'
1296 32-bit on all platforms.
1297 * util/elf/grub-mkimage.c (load_modules): Treat `type' as an
1298 8-bit field. Use grub_host_to_target32() for `size'.
1299 * util/i386/efi/grub-mkimage.c (make_mods_section): Likewise.
1300 * util/i386/pc/grub-mkimage.c (generate_image): Likewise.
1301 * util/sparc64/ieee1275/grub-mkimage.c (generate_image): Likewise.
1302
4e5a02a7 13032009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1304
1305 Fix "lost keypress" bug in at_keyboard.
1306
1307 * term/i386/pc/at_keyboard.c (grub_at_keyboard_checkkey): New function.
1308 Checks for readyness of input buffer (without flushing it).
1309 (grub_at_keyboard_term): Use grub_at_keyboard_checkkey() rather
1310 than grub_at_keyboard_getkey_noblock() for `checkkey' struct member.
1311
c6dcedf6 13122009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1313
1314 * util/i386/pc/grub-mkimage.c (generate_image): Enclose BIOS-specific
1315 size check within GRUB_MACHINE_PCBIOS section.
1316
74c958b1 13172009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1318
1319 * include/grub/i386/at_keyboard.h (KEYBOARD_ISREADY): Negate
1320 return value.
1321 * term/i386/pc/at_keyboard.c (grub_keyboard_getkey): Negate
1322 KEYBOARD_ISREADY check.
1323 (grub_at_keyboard_checkkey): Rename to ...
1324 (grub_at_keyboard_getkey_noblock): ... this. Update all users.
1325 Remove gratuitous cast.
1326
ff420223 13272009-09-23 Colin Watson <cjwatson@ubuntu.com>
1328
1329 * configure.ac: Call AC_PROG_MKDIR_P.
1330 * Makefile.in (docs/stamp-vti): Create docs directory. Create
1331 version.texi in $(builddir) rather than $(srcdir).
1332 (docs/grub.info): Create docs directory. Prepend $(builddir)/docs
1333 to makeinfo's @include search path.
1334
d96875df 13352009-09-23 Felix Zielcke <fzielcke@z-51.de>
1336
1337 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Cope with `*.dpkg-*'
1338
9b3f8365 13392009-09-23 Felix Zielcke <fzielcke@z-51.de>
1340
1341 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Add support
1342 for `*.dpkg-new'.
1343
c44c90db 13442009-09-21 Colin Watson <cjwatson@ubuntu.com>
1345
1346 Build info documentation. Some code borrowed from Automake.
1347
1348 * configure.ac: Check for makeinfo.
1349 * Makefile.in (MAKEINFO, INFOS, info_INFOS): New variables.
1350 (MAINTAINER_CLEANFILES): Add $(INFOS), docs/stamp-vti, and
1351 docs/version.texi.
1352 (MOSTLYCLEANFILES): Add vti.tmp.
1353 (docs/version.texi, docs/stamp-vti): Update automatically.
1354 (docs/grub.info): Build info documentation. Use --force and ignore
1355 errors for now.
1356 (all-local): Add $(INFOS).
1357 (install-local): Install info files.
1358 (uninstall): Uninstall info files.
1359 * docs/version.texi: Remove from revision control. This file is
1360 automatically generated on build now.
1361 * gendistlist.sh: Add `*.info'.
1362
e0b37bb5 13632009-09-21 Felix Zielcke <fzielcke@z-51.de>
1364
1365 * kern/term.c: Fix indentation.
1366
5a78865b 13672009-09-21 Felix Zielcke <fzielcke@z-51.de>
1368
1369 * util/hostdisk.c: Fix a comment.
1370
dace7e8a 13712009-09-20 Robert Millan <rmh.grub@aybabtu.com>
1372
1373 Fix regression introduced in r2539.
1374
1375 * term/usb_keyboard.c (USB_HID_DEVICE_TO_HOST): Change from 0x61
1376 to 0xA1.
1377
a83d079b 13782009-09-19 Colin Watson <cjwatson@ubuntu.com>
1379
1380 * util/grub.d/30_os-prober.in: Don't throw away stderr from
4cbbccec 1381 os-prober. Under normal operation, it does not print anything to
1382 stderr; if it does, we need to debug it, and throwing away stderr
1383 makes that excessively difficult.
a83d079b 1384
be94a509 13852009-09-16 Vladimir Serbinenko <phcoder@gmail.com>
1386
1387 * mmap/mmap.c (grub_cmd_badram): Fix off-by-one error.
1388
63f745e8 13892009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1390
1391 * aclocal.m4 (AC_LANG_PROGRAM): New macro. Overrides stock
1392 AC_LANG_PROGRAM from autoconf.
1393 (grub_ASM_USCORE, grub_PROG_OBJCOPY_ABSOLUTE): Add missing
1394 prototypes (fixes warning).
1395
1396 * configure.ac: Add `-Werror' to TARGET_CFLAGS unless
1397 `--disable-werror' was used.
1398
bbb2a70f 13992009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1400
1401 * partmap/msdos.c (pc_partition_map_iterate): Fix possible use of
1402 uninitialized `lastaddr'.
1403
77c24f1d 14042009-09-15 Vladimir Serbinenko <phcoder@gmail.com>
1405
0f0b8c87 1406 * partmap/msdos.c (pc_partition_map_iterate): Detect and break loops.
77c24f1d 1407
07197f23 14082009-09-14 Colin Watson <cjwatson@ubuntu.com>
1409
1410 * commands/test.c (get_fileinfo): Return immediately if
1411 grub_fs_probe fails.
1412
dabf1798 14132009-09-14 José Martínez <xosemp@gmail.com>
1414
1415 * commands/acpi.c (grub_cmd_acpi): Fix loading ACPI tables from file.
1416
d52109a7 14172009-09-14 Colin Watson <cjwatson@ubuntu.com>
1418
1419 * util/grub.d/30_os-prober.in: Cope with Windows 7 in os-prober
1420 output.
1421
56532179 14222009-09-13 Robert Millan <rmh.grub@aybabtu.com>
1423
1424 * configure.ac: Remove --enable-grub-pe2elf. Only build
1425 grub-pe2elf when needed by the build system itself.
1426 * conf/common.rmk: Remove $(enable_grub_pe2elf) check.
1427
8ef070f5 14282009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1429
1430 * configure.ac: Bump version to 1.97~beta3.
1431 * docs/version.texi: Likewise.
1432
61229557 14332009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1434
1435 * video/i386/pc/vbe.c (grub_vbe_get_video_mode_info): Move packed
1436 mode special handling (grub_vbe_bios_set_dac_palette_width() call)
1437 from here ...
1438 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS]
1439 (grub_linux_setup_video): ... to here (with some adjustments).
1440
5c9f8d84 14412009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1442
1443 Fix memory corruption issue (spotted by Colin Watson).
1444
1445 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette): Fix bug
1446 causing returned size to be stored in an incorrect memory location.
1447 Fix use of uninitialized value when storing the returned size.
1448
e8f5d6e9 14492009-09-12 Yves Blusseau <blusseau@zetam.org>
1450
1451 Change clean rules to properly remove files
1452
1453 * genmk.rb: add new clean rules
1454 * Makefile.in (clean): add the new targets
1455 (mostlyclean): likewise
1456
cda2a409 14572009-09-11 Colin Watson <cjwatson@ubuntu.com>
1458
1459 * include/grub/ntfs.h (struct grub_fshelp_node): Change `size'
1460 to grub_uint64_t.
1461 * fs/ntfs.c (init_file): Understand 64-bit sizes for
1462 non-resident files.
1463
86695375 14642009-09-11 Colin Watson <cjwatson@ubuntu.com>
1465
1466 * configure.ac: Don't look for help2man when cross-compiling. Fixes
1467 part of bug #27349.
1468
8aa1541a 14692009-09-10 Felix Zielcke <fzielcke@z-51.de>
1470
1471 * util/grub-mkconfig.in: Make the created config mode 400 and
1472 print a warning if it fails.
1473
48d9bb0a 14742009-09-10 Robert Millan <rmh.grub@aybabtu.com>
1475
1476 * util/grub.d/40_custom.in: Ask user to type custom entries below
1477 comment, rather than below 'exec tail' line.
1478
3b0521be 14792009-09-10 Colin Watson <cjwatson@ubuntu.com>
1480
1481 * util/grub.d/40_custom.in: Make sure that the explanatory text is
1482 visible in grub.cfg.
1483
50051d55 14842009-09-10 Colin Watson <cjwatson@ubuntu.com>
1485
1486 * util/grub.d/40_custom.in: Make it a little clearer how to use this
1487 file.
1488
c0d34387 14892009-09-10 Felix Zielcke <fzielcke@z-51.de>
1490
1491 * docs/grub.cfg: Add an example menu entry for memtest86+.
1492
80a608f3 14932009-09-09 Felix Zielcke <fzielcke@z-51.de>
1494
a2094832 1495 * config.guess: Update to latest version from config git.
80a608f3 1496 * config.sub: Likewise.
1497
99423078 14982009-09-08 Colin Watson <cjwatson@ubuntu.com>
1499
1500 * script/sh/execute.c (grub_script_execute_cmdline): Set "?" in
1501 unknown-command case. Fixes bug #27320.
1502
44454e4c 15032009-09-08 Felix Zielcke <fzielcke@z-51.de>
1504
1505 * kern/rescue_parser.c (grub_rescue_parse_line): Only suggest to try
1506 `help' if the command exists.
1507
e30d87ad 15082009-09-06 Robert Millan <rmh.grub@aybabtu.com>
1509
1510 * INSTALL: Require GCC 4.1.3 or later.
1511
9a86f1ec 15122009-09-06 Yves Blusseau <blusseau@zetam.org>
1513
1514 * Makefile.in (RMKFILES): add i386-qemu.rmk
1515 (MAINTAINER_CLEANFILES): add $(srcdir)/DISTLIST $(srcdir)/config.h.in
1516 $(srcdir)/stamp-h.in
1517
7f26d466 15182009-09-05 Robert Millan <rmh.grub@aybabtu.com>
1519
1520 * util/grub-probe.c (probe): Comment out buggy codepath, which
1521 was unexpectedly enabled by Colin Watson's 2009-09-02 fix. This
1522 should be re-enabled after 1.97.
1523
3a613259 15242009-09-05 Felix Zielcke <fzielcke@z-51.de>
1525
1526 * gendistlist.sh: Add `grub-dumpdevtree' and `*.lua' to the list
1527 find searches for.
1528
197f76c7 15292009-09-04 Vladimir Serbinenko <phcoder@gmail.com>
1530
1531 * loader/i386/xnu.c (grub_cpu_xnu_fill_devicetree): Remove
1532 unnecessary calls to grub_error.
1533
70ba68ce 15342009-09-04 Colin Watson <cjwatson@ubuntu.com>
1535
1536 * NEWS: Mention `keystatus' and Unicode fonts.
1537
4ff0d7a4 15382009-09-04 Robert Millan <rmh.grub@aybabtu.com>
1539
1540 * configure.ac: Bump version to 1.97~beta2.
1541 * docs/version.texi: Likewise.
1542
77c55a87 15432009-09-03 Colin Watson <cjwatson@ubuntu.com>
1544
1545 * configure.ac: By default, GCC 4.4 generates .eh_frame sections
1546 containing unwind information in some cases where it previously did
1547 not. Use -fno-dwarf2-cfi-asm if available to restore the old
1548 behaviour. See http://patchwork.kernel.org/patch/8555/ for related
1549 discussion.
1550
f79572cd 15512009-09-02 Yves BLUSSEAU <blusseau@zetam.org>
1552
1553 Embedding loadenv module into grub-emu
1554
1555 * conf/i386-pc.rmk (grub_emu_SOURCES): add lib/envblk.c and
1556 commands/loadenv.c
1557 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise
1558 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise
1559 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise
1560 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise
1561 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise
1562 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise
1563
93a81088 15642009-09-03 Magnus Granberg <zorry@ume.nu>
1565
1566 * aclocal.m4: Add grub_CHECK_PIE. It check if the compiler
1567 include -fPIE in the default specs.
1568 * configure.ac: Check if pie_possible is yes and add -fno-PIE
1569 to TARGET_CFLAGS.
1570
160034b2 15712009-09-03 Felix Zielcke <fzielcke@z-51.de>
1572
1573 * INSTALL: Note that GNU Bison 2.3 or later is required.
1574
087c07c4 15752009-09-03 Colin Watson <cjwatson@ubuntu.com>
1576
1577 * kern/i386/pc/startup.S: Fix typo.
1578
cbf978c0 15792009-09-02 Vladimir Serbinenko <phcoder@gmail.com>
1580
1581 * efiemu/loadcore.c (SUFFIX (grub_efiemu_loadcore_load)): Fix style
1582 according to GCS.
1583
15842009-09-02 Colin Watson <cjwatson@ubuntu.com>
f0910644 1585
1586 * docs/grub.texi (Naming convention): Describe one-based partition
1587 numbering.
1588 (Device syntax): Likewise.
1589 (File name syntax): Likewise.
1590 (Block list syntax): Likewise.
1591 (Making a GRUB bootable CD-ROM): Talk about grub.cfg rather than
1592 menu.lst.
1593 (File name syntax): Likewise.
1594 (Command-line and menu entry commands): Document acpi, blocklist,
1595 crc, export, insmod, keystatus, ls, set, and unset commands.
1596
f3e8cdfd 15972009-09-02 Colin Watson <cjwatson@ubuntu.com>
1598
1599 * commands/keystatus.c (GRUB_MOD_INIT (keystatus)): Adjust summary
1600 to avoid implying that only one of --shift, --ctrl, or --alt may be
1601 used.
1602
c0bc232b 16032009-09-02 Colin Watson <cjwatson@ubuntu.com>
1604
1605 * util/grub-probe.c (probe): Test st.st_mode using S_ISREG macro
1606 rather than comparing against S_IFREG, which will almost never work.
1607
aa0f752d 16082009-09-01 Vladimir Serbinenko <phcoder@gmail.com>
1609
1610 * commands/loadenv.c (check_blocklists): Fix off-by-one error.
1611 (write_blocklists): Likewise.
1612
ecb3166a 16132009-09-01 Colin Watson <cjwatson@ubuntu.com>
1614
1615 * script/lua/grub_lua.h (fputs): Supply a format string as the first
1616 argument to grub_printf.
1617
c403a125 16182009-09-01 Felix Zielcke <fzielcke@z-51.de>
31aba781 1619
1620 * genmk.rb: Add quotes around $(TARGET_OBJ2ELF) to cope with
c403a125 1621 non GNU test.
31aba781 1622
b5e7312c 16232009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1624
1625 * kern/file.c (grub_file_read): Spelling fix
1626
fe00f472 16272009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1628
1629 * loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix
1630 loading of headers in some cases.
1631
cc55302e 16322009-08-30 Robert Millan <rmh.grub@aybabtu.com>
1633
1634 * configure.ac: Bump version to 1.97~beta1.
1635 * docs/version.texi: Likewise.
1636
5c90cdd2 16372009-08-29 Vladimir Serbinenko <phcoder@gmail.com>
64bf71d0 1638
1639 * include/grub/i386/xnu.h: Add license header.
1640 include grub/err.h explicitly.
1641
c90edae4 16422009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1643
1644 * util/grub.d/10_freebsd.in: Detect `ufs1' and `ufs2' and map them
1645 to `ufs' in the vfs.root.mountfrom kernel parameter.
1646
d8888b5c 16472009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1648
1649 * term/i386/pc/serial.c: Include `<grub/machine/memory.h>'.
1650
1651 [GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Macroify initialization
1652 value (0x0400 -> GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR).
1653
1654 [! GRUB_MACHINE_PCBIOS] (GRUB_SERIAL_PORT_NUM): Calculate using
1655 `ARRAY_SIZE' macro.
1656
6f07b921 16572009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1658
1659 * kern/file.c (grub_file_read): Check offset.
1660 * fs/hfs.c (grub_hfs_read_file): Remove unnecessary offset check.
1661 * fs/jfs.c (grub_jfs_read_file): Likewise.
1662 * fs/ntfs.c (grub_ntfs_read): Likewise.
1663 * fs/reiserfs.c (grub_reiserfs_read): Likewise.
1664 * fs/minix.c (grub_minix_read_file): Correct offset check.
1665 * fs/ufs.c (grub_ufs_read_file): Likewise.
1666
b4f34077 16672009-08-28 Colin Watson <cjwatson@ubuntu.com>
1668
1669 * term/i386/pc/console.c (bios_data_area): Cast
1670 GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR explicitly.
1671
e7c69859 16722009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1673
1674 1-bit optimised blitters.
1675
1676 * include/grub/fbblit.h (grub_video_fbblit_replace_32bit_1bit): New
1677 prototype.
1678 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1679 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1680 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1681 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1682 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1683 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1684 * video/fb/fbblit.c (grub_video_fbblit_replace_32bit_1bit): New
1685 function.
1686 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1687 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1688 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1689 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1690 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1691 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1692 * video/fb/video_fb.c (common_blitter): Use 1-bit optimised blitters
1693 when possible.
1694 * video/video.c (grub_video_get_blit_format): Return
1695 GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED if bpp = 1.
1696
a57da43f 16972009-08-28 Colin Watson <cjwatson@ubuntu.com>
1698
1699 * normal/cmdline.c (grub_cmdline_get): Supply a format string as
1700 the first argument to grub_printf.
1701
4cbe67e5 17022009-08-28 Colin Watson <cjwatson@ubuntu.com>
17032009-08-28 Robert Millan <rmh.grub@aybabtu.com>
1704
1705 Add `getkeystatus' terminal method. Add a new `keystatus' command
1706 to query it.
1707
1708 * include/grub/term.h (GRUB_TERM_STATUS_SHIFT,
1709 GRUB_TERM_STATUS_CTRL, GRUB_TERM_STATUS_ALT): Definitions for
1710 modifier key bitmasks.
1711 (struct grub_term_input): Add `getkeystatus' member.
1712 (grub_getkeystatus): Add prototype.
1713 * kern/term.c (grub_getkeystatus): New function.
1714
1715 * include/grub/i386/pc/memory.h
1716 (GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR): New macro.
1717 (struct grub_machine_bios_data_area): Define necessary parts of BIOS
1718 Data Area layout.
1719 * term/i386/pc/console.c (grub_console_getkeystatus): New function.
1720 (grub_console_term_input): Set `getkeystatus' member.
1721 * term/usb_keyboard.c (grub_usb_hid): Macroify HID protocol
1722 constants.
1723 (grub_usb_keyboard_getreport): Likewise.
1724 (grub_usb_keyboard_checkkey): Likewise.
1725 (grub_usb_keyboard_getkeystatus): New function.
1726 (grub_usb_keyboard_term): Set `getkeystatus' member.
1727
1728 * commands/keystatus.c: New file.
1729 * conf/common.rmk (pkglib_MODULES): Add keystatus.mod.
1730 (keystatus_mod_SOURCES): New variable.
1731 (keystatus_mod_CFLAGS): Likewise.
1732 (keystatus_mod_LDFLAGS): Likewise.
1733 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add
1734 commands/keystatus.c.
1735 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1736 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1737 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1738 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1739 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1740 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4cbe67e5 1741
6e2a9085 17422009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1743
1744 Split befs.mod and afs.mod into *_be.mod and *.mod
1745
1746 * conf/common.rmk (grub_probe_SOURCES): Add afs_be.c and befs_be.c.
1747 (grub_fstest_SOURCES): Likewise.
1748 (pkglib_MODULES): Add afs_be.mod and befs_be.mod.
1749 (afs_be_mod_SOURCES): New variable.
1750 (afs_be_mod_CFLAGS): Likewise.
1751 (afs_be_mod_LDFLAGS): Likewise.
1752 (befs_be_mod_SOURCES): Likewise.
1753 (befs_be_mod_CFLAGS): Likewise.
1754 (befs_be_mod_LDFLAGS): Likewise.
1755 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add afs_be.c and befs_be.c.
1756 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1757 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1758 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
1759 (grub_emu_SOURCES): Likewise.
1760 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1761 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1762 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1763 * fs/afs_be.c: New file.
1764 * fs/befs_be.c: New file.
1765 * fs/afs.c (GRUB_AFS_FSNAME_SUFFIX): New definition.
1766 (GRUB_AFS_FSNAME): Use GRUB_AFS_FSNAME_SUFFIX.
1767 (U16): Replaced with ...
1768 (grub_afs_to_cpu16): ...this. All users updated.
1769 (U32): Replaced with ...
1770 (grub_afs_to_cpu32): ...this. All users updated.
1771 (U64): Replaced with ...
1772 (grub_afs_to_cpu64): ...this. All users updated.
1773 (GRUB_AFS_BO_LITTLE_ENDIAN): Remove.
1774 (GRUB_AFS_BO_BIG_ENDIAN): Likewise.
ad8ea1f4 1775 (grub_afs_validate_sblock): Check only one endianness.
6e2a9085 1776 (GRUB_MOD_INIT (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1777 (GRUB_MOD_INIT (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1778 (GRUB_MOD_INIT (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1779 (GRUB_MOD_INIT (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1780 (GRUB_MOD_FINI (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1781 (GRUB_MOD_FINI (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1782 (GRUB_MOD_FINI (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1783 (GRUB_MOD_FINI (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1784
32a71655 17852009-08-26 Bean <bean123ch@gmail.com>
1786
1787 * fs/xfs.c (GRUB_XFS_INO_INOINAG): Replace 1L with 1LL to support
1788 64-bit number.
1789 (GRUB_XFS_FSB_TO_BLOCK): Likewise.
1790 (grub_xfs_inode_block): Change return type to grub_uint64_t.
1791 (grub_xfs_read_inode): Change type of block to grub_uint64_t.
1792
552bf6c5 17932009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1794
1795 NetBSD memory map support.
1796
1797 * include/grub/i386/bsd.h (NETBSD_BTINFO_MEMMAP): New definition.
1798 (grub_netbsd_btinfo_mmap_header): New structure.
1799 (grub_netbsd_btinfo_mmap_entry): Likewise.
1800 * loader/i386/bsd.c (grub_netbsd_boot): Pass memory map.
1801
1ae2078c 18022009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1803
1804 Enable bsd.mod on coreboot.
1805
1806 * conf/i386-coreboot.rmk (pkglib_MODULES): Add bsd.mod.
1807 (bsd_mod_SOURCES): New variable.
1808 (bsd_mod_CFLAGS): Likewise.
1809 (bsd_mod_LDFLAGS): Likewise.
1810 (bsd_mod_ASFLAGS): Likewise.
1811 * loader/i386/bsd.c [!GRUB_MACHINE_PCBIOS]: Fix includes.
1812 (grub_bsd_get_device) [!GRUB_MACHINE_PCBIOS]: Set *biosdev to 0xff.
1813
beefc598 18142009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1815
1816 Cleanup NetBSD root support.
1817
1818 * loader/i386/bsd.c (grub_netbsd_boot): Remove call to
1819 grub_bsd_get_device.
1820 Fix typo.
1821
3b76e68b 18222009-08-25 Felix Zielcke <fzielcke@z-51.de>
1823
1824 * util/grub.d/00_header.in: Move check for the video backend of
1825 gfxterm from here ...
1826 * util/grub-mkconfig.in: ... to here. Enable gfxterm if there's
1827 a suitable video backend.
1828
aea664ea 18292009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1830
1831 Fix breakage in grub-setup.
1832
1833 * util/i386/pc/grub-setup.c (setup): Use "part_msdos" instead of
1834 "msdos_partition_map".
1835
ff747d50 18362009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1837
1838 Fix breakage in normal/auth.c.
1839
1840 * normal/auth.c (grub_iswordseparator): New function.
1841
e7e1f93f 18422009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1843
1844 Authentication support.
1845
1846 * commands/password.c: New file.
1847 * conf/common.rmk (pkglib_MODULES): Add password.mod.
1848 (password_mod_SOURCES): New variable.
1849 (password_mod_CFLAGS): Likewise.
1850 (password_mod_LDFLAGS): Likewise.
1851 (normal_mod_SOURCES): Add normal/auth.c.
1852 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add commands/password.c and
1853 normal/auth.c.
1854 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1855 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1856 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1857 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1858 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1859 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1860 * include/grub/auth.h: New file.
1861 * include/grub/err.h (grub_err_t): New enum value
1862 GRUB_ERR_ACCESS_DENIED.
1863 * include/grub/menu.h (grub_menu_entry): New fields 'restricted' and
1864 'users'.
1865 * include/grub/normal.h (grub_cmdline_get): New argument 'history'.
1866 * normal/cmdline.c (grub_cmdline_get): New argument 'history'. All
1867 users updated.
1868 * normal/auth.c: New file.
1869 * normal/main.c (grub_normal_add_menu_entry): Handle --users option.
1870 (grub_cmdline_run): Don't allow to go to command line without
1871 authentication.
1872 * normal/menu.c (grub_menu_execute_entry): Handle restricted entries.
1873 * normal/menu_entry.c (grub_menu_entry_run): Don't allow editing
1874 menuentry without superuser rights.
1875 * normal/menu_viewer.c (grub_menu_viewer_show_menu): Don't exit if
1876 user isn't a superuser.
1877
70f1161d 18782009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1879
1880 Save space by inlining misc.c functions.
1881
1882 * kern/misc.c (grub_iswordseparator): Made static.
1883 * kern/misc.c (grub_strcat): Moved from here ...
1884 * include/grub/misc.h (grub_strcat): ... here. Inlined.
1885 * kern/misc.c (grub_strncat): Moved from here ...
1886 * include/grub/misc.h (grub_strncat): ... here. Inlined.
1887 * kern/misc.c (grub_strcasecmp): Moved from here ...
1888 * include/grub/misc.h (grub_strcasecmp): ... here. Inlined.
1889 * kern/misc.c (grub_strncasecmp): Moved from here ...
1890 * include/grub/misc.h (grub_strncasecmp): ... here. Inlined.
1891 * kern/misc.c (grub_isalpha): Moved from here ...
1892 * include/grub/misc.h (grub_isalpha): ... here. Inlined.
1893 * kern/misc.c (grub_isdigit): Moved from here ...
1894 * include/grub/misc.h (grub_isdigit): ... here. Inlined.
1895 * kern/misc.c (grub_isgraph): Moved from here ...
1896 * include/grub/misc.h (grub_isgraph): ... here. Inlined.
1897 * kern/misc.c (grub_tolower): Moved from here ...
1898 * include/grub/misc.h (grub_tolower): ... here. Inlined.
1899
48e40bff 19002009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1901
1902 * script/sh/function.c (grub_script_function_find): Cut error message
1903 not to flood terminal.
1904 * script/sh/lexer.c (grub_script_yylex): Remove command line length
1905 limit.
1906 * script/sh/script.c (grub_script_arg_add): Duplicate string.
1907
c385bfc3 19082009-08-24 Colin Watson <cjwatson@ubuntu.com>
1909
1910 * term/usb_keyboard.c (grub_usb_keyboard_getreport): Make
1911 `report' grub_uint8_t *.
1912 (grub_usb_keyboard_checkkey): Make `data' elements grub_uint8_t.
1913 Use a 50-millisecond timeout rather than just repeating
1914 grub_usb_keyboard_getreport 50 times.
1915 (grub_usb_keyboard_getkey): Make `data' elements grub_uint8_t.
1916
2d21e3e8 19172009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1918
1919 Rename *_partition_map to part_*
1920
1921 * partmap/acorn.c (grub_acorn_partition_map): Set name to 'part_acorn'.
1922 * partmap/amiga.c (grub_amiga_partition_map): Set name to 'part_amiga'.
1923 * partmap/apple.c (grub_apple_partition_map): Set name to 'part_apple'.
1924 * partmap/gpt.c (grub_gpt_partition_map): Set name to 'part_gpt'.
1925 All users updated.
1926 * partmap/msdos.c (grub_msdos_partition_map): Set name to 'part_msdos'.
1927 All users updated.
1928 * partmap/sun.c (grub_sun_partition_map): Set name to 'part_sun'.
1929 * util/grub-probe.c (probe_partmap): Don't transform partition name
1930 to get module name.
1931
dd103c4e 19322009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1933
1934 Fix OpenBSD and NetBSD support.
1935
1936 * include/grub/i386/bsd.h (GRUB_BSD_TEMP_BUFFER): Change to resolve
1937 memory address conflict.
1938 (OPENBSD_MMAP_ACPI): New definition.
1939 (OPENBSD_MMAP_NVS): Likewise.
1940 * loader/i386/bsd.c (grub_openbsd_boot): Support OPENBSD_MMAP_ACPI
1941 and OPENBSD_MMAP_NVS.
1942 Add memory map terminator
1943 Explicit cast when calling grub_unix_real_boot.
ad8ea1f4 1944 (grub_netbsd_boot): Explicit cast when calling grub_unix_real_boot.
dd103c4e 1945
16c84d74 19462009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1947
1948 Let user specify NetBSD root device.
1949
1950 * loader/i386/bsd.c (netbsd_root): New variable.
1951 (netbsd_opts): New option 'root'.
1952 (NETBSD_ROOT_ARG): New macro.
1953 (grub_netbsd_boot): Use 'netbsd_root'.
1954 (grub_bsd_unload): Free 'netbsd_root'.
1955 (grub_cmd_netbsd): Fill 'netbsd_root'.
1956
adb29902 19572009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1958
1959 Support for 64-bit NetBSD.
1960
1961 * loader/i386/bsd.c (grub_bsd_load_elf): Apply correct mask to entry
1962 point when booting non-FreeBSD.
1963
f5ae9f74 19642009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1965
1966 Support --no-smp and --no-acpi for NetBSD.
1967
1968 * include/grub/i386/bsd.h (NETBSD_AB_NOSMP): New definition.
1969 (NETBSD_AB_NOACPI): Likewise.
1970 * loader/i386/bsd.c (netbsd_opts): New entries no-smp and no-acpi.
1971 (netbsd_flags): Add NETBSD_AB_NOSMP, NETBSD_AB_NOACPI.
1972
de74f136 19732009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
1974
1975 * fs/hfsplus.c (grub_hfsplus_mount): Don't ignore grub_hfsplus_read_file
1976 errors.
1977 (grub_hfsplus_btree_iterate_node): Don't ignore grub_hfsplus_read_file
1978 errors. Call grub_error when needed.
1979
e9a925da 19802009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
1981
1982 * commands/search.c (search_fs): Try searching without autoload first.
1983 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Load
1984 filesystem module explicitly for faster booting.
1985
5174302b 19862009-08-23 Colin Watson <cjwatson@ubuntu.com>
1987
1988 * util/grub-mkconfig.in: Export GRUB_DISABLE_OS_PROBER.
1989
c8c80635 19902009-08-23 Colin Watson <cjwatson@ubuntu.com>
1991
1992 * util/grub.d/30_os-prober.in: Disable os-prober if
1993 `GRUB_DISABLE_OS_PROBER' was set to true.
1994
71acf5e5 19952009-08-23 Robert Millan <rmh.grub@aybabtu.com>
1996
1997 * partmap/pc.c: Rename to ...
1998 * partmap/msdos.c: ... this. Update all users.
1999 (grub_pc_partition_map): Rename to ...
2000 (grub_msdos_partition_map): ... this. Update all users.
2001
2002 * parttool/pcpart.c: Rename to ...
2003 * parttool/msdospart.c: ... this. Update all users.
2004
2005 * include/grub/pc_partition.h: Rename to ...
2006 * include/grub/msdos_partition.h: ... this. Update all users.
2007 (grub_pc_partition_bsd_entry): Rename to ...
2008 (grub_msdos_partition_bsd_entry): ... this. Update all users.
2009 (grub_pc_partition_disk_label): Rename to ...
2010 (grub_msdos_partition_disk_label): ... this. Update all users.
2011 (grub_pc_partition_entry): Rename to ...
2012 (grub_msdos_partition_entry): ... this. Update all users.
2013 (grub_pc_partition_mbr): Rename to ...
2014 (grub_msdos_partition_mbr): ... this. Update all users.
2015 (grub_pc_partition): Rename to ...
2016 (grub_msdos_partition): ... this. Update all users.
2017 (grub_pc_partition_is_empty): Rename to ...
2018 (grub_msdos_partition_is_empty): ... this. Update all users.
2019 (grub_pc_partition_is_extended): Rename to ...
2020 (grub_msdos_partition_is_extended): ... this. Update all users.
2021 (grub_pc_partition_is_bsd): Rename to ...
2022 (grub_msdos_partition_is_bsd): ... this. Update all users.
2023
2024 * conf/common.rmk (amiga_mod_SOURCES, amiga_mod_CFLAGS)
2025 (amiga_mod_LDFLAGS, apple_mod_SOURCES, apple_mod_CFLAGS)
2026 (apple_mod_LDFLAGS, msdos_mod_SOURCES, msdos_mod_CFLAGS)
2027 (msdos_mod_LDFLAGS, sun_mod_SOURCES, sun_mod_CFLAGS)
2028 (sun_mod_LDFLAGS, acorn_mod_SOURCES, acorn_mod_CFLAGS)
2029 (acorn_mod_LDFLAGS, gpt_mod_SOURCES, gpt_mod_CFLAGS)
2030 (gpt_mod_LDFLAGS): Rename to ...
2031 (part_amiga_mod_SOURCES, part_amiga_mod_CFLAGS, part_amiga_mod_LDFLAGS)
2032 (part_apple_mod_SOURCES, part_apple_mod_CFLAGS, part_apple_mod_LDFLAGS)
2033 (part_msdos_mod_SOURCES, part_msdos_mod_CFLAGS, part_msdos_mod_LDFLAGS)
2034 (part_sun_mod_SOURCES, part_sun_mod_CFLAGS, part_sun_mod_LDFLAGS)
2035 (part_acorn_mod_SOURCES, part_acorn_mod_CFLAGS, part_acorn_mod_LDFLAGS)
2036 (part_gpt_mod_SOURCES, part_gpt_mod_CFLAGS)
2037 (part_gpt_mod_LDFLAGS): ... this.
2038 (pkglib_MODULES): Prefix partition modules with `part_'. Rename
2039 `pcpart.mod' to `msdospart.mod'.
2040 (pcpart_mod_SOURCES, pcpart_mod_CFLAGS, pcpart_mod_LDFLAGS): Rename
2041 to ...
2042 (msdospart_mod_SOURCES, msdospart_mod_CFLAGS)
2043 (msdospart_mod_LDFLAGS): ... this.
2044
c11fded5 20452009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2046
2047 * loader/i386/bsd.c (freebsd_opts): Rewritten to use extcmd.
2048 (openbsd_opts): Likewise.
2049 (netbsd_opts): Likewise.
2050 (freebsd_flags): Added 0 terminator.
2051 (openbsd_flags): Likewise.
2052 (netbsd_flags): Likewise.
2053 (grub_bsd_parse_flags): Rewritten to use extcmd. All users updated.
2054 (grub_cmd_freebsd): Transformed into extended command.
2055 (grub_cmd_openbsd): Likewise.
2056 (grub_cmd_netbsd): Likewise.
2057 (cmd_freebsd): Changed type to grub_extcmd_t.
2058 (cmd_openbsd): Likewise.
2059 (cmd_netbsd): Likewise.
2060 (GRUB_MOD_INIT (bsd)): Register grub_cmd_freebsd, grub_cmd_netbsd and
2061 grub_cmd_openbsd as extended commands.
2062 (GRUB_MOD_FINI (bsd)): Use grub_unregister_extcmd for cmd_freebsd,
2063 cmd_netbsd and cmd_openbsd
2064
11d1c769 20652009-08-22 Vladimir Serbinenko <phcoder@gmail.com>
2066
2067 * commands/xnu_uuid.c (transform): Use grub_memcpy instead of memcpy.
2068
7a9094e5 20692009-08-21 Pavel Roskin <proski@gnu.org>
2070
5496c37e 2071 * Makefile.in (install-local): When checking if a file is in the
2072 build directory, use "test -e" to detect symlinks.
2073
7a9094e5 2074 * Makefile.in (install-local): Remove all files in
2075 $(DESTDIR)$(pkglibdir) before installing new files there.
2076
e53cea11 20772009-08-18 Felix Zielcke <fzielcke@z-51.de>
2078
2079 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Use
2080 grub-mkelfimage.
2081
9aced544 20822009-08-18 Felix Zielcke <fzielcke@z-51.de>
2083
2084 * util/grub-mkconfig.in: Don't use gfxterm by default if not
2085 explicitly specified by the user.
2086
b7da6bab 20872009-08-18 Pavel Roskin <proski@gnu.org>
2088
2089 * include/grub/fbfill.h (struct grub_video_fbrender_target): Use
2090 grub_uint8_t pointer for data.
2091 * include/grub/fbutil.h (struct grub_video_fbblit_info):
2092 Likewise.
2093 * video/fb/fbutil.c: Remove unnecessary casts.
2094
19f1b335 20952009-08-17 Michal Suchanek <hramrach@centrum.cz>
2096
2097 VBE cleanup.
2098
2099 * video/i386/pc/vbe.c (vbe_mode_in_use): Removed (duplicate).
2100 (grub_vbe_set_video_mode): Save active mode info
2101 only after setting the mode.
2102 (grub_video_vbe_setup): Call 'grub_vbe_set_video_mode' with NULL as
2103 second argument.
2104
2f467aa9 21052009-08-17 Michal Suchanek <hramrach@centrum.cz>
2106
2107 Rename variables for clarity.
2108
2109 * video/i386/pc/vbe.c (active_mode_info): Renamed to ...
2110 (active_vbe_mode_info): ... this. All users updated.
2111 (framebuffer): Rename 'active_mode' to 'active_vbe_mode'.
2112 All users updated.
2113 (initial_mode): Rename to ...
2114 (initial_vbe_mode): ... this. All users updated.
2115 (mode_in_use): Rename to ..
2116 (vbe_mode_in_use): ... this. All users updated.
2117 (mode_list): Rename to ..
2118 (vbe_mode_list): ... this. All users updated.
2119 (grub_vbe_set_video_mode): Rename 'mode' to 'vbe_mode', 'mode_info' to
2120 'vbe_mode_info' and 'old_mode' to 'old_vbe_mode'.
2121 (grub_video_vbe_init): Rename 'rm_mode_list' to 'rm_vbe_mode_list' and
2122 'mode_list_size' to 'vbe_mode_list_size'.
2123 (grub_video_vbe_setup): Rename 'mode_info' to 'vbe_mode_info',
2124 'best_mode_info' to 'best_vbe_mode_info' and
2125 'best_mode' to 'best_vbe_mode'
2126
6025fcd7 21272009-08-17 Michal Suchanek <hramrach@centrum.cz>
2128
2129 Remove duplicate grub_video_fb_get_video_ptr.
2130
2131 * include/grub/fbutil.h (get_data_ptr): Rename to ...
2132 (grub_video_fb_get_video_ptr): ... this.
2133 * include/grub/video_fb.h (grub_video_fb_get_video_ptr): Removed.
2134 * video/fb/fbutil.c: Add comment about addressing.
2135 (get_data_ptr): Rename to ...
2136 (grub_video_fb_get_video_ptr): ... this. All users updated.
2137 * video/fb/video_fb.c (grub_video_fb_get_video_ptr): Remove.
2138
cc8c6faf 21392009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2140
2141 * fs/fat.c (grub_fat_read_data): Remove `#if 0' braces around the
2142 grub_dprintf() that was just added.
2143
08aa61f0 21442009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2145
2146 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT)
2147 (DEFAULT_VIDEO_MODE): Remove macros.
2148 (grub_linux_boot): Remove assumption that Linux has FB support,
2149 and use "text" as default video mode.
2150
7cef4f75 21512009-08-15 Vladimir Serbinenko <phcoder@gmail.com>
2152
2153 * fs/affs.c (grub_affs_read_symlink): Change leftover grub_printf into
2154 grub_dprintf.
2155 * fs/fat.c (grub_fat_read_data): Likewise.
2156
e1f39873 21572009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2158
2159 * loader/i386/multiboot.c (grub_multiboot): Don't pass filename to
2160 payload.
2161 (grub_module): Likewise.
2162
c166d79e 21632009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2164
2165 * loader/i386/multiboot.c (grub_multiboot_unload): Don't free mbi and
2166 mbi->cmdline but free playground.
2167
c60cee8e 21682009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2169
2170 Handle group offset on UFS1.
2171
2172 * fs/ufs.c (grub_ufs_sblock): New field 'cylg_mask'.
2173 (grub_ufs_read_inode) [!MODE_UFS2]: handle cylg_offset and cylg_mask.
2174
c0d8b5d4 21752009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2176
2177 Split ufs.mod into ufs1.mod and ufs2.mod.
2178
2179 * conf/common.rmk (grub_probe_SOURCES): Add fs/ufs2.c.
2180 (grub_fstest_SOURCES): Likewise.
2181 (pkglib_MODULES): Remove ufs.mod. Add ufs1.mod and ufs2.mod.
2182 (ufs_mod_SOURCES): Remove.
2183 (ufs_mod_CFLAGS): Likewise.
2184 (ufs_mod_LDFLAGS): Likewise.
2185 (ufs1_mod_SOURCES): New variable.
2186 (ufs1_mod_CFLAGS): Likewise.
2187 (ufs1_mod_LDFLAGS): Likewise.
25fbd77a 2188 (ufs2_mod_SOURCES): New variable.
2189 (ufs2_mod_CFLAGS): Likewise.
2190 (ufs2_mod_LDFLAGS): Likewise.
c0d8b5d4 2191 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add fs/ufs2.c.
2192 * conf/i386-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2193 Likewise.
2194 (grub_emu_SOURCES): Likewise.
2195 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2196 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2197 (grub_setup_SOURCES): Likewise.
2198 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2199 * conf/sparc64.rmk (grub_emu_SOURCES): Likewise.
2200 (grub_setup_SOURCES): Likewise.
2201 * conf/x86_64-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2202 Likewise.
2203 * fs/ufs2.c: New file.
2204 * fs/ufs.c: Separate UFS1 from UFS2 by using preprocessor.
2205
d3539132 22062009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2207
2208 Framebuffer split.
2209
2210 * commands/i386/pc/vbetest.c (grub_cmd_vbetest): Restore video
2211 subsystem at the end.
2212 * conf/common.rmk (pkglib_MODULES): Add video_fb.mod.
2213 (video_fb_mod_SOURCES): New variable.
2214 (video_fb_mod_CFLAGS): Likewise.
2215 (video_fb_mod_LDFLAGS): Likewise.
2216 * conf/i386-pc.rmk (vbe_mod_SOURCES): Remove video/i386/pc/vbeblit.c,
2217 video/i386/pc/vbefill.c and video/i386/pc/vbeutil.c.
2218 * video/i386/pc/vbeblit.c: Moved from here ...
2219 * video/fb/fbblit.c: ..here. Replaced 'vbe' with 'fb'.
2220 * video/i386/pc/vbefill.c: Moved from here ...
2221 * video/fb/fbfill.c: ..here. Replaced 'vbe' with 'fb'.
2222 * video/i386/pc/vbeutil.c: Moved from here ...
2223 * video/fb/fbutil.c: ..here. Replaced 'vbe' with 'fb'.
2224 * include/grub/i386/pc/vbeblit.h: Moved from here ...
2225 * include/grub/fbblit.h: ... here. Replaced 'vbe' with 'fb'.
2226 * include/grub/i386/pc/vbefill.h: Moved from here ...
2227 * include/grub/fbfill.h: ... here. Replaced 'vbe' with 'fb'.
2228 * include/grub/i386/pc/vbeutil.h: Moved from here ...
2229 * include/grub/fbutil.h: ... here. Replaced 'vbe' with 'fb'.
2230 * include/grub/i386/pc/vbe.h: Moved framebuffer part ...
2231 * include/grub/video_fb.h: ... here. Replaced 'vbe' with 'fb'.
2232 * include/grub/video.h (GRUB_VIDEO_RENDER_TARGET_FRONT_BUFFER): Removed.
2233 (GRUB_VIDEO_RENDER_TARGET_BACK_BUFFER): Likewise.
2234 (grub_video_adapter): Added 'get_info_and_fini'.
2235 (grub_video_get_info_and_fini): New prototype.
2236 (grub_video_set_mode): make modestring const char *.
2237 * loader/i386/linux.c (grub_linux_setup_video): Use
2238 grub_video_get_info_and_fini.
2239 (grub_linux_boot): Move modesetting just before booting.
2240 * loader/i386/pc/xnu.c (grub_xnu_set_video): Use
2241 grub_video_get_info_and_fini.
2242 * video/i386/pc/vbe.c: Moved framebuffer part ...
2243 * video/fb/video_fb.c: ... here. Replaced 'vbe' with 'fb'.
2244 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): Use
2245 grub_video_fbstd_colors and grub_video_fb_set_palette.
2246 (grub_video_vbe_init): Clear 'framebuffer' variable and use
2247 grub_video_fb_init.
2248 (grub_video_vbe_fini): Use grub_video_fb_fini.
2249 (grub_video_vbe_setup): Use framebuffer.render_target instead of
2250 render_target and use grub_video_fb_set_active_render_target and
2251 grub_video_fb_set_palette.
2252 (grub_video_vbe_set_palette): Use grub_video_fb_set_palette.
2253 (grub_video_vbe_set_viewport): Use grub_video_fb_set_viewport.
2254 (grub_video_vbe_adapter): Use framebuffer.
2255 * video/video.c (grub_video_get_info_and_fini): New function.
2256 (grub_video_set_mode): Make modestring const char *.
2257 (GRUB_MOD_INIT(video_video)): Don't set variables to 0 since these
2258 values are already initialised.
2259
d404ee56 22602009-08-14 Pavel Roskin <proski@gnu.org>
2261
2262 * boot/i386/pc/cdboot.S: Use LOCAL for local labels. Eliminate
2263 ABS and APPLE_CC.
2264 * boot/i386/pc/diskboot.S: Likewise.
2265 * boot/i386/pc/lnxboot.S: Likewise. Hardcode the number of code
2266 sectors allow compilation on MacOSX.
2267 * conf/i386-pc.rmk: Enable unconditional compilation of
2268 lnxboot.img.
2269
9a10df16 22702009-08-13 Colin Watson <cjwatson@ubuntu.com>
2271
2272 * util/grub-mkconfig.in: Export GRUB_HIDDEN_TIMEOUT.
2273 * util/grub.d/00_header.in: Enter interruptible sleep if
2274 GRUB_HIDDEN_TIMEOUT is set.
2275
be3c9ca7 22762009-08-13 Yves Blusseau <blusseau@zetam.org>
2277
2278 * include/grub/symbol.h: Add the LOCAL macro.
2279 * boot/i386/pc/boot.S: Use the LOCAL macro for all labels
2280 starting with "L_".
2281
1f9e557e 22822009-08-13 Pavel Roskin <proski@gnu.org>
2283
9ca62843 2284 * boot/i386/pc/boot.S: Remove ABS macro, it's not required by
2285 any modern compilers we support.
2286
1f9e557e 2287 * boot/i386/pc/boot.S: Remove all code dependent on APPLE_CC.
2288 Use local labels starting with "L_" so that Apple assembler
2289 knows they are local.
2290
81623db6 22912009-08-10 Robert Millan <rmh.grub@aybabtu.com>
2292
2293 * include/grub/i386/bsd.h (KERNEL_TYPE_NONE, KERNEL_TYPE_FREEBSD)
2294 (KERNEL_TYPE_OPENBSD, KERNEL_TYPE_NETBSD): Convert to ...
2295 (bsd_kernel_types): ... this enum.
2296
2297 * loader/i386/bsd.c (grub_cmd_freebsd_loadenv, grub_cmd_freebsd_module)
2298 (grub_cmd_freebsd_module_elf): Abort with "You need to load the
2299 kernel first." when `kernel_type' is set to KERNEL_TYPE_NONE.
2300
2301 (grub_bsd_load_aout, grub_bsd_load, grub_cmd_freebsd_loadenv)
2302 (grub_cmd_freebsd_module, grub_cmd_freebsd_module_elf)
2303 (GRUB_MOD_INIT (bsd)): Fix capitalization in a few error
2304 messages.
2305
f5d35e7a 23062009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2307
2308 * util/grub-dumpdevtree: Moved from here ...
2309 * util/i386/efi/grub-dumpdevtree: ... to here.
2310 (hexify): New function. Converts a string to its hex version.
2311 Generate hex versions of "efi" and "device-properties" by calling
2312 hexify() on the ASCII strings rather than by hardcoding numbers.
2313
d1e1d527 23142009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2315
2316 * fs/jfs.c: Update copyright year.
2317
1ebbe064 23182009-08-08 Felix Zielcke <fzielcke@z-51.de>
2319
2320 * util/grub.d/00_header.in: Fix a comment.
2321 * util/grub.d/10_linux.in: Likewise.
2322 * util/grub.d/10_windows.in: Likewise.
2323 * util/grub.d/10_hurd.in: Likewise.
2324
a78c8d24 23252009-08-08 Felix Zielcke <fzielcke@z-51.de>
2326
2327 * util/grub-mkconfig.in: Allow the user to specify the used font
2328 with GRUB_FONT.
2329
29a6b9e8 23302009-08-08 Pavel Roskin <proski@gnu.org>
2331
b5f16cc4 2332 * include/grub/powerpc/libgcc.h: Export __ashrdi3() if
2333 available, xfs.mod needs it now.
2334
2f5cb827 2335 * util/grub-mkconfig_lib.in (version_test_numeric): Don't use
2336 the "g" modifier in sed when the intention is to strip something
2337 once. This fixes comparison of kernels with multiple dashes.
2338
29a6b9e8 2339 * util/grub-mkconfig.in: Define datarootdir, datadir may depend
2340 on it. Add missing space before closing bracket. Fix
2341 misleading formatting.
2342
892a3d98 23432009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2344
2345 * docs/grub.texi: Major overhaul. Remove all sections that are
2346 specific to GRUB Legacy, or mostly composed of Legacy-specific
2347 information.
2348
ed94253f 23492009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2350
2351 * docs/version.texi: New file. Provides version information for
2352 grub.texi.
2353
126d6628 23542009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2355
2356 * docs/grub.texi: Update CVS information to SVN.
2357 Replace outdated "GRUB 2 will include" phrase with "GRUB 2 includes".
2358
998b5aa9 23592009-08-07 Felix Zielcke <fzielcke@z-51.de>
2360
2361 * util/grub-mkconfig.in: Remove a wrong `fi'.
2362
818e094a 23632009-08-07 Felix Zielcke <fzielcke@z-51.de>
2364
2365 * fs/uuid.c (grub_jfs_superblock): New fields unused2 and uuid.
2366 (grub_jfs_uuid): New function.
2367 (grub_jfs_fs): Set uuid field to grub_jfs_uuid.
2368
b969c52f 23692009-08-07 Felix Zielcke <fzielcke@z-51.de>
2370
2371 * util/grub-mkconfig_lib.in (font_path): Move the functionality
2372 of it to ...
2373 * util/grub-mkconfig.in: ... here. Prefer unicode.pf2 and
2374 unifont.pf2 over ascii.pf2. Export LANG=C in case ascii.pf2 gets used.
2375
7a4894cc 23762009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2377
2378 * util/grub.d/10_linux.in (test_numeric): Moved from here ...
2379 * util/grub-mkconfig_lib.in (version_test_numeric): ... to here.
2380 Update all users.
2381
2382 * util/grub.d/10_linux.in (test_gt): Strip any basename prefix,
2383 not just "vmlinu[zx]".
2384 Moved from here ...
2385 * util/grub-mkconfig_lib.in (version_test_gt): ... to here. Update
2386 all users.
2387
2388 * util/grub.d/10_linux.in (find_latest): Moved from here ...
2389 * util/grub-mkconfig_lib.in (version_find_latest): ... to here. Update
2390 all users.
2391
4e2171f8 23922009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2393
2394 * util/grub.d/10_freebsd.in: Use an absolute device path for
2395 `vfs.root.mountfrom'. Set `vfs.root.mountfrom.options=rw'.
2396
6dcfcb32 23972009-08-06 Felix Zielcke <fzielcke@z-51.de>
2398
2399 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Fix
2400 handling of multiple abstraction modules.
2401
f56a8756 24022009-08-04 Robert Millan <rmh.grub@aybabtu.com>
2403
2404 Fix a bug resulting in black screen when loading Linux using a
2405 packed video mode.
2406
2407 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette_width): New
2408 function.
2409
2410 * include/grub/i386/pc/vbe.h (GRUB_VBE_CAPABILITY_DACWIDTH): New macro.
2411 (grub_vbe_bios_getset_dac_palette_width): New function.
2412 (grub_vbe_bios_get_dac_palette_width)
2413 (grub_vbe_bios_set_dac_palette_width): New macros (act as wrappers for
2414 grub_vbe_bios_getset_dac_palette_width()).
2415
2416 * video/i386/pc/vbe.c (grub_vbe_probe): Use `GRUB_VBE_STATUS_OK' to
2417 check for return status.
2418 (grub_vbe_get_video_mode_info): When getting information for a packed
2419 mode (<= 8 bpp), obtain DAC palette width using
2420 grub_vbe_bios_getset_dac_palette_width(), and use that for initializing
2421 {red,green,blue}_mark_size.
2422
222671b2 24232009-08-04 Felix Zielcke <fzielcke@z-51.de>
2424
ecb1a6d9 2425 * commands/search.c (options): Fix help output to match actual code.
222671b2 2426
f84114f5 24272009-08-02 Vladimir Serbinenko <phcoder@gmail.com>
2428
2429 * commands/hexdump.c (grub_cmd_hexdump): Use grub_disk_read instead
2430 of homegrown code.
2431
bd288a20 24322009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
e768b770 2433
2434 * util/hostfs.c (grub_hostfs_dir): Don't use DT_DIR: It doesn't work
2435 on XFS or ReiserFS.
2436
8aab5e25 24372009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
2438
2439 Support Apple partition map with sector size different from 512 bytes.
2440
2441 * partmap/apple.c (grub_apple_header): New field 'blocksize'.
2442 (apple_partition_map_iterate): Respect 'aheader.blocksize'
2443 and 'apart.partmap_size'.
2444
6ad6258a 24452009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
24462009-08-01 Robert Millan <rmh.grub@aybabtu.com>
2447
2448 Fix cpuid command.
2449
2450 * commands/i386/cpuid.c (options): New variable.
2451 (grub_cmd_cpuid): Return real error.
2452 (GRUB_MOD_INIT(cpuid)): Declare options.
2453
67459bc6 24542009-07-31 Vladimir Serbinenko <phcoder@gmail.com>
2455
2456 * partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
2457 valid.
2458
fbc6ab54 24592009-07-31 Bean <bean123ch@gmail.com>
2460
2461 * fs/xfs.c (grub_xfs_sblock): Change unused5 field to log2_sect and
2462 log2_inode.
2463 (grub_fshelp_node): Move inode field to the end.
2464 (grub_xfs_data): Remove inode field.
2465 (grub_xfs_inode_block): Calculate inode size using sblock.
2466 (grub_xfs_inode_offset): Likewise.
2467 (grub_xfs_read_inode): Calculate inode size using sblock.
2468 (grub_xfs_read_block): Replace XFS_INODE_EXTENTS with nrec.
2469 (grub_xfs_iterate_dir): Calculate inode size using sblock.
2470 (grub_xfs_mount): Use grub_zalloc instead of grub_malloc. Realloc data
2471 to match inode size.
2472 (grub_xfs_dir): goto mount_fail when mount fails, as data->diropen is
2473 not accessible when data is null.
2474 (grub_xfs_open): Likewise.
2475
f45d6cfc 24762009-07-31 Bean <bean123ch@gmail.com>
2477
2478 * disk/lvm.c (grub_lvm_scan_device): Ignore extra copy of metadata.
2479 Don't change pv->disk if it's already set.
2480
2481 * disk/raid.c (grub_raid_scan_device): Merge this function into ...
2482 (grub_raid_register): ... here.
2483 (grub_raid_rescan): Removed.
2484
2485 * include/grub/raid.h (grub_raid_rescan): Removed.
2486
2487 * util/grub-fstest.c: Remove include file <grub/raid.h>.
2488 (fstest): Replace grub_raid_rescan with module fini function followed
2489 by init function.
2490
2491 * util/grub-probe.c: Add include file <grub/raid.h>.
2492 (probe_raid_level): New function.
2493 (probe): Detect abstraction by walking the disk device, support two
2494 level of abstraction (LVM on RAID) when detecting partition map.
2495
24443b5a 24962009-07-31 Pavel Roskin <proski@gnu.org>
2497
2498 * disk/raid5_recover.c (grub_raid5_recover): Revert conversion
2499 to grub_zalloc(), it was erroneous.
2500 Reported by Bean <bean123ch@gmail.com>
2501
a275d9e7 25022009-07-30 Vladimir Serbinenko <phcoder@gmail.com>
2503
2504 * util/i386/pc/grub-setup.c (setup): Check that no partition is in
ad8ea1f4 2505 embedding zone, not only the first one.
a275d9e7 2506
56c5a47f 25072009-07-29 Joe Auricchio <jauricchio@gmail.com>
2508
2509 * term/gfxterm.c (clear_char): New function.
2510 (grub_virtual_screen_setup): Use clear_char.
2511 (scroll_up): Likewise.
2512 (grub_virtual_screen_cls): Likewise.
2513
67bb323a 25142009-07-29 Felix Zielcke <fzielcke@z-51.de>
2515
2516 * util/deviceiter.c (get_acceleraid_disk_name): New static
2517 function.
2518 (grub_util_iterate_devices): Handle Accelraid devices.
2519 * util/hostdisk.c (convert_system_partition_to_system_disk): Likewise.
2520
388a7c75 25212009-07-28 Robert Millan <rmh.grub@aybabtu.com>
2522
2523 * loader/i386/linux.c (grub_cmd_linux): Use ',' rather than ';' as
2524 separator for the suggested gfxpayload string (';' collides with the
2525 parser and needs escaping).
2526
3bb7abcf 25272009-07-28 Vladimir Serbinenko <phcoder@gmail.com>
2528
2529 * loader/i386/multiboot_helper.S (grub_multiboot_backward_relocator):
2530 Clear direction flag before jumping to OS.
2531 (grub_multiboot2_real_boot): Likewise.
2532
2ddd36d7 25332009-07-28 Felix Zielcke <fzielcke@z-51.de>
2534
2535 * util/i386/pc/grub-install: Fix parsing of --disk-module
2536 option.
2537
c521b62b 25382009-07-28 Felix Zielcke <fzielcke@z-51.de>
2539
2540 * util/i386/pc/grub-setup.c (setup): Fix 2 incorrect checks
2541 when embedding.
2542
880e0a0c 25432009-07-26 Felix Zielcke <fzielcke@z-51.de>
2544
2545 * util/grub-mkconfig.in (package_version): New variable.
2546 Use it do display the version.
2547
2366e356 25482009-07-25 Felix Zielcke <fzielcke@z-51.de>
2549
2550 * kern/file.c (grub_file_open): Revert to previous check with
2551 grub_errno.
2552
7ad8c80e 25532009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2554
2555 * commands/probe.c (GRUB_MOD_INIT (probe)): Remove "[--target=target]"
2556 from help line. It's out of sync with code.
2557
72b9658b 25582009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2559
2560 * kern/parser.c (grub_parser_execute): Fix a bug causing truncated
2561 entries on failed boot.
2562
77435277 25632009-07-25 Felix Zielcke <fzielcke@z-51.de>
2564
2565 * kern/file.c (grub_file_open): Fix an error check.
2566
fcaa8b21 25672009-07-24 Vladimir Serbinenko <phcoder@gmail.com>
2568
35d16c74 2569 * util/i386/pc/grub-setup.c (setup): Fix segmentation fault when
2570 partition map couldn't be identified.
fcaa8b21 2571
48904cd1 25722009-07-23 Pavel Roskin <proski@gnu.org>
2573
ef3c317f 2574 * commands/xnu_uuid.c (transform): Use GRUB_CPU_WORDS_BIGENDIAN
2575 instead of WORDS_BIGENDIAN. Use grub_le_to_cpu32(), so that the
2576 case of little endian words becomes just an optimization.
2577 Respect const modifier.
ad8ea1f4 2578 (md5_final): Use code that doesn't depend on endianness.
ef3c317f 2579
48904cd1 2580 * include/grub/misc.h (ALIGN_UP): Cast align to the type of addr
2581 to avoid loss of upper bits if align is unsigned and shorter
2582 than addr.
2583
260c9a89 25842009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2585
2586 UUID support for UFS
2587
2588 * fs/ufs.c (grub_ufs_sblock): Add uuidhi and uuidlow.
2589 (grub_ufs_uuid): New function.
2590 (grub_ufs_fs): add .uuid
2591
f76ce889 25922009-07-21 Pavel Roskin <proski@gnu.org>
2593
2594 * kern/dl.c (grub_dl_check_header): Make static.
2595
6a6cbcaf 25962009-07-21 Felix Zielcke <fzielcke@z-51.de>
2597
2598 * util/grub.d/30_os-prober.in: Remove unused CHAINROOT. Don't
2599 add drivemap for Vista. It breaks Windows 7.
2600
cffcddb2 26012009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2602
2603 * fs/ufs.c (grub_ufs_sblock): Fix offset of mtime2 which was off by
2604 128 bytes
2605
1ef44b80 26062009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2607
2608 Add BFS support
2609
2610 * conf/common.rmk (grub_probe_SOURCES): Add fs/befs.c.
2611 (grub_fstest_SOURCES): Likewise.
2612 (pkglib_MODULES): Add befs.mod.
2613 (befs_mod_SOURCES): New variable.
2614 (befs_mod_CFLAGS): Likewise.
2615 (befs_mod_LDFLAGS): Likewise.
2616 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
2617 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2618 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2619 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2620 (grub_setup_SOURCES): Likewise.
2621 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2622 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2623 (grub_setup_SOURCES): Likewise.
2624 * fs/befs.c: New file.
2625 * fs/afs.c (GRUB_AFS_FSNAME): New declaration.
2626 (GRUB_AFS_SBLOCK_SECTOR): Likewise.
2627 (GRUB_AFS_SBLOCK_MAGIC1) [MODE_BFS]: New conditional declaration.
2628 (GRUB_AFS_BTREE_MAGIC) [MODE_BFS]: Likewise
2629 (B_KEY_INDEX_ALIGN): New declaration.
2630 (B_KEY_INDEX_OFFSET): Use B_KEY_INDEX_ALIGN.
2631 (grub_afs_bnode) [MODE_BFS]: Make key_count and key_size 16-bit
2632 (grub_afs_btree) [MODE_BFS]: New conditional declaration.
2633 (grub_afs_sblock) [MODE_BFS]: Remove link_count.
2634 (grub_afs_validate_sblock) [MODE_BFS]: Support BFS
2635 (grub_afs_mount) [MODE_BFS]: Likewise.
2636 (grub_afs_dir) [MODE_BFS]: Divide mtime by 65536 and not 1000000.
2637 (grub_afs_fs): Use GRUB_AFS_FSNAME
2638 (GRUB_MOD_INIT (afs)) [MODE_BFS]: Rename to ...
2639 (GRUB_MOD_INIT (befs)) [MODE_BFS]: ... this
2640 (GRUB_MOD_FINI (afs)) [MODE_BFS]: Rename to ...
2641 (GRUB_MOD_FINI (befs)) [MODE_BFS]: ... this
2642
4f253044 26432009-07-19 Yves BLUSSEAU <yves.grub-devel@zetam.org>
2644
2645 * util/getroot.c (find_root_device): Add support for MacOSX.
2646 * util/hostdisk.c: Likewise.
2647
57a55913 26482009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2649
2650 * font/font.c (find_glyph): Check whether a font is present to avoid
2651 segmentation fault.
75421ca9 2652
26532009-07-20 Joe Auricchio <jauricchio@gmail.com>
04c7c429 2654
2655 * term/gfxterm.c (grub_virtual_screen_setup): Clear virtual_screen.
2656
e98cd0c2 26572009-07-20 Pavel Roskin <proski@gnu.org>
2658
2659 * configure.ac: Trim excessively wordy excuses.
2660
1d2d169a 26612009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2662
2663 Add symlink, mtime and label support to AtheFS.
2664
2665 * fs/afs.c (grub_afs_sblock): Declare `name' as char.
2666 (grub_afs_iterate_dir): Handle symlinks.
2667 (grub_afs_open): Use grub_afs_read_symlink.
2668 (grub_afs_dir): Likewise.
2669 Pass mtime.
2670 (grub_afs_label): New function.
2671 (grub_afs_fs): Add grub_afs_label.
2672 (grub_afs_read_symlink): New function.
2673
186f3189 26742009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2675
2676 Fix AtheFS support.
2677
2678 * fs/afs.c: Fix comments style.
2679 (grub_afs_blockrun): Declare as packed.
2680 (grub_afs_datastream): Likewise.
2681 (grub_afs_bnode): Likewise.
2682 (grub_afs_btree): Likewise.
2683 (grub_afs_sblock): Likewise.
2684 Declare `name' as char.
2685 (grub_afs_inode): Declare as packed.
2686 Change void *vnode to grub_uint32_t unused.
2687 (grub_afs_iterate_dir): Check that key_size is positive.
2688 (grub_afs_mount): Don't read superblock twice.
75421ca9 2689 (grub_afs_dir): Don't free node in case of error,
186f3189 2690 grub_fshelp_find_file already handles this.
2691 (grub_afs_open): Likewise.
2692
5680109e 26932009-07-19 Pavel Roskin <proski@gnu.org>
2694
2695 * Makefile.in: Remove LIBLZO and enable_lzo.
2696 * conf/i386-pc.rmk: Remove lzo support.
2697 * configure.ac: Remove checks for lzo, don't define ENABLE_LZMA.
2698 * include/grub/i386/pc/kernel.h: Define ENABLE_LZMA. Remove lzo
2699 support.
2700 * kern/i386/pc/lzo1x.S: Remove.
2701 * kern/i386/pc/startup.S: Remove lzo support.
2702 * util/i386/pc/grub-mkimage.c: Likewise.
2703
ac70fa32 27042009-07-19 Vladimir Serbinenko <phcoder@gmail.com>
2705
2706 * disk/usbms.c (grub_usbms_transfer): Fix double semicolon.
2707 * fs/xfs.c (grub_xfs_dir): Likewise.
2708 * fs/afs.c (grub_afs_dir): Likewise.
2709 * fs/iso9660.c (grub_iso9660_iterate_dir): Likewise.
2710 (grub_iso9660_open): Likewise.
2711 * fs/jfs.c (grub_jfs_open): Likewise.
2712 * fs/ext2.c (grub_ext2_dir): Likewise.
2713 * include/grub/macho.h (grub_macho_fat_arch): Likewise.
2714 * script/sh/lexer.c (grub_script_yylex): Likewise.
75421ca9 2715
eab58da2 27162009-07-16 Pavel Roskin <proski@gnu.org>
2717
d2838156 2718 * configure.ac: Never add "-c" to CFLAGS.
2719
55c70904 2720 * configure.ac: Fix incorrect comparison for grub_cv_cc_efiemu.
2721
43e6200c 2722 * configure.ac: Fix wrong use of grub_cv_cc_no_red_zone where
2723 grub_cv_cc_efiemu should be used.
2724
ce7a733d 2725 * configure.ac: Typo fixes.
2726
eab58da2 2727 * kern/mm.c (grub_zalloc): New function.
2728 (grub_debug_zalloc): Likewise.
2729 * include/grub/mm.h: Declare grub_zalloc() and
2730 grub_debug_zalloc().
2731 * util/misc.c (grub_zalloc): New function.
2732 * bus/usb/uhci.c (grub_uhci_pci_iter): Use grub_zalloc()
2733 instead of grub_malloc(), remove unneeded initializations.
2734 * bus/usb/usbhub.c (grub_usb_hub_add_dev): Likewise.
2735 * commands/extcmd.c (grub_extcmd_dispatcher): Likewise.
2736 * commands/parttool.c (grub_cmd_parttool): Likewise.
2737 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Likewise.
2738 * disk/raid5_recover.c (grub_raid5_recover): Likewise.
2739 * disk/raid6_recover.c (grub_raid6_recover): Likewise.
2740 * disk/usbms.c (grub_usbms_finddevs): Likewise.
2741 * efiemu/mm.c (grub_efiemu_request_memalign): Likewise.
2742 * efiemu/pnvram.c (grub_efiemu_pnvram): Likewise.
2743 (grub_cmd_efiemu_pnvram): Likewise.
2744 * fs/i386/pc/pxe.c (grub_pxefs_open): Likewise.
2745 * fs/iso9660.c (grub_iso9660_mount): Likewise.
2746 (grub_iso9660_iterate_dir): Likewise.
2747 * fs/jfs.c (grub_jfs_opendir): Likewise.
2748 * fs/ntfs.c (list_file): Likewise.
2749 (grub_ntfs_mount): Likewise.
2750 * kern/disk.c (grub_disk_open): Likewise.
2751 * kern/dl.c (grub_dl_load_core): Likewise.
2752 * kern/elf.c (grub_elf_file): Likewise.
2753 * kern/env.c (grub_env_context_open): Likewise.
2754 (grub_env_set): Likewise.
2755 (grub_env_set_data_slot): Likewise.
2756 * kern/file.c (grub_file_open): Likewise.
2757 * kern/fs.c (grub_fs_blocklist_open): Likewise.
2758 * loader/i386/multiboot.c (grub_module): Likewise.
2759 * loader/xnu.c (grub_xnu_create_key): Likewise.
2760 (grub_xnu_create_value): Likewise.
2761 * normal/main.c (grub_normal_add_menu_entry): Likewise.
2762 (read_config_file): Likewise.
2763 * normal/menu_entry.c (make_screen): Likewise.
2764 * partmap/sun.c (sun_partition_map_iterate): Likewise.
2765 * script/sh/lexer.c (grub_script_lexer_init): Likewise.
2766 * script/sh/script.c (grub_script_parse): Likewise.
2767 * video/bitmap.c (grub_video_bitmap_create): Likewise.
2768 * video/readers/jpeg.c (grub_video_reader_jpeg): Likewise.
2769 * video/readers/png.c (grub_png_output_byte): Likewise.
2770 (grub_video_reader_png): Likewise.
2771
830afef7 27722009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
5ce5507f 2773
2774 Enable all targets that can be built by default
2775
830afef7 2776 * configure.ac: enable efiemu runtime, grub-emu, grub-emu-usb,
5ce5507f 2777 grub-mkfont and grub-fstest if they can be built
2778
ee293aee 27792009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2780
2781 Fix hang and segmentation fault in grub-emu-usb
2782
2783 * disk/scsi.c (grub_scsi_open): return err and not grub_errno
2784 * util/usb.c (grub_libusb_devices): likewise
2785 (grub_libusb_init): rename to ...
2786 (GRUB_MOD_INIT (libusb)):...this
2787 (grub_libusb_fini): rename to ..
2788 (GRUB_MOD_FINI (libusb)):...this
2789 * disk/usbms.c (grub_usbms_transfer): fix retry logic
2790 * include/grub/disk.h (grub_raid_init): removed, it's useless
2791 (grub_raid_fini): likewise
2792 (grub_lvm_init): likewise
2793 (grub_lvm_fini): likewise
2794 * util/grub-emu.c (main): don't call grub_libusb_init, it's done
2795 by grub_init_all
2796
94414221 27972009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2798
2799 Fix libusb
2800
2801 * Makefile.in (LIBUSB): new macro
2802 * genmk.rb (Utility/print_tail): new method
2803 (Utility/rule): use intermediary variable #{prefix}_OBJECTS
2804 (top level): call util.print_tail at the end.
2805
59ade63d 28062009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2807
2808 Make FreeBSD accept zpool.cache
2809
2810 * loader/i386/bsd.c (grub_freebsd_add_meta_module): spoof filename if
2811 type is /boot/zfs/zpool.cache
2812
a58da8c7 28132009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2814
2815 Fix 64-bit efiemu
2816
2817 * include/grub/efiemu/efiemu.h (grub_efiemu_configuration_table64_t):
2818 correct wrong typedef
2819 * efiemu/prepare.c (SUFFIX (grub_efiemu_prepare)): minor style fixes
2820
20591577 28212009-07-15 Pavel Roskin <proski@gnu.org>
2822
560ca572 2823 * include/grub/disk.h (struct grub_disk_dev): Use enum for id.
2824 * kern/disk.c (struct grub_disk_cache): Likewise.
2825
e8e8e4fd 2826 * commands/probe.c (options): Typo fix.
2827
fde24e10 2828 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_BPB_END):
2829 Increase to 0x5a to accommodate FAT32. Adjust other offsets
2830 accordingly.
2831 Original patch by Yves Blusseau <yves.grub-devel@zetam.org>
2832
379c54c1 2833 * boot/i386/pc/boot.S (general_error_string): Add DOS newline at
2834 the end of "Error" to make the message more readable.
2835
7bd8f5bf 2836 * boot/i386/pc/boot.S (kernel_segment): Remove.
2837 (copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
2838 for destination.
2839
40b132c5 2840 * boot/i386/pc/boot.S (boot_version): Remove.
2841 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
2842 Remove.
2843
20591577 2844 * include/grub/i386/pc/boot.h: Sort all offsets.
2845 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Remove, it's unused.
2846 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Likewise.
2847 * boot/i386/pc/boot.S: Assert location of every offset listed in
2848 include/grub/i386/pc/boot.h.
2849
2df32b2c 28502009-07-13 Pavel Roskin <proski@gnu.org>
2851
44b5d879 2852 * include/grub/i386/coreboot/machine.h: Rename
2853 GRUB_MACHINE_LINUXBIOS to GRUB_MACHINE_COREBOOT.
2854 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Allow
2855 multiboot 1 for GRUB_MACHINE_COREBOOT and GRUB_MACHINE_QEMU.
2856
17dc3751 2857 * kern/dl.c: Force native word size to suppress warnings when
2858 compiling grub-emu.
2859
2df32b2c 2860 * kern/device.c (grub_device_iterate): Change struct part_ent to
2861 hold the name, not a pointer to it. Use one grub_malloc() per
2862 partition, not two. Free partition_name if grub_malloc() fails.
2863 Set ents to NULL only before grub_partition_iterate() is called.
2864
75c59f59 28652009-07-11 Bean <bean123ch@gmail.com>
2866
2867 * kern/ieee1275/openfw.c (grub_children_iterate): Fix size of
2868 childname.
2869
0ae1bf88 28702009-07-10 Bean <bean123ch@gmail.com>
28712009-07-10 Robert Millan <rmh.grub@aybabtu.com>
2872
2873 * kern/ieee1275/openfw.c (grub_children_iterate)
2874 (grub_devalias_iterate): Fix size evaluation for property or path
2875 strings, which was broken since r2132.
2876
8279cade 28772009-07-07 Pavel Roskin <proski@gnu.org>
2878
7d8a52d3 2879 * commands/search.c (search_file): Merge into ...
2880 (search_fs): ... this. Accept search type as argument.
2881 (grub_cmd_search): Pass search type to search_fs().
2882
25f9a05a 2883 * include/grub/util/console.h: New file.
2884 * util/console.c: Use it instead of grub/machine/console.h.
2885 * util/grub-emu.c: Likewise.
2886
8279cade 2887 * lib/arg.c (find_long_option): Remove.
2888 (find_long): Add `len' argument, make `s' const char *.
2889 (grub_arg_parse): Parse long options in place, not in a
2890 temporary buffer.
2891
4a11b60f 28922009-07-06 Pavel Roskin <proski@gnu.org>
2893
99f68041 2894 * commands/search.c (search_fs): Fix potential NULL pointer
2895 dereference.
2896
4a11b60f 2897 * commands/search.c (search_fs): Replace QUID macro with quid_fn
2898 function pointer.
2899
e110f4de 29002009-07-06 Daniel Mierswa <impulze@impulze.org>
2901
2902 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
2903 comparison.
2904
46eeb6a2 29052009-07-05 Pavel Roskin <proski@gnu.org>
2906
bab74958 2907 * include/grub/i386/linux.h (struct linux_kernel_params):
2908 Restore padding3, it's still needed.
2909
46eeb6a2 2910 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
2911 FreeBSD.
2912 * util/osdetect.lua: Likewise.
2913
b4a1dc79 29142009-07-05 Bean <bean123ch@gmail.com>
2915
2916 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
2917
2918 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
2919 (grub_lua_getenv): Likewise.
2920 (grub_lua_setenv): Likewise.
2921 (save_errno): New function.
2922 (push_result): Likewise.
2923 (grub_lua_enum_device): Likewise.
2924 (grub_lua_enum_file): Likewise.
2925 (grub_lua_file_open): Likewise.
2926 (grub_lua_file_close): Likewise.
2927 (grub_lua_file_seek): Likewise.
2928 (grub_lua_file_read): Likewise.
2929 (grub_lua_file_getline): Likewise.
2930 (grub_lua_file_getsize): Likewise.
2931 (grub_lua_file_getpos): Likewise.
2932 (grub_lua_file_eof): Likewise.
2933 (grub_lua_file_exist): Likewise.
2934 (grub_lua_add_menu): Likewise.
2935
2936 * script/lua/grub_lua.h (isupper): New inline function.
2937 (islower): Likewise.
2938 (ispunct): Likewise.
2939 (isxdigit): Likewise.
2940 (strcspn): Change to normal function.
2941 (strpbkr): New function declaration.
2942 (memchr): Likewise.
2943
2944 * script/lua/grub_main.c (scan_str): New function.
2945 (strcspn): Likewise.
2946 (strpbrk): Likewise.
2947 (memchr): Likewise.
2948
2949 * script/lua/linit.c (lualibs): Enable the string library.
2950
2951 * util/osdetect.lua: New file.
2952
2da92295 29532009-07-04 Robert Millan <rmh.grub@aybabtu.com>
2954
2955 * include/grub/i386/linux.h (struct linux_kernel_params): Add
2956 `capabilities' member.
2957
b2582ec9 29582009-07-02 Pavel Roskin <proski@gnu.org>
2959
2960 * genparttoollist.sh: Add missing newline at the end.
2961
32622956 29622009-07-01 Pavel Roskin <proski@gnu.org>
2963
87a7339e 2964 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
2965
d23af54e 2966 * util/hostdisk.c (open_device): Remove `const' from
2967 `sysctl_size', as sysctlbyname() can change it (in this case it
2968 doesn't actually happen).
2969
c94b18a9 2970 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
2971 using signed long int constants.
2972
c6cd3ef0 2973 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
2974 constant to avoid a warning on FreeBSD.
2975
0df63420 2976 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
2977 where it's needed.
2978
999577f1 2979 * Makefile.in: Install include/grub/machine symlink.
2980
6f41557f 2981 * Makefile.in: When installing symlinks, use "cp -fR", which
2982 works on FreeBSD and MacOSX.
2983 From Yves Blusseau <cl7m42e02@sneakemail.com>
2984
c8d22988 2985 * kern/dl.c (grub_dl_resolve_symbol): Make static.
2986 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
2987
1b96e952 2988 * util/misc.c: Move grub_reboot() and grub_halt() ...
2989 * util/grub-emu.c: ... here. Make main_env static.
2990 * include/grub/util/misc.h: Remove main_env.
2991
2ef0084d 2992 * kern/mm.c: Use correct format to print size_t.
2993
32622956 2994 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
2995 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
2996 * kern/powerpc/dl.c: Likewise.
2997 * kern/sparc64/dl.c: Likewise.
2998 * kern/x86_64/dl.c: Likewise.
2999
3f7f0cd0 30002009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3001
3002 Fix grub-emu build on sparc64-ieee1275.
3003
75421ca9 3004 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Synchronize with ...
3f7f0cd0 3005 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
3006
211d06b5 30072009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3008
3009 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
3010 (grub_reboot, grub_halt): New functions.
3011
3012 * util/i386/pc/misc.c: Delete. Update all users.
3013 * util/sparc64/ieee1275/misc.c: Likewise.
3014 * util/powerpc/ieee1275/misc.c: Likewise.
3015
aaf53e3c 30162009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3017
3018 * conf/i386.rmk (setjmp_mod_SOURCES)
3019 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
3020 * conf/common.rmk (setjmp_mod_SOURCES)
3021 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
3022 to use $(target_cpu).
3023 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
3024 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
3025 * conf/powerpc-ieee1275.rmk: Likewise.
3026 * conf/sparc64-ieee1275.rmk: Likewise.
3027
3028 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
3029 $(target_cpu) for kern/$(target_cpu)/dl.c.
3030 * conf/i386-efi.rmk: Likewise.
3031 * conf/i386-ieee1275.rmk: Likewise.
3032 * conf/x86_64-efi.rmk: Likewise.
3033 * conf/i386-coreboot.rmk: Likewise.
3034 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
3035 $(target_cpu) for kern/$(target_cpu)/dl.c and for
3036 kern/$(target_cpu)/cache.S.
3037 * conf/sparc64-ieee1275.rmk: Likewise.
3038
a337130b 30392009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3040
3041 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
3042 type to `grub_uint8_t', and adjust `padding9' accordingly.
3043
c6fe4d53 30442009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3045
b09db61d 3046 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
3047
c6fe4d53 3048 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
3049 assembly in final jump, using register constraints.
3050
b09db61d 3051 (grub_linux_boot): For text mode, initialize `have_vga' using
3052 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
3053
3054 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
3055 right before the final jump.
3056
3057 Set `video_mode' to 0x3.
3058
3059 Document initialization of `video_page', `video_mode' and
3060 `video_ega_bx'.
3061
28333ad0 30622009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3063
3064 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
3065 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
75421ca9 3066 and set GRUB_LINUX_FLAG_QUIET appropriately.
28333ad0 3067
02164e1b 30682009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3069
3070 Fix build on Debian / sparc.
3071
3072 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
3073
18b6c557 30742009-06-28 Pavel Roskin <proski@gnu.org>
3075
85f2aab6 3076 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
3077 fix a warning.
3078
18b6c557 3079 * util/grub.d/10_linux.in: Match SUSE style initrd names.
3080
ad760f81 30812009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3082
3083 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
3084 `err'.
3085
87a4623b 30862009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3087
3088 Revert r2338.
3089
3090 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
3091 file can't be opened. grub_file_open() is already supposed to set
75421ca9 3092 grub_errno / grub_errmsg appropriately.
87a4623b 3093 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3094
8231fb77 30952009-06-27 Pavel Roskin <proski@gnu.org>
30962009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3097
3098 * include/grub/dl.h: Include grub/elf.h.
3099 (struct grub_dl): Add symtab field.
3100 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
3101 GRUB_MODULES_MACHINE_READONLY.
3102 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
3103 of the header for read-only modules.
3104 (grub_dl_unload): Free mod->symtab for read-only modules.
3105 * kern/i386/dl.c: Use mod->symtab.
3106 * kern/powerpc/dl.c: Likewise.
3107 * kern/sparc64/dl.c: Likewise.
3108 * kern/x86_64/dl.c: Likewise.
3109
3110 * conf/i386-qemu.rmk: New file.
3111 * kern/i386/qemu/startup.S: Likewise.
3112 * kern/i386/qemu/mmap.c: Likewise.
3113 * boot/i386/qemu/boot.S: Likewise.
3114 * include/grub/i386/qemu/time.h: Likewise.
3115 * include/grub/i386/qemu/serial.h: Likewise.
3116 * include/grub/i386/qemu/kernel.h: Likewise.
3117 * include/grub/i386/qemu/console.h: Likewise.
3118 * include/grub/i386/qemu/boot.h: Likewise.
3119 * include/grub/i386/qemu/init.h: Likewise.
3120 * include/grub/i386/qemu/machine.h: Likewise.
3121 * include/grub/i386/qemu/loader.h: Likewise.
3122 * include/grub/i386/qemu/memory.h: Likewise.
3123
3124 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
3125 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
3126 [qemu] (pkglib_IMAGES): Add `boot.img'.
3127 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
3128 [qemu] (boot_img_FORMAT): New variables.
3129 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
3130 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
3131 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
3132 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
3133 [qemu] (kernel_img_FORMAT): New variables.
3134
3135 * configure.ac: Recognise `i386-qemu'.
3136
3137 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
3138 (for no compression).
3139 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
3140 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
3141 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
3142 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
3143 ifdefs).
3144
97fe384e 31452009-06-27 Pavel Roskin <proski@gnu.org>
3146
3147 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
3148 read.
3149 * efiemu/prepare32.c: Likewise.
3150 * efiemu/prepare64.c: Likewise.
3151
c402ab17 31522009-06-26 Pavel Roskin <proski@gnu.org>
3153
3154 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
3155 * include/grub/elf.h: Define symbols without "32" or "64" based
3156 on GRUB_TARGET_WORDSIZE.
3157 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
3158 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
3159 ELF definitions.
3160 * efiemu/loadcore64.c: Likewise.
3161 * loader/i386/bsd32.c: Likewise.
3162 * loader/i386/bsd64.c: Likewise.
3163 * kern/dl.c: Remove own ELF definitions.
3164 * util/i386/efi/grub-mkimage.c: Likewise.
3165
9bbdfd4d 31662009-06-23 Robert Millan <rmh.grub@aybabtu.com>
3167
3168 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
3169 segment 0x0 unconditionally, because the reference generated by
3170 GAS is an absolute address.
3171
a42ce6e9 31722009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3173
3174 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
3175 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
3176
c952cf92 31772009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3178
3179 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
3180 indexes. Check for -f explicitly.
cc3752ad 3181 (search_file): Improve error message.
3182 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
c952cf92 3183
132a0a59 31842009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3185
3186 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
3187 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
3188
387a140c 31892009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3190
3191 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
3192 * conf/i386-ieee1275.rmk: Likewise.
3193 * conf/i386-coreboot.rmk: Likewise.
3194
3195 * kern/i386/pc/startup.S (grub_stop): Remove function.
3196 * kern/i386/ieee1275/startup.S: Likewise.
3197 * kern/i386/coreboot/startup.S: Likewise.
3198 * kern/i386/misc.S (grub_stop): New function.
3199
41da9665 32002009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3201
3202 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
3203 * kern/i386/realmode.S (real_to_prot): ... to here.
3204
bf337234 32052009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3206
3207 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
3208 with `kernel.img'.
3209 (kernel_elf_SOURCES): Rename to ...
3210 (kernel_img_SOURCES): ... this.
3211 (kernel_elf_HEADERS): Rename to ...
3212 (kernel_img_HEADERS): ... this. Update all users.
3213 (kernel_elf_ASFLAGS): Rename to ...
3214 (kernel_img_ASFLAGS): ... this.
3215 (kernel_elf_CFLAGS): Rename to ...
3216 (kernel_img_CFLAGS): ... this.
3217 (kernel_elf_LDFLAGS): Rename to ...
3218 (kernel_img_LDFLAGS): ... this.
3219 * conf/i386-coreboot.rmk: Likewise.
3220 * conf/powerpc-ieee1275.rmk: Likewise.
3221
3222 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
3223 with "kernel.img".
3224
f52196ff 32252009-06-21 Pavel Roskin <proski@gnu.org>
3226
c3cee413 3227 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
3228 to match nested functions.
3229 * loader/sparc64/ieee1275/linux.c: Likewise.
3230
f52196ff 3231 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
3232
58750afc 32332009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3234
3235 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
3236 all i386 platforms.
3237
15355c7d 32382009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3239
3240 Fix asm file handling on ELF, and remove workarounds.
3241
3242 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
75421ca9 3243 and -DASM_FILE=1 appropriately (copied from `class Images' stanza).
15355c7d 3244 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
3245 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
3246
3f3ec72b 32472009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
3248
3249 Load BSD ELF modules
3250
3251 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
3252 and loader/i386/bsd64.c
3253 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
3254 (FREEBSD_MODTYPE_ELF_MODULE): New definition
3255 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
3256 (grub_freebsd_load_elfmodule32): New declaration
3257 (grub_freebsd_load_elfmoduleobj64): Likewise
3258 (grub_freebsd_load_elf_meta32): Likewise
3259 (grub_freebsd_load_elf_meta64): Likewise
3260 (grub_freebsd_add_meta): Likewise
3261 (grub_freebsd_add_meta_module): Likewise
3262 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
3263 (grub_freebsd_add_meta_module): Likewise and move module-specific
3264 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
3265 (grub_cmd_freebsd): Add elf-kernel specific parts
3266 based on grub_freebsd_add_meta_module
3267 (grub_cmd_freebsd_module): Add type parsing moved from
3268 grub_freebsd_add_meta_module
3269 (grub_cmd_freebsd_module_elf): New function
3270 (cmd_freebsd_module_elf): New variable
3271 (GRUB_MOD_INIT): Register freebsd_module_elf
3272 * loader/i386/bsd32.c: New file
3273 * loader/i386/bsd64.c: Likewise
3274 * loader/i386/bsdXX.c: Likewise
3275 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
3276 (grub_elf64_load): Likewise
3277 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
3278 All users updated
3279 (grub_elf64_load_hook_t): Likewise
3280
0db15301 32812009-06-21 Colin Watson <cjwatson@ubuntu.com>
3282
3283 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
3284 variable.
3285 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
3286 don't write a menu entry for recovery mode.
3287
546796c1 32882009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3289
3290 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
3291 after it's no longer needed.
3292
cd7310d5 32932009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3294
3295 * include/grub/i386/loader.h (grub_linux_prot_size)
3296 (grub_linux_tmp_addr, grub_linux_real_addr)
3297 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
3298 GRUB_MACHINE_PCBIOS.
3299 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
3300 common grub_util_info() call to ...
3301 (generate_image): ... here.
3302 Fix use of uninitialized memory, comparison of signed with
3303 unsigned integers and memory leak.
3304 Remove bogus module address message.
3305
ab32d3b5 33062009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
3307
3308 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
3309 grub_raid_register
3310 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
3311
024ef597 33122009-06-19 Pavel Roskin <proski@gnu.org>
3313
3314 * configure.ac: Remove stray AC_MSG_CHECKING.
3315
3ac72b51 33162009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
3317
3318 * disk/scsi.c (grub_scsi_open): use continue instead of big if
dd74360c 3319
e14cd814 33202009-06-18 Pavel Roskin <proski@gnu.org>
3321
3322 * conf/common.rmk: Add fs_file.mod.
3323 * disk/fs_file.c: New file.
3324 * include/grub/disk.h (enum grub_disk_dev_id): Add
3325 GRUB_DISK_DEVICE_FILE_ID.
3326
26586d98 33272009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3328
3329 Fix build with Apple's toolchain. Part 2
3330
3331 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
3332 a fake start
3333
26de2bcd 33342009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3335
3336 Fix build with Apple's toolchain. Part 1
3337
3338 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
3339 for long calls
3340 * configure.ac: remove a leftover AC_MSG_RESULT
dd74360c 3341 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
26de2bcd 3342 Apple's toolchain
3343
09b3490b 33442009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3345
3346 Fix warnings
3347
3348 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
3349 (decomp_block): initialize ch
3350 use grub_memcpy instead of memcpy
3351
c22a006a 33522009-06-17 Pavel Roskin <proski@gnu.org>
3353
d3638678 3354 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
3355 version, use declarations needed to use vga_text as the startup
3356 console.
3357
c22a006a 3358 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
3359 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
3360 the kernel.
3361 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
3362 and grub_at_keyboard_fini(), it's done on module load and
3363 unload.
3364
05b129e0 33652009-06-17 Felix Zielcke <fzielcke@z-51.de>
3366
3367 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
3368 file can't be found.
3369 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3370
cf24ed9e 33712009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3372
3373 Fix newline handling
3374
3375 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
dd74360c 3376 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
cf24ed9e 3377 (grub_script_yylex): don't segfault on unterminated script
3378 newline terminates command and variable
3379
74aa8e4b 33802009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3381
3382 avoid double grub_adjust_range call. Bug reported by David Simner
3383
3384 * kern/disk.c (grub_disk_write): change to raw disk access before
3385 calling disk_read
3386
1bd265f3 33872009-06-17 Colin Watson <cjwatson@ubuntu.com>
3388
3389 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
3390 spaces, for the benefit of help2man.
3391 * util/i386/efi/grub-mkimage.c (usage): Likewise.
3392
a2d08c06 33932009-06-16 Pavel Roskin <proski@gnu.org>
3394
3395 * kern/i386/halt.c: Include grub/machine/init.h.
3396 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
3397
b97bcb19 33982009-06-16 Felix Zielcke <fzielcke@z-51.de>
3399
3400 * util/grub.d/30_os-prober.in: Use ${root} in the generated
3401 drivemap menuentry.
3402
0644f96c 34032009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
3404
3405 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
3406 `echo' command.
3407
3ef17a2e 34082009-06-16 Pavel Roskin <proski@gnu.org>
3409
3410 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
3411 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
3412 save %dx, we only need %dl and we never change it.
3413 * boot/i386/pc/cdboot.S: Don't set the root drive.
3414 * boot/i386/pc/pxeboot.S: Likewise.
3415 * include/grub/i386/pc/boot.h: Remove
3416 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
3417 GRUB_BOOT_MACHINE_DRIVE_CHECK.
3418 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
3419 * kern/i386/pc/init.c (make_install_device): Remove references
3420 to grub_root_drive.
3421 * kern/i386/pc/startup.S: Likewise.
3422 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
3423
693fe637 34242009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3425
3426 xnu_uuid command
3427
3428 * commands/xnu_uuid.c: new file
3429 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
3430 (xnu_uuid_mod_SOURCES): new variable
3431 (xnu_uuid_mod_CFLAGS): likewise
3432 (xnu_uuid_mod_LDFLAGS): likewise
3433 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3434 * conf/i386-ieee1275.rmk: likewise
3435 * conf/i386-pc.rmk: likewise
3436 * conf/powerpc-ieee1275.rmk: likewise
3437 * conf/sparc64-ieee1275.rmk: likewise
3438 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
3439
c9da87d0 34402009-06-16 Pavel Roskin <proski@gnu.org>
3441
3442 * configure.ac: Avoid '==' in test command, it's not portable.
3443
9c6f4596 34442009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3445
3446 Probe command
3447
3448 * commands/probe.c: new file
3449 * conf/common.rmk (pkglib_MODULES): add probe.mod
3450 (probe_mod_SOURCES): new variable
3451 (probe_mod_CFLAGS): likewise
3452 (probe_mod_LDFLAGS): likewise
3453 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3454 * conf/i386-ieee1275.rmk: likewise
3455 * conf/i386-pc.rmk: likewise
3456 * conf/powerpc-ieee1275.rmk: likewise
3457 * conf/sparc64-ieee1275.rmk: likewise
3458
70b7f9fd 34592009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
3460
3461 Fix handling of string like \"hello\" and "a
3462 b"
3463
3464 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
3465 (grub_script_yylex): fix parsing of quoting, escaping and newline
3466
71c79a6b 34672009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
3468
dd74360c 3469 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
71c79a6b 3470 handling
dd74360c 3471
0644f96c 34722009-06-13 Jun Inoue <jun.lambda@gmail.com>
880fc3c4 3473
3474 * util/grub-mkconfig.in: Fix parsing of --output option.
3475
e40893c3 34762009-06-12 Pavel Roskin <proski@gnu.org>
3477
3478 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
3479 genmk.rb don't need to be generated or installed.
3480
3a1acfe2 34812009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
3482
3483 * commands/i386/pc/drivemap_int13h.S: add more comments
3484
3a4575d4 34852009-06-11 Pavel Roskin <proski@gnu.org>
3486
0658e928 3487 * Makefile.in (uninstall): Uninstall manuals.
3488
ca0388f0 3489 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
3490 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
3491 and update-grub_lib in two places.
3492 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
3493
e3b27c39 3494 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
3495 a compiler warning.
3496
3a4575d4 3497 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
3498 `entry_lo' to fix variable shadowing.
3499
af1f4f55 35002009-06-11 Christian Franke <franke@computer.org>
3501
3502 * kern/misc.c (__enable_execute_stack): Add missing return type
3503 to prevent gcc warning.
3504
5225e649 35052009-06-11 Felix Zielcke <fzielcke@z-51.de>
3506
3507 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
3508
7d83bd47 35092009-06-11 Pavel Roskin <proski@gnu.org>
3510
c1cb63ba 3511 * Makefile.in: Don't rely on any scripts being executable.
3512 Always use $(SHELL) to run shell scripts.
3513
7d83bd47 3514 * configure.ac: Always define ___main if using -nostdlib. This
3515 fixes tests on Cygwin.
3516
948f48e7 35172009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
3518
3519 UDF fix
3520
7d83bd47 3521 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
948f48e7 3522 is in bytes and not in blocks
7d83bd47 3523
8ada9bc1 35242009-06-11 Pavel Roskin <proski@gnu.org>
3525
3526 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
3527 warning.
3528
25ad2323 35292009-06-11 Felix Zielcke <fzielcke@z-51.de>
3530
3531 * util/grub.d/30_os-prober.in: Fix a comment. Source
3532 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
3533 to set the root device. Place drivemap command in the generated
3534 chain entry.
3535
e65acb0c 35362009-06-11 Pavel Roskin <proski@gnu.org>
3537
3538 * configure.ac: Remove host_m32. Issues with 64-bit utilities
3539 have long been resolved.
3540
f285fe2d 35412009-06-11 Colin Watson <cjwatson@ubuntu.com>
3542
bd47b0b5 3543 * util/grub.d/10_linux.in: Capitalise "Linux".
3544
f285fe2d 3545 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
3546
a0c62e4e 35472009-06-11 Pavel Roskin <proski@gnu.org>
3548
b6783cb2 3549 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
3550 fix a gcc warning and ensure that the function won't ever exit.
3551
dde032e8 3552 * kern/i386/ieee1275/init.c: Add missing prototype for
3553 grub_stop_floppy().
3554
22cd079d 3555 * loader/ieee1275/multiboot2.c [__i386__]: Include
3556 grub/cpu/multiboot.h.
3557
a0c62e4e 3558 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
3559 casts to short - they are not portable and cause warnings. Fix
3560 use of uninitialized values in input_buf. Use ARRAY_SIZE.
3561
63963d17 35622009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
3563
3564 Drivemap fixes
3565
3566 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
3567 new function
3568 (grub_get_root_biosnumber_saved): new variable
3569 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
3570 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
775dbc4d 3571 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
63963d17 3572 %dx after the call if necessary
3573 * conf/common.rmk (pkglib_MODULES): remove boot.mod
3574 (boot_mod_SOURCES): remove
3575 (boot_mod_CFLAGS): remove
3576 (boot_mod_LDFLAGS): remove
3577 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
3578 (boot_mod_SOURCES): new variable
3579 (boot_mod_CFLAGS): likewise
3580 (boot_mod_LDFLAGS): likewise
3581 * conf/i386-efi.rmk: likewise
3582 * conf/i386-ieee1275.rmk: likewise
3583 * conf/i386-pc.rmk: likewise
3584 * conf/powerpc-ieee1275.rmk: likewise
3585 * conf/sparc64-ieee1275.rmk: likewise
3586 * conf/x86_64-efi.rmk: likewise
3587 * include/grub/i386/pc/biosnum.h: new file
3588 * lib/i386/pc/biosnum.c: likewise
3589 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
3590 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
3591 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
775dbc4d 3592
33abf7ae 35932009-06-10 Pavel Roskin <proski@gnu.org>
3594
5ac35b35 3595 * io/gzio.c (test_header): Don't reuse one buffer for all data.
3596 Use separate variables. Read only the file size at the end, but
3597 not the checksum that we don't use.
3598
5c5215d5 3599 * kern/file.c (grub_file_read): Use void pointer for the buffer.
3600 Adjust all callers.
3601
27d5fef7 3602 * kern/ieee1275/openfw.c: Remove libc includes.
3603 * kern/ieee1275/cmain.c: Likewise.
3604 * include/grub/ieee1275/ieee1275.h: Likewise.
3605
33abf7ae 3606 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
3607 compiler warnings.
3608
19d50c2b 36092009-06-10 Felix Zielcke <fzielcke@z-51.de>
3610
3611 * Makefile.in: Remove all trailing whitespace.
3612 * conf/i386-pc.rmk: Likewise.
3613 * conf/powerpc-ieee1275.rmk: Likewise.
3614 * conf/sparc64-ieee1275.rmk: Likewise.
3615 * docs/grub.texi: Likewise.
3616 * docs/texinfo.tex: Likewise.
3617 * disk/fs_uuid.c: Likewise.
3618 * disk/lvm.c: Likewise.
3619 * disk/scsi.c: Likewise.
3620 * disk/ata.c: Likewise.
3621 * disk/ieee1275/ofdisk.c: Likewise.
3622 * disk/i386/pc/biosdisk.c: Likewise.
3623 * disk/host.c: Likewise.
3624 * disk/raid.c: Likewise.
3625 * disk/efi/efidisk.c: Likewise.
3626 * disk/usbms.c: Likewise.
3627 * disk/memdisk.c: Likewise.
3628 * disk/loopback.c: Likewise.
3629 * kern/powerpc/dl.c: Likewise.
3630 * kern/device.c: Likewise.
3631 * kern/dl.c: Likewise.
3632 * kern/sparc64/dl.c: Likewise.
3633 * kern/ieee1275/ieee1275.c: Likewise.
3634 * kern/term.c: Likewise.
3635 * kern/fs.c: Likewise.
3636 * kern/i386/dl.c: Likewise.
3637 * kern/i386/pc/startup.S: Likewise.
3638 * kern/i386/pc/init.c: Likewise.
3639 * kern/i386/pc/mmap.c: Likewise.
3640 * kern/i386/pc/lzo1x.S: Likewise.
3641 * kern/i386/ieee1275/init.c: Likewise.
3642 * kern/i386/realmode.S: Likewise.
3643 * kern/i386/tsc.c: Likewise.
3644 * kern/partition.c: Likewise.
3645 * kern/corecmd.c: Likewise.
3646 * kern/file.c: Likewise.
3647 * kern/efi/efi.c: Likewise.
3648 * kern/efi/init.c: Likewise.
3649 * kern/efi/mm.c: Likewise.
3650 * kern/main.c: Likewise.
3651 * kern/err.c: Likewise.
3652 * kern/env.c: Likewise.
3653 * kern/disk.c: Likewise.
3654 * kern/generic/millisleep.c: Likewise.
3655 * kern/generic/rtc_get_time_ms.c: Likewise.
3656 * kern/misc.c: Likewise.
3657 * kern/parser.c: Likewise.
3658 * genmk.rb: Likewise.
3659 * configure.ac: Likewise.
3660 * boot/i386/pc/diskboot.S: Likewise.
3661 * boot/i386/pc/pxeboot.S: Likewise.
3662 * boot/i386/pc/boot.S: Likewise.
3663 * boot/i386/pc/lnxboot.S: Likewise.
3664 * boot/i386/pc/cdboot.S: Likewise.
3665 * parttool/pcpart.c: Likewise.
3666 * video/readers/tga.c: Likewise.
3667 * video/video.c: Likewise.
3668 * video/bitmap.c: Likewise.
3669 * lib/envblk.c: Likewise.
3670 * lib/i386/setjmp.S: Likewise.
3671 * fs/xfs.c: Likewise.
3672 * fs/afs.c: Likewise.
3673 * fs/fat.c: Likewise.
3674 * fs/ntfs.c: Likewise.
3675 * fs/udf.c: Likewise.
3676 * fs/affs.c: Likewise.
3677 * fs/iso9660.c: Likewise.
3678 * fs/hfs.c: Likewise.
3679 * fs/fshelp.c: Likewise.
3680 * fs/ext2.c: Likewise.
3681 * fs/jfs.c: Likewise.
3682 * fs/reiserfs.c: Likewise.
3683 * fs/hfsplus.c: Likewise.
3684 * fs/minix.c: Likewise.
3685 * fs/cpio.c: Likewise.
3686 * fs/sfs.c: Likewise.
3687 * fs/ufs.c: Likewise.
3688 * efiemu/prepare.c: Likewise.
3689 * efiemu/loadcore_common.c: Likewise.
3690 * efiemu/runtime/efiemu.sh: Likewise.
3691 * efiemu/runtime/efiemu.S: Likewise.
3692 * efiemu/runtime/efiemu.c: Likewise.
3693 * efiemu/pnvram.c: Likewise.
3694 * efiemu/main.c: Likewise.
3695 * efiemu/i386/pc/cfgtables.c: Likewise.
3696 * efiemu/i386/loadcore64.c: Likewise.
3697 * efiemu/i386/loadcore32.c: Likewise.
3698 * efiemu/loadcore.c: Likewise.
3699 * efiemu/symbols.c: Likewise.
3700 * efiemu/mm.c: Likewise.
3701 * include/grub/autoefi.h: Likewise.
3702 * include/grub/datetime.h: Likewise.
3703 * include/grub/term.h: Likewise.
3704 * include/grub/hfs.h: Likewise.
3705 * include/grub/lvm.h: Likewise.
3706 * include/grub/i386/tsc.h: Likewise.
3707 * include/grub/i386/linux.h: Likewise.
3708 * include/grub/i386/xnu.h: Likewise.
3709 * include/grub/i386/efiemu.h: Likewise.
3710 * include/grub/i386/pc/biosdisk.h: Likewise.
3711 * include/grub/i386/pc/memory.h: Likewise.
3712 * include/grub/i386/pc/vbe.h: Likewise.
3713 * include/grub/parttool.h: Likewise.
3714 * include/grub/video.h: Likewise.
3715 * include/grub/memory.h: Likewise.
3716 * include/grub/fs.h: Likewise.
3717 * include/grub/partition.h: Likewise.
3718 * include/grub/xnu.h: Likewise.
3719 * include/grub/efi/api.h: Likewise.
3720 * include/grub/efi/pe32.h: Likewise.
3721 * include/grub/efi/memory.h: Likewise.
3722 * include/grub/multiboot.h: Likewise.
3723 * include/grub/usbdesc.h: Likewise.
3724 * include/grub/multiboot2.h: Likewise.
3725 * include/grub/acpi.h: Likewise.
3726 * include/grub/efiemu/efiemu.h: Likewise.
3727 * include/grub/disk.h: Likewise.
3728 * include/grub/ieee1275/ieee1275.h: Likewise.
3729 * include/grub/net.h: Likewise.
3730 * include/grub/machoload.h: Likewise.
3731 * include/grub/macho.h: Likewise.
3732 * include/multiboot.h: Likewise.
3733 * genmoddep.awk: Likewise.
3734 * normal/main.c: Likewise.
3735 * normal/menu_entry.c: Likewise.
3736 * normal/menu_viewer.c: Likewise.
3737 * normal/completion.c: Likewise.
3738 * normal/cmdline.c: Likewise.
3739 * normal/misc.c: Likewise.
3740 * normal/datetime.c: Likewise.
3741 * bus/usb/usbtrans.c: Likewise.
3742 * bus/usb/ohci.c: Likewise.
3743 * bus/usb/uhci.c: Likewise.
3744 * bus/usb/usb.c: Likewise.
3745 * mmap/efi/mmap.c: Likewise.
3746 * mmap/i386/pc/mmap_helper.S: Likewise.
3747 * mmap/i386/pc/mmap.c: Likewise.
3748 * mmap/i386/mmap.c: Likewise.
3749 * mmap/i386/uppermem.c: Likewise.
3750 * mmap/mmap.c: Likewise.
3751 * commands/acpi.c: Likewise.
3752 * commands/echo.c: Likewise.
3753 * commands/blocklist.c: Likewise.
3754 * commands/loadenv.c: Likewise.
3755 * commands/usbtest.c: Likewise.
3756 * commands/boot.c: Likewise.
3757 * commands/parttool.c: Likewise.
3758 * commands/search.c: Likewise.
3759 * commands/cat.c: Likewise.
3760 * commands/i386/pc/play.c: Likewise.
3761 * commands/i386/pc/drivemap.c: Likewise.
3762 * commands/i386/pc/vbeinfo.c: Likewise.
3763 * commands/i386/pc/acpi.c: Likewise.
3764 * commands/i386/pc/vbetest.c: Likewise.
3765 * commands/ls.c: Likewise.
3766 * commands/cmp.c: Likewise.
3767 * commands/test.c: Likewise.
3768 * commands/efi/acpi.c: Likewise.
3769 * commands/gptsync.c: Likewise.
3770 * commands/help.c: Likewise.
3771 * partmap/amiga.c: Likewise.
3772 * partmap/apple.c: Likewise.
3773 * partmap/acorn.c: Likewise.
3774 * partmap/pc.c: Likewise.
3775 * partmap/sun.c: Likewise.
3776 * partmap/gpt.c: Likewise.
3777 * script/sh/lexer.c: Likewise.
3778 * script/sh/function.c: Likewise.
3779 * font/font.c: Likewise.
3780 * font/font_cmd.c: Likewise.
3781 * loader/powerpc/ieee1275/linux.c: Likewise.
3782 * loader/efi/chainloader.c: Likewise.
3783 * loader/multiboot_loader.c: Likewise.
3784 * loader/macho.c: Likewise.
3785 * loader/i386/multiboot.c: Likewise.
3786 * loader/i386/linux.c: Likewise.
3787 * loader/i386/pc/linux.c: Likewise.
3788 * loader/i386/pc/multiboot2.c: Likewise.
3789 * loader/i386/pc/chainloader.c: Likewise.
3790 * loader/i386/pc/xnu.c: Likewise.
3791 * loader/i386/bsd_trampoline.S: Likewise.
3792 * loader/i386/efi/linux.c: Likewise.
3793 * loader/i386/multiboot_elfxx.c: Likewise.
3794 * loader/i386/bsd_helper.S: Likewise.
3795 * loader/i386/bsd.c: Likewise.
3796 * loader/i386/linux_trampoline.S: Likewise.
3797 * loader/i386/xnu_helper.S: Likewise.
3798 * loader/i386/xnu.c: Likewise.
3799 * loader/i386/bsd_pagetable.c: Likewise.
3800 * loader/i386/multiboot_helper.S: Likewise.
3801 * loader/xnu.c: Likewise.
3802 * loader/xnu_resume.c: Likewise.
3803 * io/gzio.c: Likewise.
3804 * term/efi/console.c: Likewise.
3805 * term/terminfo.c: Likewise.
3806 * term/ieee1275/ofconsole.c: Likewise.
3807 * term/i386/pc/serial.c: Likewise.
3808 * term/i386/pc/vesafb.c: Likewise.
3809 * term/i386/pc/vga.c: Likewise.
3810 * term/usb_keyboard.c: Likewise.
3811 * term/gfxterm.c: Likewise.
3812 * aclocal.m4: Likewise.
3813 * util/lvm.c: Likewise.
3814 * util/grub.d/30_os-prober.in: Likewise.
3815 * util/grub.d/10_hurd.in: Likewise.
3816 * util/console.c: Likewise.
3817 * util/grub-macho2img.c: Likewise.
3818 * util/grub-probe.c: Likewise.
3819 * util/hostfs.c: Likewise.
3820 * util/i386/pc/grub-mkimage.c: Likewise.
3821 * util/i386/pc/grub-setup.c: Likewise.
3822 * util/i386/efi/grub-mkimage.c: Likewise.
3823 * util/grub-mkconfig.in: Likewise.
3824 * util/raid.c: Likewise.
3825 * util/resolve.c: Likewise.
3826 * util/grub-mkdevicemap.c: Likewise.
3827 * util/grub-emu.c: Likewise.
3828 * util/getroot.c: Likewise.
3829 * util/hostdisk.c: Likewise.
3830 * util/usb.c: Likewise.
3831 * util/grub-editenv.c: Likewise.
3832 * util/misc.c: Likewise.
3833
d2d49665 38342009-06-10 Felix Zielcke <fzielcke@z-51.de>
3835
3836 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
3837 `genparttoollist.sh'.
3838 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
3839 Add `*.sh' to the list find searches for and change `mdate.sh'
3840 to `mdate-sh'.
3841
fe052e37 38422009-06-10 Pavel Roskin <proski@gnu.org>
3843
2763ac18 3844 * include/grub/multiboot2.h: Provide compatibility defines for
3845 multiboot2.h.
3846 * include/multiboot2.h: Include stdint.h only if needed, using
3847 angle brackets.
3848 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
3849 grub/multiboot2.h.
3850 * loader/ieee1275/multiboot2.c: Likewise.
3851 * loader/multiboot2.c: Likewise.
3852 * loader/multiboot_loader.c: Likewise.
3853
437e6adc 3854 * configure.ac: Use -nostdlib when probing for the target. It
3855 should not be required to have libc for the target.
3856
06a6836c 3857 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
3858 they fail without libc headers for the target.
3859 * include/grub/powerpc/libgcc.h: Use weak attribute for all
3860 exports.
3861 * include/grub/sparc64/libgcc.h: Likewise. Don't use
3862 preprocessor conditionals.
3863
fe052e37 3864 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
3865 build system doesn't need to be aware of the tar.c internals.
3866
afd22553 38672009-06-09 Michel Hermier <michel.hermier@gmail.com>
87b8f28c 3868
afd22553 3869 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
8ec4a6d0 3870
6b787c4f 38712009-06-09 Robert Millan <rmh.grub@aybabtu.com>
3872
3873 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
3874 disk limit to 26 for IDE, Virtio, Xen and SCSI.
3875
38762009-06-09 Felix Zielcke <fzielcke@z-51.de>
3877
3878 * util/i386/pc/grub-install.in: Change the error message if UUIDs
473d1e45 3879 aren't available if ata.mod gets used.
6b787c4f 3880
473d1e45 38812009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
e23721e8 3882
473d1e45 3883 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
e23721e8 3884 initialising controller.
473d1e45 3885 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
e23721e8 3886
255a27d4 38872009-06-08 Felix Zielcke <fzielcke@z-51.de>
3888
3889 * util/i386/pc/grub-install.in: Add a parameter --disk-module
3890 to choose between ata and biosdisk module on i386-pc.
3891
473d1e45 38922009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
69da8877 3893
d55842d8 3894 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
3895 Subclass and Programming Interface fields in terms of the 3 byte
3896 Class Code register.
3897 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
3898
fa5db0b1 3899 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
3900 interface is OHCI. Add grub_dprintf for symmetry with
3901 bus/usb/uhci.c.
3902 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
3903 interface is UHCI. Add interf variable for programming
3904 interface. Print interface with class/subclass.
3905
c0947beb 3906 * bus/usb/ohci.c: Set interf with correct field.
3907
69da8877 3908 * bus/usb/uhci.c: Remove unneeded doubled lines.
3909 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
3910 Remove whitespace inside comment.
3911
9e172e30 39122009-06-08 Robert Millan <rmh.grub@aybabtu.com>
3913
3914 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
3915 as fallback an equivalent option without depth.
3916
de65ee2b 39172009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
3918
3919 Not fail if unable to retrieve C/H/S on LBA disks
3920
473d1e45 3921 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
de65ee2b 3922 if unable to retrieve C/H/S on LBA disks
3923
b57ea2c9 39242009-06-08 Pavel Roskin <proski@gnu.org>
3925
3926 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
3927 about aliasing.
3928
af361263 39292009-06-08 Felix Zielcke <fzielcke@z-51.de>
3930
3931 * Makefile.in (uninstall): Remove all $lib_DATA files.
3932
4c9ec6b3 39332009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
3934
3935 Bugfix: install on partitionless device
3936
3937 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
3938 is a whole disk
3939
e76fc924 39402009-06-08 Felix Zielcke <fzielcke@z-51.de>
3941
3942 * Makefile.in (uninstall): Remove all $include_DATA files.
3943
ba5a0d05 39442009-06-08 Felix Zielcke <fzielcke@z-51.de>
3945
3946 * commands/true.c: New file. Implement the true and false commands.
3947 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
3948 (true_mod_SOURCES): New variable.
3949 (true_mod_CFLAGS): Likewise.
3950 (true_mod_LDFLAGS): Likewise.
3951
c8048e32 39522009-06-05 Colin D Bennett <colin@gibibit.com>
3953
3954 Optimized font character lookup using binary search instead of linear
3955 search. Fonts now are required to have the character index ordered by
3956 code point.
3957
3958 * font/font.c (load_font_index): Verify that fonts have ordered
3959 character indices.
3960 (find_glyph): Use binary search instead of linear search to find a
3961 character in a font.
3962
408305be 39632009-06-05 Michael Scherer <misc@mandriva.org>
3964
3965 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
3966 uses case sensitive btree.
3967 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
3968 only for case insensitive filesystems.
3969
8ee1e0d9 39702009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
3971
3972 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
3973 * conf/common.rmk (search_mod_CFLAGS): likewise
3974
a9966eb1 39752009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3976
473d1e45 3977 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
a9966eb1 3978 compensate a compiler bug
3979
9e7100fb 39802009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3981
473d1e45 3982 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
9e7100fb 3983 instead of '\b'
473d1e45 3984
ede21d71 39852009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3986
3987 Definitions for creating asm symbols with Apple's CC
3988
3989 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
3990 [APPLE_CC] (VARIABLE): likewise
3991
9dbf7653 39922009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3993
3994 Disable lnxboot.img when compiled
3995 with Apple's CC
3996
3997 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
3998 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
3999 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
4000 [! APPLE_CC] (CODE_LENG): skip
4001 [! APPLE_CC] (setup_sects): likewise
4002 [! APPLE_CC]: skip filling
473d1e45 4003
e93cdc3d 40042009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4005
4006 Address in trampolines based on 32-bit registers when compiled
4007 with Apple's CC
4008
473d1e45 4009 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
e93cdc3d 4010 for addresses
4011 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
4012
6c688477 40132009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4014
4015 Avoid aliases when compiling with Apple's CC for PCBIOS machine
4016
4017 * kern/misc.c [APPLE_CC] (memcpy): new function
4018 [APPLE_CC] (memmove): likewise
4019 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
473d1e45 4020 (memcpy): define alias conditionally on !APPLE_CC
6c688477 4021 (memset): likewise
4022 (abort): likewise
4023 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
4024 APPLE_CC are defined
4025 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
4026 (grub_assert_fail): make prototype conditional
4027
e37ffc5c 40282009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4029
4030 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
4031
473d1e45 4032 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
4033 grub-macho2img
e37ffc5c 4034 (CLEANFILES): add grub-macho2img
4035 (grub_macho2img_SOURCES): new variable
4036 * kern/i386/pc/startup.S (bss_start): new variable
4037 (bss_end): likewise
4038 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
4039 * util/grub-macho2img.c: new file
4040
cf00df31 40412009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4042
4043 Use objconv when compiling with Apple's CC
4044
4045 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
4046 (efiemu64.o): likewise
4047 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
4048 when compiling with Apple's CC
4049 (efiemu64_s.o): likewise
4050 * configure.ac: check for objconv when compiling with Apple's CC
4051 * genmk.rb: use objconv for modules when compiled with Apple's CC
473d1e45 4052
d119a20c 40532009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4054
4055 Define segment as well as section when compiling with
4056 Apple's CC
4057
4058 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
4059 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
4060 (efiemu_convert_pointer): likewise
4061 (efiemu_set_virtual_address_map): likewise
4062 (efiemu_convert_pointer): likewise
4063 (efiemu_getcrc32): likewise
4064 (init_crc32_table): likewise
4065 (reflect): likewise
4066 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
4067 (GRUB_MOD_DEP): likewise
473d1e45 4068
c8600122 40692009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4070
4071 Allow a compilation without -mcmodel=large
4072
4073 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
4074 when compiled without -mcmodel=large
473d1e45 4075 (filter_memory_map): remove memory post 4 GiB when compiled
c8600122 4076 without -mcmodel=large
473d1e45 4077 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
c8600122 4078 TARGET_CFLAGS when -mcmodel=large isn't supported
473d1e45 4079
e8df1d4e 40802009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4081
4082 Remove nested functions in efiemu core
4083
4084 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
473d1e45 4085
cc6c3ac1 40862009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4087
4088 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
4089
4090 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
4091 temporary storage
473d1e45 4092 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
4093 using Apple's CC
cc6c3ac1 4094 (grub_cpu_is_tsc_supported): likewise
4095 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
473d1e45 4096
3e325901 40972009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4098
4099 Absolute addressing through constant with Apple's cc
4100
4101 * kern/i386/pc/startup.S: Define necessary constants
4102 and address through it when using ABS with Apple's CC
4103 * boot/i386/pc/diskboot.S: likewise
4104 * boot/i386/pc/boot.S: likewise
4105 * boot/i386/pc/lnxboot.S: likewise
4106 * boot/i386/pc/cdboot.S: likewise
4107 * mmap/i386/pc/mmap_helper.S: likewise
4108 * commands/i386/pc/drivemap_int13h.S: likewise
4109
2b167a72 41102009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4111
4112 Check if compiler is apple cc
4113
4114 * Makefile.in (ASFLAGS): new variable
4115 (TARGET_ASFLAGS): likewise
4116 (TARGET_MODULE_FORMAT): likewise
4117 (TARGET_APPLE_CC): likewise
4118 (OBJCONV): likewise
4119 (TARGET_IMG_CFLAGS): likewise
4120 (TARGET_CPPFLAGS): add includedir
4121 * configure.ac: call grub_apple_cc and grub_apple_target_cc
4122 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
4123 Check for linker script only if compiler isn't Apple's CC
4124 (TARGET_MODULE_FORMAT): set
4125 (TARGET_APPLE_CC): likewise
4126 (TARGET_ASFLAGS): likewise
4127 (ASFLAGS): likewise
4128 Check for objcopy only if compiler isn't Apple's CC
4129 Check for BSS symbol only if compiler isn't Apple's CC
4130 * genmk.rb: adapt nm options if we use Apple's utils
4131 * aclocal.m4 (grub_apple_cc): new test
4132 (grub_apple_target_cc): likewise
473d1e45 4133
fb14123e 41342009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4135
4136 Simplify sed expressions and improve awk
4137
4138 * Makefile.in (install-local): simplify sed expression
4139 * gencmdlist.sh: likewise
4140 * genmoddep.awk: avoid adding module as a dependency of itself
4141
5b889789 41422009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4143
4144 Add missing start symbols
4145
4146 * boot/i386/pc/boot.S: add start
fb14123e 4147 * boot/i386/pc/pxeboot.S: likewise
473d1e45 4148
fd2bf2e3 41492009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4150
4151 Fix wrong assumptions with grub-mkimage on EFI
473d1e45 4152
4153 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
fd2bf2e3 4154 (relocate_addresses): consider both r_addend and value at offset
4155 (make_mods_section): zerofill modinfo and header
4156 (convert_elf): write prefix here
473d1e45 4157
5389763d 41582009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4159
4160 Use .asciz instead of .string
4161
4162 * i386/pc/diskboot.S: use .asciz instead of .string
4163 * i386/pc/boot.S: likewise
4164 * include/grub/dl.h (GRUB_MOD_DEP): likewise
4165 (GRUB_MOD_NAME): likewise
473d1e45 4166
3eb5ed4e 41672009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4168
4169 gfxpayload support
4170
4171 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
4172 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
4173 (grub_video_setup): remove
4174 (grub_video_set_mode): new prototype
4175 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
4176 (vid_mode): remove
4177 (linux_vesafb_res): compile only on PCBIOS
4178 (grub_linux_boot): support gfxpayload
4179 * loader/i386/pc/xnu.c (video_hook): new function
4180 (grub_xnu_set_video): support gfxpayload
4181 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
4182 (DEFAULT_VIDEO_HEIGHT): likewise
4183 (DEFAULT_VIDEO_FLAGS): likewise
4184 (DEFAULT_VIDEO_MODE): new definition
4185 (video_hook): new function
4186 (grub_gfxterm_init): use grub_video_set_mode
473d1e45 4187 * util/grub.d/30_os-prober.in: remove explicit modesetting before
3eb5ed4e 4188 loading xnu
4189 * video/video.c (grub_video_setup): removed
473d1e45 4190 (grub_video_set_mode): new function based on grub_gfxterm_init and
3eb5ed4e 4191 grub_video_setup
4192
4b0e1143 41932009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4194
4195 Avoid calling biosdisk in drivemap
4196
4197 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
4198 (revparse_biosdisk): likewise
4199 (list_mappings): derive name from id directly
4200 (grub_cmd_drivemap): use tryparse_diskstring
473d1e45 4201
fda6cb98 42022009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4203
4204 Script fixes
4205
4206 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
4207 (grub_lexer_param): add tokenonhold
4208 (grub_script_create_cmdline): remove cmdline. All callers updated
4209 (grub_script_function_create): make functionname
4210 grub_script_arg. All callers updated
4211 (grub_script_execute_argument_to_string): new prototype
4212 * kern/parser.c (state_transitions): reorder
4213 (grub_parser_cmdline_state): fix a bug and make more compact
473d1e45 4214 * script/sh/execute.c (grub_script_execute_argument_to_string):
fda6cb98 4215 make global
4216 (grub_script_execute_cmdline): use new format
4217 * script/sh/function.c (grub_script_function_create): make functionname
4218 grub_script_arg. All callers updated
473d1e45 4219 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
fda6cb98 4220 (grub_script_yylex): remove
4221 (grub_script_yylex2): renamed to ...
4222 (grub_script_yylex): ...renamed
4223 parse the expressions like a${b}c
4224 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
4225 (GRUB_PARSER_TOKEN_VAR): remove
4226 (GRUB_PARSER_TOKEN_NAME): likewise
4227 ("if"): declare as typeless
4228 ("while"): likewise
4229 ("function"): likewise
4230 ("else"): likewise
4231 ("then"): likewise
4232 ("fi"): likewise
4233 (text): remove
4234 (argument): likewise
4235 (script): accept empty scripts and make exit on error
4236 (arguments): use GRUB_PARSER_TOKEN_ARG
4237 (function): likewise
4238 (command): move error handling to script
4239 (menuentry): move grub_script_lexer_ref before
473d1e45 4240 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
fda6cb98 4241 argument. All callers updated
4242
f4448a07 42432009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4244
4245 Prevent GRUB from probing floppies during boot.
4246
4247 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
4248 * commands/search.c (options): Add --no-floppy.
4249 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
4250 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
4251 --no-floppy when searching for UUIDs.
4252
2bf5885a 42532009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4254
4255 Simplify the code duplication in commands/search.c.
4256
4257 * commands/search.c (search_label, search_fs_uuid): Merge into ...
4258 (search_fs): ... this. Update all users.
4259
f6fd460a 42602009-06-03 Felix Zielcke <fzielcke@z-51.de>
4261
4262 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
4263
cbb3c83e 42642009-05-28 Pavel Roskin <proski@gnu.org>
4265
57788cfd 4266 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
4267 Remove the original symlink explicitly.
4268
cbb3c83e 4269 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
4270 just one slash. That's how grub_fshelp_find_file() does it.
4271
cd0d5e30 42722009-05-26 Pavel Roskin <proski@gnu.org>
4273
f0f8bbe2 4274 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
4275 to `str'.
4276
cd0d5e30 4277 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
4278 possibly unused.
4279
8c2cab51 42802009-05-25 Christian Franke <franke@computer.org>
4281
4282 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
4283 register.
4284 (grub_atapi_identify): Add wait after drive select.
4285 (grub_ata_identify): Do more strict status register check before
4286 calling grub_atapi_identify (). Suppress error message if status
4287 register is 0x00 after command failure. Add status register
4288 check after PIO read to avoid bogus identify due to stuck DRQ.
4289 Thanks to Pavel Roskin for testing.
4290 (grub_device_initialize): Remove unsafe status register check.
4291 Thanks to 'phcoder' for problem report and patch.
4292 Prevent sign extension in debug message.
4293
230c0ad6 42942009-05-23 Colin D Bennett <colin@gibibit.com>
4295
4296 Cleaned up `include/grub/normal.h'. Grouped prototypes by
4297 definition file, and functions defined in `normal/menu.c' have had
4298 their prototypes moved to `include/grub/menu.h' for consistency.
4299
4300 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
4301 from normal.h.
4302 (grub_menu_get_entry): Likewise.
4303 (grub_menu_get_timeout): Likewise.
4304 (grub_menu_set_timeout): Likewise.
4305 (grub_menu_execute_entry): Likewise.
4306 (grub_menu_execute_with_fallback): Likewise.
4307 (grub_menu_entry_run): Likewise.
4308
4309 * include/grub/normal.h: Re-ordered and grouped function
4310 prototypes by file that the function is defined in.
4311 (grub_menu_execute_callback): Removed; moved to menu.h.
4312 (grub_menu_get_entry): Likewise.
4313 (grub_menu_get_timeout): Likewise.
4314 (grub_menu_set_timeout): Likewise.
4315 (grub_menu_execute_entry): Likewise.
4316 (grub_menu_execute_with_fallback): Likewise.
4317 (grub_menu_entry_run): Likewise.
4318 (grub_menu_addentry): Renamed from this ...
4319 (grub_normal_add_menu_entry): ... to this.
4320
4321 * normal/main.c (grub_menu_addentry): Renamed from this ...
4322 (grub_normal_add_menu_entry): ... to this.
4323
4324 * script/sh/execute.c (grub_script_execute_menuentry): Update
4325 reference to renamed grub_menu_addentry function.
4326
861f03a5 43272009-05-23 Felix Zielcke <fzielcke@z-51.de>
4328
4329 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
4330
96b1619a 43312009-05-22 Pavel Roskin <proski@gnu.org>
4332
bf6a5fb2 4333 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
4334 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
4335 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
4336 compiling for the i386 targets, but not for the utilities.
4337
96b1619a 4338 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
4339 to grub_uint8_t.
4340 (grub_root_drive): Likewise.
4341 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
4342 remove alignment.
4343 (grub_root_drive): Change size to byte.
4344 (grub_start_addr): Remove.
4345 (grub_end_addr): Likewise.
4346 (grub_apm_bios_info): Likewise.
4347
b729776b 43482009-05-21 Felix Zielcke <fzielcke@z-51.de>
4349
4350 * normal/i386: Remove.
4351 * normal/powerpc: Likewise.
4352 * normal/sparc64: Likewise.
4353 * normal/x86_64: Likewise.
4354
0a15ce80 43552009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
4356
4357 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
473d1e45 4358 * loader/i386/linux_trampoline.S: Fix indentation
0a15ce80 4359 * loader/i386/xnu_helper.S: Likewise
d6da58e6 4360
33db9015 43612009-05-18 Colin D Bennett <colin@gibibit.com>
4362
d6da58e6 4363 Display error messages when parsing a Lua statement fails.
4364 Previously, executing a syntactically invalid statement like
4365 ")foo" or "bar;" would silently fail.
33db9015 4366
4367 * script/lua/grub_main.c (handle_lua_error): New function.
d6da58e6 4368 (grub_lua_parse_line): Improved reporting of Lua parser and
4369 execution errors.
33db9015 4370
46422c89 43712009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4372
4373 Remove -Werror which causes build to fail on some systems
4374
4375 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
4376 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
4377 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
18f547ad 4378
22f53a96 43792009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4380
4381 trampoline for linux on 64-bit platform
4382
18f547ad 4383 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
4384 loader/i386/efi/linux_trampoline.S
4385 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
473d1e45 4386 declaration
d6da58e6 4387 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
4388 here
22f53a96 4389 * loader/i386/linux_trampoline.S: moved here
d6da58e6 4390 * loader/i386/efi/linux.c (allocate_pages): reserve space for
4391 trampoline
22f53a96 4392 (jumpvector): removed
4393 (grub_linux_trampoline_start): new declaration
4394 (grub_linux_trampoline_end): likewise
4395 (grub_linux_boot): use trampoline when on 64-bit platform
4396 * loader/i386/linux.c: likewise
4397
cb5a0f40 43982009-05-16 Pavel Roskin <proski@gnu.org>
4399
4400 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
4401 const to avoid a warning.
4402 (grub_lua_setenv): Likewise.
4403 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
4404 lmsg to fix a warning.
4405
334f2c28 44062009-05-16 Felix Zielcke <fzielcke@z-51.de>
4407
4408 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
7dd10fce 4409 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4410 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
4411 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4412 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4413 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4414 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4415 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
334f2c28 4416
59e5d3ec 44172009-05-16 Felix Zielcke <fzielcke@z-51.de>
4418
4419 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
4420
9d87a1ba 44212009-05-16 Bean <bean123ch@gmail.com>
4422
4423 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
4424 (lua_mod_SOURCES): New variable.
4425 (lua_mod_CFLAGS): Likewise.
4426 (lua_mod_LDFLAGS): Likewise.
4427
4428 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
4429 (setjmp_mod_SOURCES): New variable.
4430 (setjmp_mod_CFLAGS): Likewise.
4431 (setjmp_LDFLAGS): Likewise.
4432
4433 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
4434 (setjmp_mod_SOURCES): New variable.
4435 (setjmp_mod_CFLAGS): Likewise.
4436 (setjmp_LDFLAGS): Likewise.
4437
4438 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4439 (setjmp_mod_SOURCES): New variable.
4440 (setjmp_mod_CFLAGS): Likewise.
4441 (setjmp_LDFLAGS): Likewise.
4442
4443 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4444 (setjmp_mod_SOURCES): New variable.
4445 (setjmp_mod_CFLAGS): Likewise.
4446 (setjmp_LDFLAGS): Likewise.
4447
4448 * normal/i386/setjmp.S: Moved from here ...
4449 * lib/i386/setjmp.S: ... Moved here
4450 * normal/x86_64/setjmp.S: Moved from here ...
4451 * lib/x86_64/setjmp.S: ... Moved here
4452 * normal/powerpc/setjmp.S: Moved from here ...
4453 * lib/powerpc/setjmp.S: ... Moved here
4454 * normal/sparc64/setjmp.S: Moved from here ...
4455 * lib/sparc64/setjmp.S: ... Moved here
4456
4457 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
4458 returns_twice in mingw.
4459
4460 * script/lua/grub_lib.c: New file.
4461 * script/lua/grub_lib.h: Likewise.
4462 * script/lua/grub_lua.h: Likewise.
4463 * script/lua/grub_main.c: Likewise.
4464 * script/lua/lapi.c: Likewise.
4465 * script/lua/lapi.h: Likewise.
4466 * script/lua/lauxlib.c: Likewise.
4467 * script/lua/lauxlib.h: Likewise.
4468 * script/lua/lbaselib.c: Likewise.
4469 * script/lua/lcode.c: Likewise.
4470 * script/lua/lcode.h: Likewise.
4471 * script/lua/ldblib.c: Likewise.
4472 * script/lua/ldebug.c: Likewise.
4473 * script/lua/ldebug.h: Likewise.
4474 * script/lua/ldo.c: Likewise.
4475 * script/lua/ldo.h: Likewise.
4476 * script/lua/ldump.c: Likewise.
4477 * script/lua/lfunc.c: Likewise.
4478 * script/lua/lfunc.h: Likewise.
4479 * script/lua/lgc.c: Likewise.
4480 * script/lua/lgc.h: Likewise.
4481 * script/lua/linit.c: Likewise.
4482 * script/lua/liolib.c: Likewise.
4483 * script/lua/llex.c: Likewise.
4484 * script/lua/llex.h: Likewise.
4485 * script/lua/llimits.h: Likewise.
4486 * script/lua/lmathlib.c: Likewise.
4487 * script/lua/lmem.c: Likewise.
4488 * script/lua/lmem.h: Likewise.
4489 * script/lua/loadlib.c: Likewise.
4490 * script/lua/lobject.c: Likewise.
4491 * script/lua/lobject.h: Likewise.
4492 * script/lua/lopcodes.c: Likewise.
4493 * script/lua/lopcodes.h: Likewise.
4494 * script/lua/loslib.c: Likewise.
4495 * script/lua/lparser.c: Likewise.
4496 * script/lua/lparser.h: Likewise.
4497 * script/lua/lstate.c: Likewise.
4498 * script/lua/lstate.h: Likewise.
4499 * script/lua/lstring.c: Likewise.
4500 * script/lua/lstring.h: Likewise.
4501 * script/lua/lstrlib.c: Likewise.
4502 * script/lua/ltable.c: Likewise.
4503 * script/lua/ltable.h: Likewise.
4504 * script/lua/ltablib.c: Likewise.
4505 * script/lua/ltm.c: Likewise.
4506 * script/lua/ltm.h: Likewise.
4507 * script/lua/lua.h: Likewise.
4508 * script/lua/luaconf.h: Likewise.
4509 * script/lua/lualib.h: Likewise.
4510 * script/lua/lundump.c: Likewise.
4511 * script/lua/lundump.h: Likewise.
4512 * script/lua/lvm.c: Likewise.
4513 * script/lua/lvm.h: Likewise.
4514 * script/lua/lzio.c: Likewise.
4515 * script/lua/lzio.h: Likewise.
4516
5e898c9d 45172009-05-16 Bean <bean123ch@gmail.com>
4518
4519 * include/grub/kernel.h (grub_module_header_types): Add type
4520 OBJ_TYPE_CONFIG.
4521
4522 * kern/main.c (grub_load_config): New function.
4523 (grub_main): Call grub_load_config to read boot config.
4524
4525 * grub-mkimage (generate_image): New parameter config_path.
4526 (options): New option --config.
4527 (main): Parse --config option, and pass it to generate_image.
4528
cf353a47 45292009-05-14 Christian Franke <franke@computer.org>
4530
4531 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
4532 This fixes build on Cygwin.
4533
3834887f 45342009-05-14 Pavel Roskin <proski@gnu.org>
4535
4536 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
4537 jump. This saves two bytes, so the typical case of 2 swapped
4538 drives would fit 32 bytes.
4539
8090fc01 45402009-05-13 Pavel Roskin <proski@gnu.org>
4541
ac963883 4542 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
4543 grub_uint32_t to avoid a warning.
4544
8090fc01 4545 * loader/i386/linux.c (allocate_pages): When assigning
4546 real_mode_mem, cast through grub_size_t to fix a warning. The
4547 code already makes sure that the value would fit a pointer.
4548 (grub_linux_setup_video): Cast render_target->data to
4549 grub_size_t to fix a warning.
4550
18f547ad 45512009-05-13 Javier Martín <lordhabbit@gmail.com>
4246b8a9 4552
4553 * commands/i386/pc/drivemap.c: New file - implement drivemap
4554 command.
4555 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
4556 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
4557
6f6a8b28 45582009-05-13 Pavel Roskin <proski@gnu.org>
4559
4560 * util/i386/pc/grub-setup.c (setup): Remove unused variable
4561 embedding_area_exists.
4562
15fbf4c4 45632009-05-13 Robert Millan <rmh.grub@aybabtu.com>
4564
4565 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
4566 it easier to understand / work with.
59978c8a 4567 Improve warning messages for cases where there's no embedding area,
4568 or when it is too small (or core.img too large).
15fbf4c4 4569
238e871f 45702009-05-13 Pavel Roskin <proski@gnu.org>
4571
0ab3a9a4 4572 * loader/i386/pc/multiboot2.c: Add necessary includes for
4573 grub_multiboot2_real_boot().
4574
a2c8c5f8 4575 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
4576 PX record is always little-endian. We only need the lower 2
4577 bytes of the mode.
4578
faec96af 4579 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
4580 facilitate code reuse.
4581 (grub_cpio_mount): Use "struct head", not a char buffer. This
4582 fixes a warning reported by gcc 4.4.
4583
238e871f 4584 * kernel/disk.c (grub_disk_read): Use void pointer for the
4585 buffer.
4586 (grub_disk_write): Use const void pointer for the buffer.
4587 Adjust all callers. Remove unnecessary casts.
4588
901d2f0c 45892009-05-10 Robert Millan <rmh.grub@aybabtu.com>
4590
4591 * util/i386/pc/grub-install.in: Update copyright year.
4592
18f547ad 45932009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
2eac4c16 4594
4595 gptsync
4596
4597 * commands/gptsync.c: new file
4598 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
4599 (gptsync_mod_SOURCES): new variable
4600 (gptsync_mod_CFLAGS): likewise
4601 (gptsync_mod_LDFLAGS): likewise
18f547ad 4602 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
2eac4c16 4603 new definition
4604 (GRUB_PC_PARTITION_TYPE_HFS): likewise
4605 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
4606 * conf/i386-ieee1275.rmk: likewise
4607 * conf/i386-pc.rmk: likewise
4608 * conf/powerpc-ieee1275.rmk: likewise
4609
b4ba690a 46102009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
4611
4612 Fixed grub-emu
4613
4614 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
4615 (grub_dl_ref): likewise
4616
317e1a44 46172009-05-08 Robert Millan <rmh.grub@aybabtu.com>
4618
4619 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
4620 split in two functions (one for msdos and one for gpt).
4621
041b8094 46222009-05-08 Pavel Roskin <proski@gnu.org>
4623
752473c2 4624 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
4625 not modified.
4626
041b8094 4627 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
4628 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
4629 Initialize them with -1. Add sanity check for bad1. Eliminate
4630 nerr variable.
4631
172800ce 46322009-05-08 David S. Miller <davem@davemloft.net>
4633
4634 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
4635
29aa5e81 46362009-05-06 Robert Millan <rmh.grub@aybabtu.com>
4637
4638 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
473d1e45 4639 existence.
29aa5e81 4640
96613b62 46412009-05-05 Felix Zielcke <fzielcke@z-51.de>
4642
4643 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
1905c57b 4644 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
96613b62 4645
eef73c8a 46462009-05-05 David S. Miller <davem@davemloft.net>
4647
4648 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
4649
119494b5 46502009-05-05 Pavel Roskin <proski@gnu.org>
4651
4652 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
4653 of grub_dl_ref() and grub_dl_unref().
4654 * commands/parttool.c: Remove preprocessor conditionals around
4655 grub_dl_ref() and grub_dl_unref().
4656 * fs/affs.c: Likewise.
4657 * fs/afs.c: Likewise.
4658 * fs/cpio.c: Likewise.
4659 * fs/ext2.c: Likewise.
4660 * fs/fat.c: Likewise.
4661 * fs/hfs.c: Likewise.
4662 * fs/hfsplus.c: Likewise.
4663 * fs/iso9660.c: Likewise.
4664 * fs/jfs.c: Likewise.
4665 * fs/minix.c: Likewise.
4666 * fs/ntfs.c: Likewise.
4667 * fs/reiserfs.c: Likewise.
4668 * fs/sfs.c: Likewise.
4669 * fs/udf.c: Likewise.
4670 * fs/ufs.c: Likewise.
4671 * fs/xfs.c: Likewise.
4672 * include/grub/dl.h: Likewise.
4673 * loader/xnu.c: Likewise.
4674
de5fd76e 46752009-05-04 Pavel Roskin <proski@gnu.org>
4676
4677 * commands/acpi.c: Remove unused variable my_mod.
4678 * partmap/amiga.c: Likewise.
4679 * partmap/apple.c: Likewise.
4680 * partmap/gpt.c: Likewise.
4681 * partmap/pc.c: Likewise.
4682 * partmap/sun.c: Likewise.
4683 * term/gfxterm.c: Likewise.
4684 * term/i386/pc/vesafb.c: Likewise.
4685 * term/i386/pc/vga.c: Likewise.
4686
983598ad 46872009-05-04 David S. Miller <davem@davemloft.net>
4688
4689 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
4690 pointer args to grub_ieee1275_get_property().
4691
8aadec43 4692 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
4693
9554b15e 4694 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
4695 devices, and do not traverse down under controller nodes.
4696
67e23c90 4697 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
4698 (grub_ofdisk_open): Use it to un-escape "," characters.
4699 * kern/disk.c (find_part_sep): New.
4700 (grub_disk_open): Use it to find the first non-escaped ','
4701 character in the disk name.
4702 * util/ieee1275/devicemap.c (escape_of_path): New.
4703 (grub_util_emit_devicemap_entry): Use it.
4704 * util/sparc64/ieee1275/grub-install.in: Update script to
4705 strip partition specifiers properly by not triggering on
4706 '\' escaped ',' characters.
4707
74bfdd2f 47082009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4709
4710 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
4711 to 0x300.
4712 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
4713 resolutions.
4714 (linux_vesafb_modes): Add a lot of additional modes to the list (based
4715 on documentation from Wikipedia).
4716
4241d2b1 47172009-05-04 Pavel Roskin <proski@gnu.org>
4718
4719 * disk/ata.c: Spelling fixes.
4720 * disk/raid.c: Likewise.
4721 * disk/usbms.c: Likewise.
4722 * disk/dmraid_nvidia.c: Likewise.
4723 * kern/ieee1275/openfw.c: Likewise.
4724 * kern/ieee1275/init.c: Likewise.
4725 * kern/ieee1275/cmain.c: Likewise.
4726 * boot/i386/pc/cdboot.S: Likewise.
4727 * video/readers/png.c: Likewise.
4728 * video/i386/pc/vbe.c: Likewise.
4729 * fs/udf.c: Likewise.
4730 * fs/hfs.c: Likewise.
4731 * fs/reiserfs.c: Likewise.
4732 * efiemu/runtime/efiemu.c: Likewise.
4733 * efiemu/main.c: Likewise.
4734 * efiemu/mm.c: Likewise.
4735 * include/grub/elf.h: Likewise.
4736 * include/grub/xnu.h: Likewise.
4737 * include/grub/usbdesc.h: Likewise.
4738 * include/grub/usb.h: Likewise.
4739 * include/grub/script_sh.h: Likewise.
4740 * include/grub/lib/LzmaEnc.h: Likewise.
4741 * include/grub/efiemu/efiemu.h: Likewise.
4742 * include/grub/command.h: Likewise.
4743 * normal/menu.c: Likewise.
4744 * normal/main.c: Likewise.
4745 * normal/datetime.c: Likewise.
4746 * bus/usb/uhci.c: Likewise.
4747 * mmap/i386/uppermem.c: Likewise.
4748 * mmap/mmap.c: Likewise.
4749 * commands/acpi.c: Likewise.
4750 * commands/test.c: Likewise.
4751 * partmap/apple.c: Likewise.
4752 * font/font.c: Likewise.
4753 * loader/sparc64/ieee1275/linux.c: Likewise.
4754 * loader/macho.c: Likewise.
4755 * loader/i386/bsd_trampoline.S: Likewise.
4756 * loader/i386/bsd.c: Likewise.
4757 * loader/xnu.c: Likewise.
4758 * term/i386/pc/vesafb.c: Likewise.
4759 * term/usb_keyboard.c: Likewise.
4760 * util/resolve.c: Likewise.
4761 * util/getroot.c: Likewise.
4762
0cfc0083 47632009-05-04 Felix Zielcke <fzielcke@z-51.de>
4764
4765 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
4766
7c1d00cd 47672009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4768
4769 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
4770 build error.
4771
b01f0548 47722009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4773
4774 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
4775 parameter only available on BIOS.
4776
ecc3eb22 47772009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4778
4779 Removed wrong semicolon in declaration
4780
4781 * grub/misc.h (grub_dprintf): remove semicolon
4782
112972a9 47832009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4784
4785 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
4786 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
4787 is done by grub_cmd_linux() now).
4788 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
4789 restore video to text mode.
4790 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
4791 indicates lack of "vga=" parameter. "vga=0" is mapped to
4792 `GRUB_LINUX_VID_MODE_NORMAL'.
4793
afd5c115 47942009-05-04 Felix Zielcke <fzielcke@z-51.de>
4795
4796 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
4797 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
4798 and `normal/script.c'. Add `kern/rescue_reader.c',
18f547ad 4799 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
afd5c115 4800 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
4801 `grub_script.tab.c'.
4802
4803 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4804 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4805 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4806 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
4807 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4808
faa517ce 4809 * Makefile.in: Remove duplicated 2008 in Copyright line.
4810
ae0c0bdc 48112009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4812
473d1e45 4813 * util/misc.c (grub_util_warn): New function. Emits a warning
ae0c0bdc 4814 unconditionally.
4815 * include/grub/util/misc.h (grub_util_warn): New declaration.
4816
4817 * util/i386/pc/grub-install.in: Understand --force and pass it down
4818 to grub-setup.
4819
4820 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
4821 down to setup().
4822 (setup): Improve error messages and add warnings when requested to
4823 install in odd layouts. Refuse to install using blocklists unless
4824 --force was set.
4825
18f547ad 48262009-05-04 martin f. krafft <madduck@madduck.net>
c149b500 4827
4828 * disk/raid.c (grub_raid_scan_device): Improve debug message.
4829
6d260daa 48302009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4831
4832 Updated copyright year
4833
4834 * fs/hfsplus.c: updated copyright year
18f547ad 4835
69f853f8 48362009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4837
4838 HFS+ UUID
4839
18f547ad 4840 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
69f853f8 4841 in the space previously used by unused3
4842 (grub_hfsplus_uuid): new function
4843 (grub_hfsplus_fs): added uuid field
4844
4c402e73 48452009-05-03 Pavel Roskin <proski@gnu.org>
4846
4847 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
4848 suppress warnings. It's no longer needed.
4849 * disk/host.c: Likewise.
4850 * disk/ata_pthru.c: Likewise.
4851 * disk/loopback.c: Likewise.
4852 * hook/datehook.c: Likewise.
4853 * parttool/pcpart.c: Likewise.
4854 * fs/i386/pc/pxe.c: Likewise.
4855 * fs/ntfscomp.c: Likewise.
4856 * efiemu/main.c: Likewise.
4857 * mmap/mmap.c: Likewise.
4858 * commands/crc.c: Likewise.
4859 * commands/hexdump.c: Likewise.
4860 * commands/hdparm.c: Likewise.
4861 * commands/acpi.c: Likewise.
4862 * commands/echo.c: Likewise.
4863 * commands/minicmd.c: Likewise.
4864 * commands/blocklist.c: Likewise.
4865 * commands/memrw.c: Likewise.
4866 * commands/loadenv.c: Likewise.
4867 * commands/usbtest.c: Likewise.
4868 * commands/lsmmap.c: Likewise.
4869 * commands/boot.c: Likewise.
4870 * commands/parttool.c: Likewise.
4871 * commands/configfile.c: Likewise.
4872 * commands/search.c: Likewise.
4873 * commands/ieee1275/suspend.c: Likewise.
4874 * commands/cat.c: Likewise.
4875 * commands/i386/pc/pxecmd.c: Likewise.
4876 * commands/i386/pc/play.c: Likewise.
4877 * commands/i386/pc/halt.c: Likewise.
4878 * commands/i386/pc/vbeinfo.c: Likewise.
4879 * commands/i386/pc/vbetest.c: Likewise.
4880 * commands/lspci.c: Likewise.
4881 * commands/date.c: Likewise.
4882 * commands/handler.c: Likewise.
4883 * commands/ls.c: Likewise.
4884 * commands/test.c: Likewise.
4885 * commands/cmp.c: Likewise.
4886 * commands/efi/loadbios.c: Likewise.
4887 * commands/efi/fixvideo.c: Likewise.
4888 * commands/halt.c: Likewise.
4889 * commands/help.c: Likewise.
4890 * commands/reboot.c: Likewise.
4891 * hello/hello.c: Likewise.
4892 * script/sh/main.c: Likewise.
4893 * loader/xnu.c: Likewise.
4894 * term/terminfo.c: Likewise.
4895 * term/i386/pc/serial.c: Likewise.
4896 * term/usb_keyboard.c: Likewise.
4897
515b5079 48982009-05-03 David S. Miller <davem@davemloft.net>
4899
4900 * normal/menu.c: Include grub/parser.h
4901
dfc31a22 49022009-05-03 Pavel Roskin <proski@gnu.org>
4903
2fee74f1 4904 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
4905 not char*.
4906 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
4907 Suggested by Javier Martín <lordhabbit@gmail.com>
4908
dfc31a22 4909 * util/i386/pc/grub-mkrescue.in: Allow for the case when
4910 efiemu??.o doesn't exist.
4911 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
4912 copying.
4913
18f547ad 49142009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
cef17233 4915
4916 FreeBSD 64-bit support
4917
18f547ad 4918 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
cef17233 4919 and loader/i386/bsd_trampoline.S
4920 (bsd_mod_ASFLAGS): new variable
4921 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
4922 (FREEBSD_MODTYPE_KERNEL64): likewise
4923 (grub_bsd64_trampoline_start): likewise
4924 (grub_bsd64_trampoline_end): likewise
4925 (grub_bsd64_trampoline_selfjump): likewise
4926 (grub_bsd64_trampoline_gdt): likewise
4927 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
4928 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
4929 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
4930 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
18f547ad 4931 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
cef17233 4932 of "attrib" member
4933 * loader/i386/bsd_pagetable.c: new file
4934 * loader/i386/bsd_trampoline.S: likewise
4935 * loader/i386/bsd.c (ALIGN_QWORD): new macro
4936 (ALIGN_VAR): likewise
4937 (entry_hi): new variable
4938 (kern_end_mdofs): likewise
4939 (is_64bit): likewise
4940 (grub_freebsd_add_meta): use ALIGN_VAR
4941 (grub_e820_mmap): new declaration
4942 (grub_freebsd_add_mmap): new function
4943 (grub_freebsd_add_meta_module): support 64 bit kernels
4944 (grub_freebsd_list_modules): use ALIGN_VAR
4945 (gdt_descriptor): new declaration
4946 (grub_freebsd_boot): support 64 bit kernels
4947 (grub_bsd_elf64_hook): new function
4948 (grub_bsd_load_elf): support elf64
4949
038c5720 49502009-05-03 Bean <bean123ch@gmail.com>
4951
4952 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
4953 after we get the result of if statement.
4954
fc45fb58 49552009-05-03 Bean <bean123ch@gmail.com>
4956
4957 * Makefile.in (enable_efiemu): New variable.
4958
4959 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
4960 set.
4961 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
4962 path.
4963 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
4964 path, add -mno-red-zone option.
4965 (efiemu64_s.o): Likewise.
4966 (efiemu64.o): Use macro $^ for source file.
4967
4968 * configure.ac (--enable-efiemu): New option.
4969
bbee0f2b 49702009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
4971
4972 xnu support
4973
4974 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
4975 (pkglib_MODULES): add xnu.mod
4976 (xnu_mod_SOURCES): new variable
4977 (xnu_mod_CFLAGS): likewise
4978 (xnu_mod_LDFLAGS): likewise
4979 (xnu_mod_ASFLAGS): likewise
4980 * conf/i386-pc.rmk: likewise
4981 * conf/x86_64-efi.rmk: likewise
7dd4a573 4982 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
bbee0f2b 4983 new declaration
4984 * include/grub/i386/macho.h: new file
4985 * include/grub/i386/xnu.h: likewise
4986 * include/grub/macho.h: likewise
4987 * include/grub/machoload.h: likewise
4988 * include/grub/x86_64/macho.h: likewise
4989 * include/grub/x86_64/xnu.h: likewise
4990 * include/grub/xnu.h: likewise
4991 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
4992 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
4993 * loader/i386/efi/xnu.c: new file
4994 * loader/i386/pc/xnu.c: likewise
4995 * loader/i386/xnu.c: likewise
4996 * loader/i386/xnu_helper.S: likewise
4997 * loader/macho.c: likewise
4998 * loader/xnu.c: likewise
4999 * loader/xnu_resume.c: likewise
5000 * util/grub-dumpdevtree: likewise
5001 * include/grub/i386/pit.h: include grub/err.h
5002 (grub_pit_wait): export
5003 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
7dd4a573 5004
5caf964d 50052009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5006
5007 Efiemu
7dd4a573 5008
5caf964d 5009 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
7dd4a573 5010 _linux_efi, linux_efi.
5011 new files in grub-emu
5caf964d 5012 new targets efiemu32.o and efiemu64.o
5013 * loader/linux_normal_efiemu.c: likewise
5014 * loader/i386/efi/linux.c: added preliminary efiemu support
7dd4a573 5015 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
5caf964d 5016 files to copy
5017 * include/grub/autoefi.h: new file
7dd4a573 5018 * include/grub/i386/efiemu.h: likewise
5caf964d 5019 * include/grub/i386/pc/efiemu.h: likewise
5020 * include/grub/efi/api.h: add LL suffix when necessary
5021 new definitions relating to tables
5022 * include/grub/efiemu/efiemu.h: new file
5023 * include/grub/efiemu/runtime.h: likewise
5024 * efiemu/prepare.c: likewise
5025 * efiemu/loadcore_common.c: likewise
5026 * efiemu/loadcore64.c: likewise
5027 * efiemu/runtime/efiemu.sh: likewise
5028 * efiemu/runtime/efiemu.S: likewise
5029 * efiemu/runtime/efiemu.c: likewise
5030 * efiemu/runtime/config.h: likewise
5031 * efiemu/prepare32.c: likewise
5032 * efiemu/main.c: likewise
5033 * efiemu/modules/pnvram.c: likewise
5034 * efiemu/modules/i386: likewise
5035 * efiemu/modules/i386/pc: likewise
5036 * efiemu/modules/acpi.c: likewise
5037 * efiemu/i386/pc/cfgtables.c: likewise
5038 * efiemu/i386/loadcore64.c: likewise
5039 * efiemu/i386/loadcore32.c: likewise
5040 * efiemu/prepare64.c: likewise
5041 * efiemu/loadcore.c: likewise
5042 * efiemu/symbols.c: likewise
5043 * efiemu/mm.c: likewise
5044 * efiemu/loadcore32.c: likewise
7dd4a573 5045
50462009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
f8efe3ad 5047
5048 ACPI spoofing
5049
5050 * commands/acpi.c: new file
5051 * commands/i386/pc/acpi.c: likewise
5052 * commands/efi/acpi.c: likewise
5053 * include/grub/acpi.h: likewise
5054 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
5055 (acpi_mod_SOURCES): new variable
5056 (acpi_mod_CFLAGS): likewise
5057 (acpi_mod_LDFLAGS): likewise
5058 * conf/i386-efi.rmk: likewise
5059 * conf/x86_64-efi.rmk: likewise
5060
7dd4a573 50612009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
28a85665 5062
5063 Missing part from mmap patch
5064
5065 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
5066 (grub_mmap_unregister)
5067 (grub_mmap_free_and_unregister): use grub_mmap_register
5068
7dd4a573 50692009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
09d842b9 5070
5071 Mmap services
5072
5073 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
5074 * loader/i386/linux.c (find_mmap_size): likewise
5075 (allocate_pages): likewise
5076 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
5077 (grub_fill_multiboot_mmap): likewise
5078 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
5079 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
5080 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
5081 (OPENBSD_MMAP_RESERVED): likewise
5082 * include/grub/i386/pc/memory.h: include grub/memory.h
5083 (grub_lower_mem): removed
5084 (grub_upper_mem): likewise
5085 (GRUB_MACHINE_MEMORY_ACPI): new definition
5086 (GRUB_MACHINE_MEMORY_NVS): likewise
5087 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
5088 (GRUB_MACHINE_MEMORY_HOLE): likewise
5089 (grub_machine_mmap_register): likewise
5090 (grub_machine_mmap_unregister): likewise
5091 (grub_machine_get_upper): likewise
5092 (grub_machine_get_lower): likewise
5093 (grub_machine_get_post64): likewise
5094 * include/grub/i386/efi/memory.h: new file
5095 * include/grub/x86_64/efi/memory.h: likewise
5096 * include/grub/efi/memory.h: likewise
5097 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
5098 (mmap_mod_SOURCES): new variable
5099 (mmap_mod_LDFLAGS): likewise
5100 (mmap_mod_ASFLAGS): likewise
5101 * conf/i386-coreboot.rmk: likewise
5102 * conf/i386-ieee1275.rmk: likewise
5103 * conf/i386-efi.rmk: likewise
5104 * conf/x86_64-efi.rmk: likewise
5105 * include/grub/types.h (UINT_TO_PTR): new macro
5106 (PTR_TO_UINT32): likewise
5107 (PTR_TO_UINT64): likewise
5108 * include/grub/memory.h: new file
5109 * mmap/i386/pc/mmap.c: likewise
5110 * mmap/i386/pc/mmap_helper.S: likewise
5111 * mmap/i386/uppermem.c: likewise
5112 * mmap/mmap.c: likewise
5113 * mmap/efi/mmap.c: likewise
7dd4a573 5114 * kern/i386/coreboot/init.c (grub_machine_init): don't use
09d842b9 5115 grub_upper_mem
5116 * kern/i386/pc/init.c (grub_lower_mem): removed variable
5117 (grub_upper_mem): likewise
5118 (grub_machine_init): don't use grub_upper_mem,
5119 make grub_lower_mem local
5120 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
5121 grub_mmap_iterate and grub_mmap_get_upper
5122 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
5123
d558e6b5 51242009-05-02 Bean <bean123ch@gmail.com>
5125
5126 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
5127 script/sh/parser.y.
5128 (pkglib_MODULES): Add normal.mod and sh.mod.
5129 (normal_SOURCES): New variable.
5130 (normal_mod_CFLAGS): Likewise.
5131 (normal_mod_LDFLAGS): Likewise.
5132 (sh_mod_SOURCES): Likewise.
5133 (sh_mod_CFLAGS): Likewise.
5134 (sh_mod_LDFLAGS): Likewise.
5135
5136 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
5137 script/sh/lexer.c_DEPENDENCIES.
5138 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
5139 kern/rescue_reader.c and kern/rescue_parser.c.
5140 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
5141 (grub_emu_SOURCES): Change source files.
5142 (pkglib_MODULES): Remove normal.mod.
5143 (normal_SOURCES): Removed.
5144 (normal_mod_CFLAGS): Likewise.
5145 (normal_mod_LDFLAGS): Likewise.
5146 * conf/i386-coreboot.rmk: Likewise.
5147 * conf/i386-efi.rmk: Likewise.
5148 * conf/i386-ieee1276.rmk: Likewise.
5149 * conf/powerpc-ieee1275.rmk: Likewise.
5150 * conf/sparc64-ieee1275.rmk: Likewise.
5151 * conf/x86_64-efi.rmk: Likewise.
5152
5153 * include/grub/command.h (grub_command_execute): New inline function.
5154
5155 * include/grub/menu.h (grub_menu_entry): Removed commands field.
5156
5157 * include/grub/normal.h: Remove <grub/setjmp.h>.
5158 (grub_fs_module_list): Moved to normal/autofs.c.
5159 (grub_exit_env): Removed.
5160 (grub_command_execute): Likewise.
5161 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
5162 parameter script.
5163 (read_command_list): New function declaration.
5164 (read_fs_list): Likewise.
5165
5166 * include/parser.h: Include <grub/reader.h>.
5167 (grub_parser_split_cmdline): Change type of getline parameter.
5168 (grub_parser): New structure.
5169 (grub_parser_class): New variable.
5170 (grub_parser_execute): New function declaration.
5171 (grub_register_rescue_parser): Likewise.
5172 (grub_parser_register): New inline function.
5173 (grub_parser_unregister): Likewise.
5174 (grub_parser_get_current): Likewise.
5175 (grub_parser_set_current): Likewise.
5176
5177 * include/grub/reader.h: New file.
5178 * kern/reader.c: Likewise.
5179 * kern/rescue_parser.c: Likewise.
5180 * kern/rescue_reader.c: Likewise.
5181 * normal/autofs.c: Likewise.
5182 * normal/dyncmd.c: Likewise.
5183
5184 * include/grub/rescue.h: Removed.
5185 * normal/command.h: Likewise.
5186
5187 * include/grub/script.h: Moved to ...
5188 * include/grub/script_sh.h: ... Moved here.
5189 * normal/execute.c: Moved to ...
5190 * script/sh/execute.c: ... Moved here.
5191 * normal/function.c: Moved to ...
5192 * script/sh/function.c: ... Moved here.
5193 * normal/lexer.c: Moved to ...
5194 * script/sh/lexer.c: ... Moved here.
5195 * normal/parser.y: Moved to ...
5196 * script/sh/parser.y: ... Moved here.
5197 * normal/script.c: Moved to ...
5198 * script/sh/script.c: ... Moved here.
5199
5200 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
5201 <grub/reader.h>.
5202 (grub_exit_env): Removed.
5203 (fs_module_list): Moved to normal/autofs.c.
5204 (grub_file_getline): Don't handle comment here.
5205 (free_menu): Skip removed field entry->commands.
5206 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
5207 script parameter.
5208 (read_config_file): Removed nested parameter, change getline function.
5209 (grub_enter_normal_mode): Removed.
5210 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
5211 (read_command_list): Likewise.
5212 (autoload_fs_module): Moved to normal/autofs.c.
5213 (read_fs_list): Likewise.
5214 (reader_nested): New variable.
5215 (grub_normal_execute): Run parser.sh to switch to sh parser.
5216 (grub_cmd_rescue): Removed.
5217 (cmd_normal): Removed.
5218 (grub_cmd_normal): Unregister itself at the beginning. Don't register
5219 rescue command.
5220 (grub_cmdline_run): New function.
5221 (grub_normal_reader_init): Likewise.
5222 (grub_normal_read_line): Likewise.
5223 (grub_env_write_pager): Likewise.
5224 (cmdline): New variable.
5225 (grub_normal_reader): Likewise.
5226 (GRUB_MOD_INIT): Register normal reader and set as current, register
5227 pager hook, register normal command with grub_register_command_prio,
5228 so that it won't show up in command.lst.
5229 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
5230 grub_fs_autoload_hook.
5231
5232 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
5233 (grub_menu_execute_entry): Replace grub_script_execute with
5234 grub_parser_execute, change parameter to grub_command_execute.
5235
5236 * normal/menu_text.c: Remove <grub/script.h>.
5237
5238 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
5239 and <grub/parser.h>.
5240 (run): Change editor_getline to use new parser interface. Change
5241 parameter to grub_command_execute.
5242
5243 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
5244 <grub/reader.h> and <grub/parser.h>.
5245 (grub_load_normal_mode): Execute normal command.
5246 (grub_main): Call grub_register_core_commands,
5247 grub_register_rescue_parser and grub_register_rescue_reader, use
5248 grub_reader_loop to enter input loop.
5249
7dd4a573 5250 * kern/parser.c (grub_parser_split_cmdline): Change type of
5251 getline parameter.
d558e6b5 5252 (grub_parser_class): New variable.
5253 (grub_parser_execute): New function.
5254
5255 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
5256 * loader/multiboot2.c: Likewise.
5257 * loader/sparc64/ieee1275/linux.c: Likewise.
5258
5259 * util/grub-emu.c (read_command_list): New dummy function.
5260
18db813d 52612009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5262
5263 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
5264 count to 16 for CCISS and IDA.
5265
6c67de15 52662009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5267
5268 * normal/menu_text.c (grub_wait_after_message): Print a newline
5269 after waiting for user input.
5270
5271 * loader/i386/linux.c: Include `<grub/normal.h>'.
5272 (grub_cmd_linux): Improve the error message about `ask' mode, by
5273 waiting for user input so it's not missed (we can do this, since
5274 user requested interaction).
5275
d9dc87b0 52762009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5277
5278 Added missing lst to grub-mkrescue
5279
5280 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
5281 and ${input_dir}/parttool.lst
5282
ac8a2baa 52832009-04-30 David S. Miller <davem@davemloft.net>
5284
ad22a610 5285 * util/hostdisk.c (device_is_wholedisk): New function.
5286 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
5287 zero only if device_is_wholedisk() returns true.
5288
6966215d 5289 * util/hostdisk.c (convert_system_partition_to_system_disk):
5290 Handle virtual disk devices named /dev/vdiskX as found on sparc
5291 and powerpc.
5292
ac8a2baa 5293 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
5294 lettered partition specifier is found, convert to numbered.
5295
979b4fb4 52962009-04-29 David S. Miller <davem@davemloft.net>
5297
e2bf39b2 5298 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
5299 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5300
3c64e104 5301 * normal/command.c: Add missing newline at end of file.
5302
979b4fb4 5303 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
5304 warnings.
5305 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
5306 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
5307 grub_ofdisk_read): Likewise, and deal similarly with the fact that
5308 ihandles have a 32-bit type but need to be stored in a "void *".
5309
136d9f82 53102009-04-28 Pavel Roskin <proski@gnu.org>
5311
9459c306 5312 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
5313 not disk. Adjust all dependencies.
2e08a26a 5314 (grub_fs_uuid_close): Use grub_device_close(), not
9459c306 5315 grub_disk_close().
5316
136d9f82 5317 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
5318 parent's partition, don't copy it by reference, as it gets freed
5319 on close.
5320
7dd4a573 53212009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
75a807cf 5322
5323 Preboot hooks support
5324
5325 * commands/boot.c (struct grub_preboot_t): new declaration
5326 (preboots_head): new variable
5327 (preboots_tail): likewise
5328 (grub_loader_register_preboot_hook): new function
5329 (grub_loader_unregister_preboot_hook): likewise
5330 (grub_loader_set): launch preboot hooks
5331 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
5332 (grub_loader_register_preboot_hook): new declaration
5333 (grub_loader_unregister_preboot_hook): likewise
5334
5af922b5 53352009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
5336
5337 Warning fix
5338
7dd4a573 5339 * disk/scsi.c (grub_scsi_open): added missing cast when
5af922b5 5340 calling grub_dprintf
5341
a5562c30 53422009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
5343
5344 Bug and warning fixes
5345
7dd4a573 5346 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
a5562c30 5347 declaration
5348 * commands/test.c (test_parse): fixed bug with file tests and corrected
5349 declaration of find_file
5350
4006f85c 53512009-04-26 Pavel Roskin <proski@gnu.org>
5352
5353 * Makefile.in: Don't install empty manual pages if help2man is
5354 missing. Use help2man option for output, not shell redirection.
5355
5c77c3de 53562009-04-26 David S. Miller <davem@davemloft.net>
5357
5358 * util/grub-mkdevicemap.c (make_device_map): Add missing
5359 NESTED_FUNC_ATTR to process_device().
5360
033b10a8 53612009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5362
5363 Test command
5364
5365 * commands/test.c: rewritten to use bash-like test
5366
e4343593 53672009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5368
5369 Parttool autoloading and improvements
5370
7dd4a573 5371 * Makefile.in (pkglib_DATA): add parttool.lst
e4343593 5372 (parttool.lst): new target
5373 * genmk.rb: generate parttool-*
5374 (CLEANFILES): add #{parttool}
5375 (PARTTOOLFILES): new variable
5376 * genparttoollist.sh: new file
7dd4a573 5377 * parttool/pcpart.c (grub_pcpart_boot): more feedback
e4343593 5378 (grub_pcpart_type): likewise
5379 * commands/parttool.c (helpmsg): new variable
5380 (grub_cmd_parttool): output help if not enough arguments are supplied
5381 autoload modules
5382 (GRUB_MOD_INIT(parttool)): use helpmsg
5383
0d312500 53842009-04-24 David S. Miller <davem@davemloft.net>
5385
7dd4a573 5386 Avoiding opening same device multiple times in device iterator.
0d312500 5387
5388 * kern/device.c: (grub_device_iterate): Define struct part_ent,
7dd4a573 5389 and use it to build a list of partitions in iterate_disk() and
0d312500 5390 iterate_partition().
5391
ac20caff 5392 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
5393 on disk->data.
5394
0dcf7495 5395 * disk/ieee1275/nand.c (grub_nand_iterate): Return
5396 grub_devalias_iterate() result instead of unconditional 0.
5397 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
5398 Also, capture hook return value, either directly or via
5399 grub_children_iterate(), and propagate to caller.
5400 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
5401 grub_children_iterate): Return value is now 'int' instead of
5402 'grub_err_t'.
5403 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
5404 like a proper iterator, stopping when hooks return non-zero.
5405 (grub_devalias_iterate): Likewise.
5406
c8c08833 54072009-04-23 David S. Miller <davem@davemloft.net>
5408
5409 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
5410
f01005a8 54112009-04-22 David S. Miller <davem@davemloft.net>
5412
5413 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
5414 is larger than address_cells, use that value for address_cells too.
5415
4e8269da 5416 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
5417 IEEE1275_MAX_PATH_LEN): Define.
5418 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
5419 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
5420 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
5421 'devtype'. Explicitly NULL terminate devalias expansion.
5422
a1447506 5423 * util/sparc64/ieee1275/misc.c: New file.
5424 * util/sparc64/ieee1275/grub-setup.c: New file.
5425 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
5426 * util/sparc64/ieee1275/grub-mkimage.c: New file.
5427 * util/sparc64/ieee1275/grub-install.in: New file.
5428 * util/ieee1275/ofpath.c: New file.
5429 * util/ieee1275/devicemap.c: New file.
5430 * util/devicemap.c: New file.
5431 * util/deviceiter.c: New file.
5432 * kern/sparc64/ieee1275/init.c: New file.
5433 * include/grub/util/ofpath.h: New file.
5434 * include/grub/util/deviceiter.h: New file.
5435 * util/grub-mkdevicemap.c: Include deviceiter.h.
5436 Implement using grub_util_emit_devicemap_entry and
5437 grub_util_iterate_devices.
5438 * conf/i386-corebook.rmk: Build util/deviceiter.c and
5439 util/devicemap.c into grub-mkdevicemap
5440 * conf/i386-efi.rmk: Likewise.
5441 * conf/i386-ieee1275.rmk: Likewise.
5442 * conf/i386-pc.rmk: Likewise.
5443 * conf/powerpc-ieee1275.rmk: Likewise.
5444 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
5445 images and installation utilities. Build kernel as image
5446 instead of as elf binary. Use common rules as much as possible.
5447
7dd4a573 54482009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
0aefc632 5449
5450 Correct GPT definition
5451
7dd4a573 5452 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
0aefc632 5453 of "attrib" member
5454
c6c5219f 54552009-04-19 Felix Zielcke <fzielcke@z-51.de>
5456
5457 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
5458
0552ff9f 54592009-04-19 David S. Miller <davem@davemloft.net>
5460
5461 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
5462 (grub_rescue_cmd_linux): Rename to...
5463 (grub_cmd_linux): and fix prototype.
5464 (grub_rescue_cmd_initrd): Rename to...
5465 (grub_cmd_initrd): and fix prototype.
5466 (cmd_linux, cmd_initrd): New.
5467 (GRUB_MOD_INIT(linux)): Use grub_register_command().
5468 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
5469
d1a282fc 54702009-04-17 Pavel Roskin <proski@gnu.org>
5471
07c5039f 5472 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
5473 format.
5474 (grub_ohci_transfer): Likewise.
5475
b012002d 5476 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
5477
1bc09c35 5478 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
5479 return without a value. Fix inconsistent indentation.
5480
e0ff9126 5481 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
5482 match struct grub_fs.
5483
d1a282fc 5484 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
5485 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
5486 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
5487 * commands/lspci.c (grub_lspci_iter): Likewise.
5488
a96df3f2 54892009-04-16 Bean <bean123ch@gmail.com>
5490
5491 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
5492 value.
5493
41bb0fe9 54942009-04-15 Pavel Roskin <proski@gnu.org>
5495
5496 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
5497 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
5498 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
5499 definitions.
5500
596c6970 55012009-04-15 Felix Zielcke <fzielcke@z-51.de>
5502
5503 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
7dd4a573 5504 that no multiple data or metadata areas are supported and `Unknown
596c6970 5505 metadata header'.
5506
7dd4a573 55072009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
0d5d5653 5508
5509 Move loader out of the kernel
5510
5511 * kern/loader.c: moved to ...
5512 * commands/boot.c: ... moved here
5513 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
5514 * commands/boot.c (grub_cmd_boot): moved here. All users updated
5515 * include/grub/kernel.h (grub_machine_fini): export
5516 * include/grub/loader.h (grub_loader_is_loaded): update declaration
5517 (grub_loader_set): likewise
5518 (grub_loader_unset): likewise
5519 (grub_loader_boot): likewise
5520 * conf/common.rmk: new module boot.mod
5521 (pkglib_MODULES): add boot.mod
5522 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
5523 (grub_emu_SOURCES): likewise
5524 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
5525 (grub_emu_SOURCES): likewise
5526 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
5527 (grub_emu_SOURCES): likewise
5528 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
5529 (grub_emu_SOURCES): likewise
5530 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
5531 (grub_emu_SOURCES): likewise
7dd4a573 5532 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
5533 (grub_emu_SOURCES): likewise
0d5d5653 5534 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
7dd4a573 5535 (grub_emu_SOURCES): likewise
0d5d5653 5536
7dd4a573 55372009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
5999d619 5538
5539 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
7dd4a573 5540
5999d619 5541 * kern/misc.c (grub_itoa): Removed function
5542 (grub_ltoa): likewise
5543 (grub_vsprintf): use grub_lltoa
5544
7dd4a573 55452009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
13c00781 5546
5547 Restore grub-emu
5548
5549 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
5550 * conf/i386-coreboot.rmk: likewise
5551 * conf/i386-ieee1275.rmk: likewise
5552 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 5553
20318222 55542009-04-15 Felix Zielcke <fzielcke@z-51.de>
5555
5556 * INSTALL: Add that `./autogen.sh' needs to be run before
5557 `./configure.'.
5558
d05f0df3 55592009-04-14 Bean <bean123ch@gmail.com>
5560
5561 * Makefile.in (pkglib_DATA): Add handler.lst.
5562 (handler.lst): New rule.
5563
5564 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
5565 * conf/i386-coreboot.rmk: Likewise.
5566 * conf/i386-ieee1275.rmk: Likewise.
5567 * conf/i386-efi.rmk: Likewise.
5568 * conf/x86_64-efi.rmk: Likewise.
5569 * conf/powerpc-ieee1275.rmk: Likewise.
5570 * conf/sparc64-ieee1275.rmk: Likewise.
5571
5572 * genhandlerlist.sh: New file.
5573
5574 * genmk.rb: Add rules to generate handler.lst.
5575
5576 * include/grub/normal.h (grub_file_getline): New function definition.
5577 (read_handler_list): Likewise.
5578 (free_handler_list): Likewise.
5579
5580 * include/grub/term.h (grub_term_register_input): Add name parameter
5581 for auto generation of handler.lst.
5582 (grub_term_register_output): Likewise.
5583
5584 * normal/handler.c: New file.
5585
5586 * normal/main.c (get_line): Renamed to grub_file_getline.
5587 (read_config_file): Use the newly renamed grub_file_getline.
5588 (read_command_list): Likewise.
5589 (read_fs_list): Likewise.
5590 (grub_normal_execute): Call read_handler_list to parse handler.lst.
5591 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
5592
5593 * term/efi/console.c (grub_console_init): Add name parameter for auto
5594 generation of handler.lst.
5595 * term/gfxterm.c: Likewise.
5596 * term/i386/pc/at_keyboard.c: Likewise.
5597 * term/i386/pc/console.c: Likewise.
5598 * term/i386/pc/serial.c: Likewise.
5599 * term/i386/pc/vesafb.c: Likewise.
5600 * term/i386/pc/vga.c: Likewise.
5601 * term/i386/pc/vga_text.c: Likewise.
5602 * term/ieee1275/ofconsole.c: Likewise.
5603 * term/usb_keyboard.c: Likewise.
5604
33c846be 56052009-04-14 Bean <bean123ch@gmail.com>
5606
5607 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
5608 properly with null character.
5609
4484e01e 56102009-04-14 Felix Zielcke <fzielcke@z-51.de>
5611
5612 * configure: Remove.
5613 * config.h.in: Likewise.
f93d668e 5614 * stamp-h.in: Likewise.
4484e01e 5615 * DISTLIST: Likewise.
5616 * conf/common.mk: Likewise.
5617 * conf/i386-coreboot.mk: Likewise.
5618 * conf/i386-efi.mk: Likewise.
5619 * conf/i386-ieee1275.mk: Likewise.
5620 * conf/i386.mk: Likewise.
5621 * conf/i386-pc.mk: Likewise.
5622 * conf/powerpc-ieee1275.mk: Likewise.
5623 * conf/sparc64-ieee1275.mk: Likewise.
5624 * conf/x86_64-efi.mk: Likewise.
5625
5626 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
5627 develop on GRUB.
5628
7dd4a573 56292009-04-14 John Stanley <jpsinthemix@verizon.net>
5c5bf96a 5630 David S. Miller <davem@davemloft.net>
5631
5632 * util/hostdisk.c (make_device_name): Fix buffer length
5633 calculations.
5634
e25b5a8c 56352009-04-14 Felix Zielcke <fzielcke@z-51.de>
5636
5637 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
5638 <sys/param.h> and <sys/sysctl.h>.
5639 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
5640 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
5641 opening the device and reset them afterwards.
5642
1f1f580c 56432009-04-13 Pavel Roskin <proski@gnu.org>
5644
5645 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
5646 Reported by John Stanley <jpsinthemix@verizon.net>
5647
7ebc2d6b 56482009-04-13 Robert Millan <rmh@aybabtu.com>
5649
5650 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
7dd4a573 5651 that name for menuentries when appropriate.
7ebc2d6b 5652
d8ba3667 56532009-04-13 Felix Zielcke <fzielcke@z-51.de>
5654
5655 * util/grub.d/10_freebsd.in: Add a missing `fi'.
5656
cba416eb 56572009-04-13 Robert Millan <rmh@aybabtu.com>
5658
5659 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
5660 to Linux, simply abort telling the user it's no longer supported.
5661
a547a745 56622009-04-13 Felix Zielcke <fzielcke@z-51.de>
5663
5664 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
7dd4a573 5665 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
a547a745 5666 `freebsd_loadenv' only when devices.hints exist.
5667
232a769c 56682009-04-13 Pavel Roskin <proski@gnu.org>
5669
5670 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
5671
c3012039 56722009-04-13 Felix Zielcke <fzielcke@z-51.de>
5673
5674 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
5675 partition number.
5676 (grub_drive): Likewise.
5677
234022fe 56782009-04-13 David S. Miller <davem@davemloft.net>
5679
5680 * kern/sparc64/ieee1275/ieee1275.c: New file.
5681 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
5682 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
5683 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
5684 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
5685 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
5686 grub_ieee1275_alloc_physmem): Declare new exported functions.
5687
d8e1836c 5688 * include/grub/sparc64/ieee1275/loader.h: New file.
5689 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5690 * include/grub/sparc64/kernel.h: Likewise.
5691 * loader/sparc64/ieee1275/linux.c: Likewise.
5692
96bd81ec 5693 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
5694 (grub_fstest_SOURCES): Likewise.
5695
6a4737e5 5696 * util/hostdisk.c (make_device_name): Do not make any assumptions
5697 about the length of drive names.
5698
1d7a72fd 5699 * kern/dl.c (grub_dl_load_file): Close file immediately when
5700 we are done using it.
5701
56bc2471 57022009-04-12 David S. Miller <davem@davemloft.net>
5703
5704 * kern/misc.c (grub_ltoa): Fix cast when handling negative
5705 values. Noticed by Pavel Roskin.
5706
df38d0bb 5707 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
5708 target compiler.
7dd4a573 5709
e382e93a 5710 * genmk.rb: Add more flexible image type specification, also
5711 pass --strip-unneeded to objcopy.
5712 * conf/i386-pc.rmk: Use *_FORMAT.
5713 * conf/i386-pc.mk: Rebuilt.
5714
f5dbbca9 5715 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
5716 (OFDISK_HASH_SZ): Define.
5717 (ofdisk_hash): New hash table.
5718 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
5719 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
5720 instead of device phandle which is not unique.
5721
91c88b12 5722 * kern/sparc64/ieee1275/init.c: Delete, replace with...
5723 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
5724 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
5725 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
5726 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
5727 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
5728 GRUB_KERNEL_MACHINE_DATA_END): Define.
5729 (grub_kernel_image_size, grub_total_module_size): Declare.
5730
5b5d4aa5 57312009-04-12 Pavel Roskin <proski@gnu.org>
5732
7dd4a573 5733 * configure.ac: Change the logic when we check for target tools.
5734 Do it when the target is specified and it's different from the
5735 specified value of the host.
5b5d4aa5 5736
c91e1793 57372009-04-11 Felix Zielcke <fzielcke@z-51.de>
5738
5739 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
5740 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
5741 GNU/kFreeBSD. Check if a device is a character device. Use
5742 DIOCGMEDIASIZE to get the size.
5743 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
5744 support for GNU/kFreeBSD.
5745 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
5746 is a character device instead of a block device. Add support for
5747 FreeBSD device names.
5748
5749 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
5750 is a character device instead of a block device.
5751
5752 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
5753 is a character device instead of a block device.
5754
b1ac8644 57552009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
5756
5757 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
5758 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
5759 FreeBSD. Check if a device is a character device. Use
5760 DIOCGMEDIASIZE to get the size.
5761 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
5762 support for FreeBSD.
5763 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
5764 is a character device instead of a block device. Add support for
5765 FreeBSD device names.
5766
5767 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
5768 a character device instead of a block device.
5769 (grub_util_check_char_device): New function.
5770
5771 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
5772 a character device instead of a block device.
5773
5774 * include/grub/util/getroot.h (grub_util_check_char_device): New
5775 prototype.
5776
a3f7515a 57772009-04-11 David S. Miller <davem@davemloft.net>
5778
5779 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
5780 static libgcc.
5781 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
5782 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
5783 function, if present.
5784 (__bswapdi2): Likewise.
5785
0d44993d 5786 * include/grub/sparc64/ieee1275/boot.h: New file.
5787 * boot/sparc64/ieee1275/boot.S: Likewise.
5788 * boot/sparc64/ieee1275/diskboot.S: Likewise.
5789
ed3d2bc2 5790 * kern/misc.c (grub_ltoa): New function.
5791 (grub_vsprintf): Use it to format 'long' integers.
5792
d3bfb59c 57932009-04-10 David S. Miller <davem@davemloft.net>
5794
5795 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
5796 slots are of type grub_ieee1275_cell_t.
5797 (grub_nand_read): Likewise.
5798 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
5799 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
5800 macros are used to compare values in arg/ret block of the call.
5801 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
5802 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
5803 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
5804 grub_ieee1275_instance_to_path, grub_ieee1275_write,
5805 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
5806 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
5807 grub_ieee1275_close, grub_ieee1275_set_property,
5808 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
5809 grub_ieee1275_cell_t.
5810 * kern/ieee1275/openfw.c (grub_map): Likewise.
5811 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
5812 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
5813
450e2238 5814 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
5815 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
5816 (grub_devalias_iterate): Likewise.
5817
7dd4a573 58182009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
6df8cc76 5819
5820 UFS improvements
5821
5822 * fs/ufs.c (INODE_NBLOCKS): new definition
5823 (struct grub_ufs_dirent): added fields for non-BSD dirents
5824 (grub_ufs_get_file_block): fixed double indirect handling
5825 (grub_ufs_lookup_symlink): use more robust way to determine whether
5826 symlink is inline
5827 (grub_ufs_find_file): support for non-BSD dirents
5828 (grub_ufs_dir): support for non-BSD dirents
5829
e7e6862a 58302009-04-10 Bean <bean123ch@gnail.com>
5831
5832 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
5833 attribute, otherwise the size would be wrong for i386 platform.
5834
5835 * include/grub/pci.h (grub_pci_read_word): New inline function.
5836 (grub_pci_read_byte): Likewise.
5837 (grub_pci_write): Likewise.
5838 (grub_pci_write_word): Likewise.
5839 (grub_pci_write_byte): Likewise.
5840
5841 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
5842
5843 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
5844 (find_framebuf): Scan pci to locate the frame buffer address.
5845
5846 * commands/efi/fixvideo.c: New file.
5847
5848 * commands/efi/loadbios.c: Likewise.
5849
5850 * commands/memrw.c: Likewise.
5851
5852 * util/grub-dumpbios.in: Likewise.
5853
5854 * conf/common.rmk (grub-dumpbios): New utility.
5855 (pkglib_MODULES): New module memrw.mod.
5856 (memrw_mod_SOURCE): New macro.
5857 (memrw_mod_CFLAGS): Likewise.
5858 (memrw_mod_LDFLAGS): Likewise.
5859
7dd4a573 5860 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 5861 fixvideo.mod.
5862 (loadbios_mod_SOURCE): New macro.
5863 (loadbios_mod_CFLAGS): Likewise.
5864 (loadbios_mod_LDFLAGS): Likewise.
5865 (fixvideo_mod_SOURCE): Likewise.
5866 (fixvideo_mod_CFLAGS): Likewise.
5867 (fixvideo_mod_LDFLAGS): Likewise.
5868
7dd4a573 5869 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 5870 fixvideo.mod.
5871 (loadbios_mod_SOURCE): New macro.
5872 (loadbios_mod_CFLAGS): Likewise.
5873 (loadbios_mod_LDFLAGS): Likewise.
5874 (fixvideo_mod_SOURCE): Likewise.
5875 (fixvideo_mod_CFLAGS): Likewise.
5876 (fixvideo_mod_LDFLAGS): Likewise.
5877
af63ada2 58782009-04-08 Felix Zielcke <fzielcke@z-51.de>
5879
5880 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
5881
c2cdde70 58822009-04-07 David S. Miller <davem@davemloft.net>
5883
5884 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
5885 support for R_SPARC_OLO10 relocations. Fix compile warning for
5886 R_SPARC_WDISP30 case.
ea3f72cf 5887 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
c2cdde70 5888
761319cf 58892009-04-06 Pavel Roskin <proski@gnu.org>
5890
1007d1f5 5891 * include/grub/misc.h (ARRAY_SIZE): New macro.
5892 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
5893 New macro.
5894 * loader/i386/linux.c (allocate_pages): Use free_pages().
5895 (grub_linux_unload): Don't use free_pages().
5896 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
5897 wrong index. Treat all other modes as text modes.
5898 (grub_cmd_linux): Initialize vid_mode unconditionally to
5899 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
5900
761319cf 5901 * commands/help.c (print_command_help): Use cmd->prio, not
5902 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
5903
ea761d40 59042009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
7dd4a573 5905
ea761d40 5906 Parttool
5907
5908 * parttool/pcpart.c: new file
5909 * commands/parttool.c: likewise
5910 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
5911 (parttool_mod_SOURCES): new variable
5912 (parttool_mod_CFLAGS): likewise
5913 (parttool_mod_LDFLAGS): likewise
5914 (pcpart_mod_SOURCES): likewise
5915 (pcpart_mod_CFLAGS): likewise
5916 (pcpart_mod_LDFLAGS): likewise
7dd4a573 5917 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
ea761d40 5918 and parttool/pcpart.c
5919 * conf/i386-efi.rmk: likewise
5920 * conf/i386-ieee1275.rmk: likewise
5921 * conf/i386-pc.rmk: likewise
5922 * conf/powerpc-ieee1275.rmk: likewise
5923 * conf/sparc64-ieee1275.rmk: likewise
5924 * conf/x86_64-ieee1275.rmk: likewise
5925
05aaebfb 59262009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
5927
5928 Support for mtime and further expandability of dir command
5929
5930 * include/grub/lib/datetime.h: moved to ...
7dd4a573 5931 * include/grub/datetime.h: ... moved here and added
05aaebfb 5932 declaration of grub_unixtime2datetime. All users updated
7dd4a573 5933 * include/grub/fs.h: new syntax for dir and mtime functions in
5934 struct grub_fs
05aaebfb 5935 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
5936 and GRUB_FSHELP_FLAGS_MASK
5937 * commands/ls.c (grub_ls_list_files): Write mtime in long format
5938 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
5939 (grub_ext2_mtime): new function
5940 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
5941 (grub_hfsplus_mtime): new function
5942 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
5943 (GRUB_UFS_ATTR_FILE): likewise
5944 (GRUB_UFS_ATTR_LNK): likewise
5945 (struct grub_ufs_sblock): new fields mtime
5946 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
5947 all users updated
5948 (grub_ufs_dir): mtime support
5949 (grub_ufs_mtime): new function
5950 * fs/affs.c (grub_affs_dir): use new dir syntax
5951 * fs/afs.c (grub_afs_dir): likewise
5952 * fs/cpio.c (grub_cpio_dir): likewise
5953 * fs/fat.c (grub_fat_find_dir): likewise
5954 * fs/hfs.c (grub_hfs_dir): likewise
5955 * fs/iso9660.c (grub_iso9660_dir): likewise
5956 * fs/jfs.c (grub_jfs_dir): likewise
5957 * fs/minix.c (grub_minix_dir): likewise
5958 * fs/ntfs.c (grub_ntfs_dir): likewise
5959 * fs/reiserfs.c (grub_reiserfs_dir): likewise
5960 * fs/sfs.c (grub_sfs_dir): likewise
5961 * fs/xfs.c (grub_xfs_dir): likewise
5962 * util/hostfs.c (grub_hostfs_dir): likewise
5963 * lib/datetime.c: moved to ...
5964 * normal/datetime.c: ... moved here
5965 (grub_unixtime2datetime): new function
5966 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
7dd4a573 5967 * normal/completion.c (iterate_dir): use new dir syntax
5968 * normal/misc.c (grub_normal_print_device_info): tell the
05aaebfb 5969 last modification time of a volume
7dd4a573 5970 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
05aaebfb 5971 * conf/common.rmk: added lib/datetime.c to ls.mod
7dd4a573 5972 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
05aaebfb 5973 (normal_mod_SOURCES): likewise
5974 (datetime_mod_SOURCES): Removed lib/datetime.c
5975 * conf/i386-efi.rmk: likewise
7dd4a573 5976 * conf/i386-ieee1275.rmk: likewise
05aaebfb 5977 * conf/i386-pc.rmk: likewise
5978 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 5979 * conf/sparc64-ieee1275.rmk: likewise
5980 * conf/x86_64-efi.rmk: likewise
05aaebfb 5981
8a7e1a14 59822009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
5983
5984 Trim trailing spaces in FAT label and support mtools-like labels
7dd4a573 5985
5986 * fs/fat.c (grub_fat_iterate_dir): New function based
8a7e1a14 5987 on grub_fat_find_dir
5988 (grub_fat_find_dir): use grub_fat_iterate_dir
5989 (grub_fat_label): likewise
5990
04186a9c 59912009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
5992
7dd4a573 5993 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
04186a9c 5994 and command.h
5995 remove extraneous kernel_elf_HEADERS
5996
da4c0bb6 59972009-04-04 Bean <bean123ch@gnail.com>
5998
5999 * include/grub/util/misc.h: Add dummy function fsync for mingw.
6000
6001 * util/misc.c: Likewise.
6002
54ad9555 60032009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
6004
6005 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
6006 instead of grub_printf.
6007
7a6bf9f2 60082009-04-03 Robert Millan <rmh@aybabtu.com>
6009
6010 * loader/i386/linux.c (grub_linux_setup_video): Fill
6011 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
6012 values from `mode info' structure instead of hardcoded
6013 values.
6014
3fcc2083 60152009-04-01 Pavel Roskin <proski@gnu.org>
6016
6017 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
6018 unused now.
6019 * genmk.rb: Likewise.
6020 * configure.ac: Likewise.
6021
5ec9740b 60222009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
6023
6024 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
6025 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
6026
5270cec8 60272009-04-01 David S. Miller <davem@davemloft.net>
6028
6029 * normal/sparc64/setjmp.S: Fix setjmp implementation.
7dd4a573 6030 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
5270cec8 6031 (grub_setjmp): Mark with 'returns_twice' attribute.
6032 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
6033 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
6034 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
6035
9c3dd854 60362009-04-01 Robert Millan <rmh@aybabtu.com>
6037
6038 Reapply fix from 2008-07-28 which was accidentally reverted; also
6039 perform the same fix to a similar check in same function.
6040
6041 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
6042 with the same number are found, just use issue a warning with
6043 grub_dprintf(), as this error has been reported to be non-fatal.
6044
0d818b7e 60452009-03-31 Pavel Roskin <proski@gnu.org>
6046
6047 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
6048 for cross-compilation.
6049
95646d92 60502009-03-30 Robert Millan <rmh@aybabtu.com>
6051
6052 Fix i386-ieee1275 build.
6053
6054 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
6055 Remove declaration.
6056
6a003ed1 60572009-03-30 Pavel Roskin <proski@gnu.org>
6058
6059 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
6060 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
6061 zero-terminated, rely only on the strlen value. Fix comparison
6062 of strings differing in length.
6063
92f33540 60642009-03-30 Robert Millan <rmh@aybabtu.com>
6065
6066 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
6067 checking for abi version. Improve error messages on BIOS to notify
6068 user about `linux16' command.
6069
a8c48fd5 60702009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
6071
f968172e 6072 Leak fixes
a8c48fd5 6073
f968172e 6074 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
6075 in case of collision
6076 * disk/scsi.c (grub_scsi_open): free scsi in case of error
a8c48fd5 6077
9c323f09 60782009-03-29 Robert Millan <rmh@aybabtu.com>
6079
6080 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
6081 set `vid_mode' accordingly.
6082 (grub_linux_boot): Process `vid_mode' and set video mode.
6083
ae68f423 60842009-03-29 Robert Millan <rmh@aybabtu.com>
6085
6086 * util/grub.d/10_linux.in (linux_entry): New function.
6087 Factorize generation of Linux boot entries.
6088
5709cfc4 60892009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
6090
6091 Make the format of Environment Block plain text. The boot loader
6092 part is not tested well yet.
7dd4a573 6093
5709cfc4 6094 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
6095 (buffer): Removed.
6096 (envblk): Likewise.
6097 (usage): Remove "info" and "clear". Add "unset". Update the
6098 description of "set", as this does not delete variables any
6099 longer.
6100 (create_envblk_file): Complete rewrite.
6101 (open_envblk_file): Likewise.
6102 (cmd_info): Removed.
6103 (cmd_list): Likewise.
6104 (cmd_set): Likewise.
6105 (cmd_clear): Likewise.
6106 (list_variables): New function.
6107 (write_envblk): Likewise.
6108 (set_variables): Likewise.
6109 (unset_variables): Likewise.
6110 (main): Complete rewrite.
6111
6112 * commands/loadenv.c (buffer): Removed.
6113 (envblk): Likewise.
6114 (open_envblk_file): New function.
6115 (read_envblk_file): Complete rewrite.
6116 (grub_cmd_load_env): Likewise.
6117 (grub_cmd_list_env): Likewise.
6118 (struct blocklist): New struct.
6119 (free_blocklists): New function.
6120 (check_blocklists): Likewise.
6121 (write_blocklists): Likewise.
6122 (grub_cmd_save_env): Complete rewrite.
6123
6124 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
6125 a plain text signature.
6126 (GRUB_ENVBLK_MAXLEN): Removed.
6127 (struct grub_envblk): Complete rewrite.
6128 (grub_envblk_find): Removed.
6129 (grub_envblk_insert): Likewise.
6130 (grub_envblk_open): New prototype.
6131 (grub_envblk_set): Likewise.
6132 (grub_envblk_delete): Put const to VALUE.
6133 (grub_envblk_iterate): Put const to NAME and VALUE.
6134 (grub_envblk_close): New prototype.
6135 (grub_envblk_buffer): New inline function.
6136 (grub_envblk_size): Likewise.
6137
6138 * lib/envblk.c: Include grub/mm.h.
6139 (grub_env_find): Removed.
6140 (grub_envblk_open): New function.
6141 (grub_envblk_close): Likewise.
6142 (escaped_value_len): Likewise.
6143 (find_next_line): Likewise.
6144 (grub_envblk_insert): Removed.
6145 (grub_envblk_set): New function.
6146 (grub_envblk_delete): Complete rewrite.
6147 (grub_envblk_iterate): Likewise.
6148
a9368fd3 61492009-03-28 Robert Millan <rmh@aybabtu.com>
6150
6151 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
6152 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
6153 variables. Use 16-bit loader.
6154 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
6155 loader.
6156 * kern/i386/loader.S (grub_linux_boot): Rename to ...
6157 (grub_linux16_boot): ... this. Update all users.
6158 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
6159 (grub_linux_boot): ... this. Update all users.
6160
6161 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
6162 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
6163 commands to `linux16' and `initrd16'.
6164 (GRUB_MOD_FINI(linux)): Rename to ...
6165 (GRUB_MOD_FINI(linux16)): ... this.
6166
e4dd5a7e 61672009-03-24 Pavel Roskin <proski@gnu.org>
6168
6169 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
6170 not just for compilation.
6171
c04d6e05 61722009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
6173
6174 Move multiboot helper out of kernel
6175
6176 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
6177 `loader/i386/multiboot_helper.S'.
6178 * conf/i386-coreboot.rmk: Likewise
6179 * conf/i386-ieee1275.rmk: Likewise
6180
6181 * kern/i386/loader.S: Move multiboot helpers from here...
6182 * loader/i386/multiboot_helper.S: ...moved here
6183 * include/grub/i386/loader.h: Move declarations of multiboot
6184 helpers from here...
6185 * include/grub/i386/multiboot.h: ...moved here
6186 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
6187
42a5b3fc 61882009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6189
6190 * kern/env.c (grub_env_context_open): Added an argument to specify
6191 whether a new context inherits exported variables from current
6192 one. This is useful when making a sandbox to interpret a config
6193 file.
6194 All callers updated.
6195
6196 * include/grub/env.h (grub_env_context_open): Updated the prototype.
6197
b28bbc4e 61982009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6199
6200 * kern/env.c (grub_env_context_close): Fix memory leaks.
6201
f04f02e4 62022009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6203
6204 * normal/main.c (grub_normal_execute): Added an argument
6205 BATCH to specify if an interactive interface should be provided
6206 after reading a config file.
6207 All callers updated.
6208 (read_command_list): Prevent being executed twice.
6209 (read_fs_list): Likewise.
6210
42a5b3fc 6211 * include/grub/normal.h (grub_normal_execute): Updated the
6212 prototype.
f04f02e4 6213
41473ac2 62142009-03-22 Pavel Roskin <proski@gno.org>
6215
fbc00b0c 6216 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
6217 _start.
6218 * kern/i386/pc/startup.S: Likewise.
6219 * kern/i386/efi/startup.S: Likewise.
6220 * kern/i386/ieee1275/startup.S: Likewise.
6221 * kern/i386/coreboot/startup.S: Likewise.
6222 * kern/x86_64/efi/startup.S: Likewise.
6223
41473ac2 6224 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
6225 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
6226 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
6227
2274cc8f 62282009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
6229
6230 Bugfixes in multiboot for bugs uncovered by solaris kernel.
6231
6232 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
6233 limit detection.
6234 Use vaddr of correct segment for entry_point.
6235
b1b797cb 62362009-03-21 Bean <bean123ch@gmail.com>
6237
6238 * commands/blocklist.c: Add include file <grub/command.h>, remove
6239 <grub/normal.h> and <grub/arg.h>.
6240 (grub_cmd_blocklist): Use the new command interface.
6241 (GRUB_MOD_INIT): Likewise.
6242 (GRUB_MOD_FINI): Likewise.
6243 * commands/boot.c: Likewise.
6244 * commands/cat.c: Likewise.
6245 * commands/cmp.c: Likewise.
6246 * commands/configfile.c: Likewise.
6247 * commands/crc.c: Likewise.
6248 * commands/echo.c: Likewise.
6249 * commands/halt.c: Likewise.
6250 * commands/handler.c: Likewise.
6251 * commands/hdparm.c: Likewise.
6252 * commands/help.c: Likewise.
6253 * commands/hexdump.c: Likewise.
6254 * commands/loadenv.c: Likewise.
6255 * commands/ls.c: Likewise.
6256 * commands/lsmmap.c: Likewise.
6257 * commands/lspci.c: Likewise.
6258 * commands/loadenv.c: Likewise.
6259 * commands/read.c: Likewise.
6260 * commands/reboot.c: Likewise.
6261 * commands/search.c: Likewise.
6262 * commands/sleep.c: Likewise.
6263 * commands/test.c: Likewise.
6264 * commands/usbtest.c: Likewise.
6265 * commands/videotest.c: Likewise.
6266 * commands/i386/cpuid.c: Likewise.
6267 * commands/i386/pc/halt.c: Likewise.
6268 * commands/i386/pc/play.c: Likewise.
6269 * commands/i386/pc/pxecmd.c: Likewise.
6270 * commands/i386/pc/vbeinfo.c: Likewise.
6271 * commands/i386/pc/vbetest.c: Likewise.
6272 * commands/ieee1275/suspend.c: Likewise.
6273 * disk/loopback.c: Likewise.
6274 * font/font_cmd.c: Likewise.
6275 * hello/hello.c: Likewise.
6276 * loader/efi/appleloader.c: Likewise.
6277 * loader/efi/chainloader.c: Likewise.
6278 * loader/i386/bsd.c: Likewise.
6279 * loader/i386/efi/linux.c: Likewise.
6280 * loader/i386/ieee1275/linux.c: Likewise.
6281 * loader/i386/linux.c: Likewise.
6282 * loader/i386/pc/chainloader.c: Likewise.
6283 * loader/i386/pc/linux.c: Likewise.
6284 * loader/powerpc/ieee1275/linux.c: Likewise.
6285 * loader/multiboot_loader.c: Likewise.
6286 * term/gfxterm.c: Likewise.
6287 * term/i386/pc/serial.c: Likewise.
6288 * term/terminfo.c: Likewise.
6289
6290 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
6291 * term/i386/pc/vga.c: Likewise.
6292 * video/readers/jpeg.c: Likewise.
6293 * video/readers/png.c: Likewise.
6294 * video/readers/tga.c: Likewise.
6295
6296 * util/grub-fstest (cmd_loopback): Removed.
6297 (cmd_blocklist): Likewise.
6298 (cmd_ls): Likewise.
6299 (grub_register_command): Likewise.
6300 (grub_unregister_command): Likewise.
6301 (execute_command): Use grub_command_find to locate command and execute
6302 it.
6303
6304 * include/grub/efi/chainloader.h: Removed.
6305 * loader/efi/chainloader_normal.c: Likewise.
6306 * loader/i386/bsd_normal.c: Likewise.
6307 * loader/i386/pc/chainloader_normal.c: Likewise.
6308 * loader/i386/pc/multiboot_normal.c: Likewise.
6309 * loader/linux_normal.c: Likewise.
6310 * loader/multiboot_loader_normal.c: Likewise.
6311 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
6312
6313 * gencmdlist.sh: Scan new registration command grub_register_extcmd
6314 and grub_register_command_p1.
6315
6316 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
6317 kern/command.c, lib/arg.c and commands/extcmd.c.
6318 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
6319 (minicmd_mod_SOURCES): New variable.
6320 (minicmd_mod_CFLAGS): Likewise.
6321 (minicmd_mod_LDFLAGS): Likewise.
6322 (extcmd_mod_SOURCES): Likewise.
6323 (extcmd_mod_CFLAGS): Likewise.
6324 (extcmd_mod_LDFLAGS): Likewise.
6325 (boot_mod_SOURCES): Removed.
6326 (boot_mod_CFLAGS): Likewise.
6327 (boot_mod_LDFLAGS): Likewise.
6328
6329 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
6330 kern/corecmd.c.
6331 (kernel_img_HEADERS): Add command.h.
6332 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
6333 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
6334 and lib/arg.c.
6335 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
6336 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
6337 remove the corresponding normal mode command.
6338 (normal_mod_SOURCES): Remove normal/arg.c.
6339 * conf/i386-coreboot.rmk: Likewise.
6340 * conf/i386-efi.rmk: Likewise.
6341 * conf/i386-ieee1275.rmk: Likewise.
6342 * conf/powerpc-ieee1275.rmk: Likewise.
6343 * conf/x86_64-efi.rmk: Likewise.
6344
6345 * include/grub/arg.h: Move from here ...
6346 * include/grub/lib/arg.h: ... to here.
6347
6348 * normal/arg.c: Move from here ...
6349 * lib/arg.c: ... to here.
6350
6351 * commands/extcmd.c: New file.
6352 * commands/minicmd.c: Likewise.
6353 * include/grub/command.h: Likewise.
6354 * include/grub/extcmd.h: Likewise.
6355 * kern/command.c: Likewise.
6356 * kern/corecmd.c: Likewise.
6357
6358 * kern/list.c (grub_list_iterate): Return int instead of void.
6359 (grub_list_insert): New function.
6360 (grub_prio_list_insert): Likewise.
6361
6362 * kern/rescue.c (grub_rescue_command): Removed.
6363 (grub_rescue_command_list): Likewise.
6364 (grub_rescue_register_command): Likewise.
6365 (grub_rescue_unregister_command): Likewise.
6366 (grub_rescue_cmd_boot): Move to minicmd.c
6367 (grub_rescue_cmd_help): Likewise.
6368 (grub_rescue_cmd_info): Likewise.
6369 (grub_rescue_cmd_boot): Likewise.
6370 (grub_rescue_cmd_testload): Likewise.
6371 (grub_rescue_cmd_dump): Likewise.
6372 (grub_rescue_cmd_rmmod): Likewise.
6373 (grub_rescue_cmd_lsmod): Likewise.
6374 (grub_rescue_cmd_exit): Likewise.
6375 (grub_rescue_print_devices): Moved to corecmd.c.
6376 (grub_rescue_print_files): Likewise.
6377 (grub_rescue_cmd_ls): Likewise.
6378 (grub_rescue_cmd_insmod): Likewise.
6379 (grub_rescue_cmd_set): Likewise.
6380 (grub_rescue_cmd_unset): Likewise.
7d074e3c 6381 (attempt_normal_mode): Use grub_command_find to get normal module.
b1b797cb 6382 (grub_enter_rescue_mode): Use grub_register_core_commands to register
7d074e3c 6383 commands, remove grub_rescue_register_command calls.
b1b797cb 6384
7d074e3c 6385 * normal/command.c (grub_register_command): Removed.
b1b797cb 6386 (grub_unregister_command): Likewise.
6387 (grub_command_find): Likewise.
6388 (grub_iterate_commands): Likewise.
6389 (rescue_command): Likewise.
6390 (export_command): Moved to corecmd.c.
6391 (set_command): Removed.
6392 (unset_command): Likewise.
6393 (insmod_command): Likewise.
6394 (rmmod_command): Likewise.
6395 (lsmod_command): Likewise.
6396 (grub_command_init): Likewise.
6397
6398 * normal/completion.c (iterate_command): Use cmd->prio to check for
6399 active command.
6400 (complete_arguments): Use grub_extcmd_t structure to find options.
6401 (grub_normal_do_completion): Change function grub_iterate_commands to
6402 grub_command_iterate.
6403
6404 * normal/execute.c (grub_script_execute_cmd): No need to parse
6405 argument here.
6406
6407 * normal/main.c (grub_dyncmd_dispatcher): New function.
6408 (read_command_list): Register unload commands as dyncmd.
6409 (grub_cmd_normal): Use new command interface, register rescue,
6410 unregister normal at entry, register normal, unregister rescue at exit.
6411
6412 * include/grub/list.h (grub_list_test_t): New type.
6413 (grub_list_iterate): Return int instead of void.
6414 (grub_list_insert): New function.
6415 (GRUB_AS_NAMED_LIST_P): New macro.
6416 (GRUB_AS_PRIO_LIST): Likewise.
6417 (GRUB_AS_PRIO_LIST_P): Likewise.
6418 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
6419 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
6420 (grub_prio_list): New structure.
6421 (grub_prio_list_insert): New function.
6422 (grub_prio_list_remove): New inline function.
6423
6424 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
6425 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
6426 (GRUB_COMMAND_FLAG_MENU): Likewise.
6427 (GRUB_COMMAND_FLAG_BOTH): Likewise.
6428 (GRUB_COMMAND_FLAG_TITLE): Likewise.
6429 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
6430 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
6431 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
6432 (grub_command): Likewise.
6433 (grub_register_command): Likewise.
6434 (grub_command_find): Likewise.
6435 (grub_iterate_commands): Likewise.
6436 (grub_command_init): Likewise.
6437 (grub_arg_parse): Likewise.
6438 (grub_arg_show_help): Likewise.
6439
6440 * include/grub/rescue.h (grub_rescue_register_command): Removed.
6441 (grub_rescue_unregister_command): Likewise.
6442
6443 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
6444 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
6445 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
6446
6447 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
6448 grub_rescue_cmd_initrd.
6449 * include/grub/i386/loader.h: Likewise.
6450 * include/grub/x86_64/loader.h: Likewise.
6451
6452 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
6453
1f4147aa 64542009-03-21 Bean <bean123ch@gmail.com>
6455
6456 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
6457 instead of stat in mingw environment.
6458
6459 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
6460
6461 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
6462
6463 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
6464 AC_CONFIG_LINKS.
6465
2156d5ba 64662009-03-21 Bean <bean123ch@gmail.com>
6467
6468 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
6469 out of range error.
6470
177b82ca 64712009-03-18 Michel Dänzer <michel@daenzer.net>
6472
6473 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
6474 checking inode flags for EXT4_EXTENTS_FLAG.
6475
14aad807 64762009-03-18 Robert Millan <rmh@aybabtu.com>
6477
6478 * loader/i386/linux.c: Include `<grub/video.h>' and
6479 `<grub/i386/pc/vbe.h>'..
6480 (grub_linux_setup_video): New function. Loosely based on the EFI one.
6481 (grub_linux32_boot): Attempt to configure video settings with
6482 grub_linux_setup_video().
6483 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
6484 to avoid grub_console_fini() which would step out of graphical mode
6485 unconditionally.
6486
8cf83a27 64872009-03-14 Robert Millan <rmh@aybabtu.com>
6488
6489 Fix build on powerpc.
6490 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
6491
40164e75 64922009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
6493
6494 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
6495 background image command.
6496
c58bc32a 64972009-03-12 Colin D Bennett <colin@gibibit.com>
6498
6499 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
6500 (grub_gfxterm_putchar): Extract pairs of identical calls to
6501 draw_cursor out of conditional blocks.
6502
5415144a 65032009-03-11 Pavel Roskin <proski@gnu.org>
6504
6505 * fs/hfs.c (grub_hfs_strncasecmp): New function.
6506 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
6507
6394042e 65082009-03-11 Robert Millan <rmh@aybabtu.com>
6509
6510 * loader/i386/multiboot_elfxx.c
6511 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
6512
b7b50e5f 65132009-03-11 Felix Zielcke <fzielcke@z-51.de>
6514
6515 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
6516 `kern/handler.c'.
6517
1ca7fc96 65182009-03-11 Robert Millan <rmh@aybabtu.com>
6519
6520 * loader/i386/multiboot.c (code_size): New variable.
6521 (grub_multiboot): Define offsets by adding to `code_size' rather
7d074e3c 6522 than subtracting from `grub_multiboot_payload_size'. Provide
1ca7fc96 6523 4-byte alignment to MBI and others by increasing
7d074e3c 6524 `boot_loader_name_length' appropriately.
1ca7fc96 6525
6526 * loader/i386/multiboot_elfxx.c
6527 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
6528
a83ea1d2 65292009-03-09 Felix Zielcke <fzielcke@z-51.de>
6530
6531 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
6532 `fs/ext2.c'.
6533
aa9f3bff 65342009-03-08 Robert Millan <rmh@aybabtu.com>
6535
6536 Make loader/i386/linux.c usable on i386-pc again.
6537
6538 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
6539 memory to heap.
6540 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
6541 `#error' stanza.
6542
d8b3b60e 65432009-03-07 Bean <bean123ch@gmail.com>
6544
6545 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
6546 allocation.
6547
b362c9e9 65482009-03-06 Robert Millan <rmh@aybabtu.com>
6549
6550 Fix display issue on terminals with screen size other than 80x25
6551 (e.g. gfxterm with resolution higher than 640x480).
6552
6553 * normal/main.c (grub_normal_init_page): Display title text in a
7d074e3c 6554 position relative to the center of the terminal instead of relying
b362c9e9 6555 on a hardcoded offset.
6556
9304eef1 65572009-03-04 Robert Millan <rmh@aybabtu.com>
6558
6559 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
6560 installed.
6561
6562 * Makefile.in (host_kernel): New variable.
6563 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
6564 scripts instead of just the windows one.
6565 * configure.ac: Initialize and AC_SUBST `host_kernel'.
6566
eabc95fb 65672009-03-04 Felix Zielcke <fzielcke@z-51.de>
2ba60b62 6568
6569 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
6570 `kern/handler.c'.
6571 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6572 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6573 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
6574 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6575 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6576 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6577
ceb1223c 65782009-03-04 Felix Zielcke <fzielcke@z-51.de>
6579
6580 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
6581 or if there's no space for the disk label and print the partition number on a
6582 invalid magic.
6583
4910684a 65842009-03-04 Felix Zielcke <fzielcke@z-51.de>
6585
6586 * util/misc.c: Include <time.h>.
6587 (grub_millisleep): New function.
6588
7e9ca17a 65892009-03-04 Bean <bean123ch@gmail.com>
6590
6591 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
6592 another option -mno-red-zone.
6593
6594 * commands/handler.c: Change module description.
6595
6596 * kern/handler.c: Add missing space at the end of description line.
6597
6598 * kern/list.c: Likewise.
6599
f501677c 66002009-03-03 Robert Millan <rmh@aybabtu.com>
6601
6602 Move more components to the relocation area, and fix mbi pointer
6603 handling to use the destination rather than the origin (thanks to
6604 Vladimir Serbinenko for spotting).
6605
6606 * loader/i386/multiboot.c (mbi_dest): New variable.
6607 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
6608 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
6609 relocation area.
6610
9902d047 66112009-03-01 Bean <bean123ch@gmail.com>
6612
50fb7002 6613 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
9902d047 6614 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
6615 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
6616 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
6617
6618 * loader/i386/efi/linux.c (acpi_guid): New variable.
6619 (acpi_guid): Likewise.
6620 (EBDA_SEG_ADDR): New constant.
6621 (LOW_MEM_ADDR): Likewise.
6622 (FAKE_EBDA_SEG): Likewise.
6623 (fake_bios_data): New function.
6624 (grub_linux_boot): Call fake_bios_data.
6625
71b9f361 66262009-03-01 Bean <bean123ch@gmail.com>
6627
6628 * commands/terminal.c: Removed.
6629
6630 * commands/handler.c: New file.
6631
6632 * include/grub/list.h: Likewise.
6633
6634 * include/grub/handler.h: Likewise.
6635
6636 * kern/list.c: Likewise.
6637
6638 * kern/handler.c: Likewise.
6639
6640 * kern/term.h: Include header file <grub/handler.h>.
6641 (grub_term_input): Move next field to the beginning.
6642 (grub_term_output): Likewise.
6643 (grub_term_input_class): New variable.
6644 (grub_term_output_class): Likewise.
6645 (grub_term_register_input): Changed to inline function.
6646 (grub_term_register_output): Likewise.
6647 (grub_term_unregister_input): Likewise.
6648 (grub_term_unregister_output): Likewise.
6649 (grub_term_set_current_input): Likewise.
6650 (grub_term_set_current_output): Likewise.
6651 (grub_term_get_current_input): Likewise.
6652 (grub_term_get_current_output): Likewise.
6653 (grub_term_iterate_input): Removed.
6654 (grub_term_iterate_output): Likewise.
6655
6656 * kern/term.c (grub_term_list_input): Removed.
6657 (grub_term_list_output): Likewise.
6658 (grub_term_input_class): New variable.
6659 (grub_term_output_class): Likewise.
50fb7002 6660 (grub_cur_term_input): Change variable as macro.
71b9f361 6661 (grub_cur_term_output): Likewise.
6662 (grub_term_register_input): Removed.
6663 (grub_term_register_output): Likewise.
6664 (grub_term_unregister_input): Likewise.
6665 (grub_term_unregister_output): Likewise.
6666 (grub_term_set_current_input): Likewise.
6667 (grub_term_set_current_output): Likewise.
6668 (grub_term_iterate_input): Likewise.
6669 (grub_term_iterate_output): Likewise.
6670 (grub_term_get_current_input): Likewise.
6671 (grub_term_get_current_output): Likewise.
6672
6673 * util/grub-editenv.c: Include header file <grub/handler.h>.
6674 (grub_term_get_current_input): Removed.
6675 (grub_term_get_current_output): Likewise.
6676 (grub_term_input_class): New variable.
50fb7002 6677 (grub_term_output_class): Likewise.
71b9f361 6678
6679 * util/grub-fstest.c (grub_term_get_current_input): Removed.
6680 (grub_term_get_current_output): Likewise.
6681 (grub_term_input_class): New variable.
50fb7002 6682 (grub_term_output_class): Likewise.
71b9f361 6683
6684 * util/grub-probe.c (grub_term_get_current_input): Removed.
6685 (grub_term_get_current_output): Likewise.
6686 (grub_term_input_class): New variable.
50fb7002 6687 (grub_term_output_class): Likewise.
71b9f361 6688
6689 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
6690 (grub_term_get_current_output): Likewise.
6691 (grub_term_input_class): New variable.
50fb7002 6692 (grub_term_output_class): Likewise.
71b9f361 6693
6694 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
6695 (terminal_mod_SOURCES): Likewise.
6696 (terminal_mod_CFLAGS): Likewise.
6697 (terminal_mod_LDFLAGS): Likewise.
6698
6699 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
6700 handler.c.
6701 (kernel_img_SOURCES): Add list.c and handler.c.
6702 (kernel_img_HEADERS): Add list.h and handler.h.
6703
6704 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6705 handler.c.
6706 (kernel_mod_SOURCES): Add list.c and handler.c.
6707 (kernel_mod_HEADERS): Add list.h and handler.h.
6708
6709 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
6710 handler.c.
6711 (kernel_elf_SOURCES): Add list.c and handler.c.
6712 (kernel_elf_HEADERS): Add list.h and handler.h.
6713
6714 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6715 handler.c.
6716 (kernel_elf_SOURCES): Add list.c and handler.c.
6717 (kernel_elf_HEADERS): Add list.h and handler.h.
6718
6719 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6720 handler.c.
6721 (kernel_mod_SOURCES): Add list.c and handler.c.
6722 (kernel_mod_HEADERS): Add list.h and handler.h.
6723
6724 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6725 handler.c.
6726 (kernel_elf_SOURCES): Add list.c and handler.c.
6727 (kernel_elf_HEADERS): Add list.h and handler.h.
6728
8a31787f 67292009-02-27 Robert Millan <rmh@aybabtu.com>
6730
6731 Factorize elf32 / elf64 code in Multiboot loader. This will
6732 prevent it from getting out of sync again.
6733
6734 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
6735 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
6736 grub_multiboot_load_elf64): Move from here ...
6737 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
6738 grub_multiboot_load_elf): ... to here (new file).
6739
51cd3dfc 67402009-02-27 Robert Millan <rmh@aybabtu.com>
6741
6742 * util/grub.d/10_linux.in: Rename "single-user mode" to
6743 "recovery mode".
6744
6e8c9c3a 67452009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
6746
6747 Don't leak in SCSI code.
6748 * disk/scsi.c (grub_scsi_close): free `scsi'.
6749
4b6bf4f9 67502009-02-27 Robert Millan <rmh@aybabtu.com>
6751
6752 * loader/i386/pc/multiboot.c: Move from here ...
6753 * loader/i386/multiboot.c: ... to here. Update all users.
6754
b9413424 67552009-02-27 Robert Millan <rmh@aybabtu.com>
6756
6757 Patch from Alexandre Bique <bique.alexandre@gmail.com>
6758 * util/i386/pc/grub-setup.c (setup): Fix directory path.
6759
50fb7002 67602009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
34519c3f 6761
6762 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
6763 b-tree.
6764
8cc50345 67652009-02-27 Robert Millan <rmh@aybabtu.com>
6766
6767 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
6768 `0x' qualifier as 0 when base is specified as parameter).
6769
6e09b8b7 67702009-02-24 Bean <bean123ch@gmail.com>
6771
6772 * configure.ac: Check for -mcmodel=large in x86_64 target.
6773
6774 * include/grub/efi/api.h (efi_call_10): New macro.
6775 (efi_wrap_10): New function.
6776
6777 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
6778 (GRUB_PE32_REL_BASED_HIGH): Likewise.
6779 (GRUB_PE32_REL_BASED_LOW): Likewise.
6780 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
6781 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
6782 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
6783 (GRUB_PE32_REL_BASED_SECTION): Likewise.
6784 (GRUB_PE32_REL_BASED_REL): Likewise.
6785 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
6786 (GRUB_PE32_REL_BASED_DIR64): Likewise.
6787 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
6788
6789 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
6790 issue.
6791
6792 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
6793 (efi_wrap_10): New function.
6794
6795 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
6796
6797 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
6798 MB/MBP model (NV chipset).
6799 (devdata_devs): Add devpath_5 to the list.
6800
6801 * load/i386/efi/linux.c (video_base): Remove variable.
6802 (RGB_MASK): New macro.
6803 (RGB_MAGIC): Likewise.
6804 (LINE_MIN): Likewise.
6805 (LINE_MAX): Likewise.
6806 (FBTEST_STEP): Likewise.
6807 (FBTEST_COUNT): Likewise.
6808 (fb_list): New variable.
6809 (grub_find_video_card): Remove function.
6810 (find_framebuf): New function.
6811 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
6812 line length.
6813
6814 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
6815 problem for x86_64.
6816
74b21bee 68172009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
6818
6819 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
6820
6821 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
6822 coding tool name.
6823
a455f472 68242009-02-22 Robert Millan <rmh@aybabtu.com>
6825
6826 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
6827 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
6828 in our relocation, instead of using it directly from heap. Also
6829 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
6830
6374daf3 68312009-02-21 Robert Millan <rmh@aybabtu.com>
6832
6833 Implement USB keyboard support (based on patch by Marco Gerards)
6834
6835 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
6836 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
6837 (usb_keyboard_mod_LDFLAGS): New variables.
6838
6839 * term/usb_keyboard.c: New file.
6840
8fa4ea70 68412009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
6842
6843 Corrected wrong declaration
6844
6845 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
6846
353976ac 68472009-02-14 Christian Franke <franke@computer.org>
6848
6849 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
6850 (grub_lspci_iter): Print class code and programming interface byte.
6851
6aa1169b 68522009-02-14 Christian Franke <franke@computer.org>
6853
6854 * gendistlist.sh: Ignore `.svn' directories.
6855
265372ca 68562009-02-14 Felix Zielcke <fzielcke@z-51.de>
6857
6858 * fs/fat.c: Add 2009 to Copyright line.
6859
9ff516f3 68602009-02-14 Christian Franke <franke@computer.org>
6861
6862 * commands/hdparm.c: New file. Provides `hdparm' command
6863 which sends ATA commands via grub_disk_ata_pass_through ().
6864
6865 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
6866
6867 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
6868 and <grub/cpu/io.h> to include/grub/ata.h.
6869 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
6870 (GRUB_CDROM_SECTOR_SIZE): Remove.
6871 (GRUB_ATA_*): Move to include/grub/ata.h.
6872 (GRUB_ATAPI_*): Likewise.
6873 (enum grub_ata_commands): Likewise.
6874 (enum grub_ata_timeout_milliseconds): Likewise.
6875 (struct grub_ata_device): Likewise.
6876 (grub_ata_regset): Likewise.
6877 (grub_ata_regget): Likewise.
6878 (grub_ata_regset2): Likewise.
6879 (grub_ata_regget2): Likewise.
6880 (grub_ata_check_ready): Likewise.
6881 (grub_ata_wait_not_busy): Remove static, exported in
6882 include/grub/ata.h.
6883 (grub_ata_wait_drq): Likewise.
6884 (grub_ata_pio_read): Likewise.
6885
6886 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
6887 function for hdparm.mod.
6888
6889 * include/grub/ata.h: New file, contains declarations from
6890 disk/ata.c.
6891 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
6892
6893 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
6894 (grub_disk_ata_pass_through): New exported variable.
6895
6896 * kern/disk.c (grub_disk_ata_pass_through): New variable.
6897
772e23da 68982009-02-13 Colin D Bennett <colin@gibibit.com>
6899
6900 Support multiple fallback entries, and provide an API to support
6901 executing default+fallback menu entries. Renamed the `terminal' menu
6902 viewer to `text'.
6903
6904 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
6905 variable declaration.
6906 (grub_menu_execute_callback): New structure declaration.
6907 (grub_menu_execute_callback_t): New typedef.
6908 (grub_menu_execute_with_fallback): New function declaration.
6909 (grub_menu_get_entry): Likewise.
6910 (grub_menu_get_timeout): Likewise.
6911 (grub_menu_set_timeout): Likewise.
6912
6913 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
6914
6915 * normal/menu.c (grub_wait_after_message): Moved to
6916 `normal/menu_text.c'.
6917 (draw_border): Likewise.
6918 (print_message): Likewise.
6919 (print_entry): Likewise.
6920 (print_entries): Likewise.
6921 (grub_menu_init_page): Likewise.
6922 (get_entry_number): Likewise.
6923 (print_timeout): Likewise.
6924 (run_menu): Likewise.
6925 (grub_menu_execute_entry): Likewise.
6926 (show_text_menu): Likewise.
6927 (get_and_remove_first_entry_number): New function.
6928 (grub_menu_execute_with_fallback): Likewise.
6929 (get_entry): Renamed to ...
6930 (grub_menu_get_entry): .. this and made it global.
6931 (get_timeout): Renamed to ...
6932 (grub_menu_get_timeout): ... this and made it global.
6933 (set_timeout): Renamed to ...
6934 (grub_menu_set_timeout): ... this and made it global.
6935 (grub_normal_terminal_menu_viewer): Renamed to ...
6936 (grub_normal_text_menu_viewer): ... this.
6937
6938 * normal/menu_text.c: New file. Extracted text-menu-specific code
6939 from normal/menu.c.
6940
6941 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
6942 (normal_mod_SOURCES): Likewise.
6943
6944 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6945 (normal_mod_SOURCES): Likewise.
6946
6947 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6948 (normal_mod_SOURCES): Likewise.
6949
6950 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
6951 (normal_mod_SOURCES): Likewise.
6952
6953 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6954 (normal_mod_SOURCES): Likewise.
6955
6956 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6957 (normal_mod_SOURCES): Likewise.
6958
6959 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6960 (normal_mod_SOURCES): Likewise.
6961
16ac430e 69622009-02-11 Robert Millan <rmh@aybabtu.com>
6963
6964 * util/grub.d/00_header.in: Update old reference to `font' command.
6965
06ff20fc 69662009-02-10 Felix Zielcke <fzielcke@z-51.de>
6967
6968 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
6969
6970 Based on patch from Javier Martín.
6971
96da9407 69722009-02-09 Felix Zielcke <fzielcke@z-51.de>
6973
6974 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
50fb7002 6975 to avoid false positives with FAT.
96da9407 6976 (grub_fstest_SOURCES): Likewise.
6977 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
6978 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6979 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6980 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
6981 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6982 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6983
6dca6fe4 69842009-02-09 Felix Zielcke <fzielcke@z-51.de>
6985
06ff20fc 6986 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
6dca6fe4 6987 bpb.version_specific.fat12_or_fat16.fstype and
6988 bpb.version_specific.fat32.fstype.
6989
2550c62f 69902009-02-08 Robert Millan <rmh@aybabtu.com>
6991
be110b30 6992 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
2550c62f 6993
56978920 69942009-02-08 Robert Millan <rmh@aybabtu.com>
6995
6996 * Makefile.in (host_os, host_cpu): New variables.
6997 (target_os): Remove. Update all users.
6998
d64399b5 69992009-02-08 Marco Gerards <marco@gnu.org>
7000
7001 * Makefile.in (enable_grub_emu_usb): New variable.
7002 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
7003 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
7004 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
7005 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
7006 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
7007 `usbtest.mod' and `usbms.mod'.
7008 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
7009 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
7010 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
7011 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
7012 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
7013 variables.
7014
7015 * disk/usbms.c: New file.
7016
7017 * include/grub/usb.h: Likewise.
7018
7019 * include/grub/usbtrans.h: Likewise.
7020
7021 * include/grub/usbdesc.h: Likewise.
7022
7023 * bus/usb/usbtrans.c: Likewise.
7024
7025 * bus/usb/ohci.c: Likewise.
7026
7027 * bus/usb/uhci.c: Likewise.
7028
7029 * bus/usb/usbhub.c: Likewise.
7030
7031 * bus/usb/usb.c: Likewise.
7032
7033 * commands/usbtest.c: Likewise.
7034
7035 * util/usb.c: Likewise.
50fb7002 7036
d64399b5 7037 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
7038
7039 * configure.ac: Test for libusb presence.
50fb7002 7040
d64399b5 7041 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
7042
2b40d6bb 70432009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
7044
7045 * kern/mm.c: Add more comments.
7046
73a4ce81 70472009-02-08 Robert Millan <rmh@aybabtu.com>
7048
7049 Patch from Javier Martín.
7050 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
7051 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
7052
f821ce59 70532009-02-08 Robert Millan <rmh@aybabtu.com>
7054
7055 * fs/cpio.c: Split tar functionality to ...
7056 * fs/tar.c: ... here (new file). Update all users.
7057
aebfc4b0 70582009-02-07 Robert Millan <rmh@aybabtu.com>
7059
7060 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
7061 backward-incompatible features.
7062
7063 Based on patch from Javier Martín, with some adjustments.
7064
50fb7002 70652009-02-07 Michael Scherer <misc@mandriva.org>
cea15bca 7066
7067 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
7068
0bb5115e 70692009-02-07 Robert Millan <rmh@aybabtu.com>
7070
7071 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
7072 position of `disk/lvm.c' to ensure grub_init_all() always picks it
7073 after the RAID stuff.
7074
38a0f8e7 70752009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
7076
50fb7002 7077 Fixes problem when running vbetest command as reported by
38a0f8e7 7078 Vladimir Serbinenko <phcoder@gmail.com>.
7079
7080 * (grub_vbe_set_video_mode): Fixed problem with text modes.
7081
3143cc1c 70822009-02-04 Felix Zielcke <fzielcke@z-51.de>
7083
7084 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
7085 /dev/md/NpN style mdraid devices.
7086
9cba6fce 70872009-02-03 Felix Zielcke <fzielcke@z-51.de>
7088
7089 * util/unifont2pff.rb: Remove.
7090
e507a2c1 70912009-02-03 Felix Zielcke <fzielcke@z-51.de>
7092
7093 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
7094 `#'.
7095
d2c2b4cd 70962009-02-03 Felix Zielcke <fzielcke@z-51.de>
7097
7098 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
7099 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7100 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7101 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7102 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7103 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7104 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7105
b4315fb0 71062009-02-02 Christian Franke <franke@computer.org>
7107
7108 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
7109
de3aa260 71102009-02-01 Felix Zielcke <fzielcke@z-51.de>
7111
7c3ff286 7112 * INSTALL: Note that we now require at least autoconf 2.59 and
7113 that LZO is optional.
de3aa260 7114
825a182b 71152009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7116
7117 Base on patch on bug #24154 created by Tomas Tintera
7118 <trosos@seznam.cz>.
7119
7120 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
7121
a69ef770 71222009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7123
7c3ff286 7124 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
a69ef770 7125 <bero@arklinux.org>.
7126
7127 * normal/parser.y (script_init): Add missing semicolon.
7128
6fa42fa6 71292009-01-31 Colin D Bennett <colin@gibibit.com>
7130
7c3ff286 7131 * normal/main.c: Add include to grub/menu_viewer.h.
6fa42fa6 7132 (free_menu_entry_classes): Added.
7133 (grub_normal_menu_addentry): Added class property handling.
7134 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
7135 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
7136
7137 * normal/menu_viewer.c: New file.
7138
7139 * normal/menu.c (run_menu_entry): Renamed to ...
7140 (grub_menu_execute_entry): ... this and made it as global.
7141 (grub_menu_run): Renamed to ...
7142 (show_text_menu): ... this and made it local.
7143 (show_text_menu): Adapt to new function names.
7144 (grub_normal_terminal_menu_viewer): New global variable.
7145
7146 * include/grub/menu.h: New file.
7147
7148 * include/grub/menu_viewer.h: New file.
7149
7150 * include/grub/normal.h: Added include to grub/menu.h.
7151 (grub_menu_entry): Moved to include/grub/menu.h.
7152 (grub_menu_entry_t): Likewise.
7153 (grub_menu): Likewise.
7154 (grub_menu_t): Likewise.
7155 (grub_normal_terminal_menu_viewer): Added.
7156 (grub_menu_execute_entry): Likewise.
7157 (grub_menu_run): Removed.
7158
7159 * DISTLIST: Added include/grub/menu.h.
7160 Added include/grub/menu_viewer.h.
7161 Added normal/menu_viewer.c.
7162
71632009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
7164
7165 * normal/execute.c (grub_script_execute_menuentry): Changed to use
7166 arglist for menutitle arguments.
7167
7168 * normal/main.c (grub_normal_menu_addentry): Likewise.
7169
7170 * normal/parser.y (menuentry): Likewise.
7171
7172 * normal/script.c (grub_script_create_cmdmenu): Likewise.
7173
7174 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
7175 (grub_script_create_cmdmenu): Likewise.
7176
7177 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
7178
7179 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
7180 changes.
7181
7182 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
7183
7184 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
7185
7186 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
7187
7188 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7189
7190 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7191
7192 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7193
56192c23 71942009-01-30 Christian Franke <franke@computer.org>
7195
7196 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
7197 in option help text.
7198
d72521b3 71992009-01-27 Pavel Roskin <proski@gnu.org>
7200
7201 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
7202
994b5e84 72032009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7204
7205 * commands/lsmmap.c: Add include to grub/machine/memory.h.
7206
7207 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
7208
7209 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
7210 unregister function.
7211
6a7eab2c 72122009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7213
7214 * disk/scsi.c (grub_scsi_read): Fix sign problem.
7215
7216 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
7217
7218 * util/grub-mkfont.c (usage): Fix typo.
7219
7220 * util/elf/grub-mkimage.c (load_modules): Fix warning.
7221
1806b56e 72222009-01-26 Daniel Mierswa <impulze@impulze.org>
7223
3fb18f09 7224 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
7225
336e1fb9 7226 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
7227
1806b56e 7228 * kern/misc.c (grub_strcasecmp): New function.
7229 (grub_strcasecmp): Use grub_size_t instead of int for length.
7230 Fix return value.
7231 * include/grub/misc.h: Update function prototypes.
7232
580b2a0f 72332009-01-26 Robert Millan <rmh@aybabtu.com>
7234
7235 * configure.ac: Fix cross-compilation check.
ef257b36 7236
d31c24f1 72372009-01-22 Christian Franke <franke@computer.org>
7238
7239 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
7240 (precision) digit string. Allow `.format2' without `format1' (width).
7241 Limit input chars for `%s' output to `format2' if specified. This is
7242 compatible with standard printf ().
7243
3138b44c 72442009-01-22 Christian Franke <franke@computer.org>
7245
7246 * disk/ata.c (grub_ata_wait_status): Replace by ...
7247 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
7248 other status bits may be invalid while BSY is asserted.
7249 (grub_ata_check_ready): New function.
7250 (grub_ata_cmd): Removed.
7251 (grub_ata_wait_drq): New function.
7252 (grub_ata_strncpy): Remove inline.
7253 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
7254 and error check now done by grub_ata_wait_drq ().
7255 (grub_ata_pio_write): Likewise.
7256 (grub_atapi_identify): Set DEV before check for !BSY. Use
7257 grub_ata_wait_drq () to wait for data.
7258 (grub_ata_device_initialize): Add status register check to
7259 detect missing SATA slave devices. Add debug messages.
7260 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
7261 (grub_atapi_packet): Set DEV before check for !BSY. Replace
7262 transfer loop by grub_ata_pio_write ().
7263 (grub_ata_identify): Set DEV before check for !BSY. Use
7264 grub_ata_wait_drq () to wait for data.
ef257b36 7265 (grub_ata_setaddress): Set DEV before check for !BSY.
3138b44c 7266 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
7267 read/write in one loop. Fix invalid command on write. Fix incomplete
7268 command on (size % batch) == 0. Add missing error check after write of
7269 last block. Add debug messages.
7270 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
7271
59a64ef6 72722009-01-19 Christian Franke <franke@computer.org>
7273
7274 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
7275 (GRUB_ATAPI_IREASON_*): Likewise.
7276 (grub_ata_pio_write): Fix timeout error return.
7277 (grub_atapi_identify): Add grub_ata_wait () after cmd.
7278 (grub_atapi_wait_drq): New function.
7279 (grub_atapi_packet): New parameter `size'.
7280 Use grub_atapi_wait_drq () and direct write instead of
7281 grub_ata_pio_write ().
7282 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
7283 reads the number of bytes requested by the device for each DRQ
7284 assertion.
7285 (grub_atapi_write): Remove old implementation, return not
7286 implemented instead.
7287
1cfe20b3 72882009-01-19 Christian Franke <franke@computer.org>
7289
7290 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
7291 of 512 to calculate data size.
7292 (grub_scsi_read12): Likewise.
7293 (grub_scsi_write10): Likewise.
7294 (grub_scsi_write12): Likewise.
7295 (grub_scsi_read): Adjust size according to blocksize.
7296 Add checks for invalid blocksize and unaligned transfer.
7297
bee5fe5d 72982009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
7299
7300 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
7301
ef257b36 7302 * term/gfxterm.c (write_char): Fix background rendering for wide
bee5fe5d 7303 width glyphs.
7304
3e643f8c 73052009-01-19 Robert Millan <rmh@aybabtu.com>
7306
7307 * config.guess: Update to latest version from config git.
7308 * config.sub: Likewise.
7309
4fa80998 73102009-01-17 Felix Zielcke <fzielcke@z-51.de>
7311
7312 * Makefile.in: Change font compilation to use new grub-mkfont instead
7313 of java version.
7314
7315 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
7316 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
7317 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7318 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7319 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
7320 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
7321 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
7322 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
7323 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7324
7086085b 73252009-01-16 Christian Franke <franke@computer.org>
7326
7327 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
7328 (enum grub_ata_timeout_milliseconds): New enum.
7329 (grub_ata_wait_status): Add parameter milliseconds.
7330 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
7331 recovery from timed-out commands.
7332 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
7333 return grub_errno instead of REG_ERROR.
7334 (grub_ata_pio_write): Add parameter milliseconds.
7335 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
7336 Pass milliseconds to grub_ata_wait_status () and
7337 grub_ata_pio_read ().
7338 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
7339 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
7340 grub_ata_wait_status (). Fix IDENTIFY timeout check.
7341 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
7342 It is not suitable for device detection, because DEV bit is ignored,
7343 the command may run too long, and not all devices set the signature
7344 properly.
7345 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
7346 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
7347 Fix device selection, DEV bit must be set first to address the registers
7348 of the correct device.
7349 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
7350 grub_ata_pio_read/write ().
7351 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
7352 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
7353
4a412913 73542009-01-13 Carles Pina i Estany <carles@pina.cat>
7355
7356 * util/grub-editenv.c (main): Use fseeko(), not fseek().
7357
7795c55e 73582009-01-13 Bean <bean123ch@gmail.com>
d913988c 7359
7360 * util/grub-mkfont.c (write_font): forget to remove some debug code.
7361
7795c55e 73622009-01-13 Bean <bean123ch@gmail.com>
e52db1f7 7363
7364 * Makefile.in: (enable_grub_mkfont): New variable.
7365 (freetype_cflags): Likewise.
7366 (freetype_libs): Likewise.
7367
7368 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
7369 (grub_mkfont_SOURCES): New variable.
7370 (grub_mkfont_CFLAGS): Likewise.
7371 (grub_mkfont_LDFLAGS): Likewise.
7372
7373 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
7374 library if `--enable-grub-mkfont' is requested.
7375 (enable_grub_mkfont): New variable.
7376 (freetype_cflags): Likewise.
7377 (freetype_libs): Likewise.
7378
7379 * util/grub-mkfont.c: New file.
7380
093af1fe 73812009-01-12 Christian Franke <franke@computer.org>
7382
7383 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
7384 mode check. Fix setting of compat_use[].
7385
f36cc108 73862009-01-10 Robert Millan <rmh@aybabtu.com>
7387
7388 Update a few copyright years which we forgot to do in 2008 (only for
7389 files whose changes made in 2008 were copyright-significant)
7390
7391 * Makefile.in: Add 2008 to Copyright line.
7392 * disk/ieee1275/ofdisk.c: Likewise.
7393 * disk/efi/efidisk.c: Likewise.
7394 * kern/dl.c: Likewise.
7395 * kern/sparc64/ieee1275/init.c: Likewise.
7396 * kern/mm.c: Likewise.
7397 * kern/efi/mm.c: Likewise.
7398 * boot/i386/pc/boot.S: Likewise.
7399 * genfslist.sh: Likewise.
7400 * fs/iso9660.c: Likewise.
7401 * fs/hfs.c: Likewise.
7402 * fs/jfs.c: Likewise.
7403 * fs/minix.c: Likewise.
7404 * fs/ufs.c: Likewise.
7405 * gensymlist.sh.in: Likewise.
7406 * genkernsyms.sh.in: Likewise.
7407 * include/grub/misc.h: Likewise.
7408 * include/grub/types.h: Likewise.
7409 * include/grub/symbol.h: Likewise.
7410 * include/grub/elf.h: Likewise.
7411 * include/grub/kernel.h: Likewise.
7412 * include/grub/disk.h: Likewise.
7413 * include/grub/dl.h: Likewise.
7414 * include/grub/i386/linux.h: Likewise.
7415 * include/grub/i386/pc/biosdisk.h: Likewise.
7416 * include/grub/efi/api.h: Likewise.
7417 * include/grub/efi/pe32.h: Likewise.
7418 * include/grub/util/misc.h: Likewise.
7419 * normal/execute.c: Likewise.
7420 * normal/arg.c: Likewise.
7421 * normal/completion.c: Likewise.
7422 * normal/lexer.c: Likewise.
7423 * normal/parser.y: Likewise.
7424 * normal/misc.c: Likewise.
7425 * commands/i386/pc/vbeinfo.c: Likewise.
7426 * commands/hexdump.c: Likewise.
7427 * commands/terminal.c: Likewise.
7428 * commands/ls.c: Likewise.
7429 * commands/help.c: Likewise.
7430 * partmap/pc.c: Likewise.
7431 * loader/efi/chainloader.c: Likewise.
7432 * loader/multiboot_loader.c: Likewise.
7433 * loader/i386/pc/multiboot2.c: Likewise.
7434 * term/efi/console.c: Likewise.
7435 * term/i386/pc/serial.c: Likewise.
7436 * util/lvm.c: Likewise.
7437 * util/console.c: Likewise.
7438 * util/i386/efi/grub-mkimage.c: Likewise.
7439 * util/raid.c: Likewise.
7440
7f02114b 74412009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
7442
7443 * commands/videotest.c: Removed include to grub/machine/memory.h.
7444
7445 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
7446 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
7447 (video_mod_SOURCES): Removed.
7448 (video_mod_CFLAGS): Likewise.
7449 (video_mod_LDFLAGS): Likewise.
7450 (gfxterm_mod_SOURCES): Likewise.
7451 (gfxterm_mod_CFLAGS): Likewise.
7452 (gfxterm_mod_LDFLAGS): Likewise.
7453 (videotest_mod_SOURCES): Likewise.
7454 (videotest_mod_CFLAGS): Likewise.
7455 (videotest_mod_LDFLAGS): Likewise.
7456 (bitmap_mod_SOURCES): Likewise.
7457 (bitmap_mod_CFLAGS): Likewise.
7458 (bitmap_mod_LDFLAGS): Likewise.
7459 (tga_mod_SOURCES): Likewise.
7460 (tga_mod_CFLAGS): Likewise.
7461 (tga_mod_LDFLAGS): Likewise.
7462 (jpeg_mod_SOURCES): Likewise.
7463 (jpeg_mod_CFLAGS): Likewise.
7464 (jpeg_mod_LDFLAGS): Likewise.
7465 (png_mod_SOURCES): Likewise.
7466 (png_mod_CFLAGS): Likewise.
7467 (png_mod_LDFLAGS): Likewise.
7468
7469 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
7470 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
7471 (video_mod_SOURCES): Added.
7472 (video_mod_CFLAGS): Likewise.
7473 (video_mod_LDFLAGS): Likewise.
7474 (videotest_mod_SOURCES): Likewise.
7475 (videotest_mod_CFLAGS): Likewise.
7476 (videotest_mod_LDFLAGS): Likewise.
7477 (bitmap_mod_SOURCES): Likewise.
7478 (bitmap_mod_CFLAGS): Likewise.
7479 (bitmap_mod_LDFLAGS): Likewise.
7480 (tga_mod_SOURCES): Likewise.
7481 (tga_mod_CFLAGS): Likewise.
7482 (tga_mod_LDFLAGS): Likewise.
7483 (jpeg_mod_SOURCES): Likewise.
7484 (jpeg_mod_CFLAGS): Likewise.
7485 (jpeg_mod_LDFLAGS): Likewise.
7486 (png_mod_SOURCES): Likewise.
7487 (png_mod_CFLAGS): Likewise.
7488 (png_mod_LDFLAGS): Likewise.
7489 (gfxterm_mod_SOURCES): Likewise.
7490 (gfxterm_mod_CFLAGS): Likewise.
7795c55e 7491 (gfxterm_mod_LDFLAGS): Likewise.
7f02114b 7492
7493 * term/gfxterm.c: Removed include to grub/machine/memory.h,
7494 grub/machine/console.h.
7495
644fff97 74962009-01-04 Jerone Young <jerone@gmail.com>
7497
7498 Make on screen instructions clearer
7499
7500 Based on patch created by Jidanni <jidanni@jidanni.org>
7501
7502 * normal/menu.c: print clearer instructions on the screen
7503
1e901a75 75042009-01-02 Colin D Bennett <colin@gibibit.com>
7505
7506 New font engine.
34c44600 7507
1e901a75 7508 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
7509 build system and fixed gfxterm.c to work with different sized fonts.
7510
7511 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
34c44600 7512
1e901a75 7513 * configure: Re-generated.
34c44600 7514
1e901a75 7515 * DISTLIST: Removed font/manager.c.
7516 Added font/font.c.
7517 Added font/font_cmd.c.
34c44600 7518
1e901a75 7519 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
7520 compilation.
34c44600 7521
1e901a75 7522 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
34c44600 7523
7524 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
1e901a75 7525
7526 * kern/term.c: Changed users of grub_utf8_to_ucs4.
34c44600 7527
1e901a75 7528 * normal/menu.c: Likewise.
34c44600 7529
1e901a75 7530 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
7531 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
34c44600 7532
1e901a75 7533 * include/grub/font.h: Replaced with new file.
34c44600 7534
1e901a75 7535 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
7536 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
7537 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
7538 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
7539 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
34c44600 7540 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
1e901a75 7541 fg_red, fg_green, fg_blue, fg_alpha.
7542 (grub_video_adapter): Removed blit_glyph.
34c44600 7543 (grub_video_blit_glyph): Removed.
7544
1e901a75 7545 * font/manager.c: Removed file.
34c44600 7546
7547 * font/font.c: New file.
7548
1e901a75 7549 * font/font_cmd.c: Likewise.
34c44600 7550
1e901a75 7551 * video/video.c (grub_video_blit_glyph): Removed.
34c44600 7552
1e901a75 7553 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
7554 (grub_video_vbe_map_rgba): Likewise.
7555 (grub_video_vbe_unmap_color_int): Likewise.
7556 (grub_video_vbe_blit_glyph): Removed.
7557 (grub_video_vbe_adapter): Removed blit_glyph.
34c44600 7558
1e901a75 7559 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
7560 (get_pixel): Likewise.
34c44600 7561 (set_pixel): Likewise.
7562
1e901a75 7563 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
34c44600 7564
1e901a75 7565 * term/gfxterm.c: Adapted to new font engine.
34c44600 7566
1e901a75 7567 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
34c44600 7568
1e901a75 7569 * term/i386/pc/vga.c: Likewise.
34c44600 7570
1e901a75 7571 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
34c44600 7572
1e901a75 7573 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
34c44600 7574
1e901a75 7575 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7576
1e901a75 7577 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7578
1e901a75 7579 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
34c44600 7580
1e901a75 7581 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
34c44600 7582
1e901a75 7583 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
34c44600 7584
1e901a75 7585 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
34c44600 7586
1e901a75 7587 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7588
7589 * util/grub.d/00_header.in: Changed to use new loadfont command.
34c44600 7590
1e901a75 7591 * util/grub-mkconfig_lib.in: Changed font extension.
7592
278922e8 75932008-12-28 Felix Zielcke <fzielcke@z-51.de>
7594
7595 * util/getroot.c (grub_util_get_grub_dev): Add support for
7596 /dev/md/dNNpNN style partitionable mdraid devices.
7597
3ced05cf 75982008-12-12 Alex Smith <alex@alex-smith.me.uk>
7599
7600 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
7601 at a time limit of the PXE TFTP API correctly.
7602 (grub_pxefs_close): Likewise.
7603
7fd0ee30 76042008-11-29 Robert Millan <rmh@aybabtu.com>
7605
34c44600 7606 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
7fd0ee30 7607 grub_ata_device_initialize() calls.
7608
34c44600 76092008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
0c5e79ab 7610
7611 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
7612 iteration failed.
7613 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
7614
89313780 76152008-11-28 Robert Millan <rmh@aybabtu.com>
7616
7617 Fix build on powerpc-ieee1275. Based on patch created by
7618 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
7619 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
7620 `kern/ieee1275/mmap.c'.
7621 * include/grub/powerpc/ieee1275/memory.h: New file.
7622
15257703 7623 Provide grub-install on coreboot.
7624 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
7625 (grub_install_SOURCES): New variable.
7626 * util/i386/pc/grub-install.in: Add a few condition checks to make it
7627 usable on coreboot.
7628
9fc5388a 76292008-11-25 Felix Zielcke <fzielcke@z-51.de>
7630
7631 * util/grub-fstest.c (grub_term_get_current_input): Change return type
7632 to `grub_term_input_t'.
7633 (grub_term_get_current_output): Change return type to
7634 `grub_term_output_t'.
7635
bc3a2f31 76362008-11-22 Robert Millan <rmh@aybabtu.com>
7637
34c44600 7638 Fix breakage on coreboot due to declaration mismatch.
bc3a2f31 7639 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
7640 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
7641 grub_vga_text_cls().
7642
80fc88f2 7643 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
34c44600 7644 comments. Avoid copying one more byte than necessary (just in case).
80fc88f2 7645
cbf36fd3 7646 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
7647 to 0x200000 (avoids trouble with some OFW implementations, and matches
7648 with the one in Yaboot).
7649 Reported by Manoel Abranches
7650
73e8e268 76512008-11-20 Robert Millan <rmh@aybabtu.com>
3cf6ac19 7652
7653 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
7654 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
7655
73e8e268 7656 * util/grub-mkconfig_lib.in (grub_warn): New function.
7657 (convert_system_path_to_grub_path): Use grub_warn() when issuing
7658 warnings, to obtain consistent formatting.
7659 * util/grub.d/00_header.in: Likewise.
7660 * util/update-grub_lib.in: Likewise.
7661
e94045a1 7662 * loader/i386/linux.c (allocate_pages): Fix a warning.
40f9faa4 7663 Move comment text to `#error' stanza.
e94045a1 7664
79d29fd7 7665 Harmonize ieee1275's grub_available_iterate() with the generic
7666 grub_machine_mmap_iterate() interface (fixes a recently-introduced
7667 build problem on i386-ieee1275):
7668 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
7669 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
7670 parameter `type'. Update all users of this function.
7671 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
7672 `kern/ieee1275/mmap.c'.
7673 * kern/ieee1275/init.c
7674 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
7675 with ...
7676 (grub_machine_mmap_iterate): ... this.
7677 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
7678 return type to `grub_err_t'. Update all implementations of this
7679 function prototype.
7680 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
7681 Likewise.
7682
60d6b16e 7683 Add `lsmmap' command (lists firmware-provided memory map):
7684 * commands/lsmmap.c: New file.
7685 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
7686 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
7687 variables.
7688 * conf/powerpc-ieee1275.rmk: Likewise.
7689 * conf/i386-coreboot.rmk: Likewise.
7690 * conf/i386-ieee1275.rmk: Likewise.
7691
ebaaf49b 76922008-11-19 Robert Millan <rmh@aybabtu.com>
7693
7694 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
92907110 7695 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
7696 constraints to initrd allocation (based on code from
7697 loader/i386/pc/linux.c). Without them, initrd was allocated too high
7698 for Linux to find it.
ebaaf49b 7699
dfab719f 77002008-11-14 Robert Millan <rmh@aybabtu.com>
7701
7702 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
7703 order to cope with duplicate slashes.
7704
10fc3eb9 77052008-11-14 Robert Millan <rmh@aybabtu.com>
7706
7707 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
7708 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
7709 don't want to mess with lower memory, because it is used in the Linux
7710 loader.
7711
7712 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
34c44600 7713 an appropriate place in lower memory, between 0x10000 and 0x90000,
10fc3eb9 7714 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
7715 is in our heap (probably as a result of it being corrupted during
2f2a3442 7716 decompression). Add #error instance with comment to explain why this
7717 loader isn't currently usable on PC/BIOS.
10fc3eb9 7718
e2e07847 77192008-11-14 Robert Millan <rmh@aybabtu.com>
7720
7721 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
34c44600 7722 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
e2e07847 7723
fe8e8d69 77242008-11-12 Robert Millan <rmh@aybabtu.com>
7725
7726 Make loader/i386/linux.c buildable on i386-pc (although disabled).
7727
7728 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
7729 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
7730 from here ...
7731 * include/grub/i386/pc/memory.h: ... to here.
7732
976b07d0 77332008-11-12 Robert Millan <rmh@aybabtu.com>
7734
7735 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
7736 split).
7737
7738 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
7739 (grub_console_cur_color, grub_console_real_putchar)
7740 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7741 (grub_console_setcolorstate, grub_console_setcolor)
7742 (grub_console_getcolor): Move from here ...
7743 * include/grub/i386/vga_common.h: ... to here (new file).
7744
7745 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
7746 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
7747 `<grub/i386/io.h>'.
7748 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
7749 `<grub/i386/vga_common.h>'.
7750
76679cd3 77512008-11-12 Robert Millan <rmh@aybabtu.com>
7752
7753 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
7754 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
7755 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
7756 variables.
7757 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7758 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
7759
7760 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
7761 grub_console_init() with call to grub_vga_text_init().
7762 (grub_machine_fini): Replace call to
7763 grub_console_fini() with call to grub_vga_text_fini() and
7764 grub_at_keyboard_fini().
7765
7766 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
7767 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7768 (grub_console_setcolorstate, grub_console_setcolor)
7769 (grub_console_getcolor): New function prototypes.
7770
7771 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
7772 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
7773 (grub_vga_text_setcursor): Static-ize.
7774 (grub_vga_text_term): New structure.
7775 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
7776
7777 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
7778 (grub_console_cur_color, grub_console_standard_color)
7779 (grub_console_normal_color, grub_console_highlight_color)
7780 (map_char, grub_console_putchar, grub_console_getcharwidth)
7781 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
7782 (grub_console_getcolor): Move from here ...
7783 * term/i386/vga_common.c: ... to here (same function names).
7784
95b841d3 77852008-11-12 Robert Millan <rmh@aybabtu.com>
7786
7787 Use newly-added Multiboot support in coreboot.
7788
7789 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7790 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
7791
7792 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
7793 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
7794 (codestart): Store the MBI in `startup_multiboot_info' when we're
7795 being loaded using Multiboot.
7796
7797 * kern/i386/coreboot/init.c (grub_machine_init): Move
7798 grub_at_keyboard_init() call to beginning of function (useful for
7799 debugging). Call grub_machine_mmap_init() before attempting to use
7800 grub_machine_mmap_iterate().
7801 (grub_lower_mem, grub_upper_mem): Move from here ...
7802 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
7803 here (new file).
7804
7805 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
7806 function prototype.
7807
761ca975 78082008-11-12 Robert Millan <rmh@aybabtu.com>
7809
7810 Fix a regression introduced by the at_keyboard.mod split. Because
7811 some terminals are default on some platforms and non-default on
7812 others, the first terminal being registered determines which is
7813 going to be default.
7814
7815 * kern/term.c (grub_term_register_input): If this is the first
7816 terminal being registered, set it as the current one.
7817 (grub_term_register_output): Likewise.
7818
7819 * term/efi/console.c (grub_console_init): Do not call
7820 grub_term_set_current_output() or grub_term_set_current_input().
7821 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
7822 * term/i386/pc/console.c (grub_console_init): Likewise.
7823 (grub_console_fini): Do not call grub_term_set_current_input()
7824 (but leave grub_term_set_current_output() to restore text mode).
7825
6c529df7 78262008-11-10 Robert Millan <rmh@aybabtu.com>
7827
7828 * util/grub.d/00_header.in: Add backward compatibility check for
7829 versions of terminal.mod that don't understand `terminal_input' or
7830 `terminal_output'.
7831
132e4113 78322008-11-09 Robert Millan <rmh@aybabtu.com>
7833
7834 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
7835 `terminal_input' / `terminal_output', not `terminal'.
7836
ac293d50 78372008-11-08 Robert Millan <rmh@aybabtu.com>
7838
7839 * Makefile.in (include_DATA): Fix srcdir=. assumption.
2a9c5940 7840 (DISTCLEANFILES): Add `build_env.mk'.
ac293d50 7841
0025933a 78422008-11-08 Robert Millan <rmh@aybabtu.com>
7843
7844 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
dba3f844 7845 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
0025933a 7846 members. Update all users.
7847 * util/console.c (grub_ncurses_term): Split in ...
7848 (grub_ncurses_term_input): ... this, and ...
7849 (grub_ncurses_term_output): ... this. Update all users.
dcb6fa0a 7850 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
0025933a 7851
37c86336 78522008-11-08 Robert Millan <rmh@aybabtu.com>
7853
7854 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
7855 (PKGDATA): Add $(pkgdata_SRCDIR).
7856 (pkglib_BUILDDIR): New variable.
7857 (pkgdata_SRCDIR): New variable.
7858 (build_env.mk): New target.
7859 (include_DATA): New variable.
7860 (install-local): Install $(include_DATA) files in $(includedir).
7861
b6c15a2d 78622008-11-07 Pavel Roskin <proski@gnu.org>
7863
d99d46f1 7864 * gendistlist.sh: Use C locale for sorting to ensure consistent
7865 output on all systems.
7866
b6c15a2d 7867 * util/grub.d/00_header.in: Remove incorrect space before
7868 "serial".
7869
c32ee8c9 78702008-11-07 Robert Millan <rmh@aybabtu.com>
7871
7872 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
7873 per specification.
7874 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
7875 * loader/multiboot_loader.c (find_multi_boot2_header): New function
7876 (based on find_multi_boot1_header).
7877 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
7878 using find_multi_boot2_header(), and abort if neither Multiboot or
7879 Multiboot headers were found.
7880
651c29b7 78812008-11-07 Robert Millan <rmh@aybabtu.com>
7882
7883 Modularize at_keyboard.mod:
7884
7885 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
7886 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
7887 (at_keyboard_mod_LDFLAGS): New variables.
7888
7889 Actual terminal split:
7890
7891 * include/grub/term.h (struct grub_term): Split in ...
7892 (struct grub_term_input): ... this, and ...
7893 (struct grub_term_output): ... this. Update all users.
7894 (grub_term_set_current): Split in ...
7895 (grub_term_set_current_input): ... this, and ...
7896 (grub_term_set_current_output): ... this.
7897 (grub_term_get_current): Split in ...
7898 (grub_term_get_current_input): ... this, and ...
7899 (grub_term_get_current_output): ... this.
7900 (grub_term_register): Split in ...
7901 (grub_term_register_input): ... this, and ...
7902 (grub_term_register_output): ... this.
7903 (grub_term_unregister): Split in ...
7904 (grub_term_unregister_input): ... this, and ...
7905 (grub_term_unregister_output): ... this.
7906 (grub_term_iterate): Split in ...
7907 (grub_term_iterate_input): ... this, and ...
7908 (grub_term_iterate_output): ... this.
7909
7910 * kern/term.c (grub_term_list): Split in ...
7911 (grub_term_list_input): ... this, and ...
7912 (grub_term_list_output): ... this. Update all users.
7913 (grub_cur_term): Split in ...
7914 (grub_cur_term_input): ... this, and ...
7915 (grub_cur_term_output): ... this. Update all users.
7916 (grub_term_set_current): Split in ...
7917 (grub_term_set_current_input): ... this, and ...
7918 (grub_term_set_current_output): ... this.
7919 (grub_term_get_current): Split in ...
7920 (grub_term_get_current_input): ... this, and ...
7921 (grub_term_get_current_output): ... this.
7922 (grub_term_register): Split in ...
7923 (grub_term_register_input): ... this, and ...
7924 (grub_term_register_output): ... this.
7925 (grub_term_unregister): Split in ...
7926 (grub_term_unregister_input): ... this, and ...
7927 (grub_term_unregister_output): ... this.
7928 (grub_term_iterate): Split in ...
7929 (grub_term_iterate_input): ... this, and ...
7930 (grub_term_iterate_output): ... this.
7931
7932 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
7933 a check for input and one for output (and only attempt to get keys
7934 from user when input works).
7935
7936 * util/grub-probe.c (grub_term_get_current): Split in ...
7937 (grub_term_get_current_input): ... this, and ...
7938 (grub_term_get_current_output): ... this.
7939 * util/grub-fstest.c: Likewise.
7940 * util/i386/pc/grub-setup.c: Likewise.
7941 * util/grub-editenv.c: Likewise.
7942
7943 Portability adjustments:
7944
7945 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
7946 `term/i386/pc/at_keyboard.c'.
7947 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
7948 grub_keyboard_controller_init() (now handled by terminal .init).
7949 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
7950 grub_at_keyboard_init().
7951 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
7952 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
7953 at_keyboard.mod via input terminal interface).
7954 * include/grub/i386/coreboot/console.h: Convert into a stub for
7955 `<grub/i386/pc/console.h>'.
7956
7957 Migrate full terminals to new API:
7958
7959 * term/efi/console.c (grub_console_term): Split into ...
7960 (grub_console_term_input): ... this, and ...
7961 (grub_console_term_output): ... this. Update all users.
7962 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
7963 (grub_ofconsole_init): Split into ...
7964 (grub_ofconsole_init_input): ... this, and ...
7965 (grub_ofconsole_init_output): ... this.
7966 (grub_ofconsole_term): Split into ...
7967 (grub_ofconsole_term_input): ... this, and ...
7968 (grub_ofconsole_term_output): ... this. Update all users.
7969 * term/i386/pc/serial.c (grub_serial_term): Split into ...
7970 (grub_serial_term_input): ... this, and ...
7971 (grub_serial_term_output): ... this. Update all users.
7972 * term/i386/pc/console.c (grub_console_term): Split into ...
7973 (grub_console_term_input): ... this, and ...
7974 (grub_console_term_output): ... this. Update all users.
7975 (grub_console_term_input): Only enable it on PC/BIOS platform.
7976 (grub_console_init): Remove grub_keyboard_controller_init() call.
7977
7978 Migrate input terminals to new API:
7979
7980 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
7981 `i386' and `i386/pc' to enable build on x86_64 (this driver is
7982 i386-specific anyway).
7983 (grub_console_checkkey): Rename to ...
7984 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
7985 users.
7986 (grub_keyboard_controller_orig): New variable.
7987 (grub_console_getkey): Rename to ...
7988 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
7989 users.
7990 (grub_keyboard_controller_init): Static-ize. Save original
7991 controller value so that it can be restored ...
7992 (grub_keyboard_controller_fini): ... here (new function).
7993 (grub_at_keyboard_term): New structure.
7994 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
7995 functions.
7996
7997 Migrate output terminals to new API:
7998
7999 * term/i386/pc/vga.c (grub_vga_term): Change type to
8000 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8001 members. Update all users.
8002 * term/gfxterm.c (grub_video_term): Change type to
8003 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8004 members. Update all users.
8005 * include/grub/i386/pc/console.h (grub_console_checkkey)
8006 (grub_console_getkey): Do not export (no longer needed by gfxterm,
8007 etc).
8008
8009 Migrate `terminal' command and userland tools to new API:
8010
8011 * commands/terminal.c (grub_cmd_terminal): Split into ...
8012 (grub_cmd_terminal_input): ... this, and ...
8013 (grub_cmd_terminal_output): ... this.
8014 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
8015 `terminal_input' and `terminal_output'.
8016 * util/grub.d/00_header.in: Adjust `terminal' calls to new
8017 `terminal_input' / `terminal_output' API.
8018 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
8019 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
8020 provided ${GRUB_TERMINAL}, convert it).
8021
96e5d876 80222008-11-04 Robert Millan <rmh@aybabtu.com>
8023
8024 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
8025 for FreeBSD.
8026 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
8027
556f3775 80282008-11-03 Bean <bean123ch@gmail.com>
8029
8030 * kern/elf.c (grub_elf32_load): Revert to previous code.
8031 (grub_elf64_load): Likewise.
8032
8033 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
8034
926b9823 80352008-11-01 Robert Millan <rmh@aybabtu.com>
8036
8037 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
8038 (TARGET_CPPFLAGS): Likewise.
8039 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
8040
1432e958 80412008-11-01 Carles Pina i Estany <carles@pina.cat>
8042
8043 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
8044
dba3f844 80452008-10-29 Guillem Jover <guillem.jover@nokia.com>
de4fa71c 8046
8047 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
8048 addition of objects until the code is not going to be able to fail.
8049
dba3f844 80502008-10-29 Guillem Jover <guillem.jover@nokia.com>
b7279447 8051
8052 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
8053 (add a missing NULL check, and correct them by moving the pointer
8054 operations after the actual check).
8055
7ab28c21 80562008-10-29 Robert Millan <rmh@aybabtu.com>
8057
8058 * util/i386/pc/grub-install.in: Handle empty string as output from
8059 make_system_path_relative_to_its_root().
8060
1b7748eb 80612008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
8062
8063 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
8064 circular metadata worst case scenario. If the metadata is circular
8065 then copy the wrap in place.
8066 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
8067 project lib/format_text/layout.h
8068 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
8069
c9618ab2 80702008-10-03 Felix Zielcke <fzielcke@z-51.de>
8071
7a36edca 8072 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
c9618ab2 8073
bf981c62 80742008-10-03 Felix Zielcke <fzielcke@z-51.de>
8075
8076 * util/update-grub_lib.in: Mention filename in warning message.
8077
6d994591 80782008-09-29 Felix Zielcke <fzielcke@z-51.de>
8079
8080 * NEWS: Update for rename of update-grub to grub-mkconfig.
8081
18ade780 80822008-09-29 Felix Zielcke <fzielcke@z-51.de>
8083
8084 * util/update-grub_lib.in: Copy to ...
8085 * util/grub-mkconfig_lib.in: ... this. Update all users.
7c3ff286 8086 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
18ade780 8087 * util/update-grub.in: Rename to ...
8088 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
8089 option. Add `--output' option to allow users to specify the generated
8090 configuration file. Default to stdout.
8091 (update_grub_dir): Rename to ...
8092 (grub_mkconfig_dir): ... this.
8093 (grub_cfg): Default to an empty string.
8094 * conf/common.rmk (update-grub): Rename to ...
8095 (grub-mkconfig): ... this.
8096 (update-grub_lib): Copy to ...
8097 (grub-mkconfig_lib): ... this.
8098 (update-grub_SCRIPTS): Copy to ...
8099 (grub-mkconfig_SCRIPTS): ... this. Update all users.
8100 (update-grub_DATA): Rename to ...
8101 (grub-mkconfig_DATA): ... this.
8102
556ce6ac 81032008-09-28 Robert Millan <rmh@aybabtu.com>
8104
8105 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
8106 to `modified'. Add the real `created' field.
8107 (grub_iso9660_uuid): Use `modified' rather than `created' for
8108 constructing the UUID.
8109
81102008-09-28 Felix Zielcke <fzielcke@z-51.de>
eb079ba9 8111
8112 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
8113 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
8114
92274e85 81152008-09-28 Bean <bean123ch@gmail.com>
8116
8117 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
8118 Thanks to Christian Franke for finding this bug.
8119
add6f17a 81202008-09-25 Robert Millan <rmh@aybabtu.com>
8121
8122 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
8123 instances of grub_util_get_disk_name() (see previous commit).
8124
d2a367b8 81252008-09-25 Robert Millan <rmh@aybabtu.com>
8126
8127 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
8128 `util/i386/get_disk_name.c'.
8129 * conf/i386-efi.rmk: Likewise.
8130 * conf/x86_64-efi.rmk: Likewise.
8131 * conf/i386-coreboot.rmk: Likewise.
8132 * conf/i386-ieee1275.rmk: Likewise.
8133 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
8134 `util/ieee1275/get_disk_name.c'.
8135 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
8136 * util/ieee1275/get_disk_name.c: Remove file.
8137 * util/i386/get_disk_name.c: Remove file.
8138 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
8139 "hd%d" for device.map entries, rather than using
8140 grub_util_get_disk_name().
8141
81a06771 81422008-09-24 Carles Pina i Estany <carles@pina.cat>
b0c301f7 8143
8144 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
8145 warning.
8146 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
8147
5a004279 81482008-09-24 Carles Pina i Estany <carles@pina.cat>
8149
8150 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
8151 Changed to 0x5100.
8152 (GRUB_TERM_PPAGE): Changed to 0x4900.
8153
397093d3 81542008-09-24 Robert Millan <rmh@aybabtu.com>
8155
8156 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
8157 macros (they were i386-pc specific).
8158 * include/grub/sparc64/ieee1275/console.h: Likewise.
8159 * include/grub/efi/console.h: Likewise.
8160
a91b6c7c 81612008-09-22 Bean <bean123ch@gmail.com>
8162
8163 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
8164 resident and in attribute list.
8165
8166 * include/grub/ntfs.h (BMP_LEN): Removed.
8167
c40fd116 81682008-09-22 Bean <bean123ch@gmail.com>
8169
81a06771 8170 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
c40fd116 8171 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
8172
8173 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
8174 error occurs, as grub_disk_open will call grub_disk_close, which will
8175 call p->close (scsi).
8176
81a06771 81772008-09-21 Felix Zielcke <fzielcke@z-51.de>
eb73121d 8178
8179 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
8180 (AC_PREREQ): Bumped to 2.59.
8181 (AC_TRY_COMPILE): Replace obsolete macro with ...
8182 (AC_COMPILE_IFELSE): ... this.
8183 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
8184 (AC_LINK_IFELSE): ... this.
8185
5dc43410 81862008-09-21 Felix Zielcke <fzielcke@z-51.de>
8187
8188 * autogen.sh: Add a call to `gendistlist.sh'.
8189
9035dce4 81902008-09-19 Christian Franke <franke@computer.org>
8191
8192 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
8193 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
8194 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
8195 Export __enable_execute_stack() to modules.
8196 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
8197 New function.
8198
7fd75377 81992008-09-09 Felix Zielcke <fzielcke@z-51.de>
8200
040030b3 8201 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
8202 Sort the list.
8203
82042008-09-09 Felix Zielcke <fzielcke@z-51.de>
8205
8206 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
7fd75377 8207 #include <grub/util/hostdisk.h>.
8208
89d5ffcf 82092008-09-08 Robert Millan <rmh@aybabtu.com>
8210
8211 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
8212 segments when their filesz is zero (grub_file_read() interprets
81a06771 8213 zero-size as "read until EOF", which results in memory corruption).
89d5ffcf 8214 Use `lowest_segment' rather than 0 for calculating the current
8215 segment load address.
8216
40da438f 82172008-09-08 Robert Millan <rmh@aybabtu.com>
8218
8219 * util/hostdisk.c (open_device): Replace a grub_util_info() call
8220 with grub_dprintf("hostdisk", ...), as it was so verbose that it
8221 clobbered useful information.
8222
ddbf5556 82232008-09-08 Robert Millan <rmh@aybabtu.com>
8224
8225 * include/grub/util/biosdisk.h: Move to ...
8226 * include/grub/util/hostdisk.h: ... here. Update all users.
8227 * util/biosdisk.c: Move to ...
8228 * util/hostdisk.c: ... here. Update all users.
8229
783d0f48 82302008-09-07 Robert Millan <rmh@aybabtu.com>
8231
8232 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
8233 variables.
8234 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
8235 and length can be stored directly in the `mbi->mmap_addr' and
8236 `mbi->mmap_length' struct fields.
8237
548e2ea5 82382008-09-07 Robert Millan <rmh@aybabtu.com>
8239
8240 * conf/i386.rmk: New file. Provides declaration for building
8241 `cpuid.mod'.
8242 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
8243 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
8244 variables.
8245 Include `conf/i386.mk'.
8246 * conf/i386-efi.rmk: Likewise.
8247 * conf/x86_64-efi.rmk: Likewise.
8248 * conf/i386-coreboot.rmk: Likewise.
8249 * conf/i386-ieee1275.rmk: Likewise.
8250
0ea85a37 82512008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
8252
8253 Based on patch created by Colin D Bennett <colin@gibibit.com>.
8254 Adds optimization support for BGR based modes.
8255
8256 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
8257 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8258 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8259 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8260 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8261 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8262 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8263 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8264 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8265 (grub_video_i386_vbeblit_index_index): Likewise.
8266 (grub_video_i386_vbeblit_replace_directN): Added.
8267 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8268 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8269 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8270 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8271 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8272 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
81a06771 8273 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
0ea85a37 8274 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8275 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8276 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8277 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8278 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8279 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
8280
8281 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
8282 (grub_video_i386_vbefill_R8G8B8): Likewise.
8283 (grub_video_i386_vbefill_index): Likewise.
8284 (grub_video_i386_vbefill_direct32): Added.
8285 (grub_video_i386_vbefill_direct24): Likewise.
8286 (grub_video_i386_vbefill_direct16): Likewise.
8287 (grub_video_i386_vbefill_direct8): Likewise.
8288
81a06771 8289 * include/grub/video.h (grub_video_blit_format): Removed
0ea85a37 8290 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
8291 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
8292 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
8293 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
8294 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
81a06771 8295
0ea85a37 8296 * video/video.c (grub_video_get_blit_format): Updated to use new
8297 blit formats. Added handling for 16 bit color modes.
81a06771 8298
8299 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
0ea85a37 8300 fillers.
8301 (common_blitter): Updated to use new blitters.
8302
8303 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
8304 Removed.
8305 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8306 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8307 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8308 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8309 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8310 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8311 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8312 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8313 (grub_video_i386_vbeblit_index_index): Likewise.
8314 (grub_video_i386_vbeblit_replace_directN): Added.
8315 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8316 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8317 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8318 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8319 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8320 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
8321 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
8322 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8323 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8324 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8325 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8326 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8327 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
81a06771 8328
0ea85a37 8329 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
8330 (grub_video_i386_vbefill_R8G8B8): Likewise.
8331 (grub_video_i386_vbefill_index): Likewise.
8332 (grub_video_i386_vbefill_direct32): Added.
8333 (grub_video_i386_vbefill_direct24): Likewise.
8334 (grub_video_i386_vbefill_direct16): Likewise.
8335 (grub_video_i386_vbefill_direct8): Likewise.
81a06771 8336
0ea85a37 8337 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
8338 types.
81a06771 8339
0ea85a37 8340 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
8341 types.
81a06771 8342
0ea85a37 8343 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
8344 blitter types.
81a06771 8345
0ea85a37 8346 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
8347 types.
8348
e8a83df6 83492008-09-06 Felix Zielcke <fzielcke@z-51.de>
8350
8351 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
8352 RAID level 1.
8353
6bcd8ee5 83542008-09-06 Felix Zielcke <fzielcke@z-51.de>
c375ae58 8355
6bcd8ee5 8356 * fs/iso9660.c (grub_iso9660_date): New structure.
8357 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
8358 (grub_iso9660_uuid): New function.
c375ae58 8359
59261157 83602008-09-05 Bean <bean123ch@gmail.com>
8361
8362 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
8363
8364 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
8365 insensitive bit for names in Win32 and Win32 & DOS namespace.
8366
8367 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
8368
8369 * include/grub/types.h (LONG_MAX): Likewise.
8370
58b6645a 83712008-09-04 Felix Zielcke <fzielcke@z-51.de>
8372
4ee55921 8373 * util/getroot.c: Include <config.h>.
8374 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
8375 add support for /dev/md/N devices and handle LVM double dash escaping.
8376
83772008-09-04 Felix Zielcke <fzielcke@z-51.de>
8378
8379 * config.guess: Update to latest version from config git.
8380 * config.sub: Likewise.
58b6645a 8381
9124f65d 83822008-09-03 Robert Millan <rmh@aybabtu.com>
8383
8384 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
8385 `disk->total_sectors'.
8386
81a06771 83872008-09-01 Colin D Bennett <colin@gibibit.com>
a0224a4e 8388
8389 * include/grub/normal.h: Fixed incorrect comment for
8390 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
8391
81a06771 83922008-09-01 Colin D Bennett <colin@gibibit.com>
f0619958 8393
8394 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
8395 values with defines.
8396
8397 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
8398 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
8399 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
8400 (GRUB_VBE_MODEATTR_COLOR): Likewise.
8401 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
8402 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
8403 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
8404 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
8405 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
8406 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
8407 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
8408 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
8409 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
8410 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
8411 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
8412 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
8413 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
8414 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
8415 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
8416
93d5cbf8 84172008-08-31 Robert Millan <rmh@aybabtu.com>
8418
8419 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
8420 declaration.
8421 (grub_multiboot): Fix a few warnings.
8422
21751d50 84232008-08-31 Robert Millan <rmh@aybabtu.com>
8424
8425 * loader/i386/pc/multiboot.c: Update comment not to say that
8426 boot_device support is unimplemented.
8427
e27a75c5 84282008-08-31 Robert Millan <rmh@aybabtu.com>
8429
8430 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
8431 or memory map support are unimplemented.
8432
81a06771 84332008-08-31 Colin D Bennett <colin@gibibit.com>
64d2d53c 8434
8435 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
8436
81a06771 84372008-08-31 Colin D Bennett <colin@gibibit.com>
c08a6c18 8438
8439 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
8440 total video memory in 'vbeinfo' output; show color format details for
8441 each video mode.
8442
7c5d8d95 84432008-08-30 Pavel Roskin <proski@gnu.org>
8444
8445 * util/genmoddep.c: Remove for real this time.
8446 * DISTLIST: Remove util/genmoddep.c.
8447
4cebd25a 84482008-08-30 Robert Millan <rmh@aybabtu.com>
8449
8450 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
8451 as required by Multiboot spec (it was already 4-byte aligned, but
8452 only by chance).
8453
b497a269 84542008-08-29 Pavel Roskin <proski@gnu.org>
8455
e3925185 8456 * kern/powerpc/ieee1275/crt0.S: Rename to ...
8457 * kern/powerpc/ieee1275/startup.S: ... this.
8458 * conf/powerpc-ieee1275.rmk: Adjust for the above.
8459 * DISTLIST: Likewise.
8460
b497a269 8461 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
8462 grub/cpu/kernel.h. Add start label for consistency with other
8463 platforms. Add grub_prefix immediately after start. Add jump
8464 to the code after grub_prefix.
8465 * include/grub/powerpc/kernel.h: Provide valid values for
8466 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
8467
6e5a42fe 84682008-08-29 Bean <bean123ch@gmail.com>
8469
8470 * configure.ac: Change host_os to cygwin for mingw.
8471 (asprintf): New check for function.
8472
8473 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
8474 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
8475
8476 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
81a06771 8477 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
6e5a42fe 8478 sync, sleep and grub_util_get_disk_size for mingw.
8479
8480 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
8481 to get size in mingw.
8482 (open_device): Use flag O_BINARY if it's defined.
8483 (find_root_device): Add dummy code for mingw.
8484
8485 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
8486 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
8487 (get_scsi_disk_name): Return 0 for mingw.
8488
8489 * util/hostfs.c: #include <grub/util/misc.h>.
8490 (grub_hostfs_open): Use "rb" flag to open file, use
8491 grub_util_get_disk_size to get disk size for mingw.
8492
8493 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
8494 (asprintf): New function if HAVE_ASPRINTF is not set.
8495 (sync): New function for mingw.
8496 (sleep): Likewise.
8497 (grub_util_get_disk_size): Likewise.
8498
ab3f2673 84992008-08-28 Pavel Roskin <proski@gnu.org>
8500
8501 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
8502 kern/time.c.
8503
1c282483 85042008-08-28 Robert Millan <rmh@aybabtu.com>
8505
8506 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
8507
678e849c 85082008-08-28 Robert Millan <rmh@aybabtu.com>
8509
8510 Change find_grub_drive() syntax so it doesn't prevent it from
8511 detecting NULL names as errors.
8512
8513 * util/biosdisk.c (find_grub_drive): Move free slot search code
8514 from here ...
8515 (find_free_slot): ... to here.
8516 (read_device_map): Use find_free_slot() to search for free slots.
8517
965c75ca 85182008-08-27 Marco Gerards <marco@gnu.org>
8519
8520 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
8521 (scsi_mod_SOURCES): New variable.
8522 (scsi_mod_CFLAGS): Likewise
8523 (scsi_mod_LDFLAGS): Likewise.
8524
8525 * disk/scsi.c: New file.
8526
8527 * include/grub/scsi.h: Likewise.
8528
8529 * include/grub/scsicmd.h: Likewise.
8530
8531 * disk/ata.c: Include <grub/scsi.h>.
8532 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
8533 instead.
8534 (grub_ata_iterate): Skip ATAPI devices.
8535 (grub_ata_open): Only handle ATAPI devices.
8536 (struct grub_atapi_read): Removed.
8537 (grub_atapi_readsector): Likewise.
8538 (grub_ata_read): No longer handle ATAPI devices.
8539 (grub_ata_write): Likewise.
8540 (grub_atapi_iterate): New function.
8541 (grub_atapi_read): Likewise.
8542 (grub_atapi_write): Likewise.
8543 (grub_atapi_open): Likewise.
8544 (grub_atapi_close): Likewise.
8545 (grub_atapi_dev): New variable.
8546 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
8547 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
8548
8549 * include/grub/disk.h (enum grub_disk_dev_id): Add
8550 `GRUB_DISK_DEVICE_SCSI_ID'.
8551
c07ae501 85522008-08-26 Robert Millan <rmh@aybabtu.com>
8553
8554 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
8555 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
8556 descriptive.
8557
5ed20adc 85582008-08-23 Bean <bean123ch@gmail.com>
8559
8560 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
8561 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8562 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
8563 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
8564 dm_nv.mod.
8565 (raid5rec_mod_SOURCES): New macro.
8566 (raid5rec_mod_CFLAGS): Likewise.
8567 (raid5rec_mod_LDFLAGS): Likewise.
8568 (raid6rec_mod_SOURCES): Likewise.
8569 (raid6rec_mod_CFLAGS): Likewise.
8570 (raid6rec_mod_LDFLAGS): Likewise.
8571 (mdraid_mod_SOURCES): Likewise.
8572 (mdraid_mod_CFLAGS): Likewise.
8573 (mdraid_mod_LDFLAGS): Likewise.
8574 (dm_nv_mod_SOURCES): Likewise.
8575 (dm_nv_mod_CFLAGS): Likewise.
8576 (dm_nv_mod_LDFLAGS): Likewise.
8577
8578 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
8579 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8580 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8581
8582 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
8583 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8584
8585 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8586
8587 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
8588
8589 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8590
8591 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8592
8593 * disk/raid5_recover.c: New file.
8594
8595 * disk/raid6_recover.c: Likewise.
8596
8597 * disk/mdraid_linux.c: Likewise.
8598
8599 * disk/dmraid_nvidia.c: Likewise.
8600
8601 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
8602 ULONG_MAX.
8603
8604 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
8605 calculate the size of raid device.
8606 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
8607 different layout of raid5.
8608 (grub_raid_scan_device): Remove code specific to mdraid.
8609 (grub_raid_list): New variable.
8610 (free_array): New function.
8611 (grub_raid_register): Likewise.
8612 (grub_raid_unregister): Likewise.
8613 (grub_raid_rescan): Likewise.
8614 (GRUB_MOD_INIT): Don't iterate device here.
8615 (GRUB_MOD_FINI): Use free_array to release resource.
8616
8617 * include/grub/raid.h: Remove macro and structure specific to mdraid.
8618 (grub_raid5_recover_func_t): New function variable type.
8619 (grub_raid6_recover_func_t): Likewise.
8620 (grub_raid5_recover_func): New variable.
8621 (grub_raid6_recover_func): Likewise.
8622 (grub_raid_register): New function.
8623 (grub_raid_unregister): Likewise.
8624 (grub_raid_rescan): Likewise.
8625 (grub_raid_block_xor): Likewise.
8626
8627 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
8628 (CMD_CRC): New macro.
8629 (part): Removed.
8630 (read_file): Handle device as well as file.
8631 (cmd_crc): New function.
8632 (fstest): Handle multiple disks.
8633 (options): Remove part, raw and long, add root and diskcount.
8634 (usage): Add crc, remove -p, -r, -l, add -r and -c.
dba3f844 8635 (main): Find the first non option entry and ignore subsequent options,
5ed20adc 8636 add handling for the new options, support multiple disks.
8637
8638 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
8639
29c18915 86402008-08-23 Bean <bean123ch@gmail.com>
8641
8642 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
8643
8644 * genfslist.sh: Ignore kernel.mod.
8645
8646 * genpartmaplist.sh: Likewise.
8647
8415f261 86482008-08-23 Robert Millan <rmh@aybabtu.com>
8649
8650 * util/getroot.c (find_root_device): Skip anything that starts with
8651 a dot, not just directories. This avoids things like /dev/.tmp.md0.
8652
d5a7dc5b 86532008-08-22 Felix Zielcke <fzielcke@z-51.de>
81a06771 8654
d5a7dc5b 8655 * util/update-grub.in (GRUB_GFXMODE): Export variable.
8656 * util/grub.d/00_header.in: Allow the administrator to change default
8657 gfxmode via ${GRUB_GFXMODE}.
8658
380cfbb4 86592008-08-21 Felix Zielcke <fzielcke@z-51.de>
8660
8661 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
8662
c9baafe7 86632008-08-21 Robert Millan <rmh@aybabtu.com>
8664
8665 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
8666 loader.
8667 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
8668 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
8669
e290bef2 86702008-08-20 Carles Pina i Estany <carles@pina.cat>
8671
8672 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
8673 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
8674
f9dbfc96 86752008-08-19 Robert Millan <rmh@aybabtu.com>
8676
8677 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
8678 (struct grub_virtual_screen): Remove `cursor_color'.
8679 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
8680 initialization.
8681 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
8682
dd6bd6ab 86832008-08-18 Robert Millan <rmh@aybabtu.com>
8684
8685 Unify (identical) linux_normal.c files.
8686 * loader/i386/efi/linux_normal.c: Move from here ...
8687 * loader/linux_normal.c: ... to here. Update all users.
8688 * loader/i386/pc/linux_normal.c: Delete. Update all users.
8689 * loader/i386/ieee1275/linux_normal.c: Likewise.
8690
7f42f83e 86912008-08-18 Robert Millan <rmh@aybabtu.com>
8692
8693 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
8694 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
8695 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
8696 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
8697 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
8698 New macros.
8699 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
8700 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
8701 (GRUB_LINUX_CL_END_OFFSET): ... to here.
8702 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
8703 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
8704 (GRUB_EFI_CL_END_OFFSET): Rename to ...
8705 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
8706 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
8707 Initialize `params->video_cursor_x' and `params->video_cursor_y'
8708 portably using grub_getxy().
8709 Replace `-EFI' with `-bzImage' in boot message.
8710
38487ddb 87112008-08-17 Robert Millan <rmh@aybabtu.com>
8712
8713 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
8714
deceb3ec 87152008-08-17 Robert Millan <rmh@aybabtu.com>
8716
8717 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
8718
8719 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
8720 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
8721 (grub_machine_mmap_iterate): New function declaration.
8722 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
8723 structure.
8724 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
8725 macros.
8726
8727 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
8728 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
8729 Move e820 parsing from here ...
8730 * kern/i386/pc/mmap.c: New file.
8731 (grub_machine_mmap_iterate): ... to here.
8732
8733 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
8734 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
8735 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
8736 (grub_available_iterate): Redeclare to return `void', and redeclare
8737 its hook to use grub_uint64_t as addr and size parameters, and rename
8738 to ...
8739 (grub_machine_mmap_iterate): ... this. Update all users.
8740
8741 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
8742 to make it more readable. Rename to ...
8743 (grub_machine_mmap_iterate): ... this.
8744
8745 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
8746 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
8747 (grub_multiboot): Allocate an extra region after the payload, and fill
8748 it with a Multiboot memory map. Adjust a.out loader to calculate size
8749 with the extra space.
8750 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
8751 with the extra space.
8752
f8aa0f43 87532008-08-17 Carles Pina i Estany <carles@pina.cat>
8754
9807deb9 8755 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
f8aa0f43 8756
605f5bb6 87572008-08-17 Felix Zielcke <fzielcke@z-51.de>
8758
8759 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
8760 mdate-sh to the list `find' searches for.
8761 * DISTLIST: Regenerated.
8762
210db6c6 87632008-08-16 Felix Zielcke <fzielcke@z-51.de>
8764
8765 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
8766 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
48cdbfd4 8767 genmoddep.awk, gensymlist.sh.in.
8768 (DISTDIRS): Add bus, docs, hook, lib.
210db6c6 8769 * DISTLIST: Regenerated.
48cdbfd4 8770 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
210db6c6 8771
1082b929 87722008-08-16 Robert Millan <rmh@aybabtu.com>
8773
8774 * disk/raid.c (grub_raid_init): Handle/report errors set by
8775 grub_device_iterate().
8776 * disk/lvm.c (grub_lvm_init): Likewise.
8777
42ce5170 87782008-08-15 Bean <bean123ch@gmail.com>
8779
8780 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8781 and datehook.mod.
8782 (datetime_mod_SOURCES): New macro.
8783 (datetime_mod_CFLAGS): Likewise.
8784 (datetime_mod_LDFLAGS): Likewise.
8785 (date_mod_SOURCES): Likewise.
8786 (date_mod_CFLAGS): Likewise.
8787 (date_mod_LDFLAGS): Likewise.
8788 (datehook_mod_SOURCES): Likewise.
8789 (datehook_mod_CFLAGS): Likewise.
8790 (datehook_mod_LDFLAGS): Likewise.
8791
8792 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8793 and datehook.mod.
8794 (datetime_mod_SOURCES): New macro.
8795 (datetime_mod_CFLAGS): Likewise.
8796 (datetime_mod_LDFLAGS): Likewise.
8797 (date_mod_SOURCES): Likewise.
8798 (date_mod_CFLAGS): Likewise.
8799 (date_mod_LDFLAGS): Likewise.
8800 (datehook_mod_SOURCES): Likewise.
8801 (datehook_mod_CFLAGS): Likewise.
8802 (datehook_mod_LDFLAGS): Likewise.
8803
8804 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8805 and datehook.mod.
8806 (datetime_mod_SOURCES): New macro.
8807 (datetime_mod_CFLAGS): Likewise.
8808 (datetime_mod_LDFLAGS): Likewise.
8809 (date_mod_SOURCES): Likewise.
8810 (date_mod_CFLAGS): Likewise.
8811 (date_mod_LDFLAGS): Likewise.
8812 (datehook_mod_SOURCES): Likewise.
8813 (datehook_mod_CFLAGS): Likewise.
8814 (datehook_mod_LDFLAGS): Likewise.
8815
8816 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8817 and datehook.mod.
8818 (datetime_mod_SOURCES): New macro.
8819 (datetime_mod_CFLAGS): Likewise.
8820 (datetime_mod_LDFLAGS): Likewise.
8821 (date_mod_SOURCES): Likewise.
8822 (date_mod_CFLAGS): Likewise.
8823 (date_mod_LDFLAGS): Likewise.
8824 (datehook_mod_SOURCES): Likewise.
8825 (datehook_mod_CFLAGS): Likewise.
8826 (datehook_mod_LDFLAGS): Likewise.
8827
8828 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8829 and datehook.mod.
8830 (datetime_mod_SOURCES): New macro.
8831 (datetime_mod_CFLAGS): Likewise.
8832 (datetime_mod_LDFLAGS): Likewise.
8833 (date_mod_SOURCES): Likewise.
8834 (date_mod_CFLAGS): Likewise.
8835 (date_mod_LDFLAGS): Likewise.
8836 (datehook_mod_SOURCES): Likewise.
8837 (datehook_mod_CFLAGS): Likewise.
8838 (datehook_mod_LDFLAGS): Likewise.
8839
8840 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
8841
8842 * commands/date.c: New file.
8843
8844 * hook/datehook.c: Likewise.
8845
8846 * include/grub/lib/datetime.h: Likewise.
8847
8848 * include/grub/i386/cmos.h: Likewise.
8849
8850 * lib/datetime.c: Likewise.
8851
8852 * lib/i386/datetime.c: Likewise.
8853
8854 * lib/efi/datetime.c: Likewise.
8855
0e9242da 88562008-08-14 Robert Millan <rmh@aybabtu.com>
8857
8858 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
8859 (grub_mkelfimage_SOURCES): New variable.
8860 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
8861
8862 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
8863 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
8864 * conf/powerpc-ieee1275.rmk: Likewise.
8865 * conf/i386-ieee1275.rmk: Likewise.
8866
8867 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
8868 * kern/i386/coreboot/init.c: Likewise.
8869
8870 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
8871 with `<grub/cpu/kernel.h>'.
8872 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
8873 to ...
8874 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
8875 * kern/i386/coreboot/startup.S: Likewise.
8876
8877 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
8878 (GRUB_MOD_GAP): Remove.
8879 * include/grub/powerpc/kernel.h: New file.
8880 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
8881 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
8882 * include/grub/i386/kernel.h: New file.
8883 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
8884 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
8885 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
8886
8887 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
8888 `grub-mkelfimage'.
8889 Use --directory when invoking grub_mkimage.
8890
8891 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
8892 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
8893 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
8894 and GRUB_KERNEL_CPU_PREFIX.
8895
b86408f8 88962008-08-14 Felix Zielcke <fzielcke@z-51.de>
8897
d5e619ca 8898 * include/grub/err.h (grub_err_printf): New function prototype.
8899 * util/misc.c (grub_err_printf): New function.
8900 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
8901 grub_printf.
8902 * kern/err.c (grub_print_error): Use grub_err_printf.
b86408f8 8903
7161f0e0 89042008-08-13 Robert Millan <rmh@aybabtu.com>
8905
8906 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
8907
a1967522 89082008-08-13 Robert Millan <rmh@aybabtu.com>
8909
8910 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
8911 boot entry.
8912
371458b5 89132008-08-12 Robert Millan <rmh@aybabtu.com>
8914
8915 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
8916 of the relocation code from here ...
8917 (grub_multiboot): ... to here.
8918 (forward_relocator, backward_relocator): Move from here ...
8919 * kern/i386/loader.S (grub_multiboot_forward_relocator)
8920 (grub_multiboot_backward_relocator): ... to here.
8921 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
8922 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
8923 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
8924 (grub_multiboot_forward_relocator_end)
8925 (grub_multiboot_backward_relocator)
8926 (grub_multiboot_backward_relocator_end): New variables.
8927
05f9452b 89282008-08-12 Bean <bean123ch@gmail.com>
8929
8930 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
8931
20024ab0 89322008-08-11 Robert Millan <rmh@aybabtu.com>
8933
8934 * kern/i386/linuxbios/startup.S: Move from here ...
8935 * kern/i386/coreboot/startup.S: ... to here.
8936
8937 * kern/i386/linuxbios/init.c: Move from here ...
8938 * kern/i386/coreboot/init.c: ... to here.
8939
8940 * kern/i386/linuxbios/table.c: Move from here ...
8941 * kern/i386/coreboot/mmap.c: ... to here.
8942
8943 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
8944
e352e9cd 89452008-08-11 Robert Millan <rmh@aybabtu.com>
8946
8947 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
8948 errors. Leave it to the upper layer to handle them.
8949
2d05bc6a 89502008-08-09 Christian Franke <franke@computer.org>
8951
8952 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
8953 * conf/common.rmk: Install `grub-pe2elf' only if requested.
8954 Install `grub.d/10_windows' only on Cygwin.
8955 * configure.ac: Add subst of `target_os'.
8956 Check `target_os' also before setting TARGET_OBJ2ELF.
8957 Add `--enable-grub-pe2elf'.
8958
042bd419 89592008-08-08 Robert Millan <rmh@aybabtu.com>
8960
8961 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
8962 (grub_last_time): Change type to grub_uint64_t.
8963 (grub_disk_open): Migrate code from to using grub_get_time_ms().
8964 (grub_disk_close): Likewise.
8965
8966 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
8967 (run_menu): Migrate code from to using grub_get_time_ms().
8968
8969 * util/misc.c (grub_get_time_ms): New function.
8970
7f280db5 89712008-08-08 Marco Gerards <marco@gnu.org>
8972
8973 * disk/ata.c (grub_ata_regget): Change return type to
8974 `grub_uint8_t'.
8975 (grub_ata_regget2): Likewise.
8976 (grub_ata_wait_status): New function.
8977 (grub_ata_wait_busy): Removed function, updated all users to use
8978 `grub_ata_wait_status'.
8979 (grub_ata_wait_drq): Likewise.
8980 (grub_ata_cmd): New function.
8981 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
8982 error handling.
8983 (grub_ata_pio_write): Add error handling.
8984 (grub_atapi_identify): Likewise.
8985 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
8986 handling.
8987 (grub_ata_identify): Use `grub_ata_cmd' and improve error
8988 handling. Actually use the detected registers. Reorder the
8989 detection logic such that it is easier to read.
8990 (grub_ata_pciinit): Do not assign the same ID to each controller.
8991 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
8992 handling.
8993 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
8994
8995 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
8996
1fbc5e66 89972008-08-08 Marco Gerards <marco@gnu.org>
8998
8999 * NEWS: Update.
9000
819ce6c0 90012008-08-07 Bean <bean123ch@gmail.com>
9002
9003 * include/grub/x86_64/pci.h: New file.
9004
5c41d44d 90052008-08-07 Christian Franke <franke@computer.org>
9006
9007 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
9008 (TIMER2_GATE): Likewise.
9009 (grub_pit_wait): Add enable/disable of the timer2 gate
9010 bit of port 0x61. This fixes a possible infinite loop.
9011
5ebc275d 90122008-08-07 Bean <bean123ch@gmail.com>
9013
9014 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
9015 kern/i386/tsc.c and kern/i386/pit.c.
9016
9017 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
9018 x86_64 platform.
9019
9020 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
9021 <grub/i386/tsc.h>.
9022
9023 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
9024
e383b3d0 90252008-08-07 Bean <bean123ch@gmail.com>
9026
9027 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
9028
9029 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
9030
9031 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
9032 multiple inclusion. Add #include <grub/types.h>.
9033
1cbb58ac 90342008-08-06 Christian Franke <franke@computer.org>
9035
9036 * conf/common.rmk: Build and install `10_windows'.
9037 * util/grub.d/10_windows.in: New script.
9038
337f5a1e 90392008-08-06 Pavel Roskin <proski@gnu.org>
9040
9041 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
9042
057bc4ac 90432008-08-06 Robert Millan <rmh@aybabtu.com>
9044
9045 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
9046 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
9047
2b99f123 90482008-08-06 Bean <bean123ch@gmail.com>
9049
9050 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
9051 (grub_pxefs_fs_int): Remove dummy definition.
9052 (grub_pxefs_open): Use data->block_size to store the current block
9053 size setting.
9054 (grub_pxefs_read): Use block size stored in data->block_size. As the
9055 value of grub_pxe_blksize can be changed after the file is opened.
9056
9f0234cb 90572008-08-06 Bean <bean123ch@gmail.com>
9058
9059 * fs/i386/pc/pxe.c (curr_file): new variable.
9060 (grub_pxefs_open): Simply the handling of pxe file system. Don't
9061 require the dummy internal file system anymore.
9062 (grub_pxefs_read): Removed.
9063 (grub_pxefs_close): Likewise.
9064 (grub_pxefs_fs_int): Likewise.
9065 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
9066 connection when we switch file.
9067 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
9068
a55d42e0 90692008-08-06 Robert Millan <rmh@aybabtu.com>
9070
9071 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
9072 `halt.mod'.
9073 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
9074 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
9075
9076 * kern/i386/halt.c: New file.
9077 * kern/i386/reboot.c: Likewise.
9078 * include/grub/i386/reboot.h: Likewise.
9079 * include/grub/i386/halt.h: Likewise.
9080
9081 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
9082 Include `<grub/cpu/halt.h>'.
9083 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
9084 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
9085
9086 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
9087 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
9088 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
9089 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
9090 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
9091 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
9092 from here ...
9093 * include/grub/i386/at_keyboard.h: ... to here.
9094
24371d26 90952008-08-05 Robert Millan <rmh@aybabtu.com>
9096
9097 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
9098 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
9099 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
9100 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9101 `kern/generic/millisleep.c'.
9102
9103 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
9104 instead of grub_get_rtc().
9105 (grub_tsc_init): Initialize `tsc_boot_time'.
9106
9107 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
9108 (grub_machine_init): Use grub_tsc_init() rather than
9109 installing an RTC-based handler via grub_install_get_time_ms().
9110
9111 * kern/i386/pit.c: New file.
9112 * include/grub/i386/pit.h: Likewise.
9113
9e7007b3 91142008-08-05 Bean <bean123ch@gmail.com>
9115
9116 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
9117
9118 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
9119 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
9120 (pxe_mod_SOURCES): New macro.
9121 (pxe_mod_CFLAGS): Likewise.
9122 (pxe_mod_LDFLAGS): Likewise.
9123 (pxecmd_mod_SOURCES): Likewise.
9124 (pxecmd_mod_CFLAGS): Likewise.
9125 (pxecmd_mod_LDFLAGS): Likewise.
9126
9127 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
9128 (grub_pxe_call): Likewise.
9129
9130 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
9131
9132 * commands/i386/pc/pxecmd.c: New file.
9133
9f0234cb 9134 * fs/i386/pc/pxe.c: Likewise.
9e7007b3 9135
9136 * include/grub/i386/pc/pxe.h: Likewise.
9137
6977d49f 91382008-08-05 Bean <bean123ch@gmail.com>
9139
9140 * util/console.c (grub_console_cur_color): New variable.
9141 (grub_console_standard_color): Likewise.
9142 (grub_console_normal_color): Likewise.
9143 (grub_console_highlight_color): Likewise.
9144 (color_map): Likewise.
9145 (use_color): Likewise.
9146 (NUM_COLORS): New macro.
9147 (grub_ncurses_setcolorstate): Handle color properly.
9148 (grub_ncurses_setcolor): Don't change color here, just remember the
9149 settings, color will be set in grub_ncurses_setcolorstate.
9150 (grub_ncurses_getcolor): New function.
9151 (grub_ncurses_init): Initialize color pairs.
9152 (grub_ncurses_term): New member grub_ncurses_getcolor.
9153
9c2ff3ee 91542008-08-05 Colin D Bennett <colin@gibibit.com>
337f5a1e 9155
9c2ff3ee 9156 High resolution timer support. Implemented for x86 CPUs using TSC.
9157 Extracted generic grub_millisleep() so it's linked in only as needed.
9158 This requires a Pentium compatible CPU; if the RDTSC instruction is
9159 not supported, then it falls back on the generic grub_get_time_ms()
9160 implementation that uses the machine's RTC.
9161
9162 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
9163 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9164 `kern/generic/millisleep.c'.
9165
9166 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
9167 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
9168
9169 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
9170 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
9171
9172 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9173
9174 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
9175 `kern/generic/millisleep.c'.
9176
9177 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9178
9179 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
9180
9181 * kern/generic/rtc_get_time_ms.c: New file.
9182
9183 * kern/generic/millisleep.c: New file.
337f5a1e 9184
9c2ff3ee 9185 * kern/misc.c: Don't include
9186 <kern/time.h> anymore.
9187 (grub_millisleep_generic): Removed.
9188
9189 * commands/sleep.c (grub_interruptible_millisleep): Uses
9190 grub_get_time_ms() instead of grub_get_rtc().
9191
9192 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
9193 function.
9194 (grub_cpu_is_cpuid_supported): New inline function.
9195 (grub_cpu_is_tsc_supported): New inline function.
9196 (grub_tsc_init): New function prototype.
9197 (grub_tsc_get_time_ms): New function prototype.
9198
9199 * kern/i386/tsc.c (grub_get_time_ms): New file.
9200
9201 * include/grub/time.h: Include <grub/types.h.
9202 (grub_millisleep_generic): Removed.
9203 (grub_get_time_ms): New prototype.
9204 (grub_install_get_time_ms): New prototype.
9205 (grub_rtc_get_time_ms): New prototype.
9206
9207 * kern/time.c (grub_get_time_ms): New function.
9208 (grub_install_get_time_ms): New function.
9209
9210 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
9211 <grub/time.h> anymore.
9212 (grub_millisleep): Removed.
9213 (grub_machine_init): Call grub_tsc_init.
9214
9215 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
9216 get_time_ms() implementation.
9217
9218 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
9219 (ieee1275_get_time_ms): New function.
9220 (grub_machine_init): Install get_time_ms() implementation.
9221
9222 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
9223 (grub_machine_init): Call grub_tsc_init().
9224 (grub_millisleep): Removed.
bf06a93f 9225
9c2ff3ee 9226 * kern/ieee1275/init.c (grub_millisleep): Removed.
9227 (grub_machine_init): Install ieee1275_get_time_ms()
9228 implementation.
9229 (ieee1275_get_time_ms): New function.
9230 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
9231 real work.
9232
9ec92aaf 92332008-08-05 Marco Gerards <marco@gnu.org>
9234
9235 * disk/ata.c: Include <grub/pci.h>.
9236 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
9237 (grub_ata_initialize): Rewritten.
9238 (grub_ata_device_initialize): New function.
9239
8d23f507 92402008-08-04 Pavel Roskin <proski@gnu.org>
9241
9242 * kern/main.c: Include grub/mm.h.
9243
5e15ee3d 92442008-08-04 Robert Millan <rmh@aybabtu.com>
9245
9246 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
9247 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
9248 corruption problem).
9249
a9053f8f 92502008-08-04 Robert Millan <rmh@aybabtu.com>
9251
9252 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
9253 warnings introduced in my last commit.
9254
dd19c7d7 92552008-08-03 Robert Millan <rmh@aybabtu.com>
9256
9257 Make PCI available on all i386 architectures.
9258
9259 * include/grub/i386/pc/pci.h: Move from here ...
9260 * include/grub/i386/pci.h: ... to here.
9261
9262 * include/grub/i386/pc/pci.h: Remove.
9263 * include/grub/i386/efi/pci.h: Remove.
9264 * include/grub/x86_64/efi/pci.h: Remove.
9265
9266 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
9267 `<grub/cpu/pci.h>'.
9268
9269 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
9270 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
9271 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
9272
9273 * conf/i386-ieee1275.rmk: Likewise.
9274
e14a6184 92752008-08-03 Robert Millan <rmh@aybabtu.com>
9276
9277 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
9278 (grub_console_setcursor): Make it possible to set cursor off.
9279
52768e37 92802008-08-03 Robert Millan <rmh@aybabtu.com>
9281
9282 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
9283 of modules instead of assuming which platform provides what.
9284 * util/update-grub.in: Likewise.
9285
2d52f57f 92862008-08-03 Robert Millan <rmh@aybabtu.com>
9287
9288 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
9289 instead of `grub_install_dos_part' to determine whether a drive needs
9290 to be prepended to prefix (`grub_install_dos_part' is not reliable,
825aa57a 9291 because it can be overridden when loading GRUB via Multiboot).
2d52f57f 9292
2a5cd121 92932008-08-02 Robert Millan <rmh@aybabtu.com>
9294
9295 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
9296
93808428 92972008-08-02 Robert Millan <rmh@aybabtu.com>
9298
9299 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
9300 of informational grub_dprintf() calls.
9301
3bd0a12a 93022008-08-02 Robert Millan <rmh@aybabtu.com>
9303
9304 * disk/memdisk.c (memdisk_size): Don't initialize.
9305 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
9306
9307 * include/grub/i386/pc/kernel.h
9308 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
9309 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
9310 (grub_memdisk_image_size, grub_arch_memdisk_addr)
9311 (grub_arch_memdisk_size): Remove.
9312
9313 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
9314 field (was only used to transfer a constant). Add `type' field to
9315 support multiple module types.
9316 (grub_module_iterate): New function.
9317
9318 * kern/device.c (grub_device_open): Do not hide error messages
9319 when grub_disk_open() fails. Use grub_print_error() instead.
9320
9321 * kern/i386/pc/init.c (grub_arch_modules_addr)
9322 (grub_arch_memdisk_size): Remove functions.
9323 (grub_arch_modules_addr): Return the module address in high memory
9324 (now that it isn't copied anymore).
9325
9326 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
9327 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
9328 decompression routine (grub_total_module_size already includes that
9329 now). Don't copy modules back to low memory.
9330
9331 * kern/main.c: Include `<grub/mm.h>'.
9332 (grub_load_modules): Split out (and use) ...
9333 (grub_module_iterate): ... this function, which iterates through
9334 module objects and runs a hook.
9335 Comment out grub_mm_init_region() call, as it would cause non-ELF
9336 modules to be overwritten.
9337
9338 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
9339 the memdisk image in its own region, make it part of the module list.
9340 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
9341 (main): Parse --memdisk|-m option, and pass user-provided path as
9342 parameter to generate_image().
9343 (add_segments): Pass `memdisk_path' down to load_modules().
9344 (load_modules): Embed memdisk image in module section when requested.
9345 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
9346 `header.type' instead of `header.offset'.
9347
9348 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
9349 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
9350 (memdisk_mod_LDFLAGS): New variables.
9351 * conf/i386-coreboot.rmk: Likewise.
9352 * conf/i386-ieee1275.rmk: Likewise.
9353
a927cc73 93542008-08-02 Robert Millan <rmh@aybabtu.com>
9355
9356 * loader/i386/pc/multiboot.c (playground, forward_relocator)
9357 (backward_relocator): New variables. Used to allocate and relocate
9358 the payload, respectively.
9359 (grub_multiboot_load_elf32): Load into heap instead of requested
825aa57a 9360 address, install the appropriate relocator code in each bound of
a927cc73 9361 the payload, and set the entry point such that
9362 grub_multiboot_real_boot() will jump to one of them.
9363
9364 * kern/i386/loader.S (grub_multiboot_payload_size)
9365 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9366 (grub_multiboot_payload_entry_offset): New variables.
9367 (grub_multiboot_real_boot): Set cpu context to what the relocator
9368 expects, and jump to the relocator instead of the payload.
9369
9370 * include/grub/i386/loader.h (grub_multiboot_payload_size)
9371 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9372 (grub_multiboot_payload_entry_offset): Export.
9373
b15d8a0c 93742008-08-01 Bean <bean123ch@gmail.com>
9375
9376 * normal/menu_entry.c (editor_getline): Don't return the original
9377 string as result, as it will be released by lexer once it has done
9378 using it.
9379
cdfb3d22 93802008-08-01 Robert Millan <rmh@aybabtu.com>
9381
9382 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
9383 within menuentries, not before them.
9384 util/grub.d/10_hurd.in: Likewise.
9385
9175e93d 93862008-08-01 Bean <bean123ch@gmail.com>
9387
9388 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
9389 (bufio_mod_SOURCES): New macro.
9390 (bufio_mod_CFLAGS): Likewise.
9391 (bufio_mod_LDFLAGS): Likewise.
9392
9393 * include/grub/bufio.h: New file.
9394
9395 * io/bufio.c: Likewise.
9396
9397 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
9398 (grub_video_reader_png): Use grub_buffile_open to open file.
9399
9400 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
9401 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
9402
9403 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
9404 (grub_video_reader_tga): Use grub_buffile_open to open file.
9405
9406 * font/manager.c: Include <grub/bufio.h>.
9407 (add_font): Use grub_buffile_open to open file.
9408
3d8383e7 94092008-07-31 Robert Millan <rmh@aybabtu.com>
9410
9411 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
9412 ELF segments, use a macro for arbitrarily accessing any of them instead
9413 of preparing a pointer that allows access to one at a time.
9414 (grub_multiboot_load_elf64): Likewise.
9415
16e641b6 94162008-07-31 Bean <bean123ch@gmail.com>
9417
9418 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
9419 GRUB_KERNEL_MACHINE_DATA_END.
9420
59198b72 94212008-07-30 Robert Millan <rmh@aybabtu.com>
9422
9423 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
9424 Increase from 0x50 to 0x60.
9425 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
9426 use UUIDs to identify the root drive for them. If that's not
9427 possible, abort.
9428 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
9429 check, for cross-disk installs.
9430
ae88bca3 94312008-07-30 Robert Millan <rmh@aybabtu.com>
9432
9433 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
9434 is non-empty, use it to set the `prefix' environment variable instead
9435 of the usual approach.
9436 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
9437 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
9438 environment variable instead of dummy make_install_device().
9439
9440 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
9441 (start): Insert a data section, with `grub_prefix' variable.
825aa57a 9442 * kern/i386/linuxbios/startup.S: Likewise.
ae88bca3 9443
9444 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
9445 New variable reference.
9446 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
9447 New macro. Defines offset of `grub_prefix' within startup.S (relative
9448 to `start').
9449 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
9450 section within startup.S (relative to `start').
9451 * include/grub/i386/coreboot/kernel.h: Likewise.
9452
9453 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
9454 Overwrite grub_prefix with its contents, at the beginning of the
9455 first segment.
9456 (main): Understand -p|--prefix.
9457
14f41dd1 94582008-07-30 Robert Millan <rmh@aybabtu.com>
9459
9460 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
9461
4ca049a3 94622008-07-30 Robert Millan <rmh@aybabtu.com>
9463
9464 * term/i386/pc/vga_text.c (grub_console_cls): Use
9465 grub_console_gotoxy() to go back to beginning of the screen.
9466 Found by Patrick Georgi <patrick.georgi@coresystems.de>
9467
2921d337 94682008-07-29 Christian Franke <franke@computer.org>
9469
9470 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
9471 Add conversion of emulated mount points on Cygwin.
9472
b609876d 94732008-07-29 Christian Franke <franke@computer.org>
9474
9475 * util/update-grub.in: Add a check for admin
9476 group on Cygwin.
9477 Remove old `grub.cfg.new' before creation.
9478 Add `-f' to `mv' to handle the different filesystem
9479 semantics of Windows.
9480
e93e4679 94812008-07-29 Bean <bean123ch@gmail.com>
9482
9483 * normal/main.c (get_line): Fix buffer overflow bug.
9484
41694fd0 94852008-07-28 Robert Millan <rmh@aybabtu.com>
9486
9487 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
9488 (struct grub_apple_header): New struct. Describes the layout of
9489 the partmap header.
9490 (apple_partition_map_iterate): Check the header magic as well as the
9491 partition magic (which was already being checked).
9492
cfd0b4e6 94932008-07-28 Pavel Roskin <proski@gnu.org>
9494
9495 * genmk.rb: Add a warning to the beginning of the output that
9496 it's a generated file and should not be edited.
9497
93cce016 94982008-07-28 Robert Millan <rmh@aybabtu.com>
9499
9500 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
9501 with the same number are found, just use issue a warning with
9502 grub_dprintf(), as this error has been reported to be non-fatal.
c298def0 9503
cd1df915 95042008-07-27 Robert Millan <rmh@aybabtu.com>
9505
9506 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
9507 information.
9508
b70a8427 95092008-07-27 Bean <bean123ch@gmail.com>
9510
9511 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
9512 (grub_fat_find_dir): Ignore case when comparing filename.
9513
8f5e379f 95142008-07-27 Bean <bean123ch@gmail.com>
9515
9516 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
9517 smallino, as it's more descriptive, and i8count can be confused with
9518 the other field count.
9519 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
9520 inode type.
9521
a85cd5a0 95222008-07-27 Bean <bean123ch@gmail.com>
9523
9524 * commands/crc.c: New file.
9525
9526 * lib/crc.c: Likewise.
9527
9528 * include/grub/lib/crc.h: Likewise.
9529
9530 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
9531
9532 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
9533 (hexdump): Move this function to ...
9534
9535 * lib/hexdump.c: ... here.
9536
9537 * include/grub/hexdump.h: Renamed to ...
9538
9539 * include/grub/lib/hexdump.h: ... this.
9540
9541 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
9542
9543 * util/grub-editenv.c: Likewise.
9544
9545 * include/envblk.h: Renamed to ...
9546
9547 * include/lib/envblk.h: ... this.
9548
9549 * util/envblk.c: Renamed to ...
9550
9551 * lib/envblk.c: ... this.
9552
9553 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
9554 lib/hexdump.c.
9555 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
9556 (pkglib_MODULES): Add crc.mod.
9557 (hexdump_mod_SOURCES): Add lib/hexdump.c.
9558 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
9559 (crc_mod_SOURCES): New macro.
9560 (crc_mod_CFLAGS): Likewise.
9561 (crc_mod_LDFLAGS): Likewise.
9562
9563 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
9564
9565 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9566
9567 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
9568
9569 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9570
9571 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
9572
c298def0 95732008-07-27 Felix Zielcke <fzielcke@z-51.de>
8749e9e5 9574
9575 * commands/help.c: Include <grub/term.h>.
9576 (TERM_WIDTH): Removed. Updated all users.
9577
cc349fb3 95782008-07-27 Pavel Roskin <proski@gnu.org>
9579
9580 * util/getroot.c (find_root_device): Rephrase a comment to avoid
9581 spurious warnings about a comment within a comment.
9582
9051607e 95832008-07-25 Robert Millan <rmh@aybabtu.com>
9584
9585 * util/getroot.c (find_root_device): Skip devices that match
9586 /dev/dm-[0-9]. This lets the real device be found for any type of
9587 abstraction (LVM, EVMS, RAID..).
9588 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
9589 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
9590 device is found first, find_root_device() will now skip it.
9591
01453bfc 95922008-07-24 Pavel Roskin <proski@gnu.org>
9593
9594 * include/grub/types.h: Use __builtin_bswap32() and
9595 __builtin_bswap64() with gcc 4.3 and newer.
9596
6af9849f 95972008-07-24 Christian Franke <franke@computer.org>
9598
3a0fa256 9599 * util/i386/pc/grub-install.in: If `--debug' is specified,
9600 pass `--verbose' to grub-setup.
9601 Abort script if make_system_path_relative_to_its_root() fails.
9602
7810e747 96032008-07-24 Bean <bean123ch@gmail.com>
9604
9605 * configure.ac: Fixed a bug caused by the previous cygwin patch,
9606 variable `target_platform' should be `platform'.
9607
42290e17 96082008-07-24 Bean <bean123ch@gmail.com>
9609
51cc5193 9610 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
42290e17 9611 (grub_png_init_fixed_block): New function.
9612 (grub_png_decode_image_data): Handle fixed huffman code compression.
9613
2a8a80e4 96142008-07-24 Bean <bean123ch@gmail.com>
9615
9616 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
9617 (grub_pe2elf_SOURCES): New macro.
9618 (CLEANFILES): Add grub-pe2elf.
9619
9620 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
9621 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
9622 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
9623 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
9624 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
9625 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
9626 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
9627 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
9628 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
9629 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
9630 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
9631 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
9632 (GRUB_PE32_DT_FUNCTION): Likewise.
9633 (GRUB_PE32_REL_I386_DIR32): Likewise.
9634 (GRUB_PE32_REL_I386_REL32): Likewise.
9635 (grub_pe32_symbol): New structure.
9636 (grub_pe32_reloc): Likewise.
9637
9638 * util/grub-pe2elf.c: New file.
9639
9640 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
9641 start symbol in non pc platform.
9642
9643 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
9644
9645 The following patches are from Christian Franke.
9646
9647 * include/grub/dl.h: Remove .previous, gas supports this only
9648 for ELF format.
9649
9650 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
9651 Remove .type, gas supports this only for ELF format.
9652
9653 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
9654 nullbytes in symbol table. This fixes an infinite loop if table is
9655 zero filled.
9656
9657 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
9658 TARGET_IMG_LDFLAGS and EXEEXT.
9659
9660 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
9661 TARGET_IMG_LDFLAGS_AC.
9662 (grub_CHECK_STACK_ARG_PROBE): New function.
9663
9664 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
9665
9666 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
9667
9668 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
9669 to set TARGET_IMG_LD* accordingly.
9670 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
9671 Add call to grub_CHECK_STACK_ARG_PROBE.
9672 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
9673
9674 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
9675
9676 * genmk.rb: Add EXEEXT to CLEANFILES.
9677
12ccdb75 96782008-07-23 Robert Millan <rmh@aybabtu.com>
9679
9680 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
9681 define the codes for arrows and lines used for the menu).
9682 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
9683 as well.
9684
9685 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
9686 fonts, because the latter are too slow.
9687
18eeaf04 96882008-07-21 Bean <bean123ch@gmail.com>
9689
9690 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
9691 a20. Run keyboard test last, as it will cause macbook to halt.
9692
b095e2ad 96932008-07-18 Pavel Roskin <proski@gnu.org>
9694
9695 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
9696 load foreign architecture modules correctly anyway. Keep
9697 support for loading host architecture modules, whether we
9698 compile them or not.
9699
737feb35 97002008-07-17 Pavel Roskin <proski@gnu.org>
9701
3f4ce737 9702 * configure.ac: Use -m32 or -m64 regardless of whether we had to
9703 change target_cpu. The compiler default can mismatch target_cpu
9704 in any case.
9705
4ad2d049 9706 * disk/efi/efidisk.c: Fix format warnings on x86_64.
9707 * kern/efi/efi.c: Likewise.
9708
f6130a12 9709 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
9710 target compiler is functional.
9711 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
9712 are set up.
9713
58393a2d 9714 * configure.ac: Default to efi platform for x86_64-apple. Allow
9715 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
9716 adjustments from the rest, only do them if target is not
9717 explicitly given. Merge other adjustments with the final sanity
9718 check. Remove an extraneous check for supported CPU. Be
9719 specific which CPU and which platform is not supported.
9720
737feb35 9721 * configure.ac: Default to pc platform for x86_64.
9722
546f966a 97232008-07-17 Robert Millan <rmh@aybabtu.com>
9724
9725 Partial LinuxBIOS -> Coreboot rename.
9726
9727 * conf/i386-linuxbios.rmk: Renamed to ...
9728 * conf/i386-coreboot.rmk: ... this.
9729 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
9730 * configure.ac: Accept "coreboot" as input platform (but maintain
9731 compatibility with "linuxbios").
9732 * include/grub/i386/linuxbios: Renamed to ...
9733 * include/grub/i386/coreboot: ... this.
9734
20011694 97352008-07-17 Bean <bean123ch@gmail.com>
9736
9737 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
c11f6d16 9738 (appleldr_mod_SOURCE): New variable.
20011694 9739 (appleldr_mod_CFLAGS): Likewise.
9740 (appleldr_mod_LDFLAGS): Likewise.
9741 (pci_mod_SOURCES): Likewise.
9742 (pci_mod_CFLAGS): Likewise.
9743 (pci_mod_LDFLAGS): Likewise.
9744 (lspci_mod_SOURCES): Likewise.
9745 (lspci_mod_CFLAGS): Likewise.
9746 (lspci_mod_LDFLAGS): Likewise.
9747
9748 * conf/x86_64-efi.rmk: New file.
9749
9750 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
9751 macro.
9752 (grub_efidisk_write): Likewise.
9753
9754 * include/efi/api.h (efi_call_0): New macro.
9755 (efi_call_1): Likewise.
9756 (efi_call_2): Likewise.
9757 (efi_call_3): Likewise.
9758 (efi_call_4): Likewise.
9759 (efi_call_5): Likewise.
9760 (efi_call_6): Likewise.
9761
9762 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
9763 grub_rescue_cmd_chainloader.
9764
9765 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
9766 (grub_pe32_optional_header): Change some fields based on i386 or
9767 x86_64 platform.
9768 (GRUB_PE32_PE32_MAGIC): Likewise.
9769
9770 * include/grub/efi/uga_draw.h: New file.
9771
9772 * include/grub/elf.h (STN_ABS): New constant.
9773 (R_X86_64_NONE): Relocation constant for x86_64.
9774 (R_X86_64_64): Likewise.
9775 (R_X86_64_PC32): Likewise.
9776 (R_X86_64_GOT32): Likewise.
9777 (R_X86_64_PLT32): Likewise.
9778 (R_X86_64_COPY): Likewise.
9779 (R_X86_64_GLOB_DAT): Likewise.
9780 (R_X86_64_JUMP_SLOT): Likewise.
9781 (R_X86_64_RELATIVE): Likewise.
9782 (R_X86_64_GOTPCREL): Likewise.
9783 (R_X86_64_32): Likewise.
9784 (R_X86_64_32S): Likewise.
9785 (R_X86_64_16): Likewise.
9786 (R_X86_64_PC16): Likewise.
9787 (R_X86_64_8): Likewise.
9788 (R_X86_64_PC8): Likewise.
9789
9790 * include/grub/i386/efi/pci.h: New file.
9791
9792 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
9793 Change it value based on platform.
9794 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
9795 (GRUB_E820_RAM): Likewise.
9796 (GRUB_E820_RESERVED): Likewise.
9797 (GRUB_E820_ACPI): Likewise.
9798 (GRUB_E820_NVS): Likewise.
9799 (GRUB_E820_EXEC_CODE): Likewise.
9800 (GRUB_E820_MAX_ENTRY): Likewise.
9801 (grub_e820_mmap): New structure.
9802 (linux_kernel_header): Change the efi field according to different
9803 kernel version, also field from linux_kernel_header.
9804
9805 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
9806
9807 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
9808 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
9809 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
9810 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
9811 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
9812 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
9813 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
9814 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
9815 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
9816 (GRUB_PCI_ADDR_IO_MASK): Likewise.
9817
9818 * include/grub/x86_64/efi/kernel.h: New file.
9819
9820 * include/grub/x86_64/efi/loader.h: Likewise.
9821
9822 * include/grub/x86_64/efi/machine.h: Likewise.
9823
9824 * include/grub/x86_64/efi/pci.h: Likewise.
9825
9826 * include/grub/x86_64/efi/time.h: Likewise.
9827
9828 * include/grub/x86_64/linux.h: Likewise.
9829
9830 * include/grub/x86_64/setjmp.h: Likewise.
9831
9832 * include/grub/x86_64/time.h: Likewise.
9833
9834 * include/grub/x86_64/types.h: Likewise.
9835
9836 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
9837 GRUB_TARGET_SIZEOF_VOID_P.
9838
9839 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
9840 (grub_efi_locate_handle): Likewise.
9841 (grub_efi_open_protocol): Likewise.
9842 (grub_efi_set_text_mode): Likewise.
9843 (grub_efi_stall): Likewise.
9844 (grub_exit): Likewise.
9845 (grub_reboot): Likewise.
9846 (grub_halt): Likewise.
9847 (grub_efi_exit_boot_services): Likewise.
9848 (grub_get_rtc): Likewise.
9849
9850 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
9851 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
9852 (grub_efi_allocate_pages): Wrap efi calls.
9853 (grub_efi_free_pages): Wrap efi calls.
9854 (grub_efi_get_memory_map): Wrap efi calls.
9855
9856 * kern/x86_64/dl.c: New file.
9857
9858 * kern/x86_64/efi/callwrap.S: Likewise.
9859
9860 * kern/x86_64/efi/startup.S: Likewise.
9861
9862 * loader/efi/appleloader.c: Likewise.
9863
9864 * loader/efi/chainloader.c (cmdline): New variable.
9865 (grub_chainloader_unload): Wrap efi calls.
9866 (grub_chainloader_boot): Likewise.
9867 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
9868 command line.
9869
9870 * loader/efi/chainloader_normal.c (chainloader_command):
9871 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
9872 command line.
9873
9874 * loader/i386/efi/linux.c (allocate_pages): Change allocation
9875 method.
9876 (grub_e820_add_region): New function.
9877 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
9878 booting.
9879 (grub_find_video_card): New function.
9880 (grub_linux_setup_video): New function.
9881 (grub_rescue_cmd_linux): Probe for video information.
9882
9883 * normal/x86_64/setjmp.S: New file.
9884
9885 * term/efi/console.c (map_char): New function.
9886 (grub_console_putchar): Map unicode char.
9887 (grub_console_checkkey): Wrap efi calls.
9888 (grub_console_getkey): Likewise.
9889 (grub_console_getwh): Likewise.
9890 (grub_console_gotoxy): Likewise.
9891 (grub_console_cls): Likewise.
9892 (grub_console_setcolorstate): Likewise.
9893 (grub_console_setcursor): Likewise.
9894
9895 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
9896
59652a20 98972008-07-16 Pavel Roskin <proski@gnu.org>
9898
ef294055 9899 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
9900 format strings.
9901
59652a20 9902 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
9903 pointer, not an integer. This fixes a warning and prevents
9904 precision loss on 64-bit systems.
9905 (relocate_addresses): Remove unneeded cast.
9906
afc3b5d7 99072008-07-15 Pavel Roskin <proski@gnu.org>
9908
506b2b3e 9909 * kern/i386/ieee1275/init.c: Include grub/cache.h.
9910
62ead89c 9911 * term/ieee1275/ofconsole.c: Disable code unused on i386.
9912
c4cd51d7 9913 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
9914 Fix comparison between signed and unsigned.
9915
0d3d8f28 9916 * include/grub/i386/ieee1275/console.h: Declare
9917 grub_console_init() and grub_console_fini().
9918
8804b286 9919 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
9920 It's empty and unused.
9921
ee01cf35 9922 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
9923 beginning to avoid warnings with some compilers.
9924
afc3b5d7 9925 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
9926 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
9927
e4e8eaa5 99282008-07-14 Pavel Roskin <proski@gnu.org>
9929
407aceb4 9930 * kern/env.c (grub_register_variable_hook): Don't copy empty
9931 string, it leaks memory. Pass "" to grub_env_set(), it should
9932 handle constant strings.
9933
e4e8eaa5 9934 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
9935 * commands/cmp.c (grub_cmd_cmp): Likewise.
9936 * kern/dl.c (grub_dl_flush_cache): Likewise.
9937 (grub_dl_load_core): Likewise.
9938 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
9939 (grub_elf64_load_phdrs): Likewise.
9940
d4e2dad3 99412008-07-13 Pavel Roskin <proski@gnu.org>
9942
9943 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
9944 between signed and unsigned.
9945 (LzmaEnc_Finish): Fix warning about an unused parameter.
9946
aa24b516 99472008-07-13 Bean <bean123ch@gmail.com>
9948
9949 * Makefile.in (enable_lzo): New rule.
9950
9951 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
9952
9953 * configure.ac (ENABLE_LZO): New option --enable-lzo.
9954
9955 * boot/i386/pc/lnxboot.S: #include <config.h>.
9956
9957 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
fe987087 9958 its value according to the compression algorithm used, lzo or lzma.
aa24b516 9959
9960 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
9961 compression algorithm according to configure macro.
9962
9963 * kern/i386/pc/startup.S (codestart): Likewise.
9964
9965 * kern/i386/pc/lzma_decode.S: New file.
9966
9967 * include/grub/lib/LzFind.h: Likewise.
9968
9969 * include/grub/lib/LzHash.h: Likewise.
9970
9971 * include/grub/lib/LzmaDec.h: Likewise.
9972
9973 * include/grub/lib/LzmaEnc.h: Likewise.
9974
9975 * include/grub/lib/LzmaTypes.h: Likewise.
9976
9977 * lib/LzFind.c: Likewise.
9978
9979 * lib/LzmaDec.c: Likewise.
9980
9981 * lib/LzmaEnc.c: Likewise.
9982
4ae821ac 99832008-07-13 Bean <bean123ch@gmail.com>
9984
9985 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
9986 (grub_ext4_extent_header): New structure.
9987 (grub_ext4_extent): Likewise.
9988 (grub_ext4_extent_idx): Likewise.
9989 (grub_ext4_find_leaf): New function.
9990 (grub_ext2_read_block): Handle extents.
9991
9a745147 99922008-07-12 Robert Millan <rmh@aybabtu.com>
9993
9994 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
9995
d49a4cf6 99962008-07-11 Robert Millan <rmh@aybabtu.com>
9997
9998 * util/grub.d/40_custom.in: New file. Example on how to add custom
9999 entries to /etc/grub.d.
10000 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
10001 40_custom (implicitly, by merging all the grub.d rules).
10002
947414b4 100032008-07-11 Pavel Roskin <proski@gnu.org>
10004
0059cf6f 10005 * commands/read.c (grub_getline): Fix invalid memory access.
10006 Don't add newline to the variable value.
10007
947414b4 10008 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
10009 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
10010 (serial_hw_get_port): Check validity of the port number.
10011 (grub_cmd_serial): Check return value of serial_hw_get_port().
10012
62a02d00 100132008-07-07 Pavel Roskin <proski@gnu.org>
10014
10015 * boot/i386/pc/diskboot.S (notification_string): Replace
10016 "Loading kernel" with just "loading". This is shorter, less
10017 confusing and saves a few bytes for possible future changes.
10018
3e5581b0 100192008-07-05 Pavel Roskin <proski@gnu.org>
10020
ea387a48 10021 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
10022 size for ATAPI devices, they are undefined. Output sector
10023 number in decimal form.
10024
3e5581b0 10025 * disk/ata.c: Use named constants for status bits.
10026
fdecb8fd 100272008-07-04 Pavel Roskin <proski@gnu.org>
10028
bcd35b90 10029 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
10030 grub_addr_t before casting it to the void pointer to fix a
10031 warning. Non-addressable regions are discarded earlier.
10032 (grub_arch_modules_addr): Cast _end to grub_addr_t.
10033 * kern/i386/linuxbios/table.c: Include grub/misc.h.
10034 (check_signature): Don't shadow table_header.
10035 (grub_linuxbios_table_iterate): Cast numeric constants to
10036 grub_linuxbios_table_header_t.
10037 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
10038 grub_stop().
10039
af58ab3d 10040 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
10041 prevent warnings.
10042
1759aa57 10043 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
10044 pointer, which can cause warnings. Support 64-bit addresses.
10045
fdecb8fd 10046 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
10047 of sizeof(long). This fixes PowerPC image generation on x86_64.
10048
8516d2a8 100492008-07-04 Robert Millan <rmh@aybabtu.com>
10050
10051 This fixes a performance issue when pc & gpt partmap iterators
10052 didn't abort iteration even after our hook found what it was
fe987087 10053 looking for (often causing expensive probes of non-existent drives).
8516d2a8 10054
10055 Some callers relied on previous buggy behaviour, since they would
34c44600 10056 raise an error when their own hooks caused early abortion of its
8516d2a8 10057 iteration.
10058
10059 * kern/device.c (grub_device_open): Improve error message.
10060 * disk/lvm.c (grub_lvm_open): Likewise.
10061 * disk/raid.c (grub_raid_open): Likewise.
10062
10063 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
10064 when hook requests it, independently of grub_errno.
10065 (pc_partition_map_probe): Do not fail when find_func() caused
10066 early abortion of pc_partition_map_iterate().
10067
10068 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
10069 when hook requests it, independently of grub_errno.
10070 (gpt_partition_map_probe): Do not fail when find_func() caused
10071 early abortion of gpt_partition_map_iterate().
10072
10073 * kern/partition.c (grub_partition_iterate): Abort parent iteration
10074 when hook requests it, independently of grub_errno. Do not fail when
10075 part_map_iterate_hook() caused early abortion of p->iterate().
10076
10077 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
10078 when grub_partition_iterate() returned with non-zero.
10079
277d0de9 100802008-07-03 Pavel Roskin <proski@gnu.org>
10081
10082 * disk/ata.c (grub_ata_pio_write): Check status before writing,
10083 like we do in grub_ata_pio_read().
10084 (grub_ata_readwrite): Always write individual sectors. Fix the
10085 sector count for the remainder.
10086 (grub_ata_write): Enable writing to ATA devices. Correctly
10087 report error for ATAPI devices.
10088
d4c9b428 100892008-07-02 Pavel Roskin <proski@gnu.org>
10090
e43fc690 10091 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
10092 warning.
10093
f707af42 10094 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
10095 for every read sector, we already increment it for the whole
10096 batch. This fixes reading more than 256 sectors at once.
10097
11e16b15 10098 * util/grub-editenv.c (cmd_info): Cast argument to long
10099 explicitly. ptrdiff_t reduces to int on i386.
10100
cbabfdd4 10101 * util/grub-editenv.c (main): Be specific which parameter is
10102 missing.
10103
b8fbce0a 10104 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
10105 (memdisk): Make memdisk_orig_addr a pointer.
10106
c9c8e606 10107 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
10108 for file offsets, use grub_off_t instead. Fix printf format
10109 warnings.
10110
ca62e598 10111 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
10112 there. Real unexpected warnings should not drown in the noise
10113 about known problems.
10114
ce8d1766 10115 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
10116 grub_disk_addr_t for memory addresses.
10117
00c7a56a 10118 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
10119 explicitly to fix a warning.
10120
08d3ef09 10121 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
10122
cb71ba20 10123 * Makefile.in (MODULE_LDFLAGS): New variable.
10124 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
10125 the linker accepts --build-id=none.
10126 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
10127 MODULE_LDFLAGS.
10128 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
10129
d4c9b428 10130 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
10131 those in Linux XFS code. Provide a way to access 64-bit parent
10132 inode.
10133 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
10134 the end of struct grub_xfs_dir_header.
10135
d4156eee 101362008-07-02 Bean <bean123ch@gmail.com>
10137
10138 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
10139 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10140 and GRUB_IEEE1275_FLAG_NO_ANSI.
10141
10142 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
10143 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10144 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
10145
10146 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
10147 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
10148
10149 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
10150 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
10151
10152 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
10153 esc sequence on non ANSI terminal.
10154 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
10155
10156 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
10157 beginning of file.
10158
2270f77b 101592008-07-02 Bean <bean123ch@gmail.com>
10160
10161 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
10162 (grub_editenv_SOURCES): New variable.
10163 (pkglib_MODULES): Add loadenv.mod.
10164 (loadenv_mod_SOURCES): New variable.
10165 (loadenv_mod_CFLAGS): Likewise.
10166 (loadenv_mod_LDFLAGS): Likewise.
10167
10168 * include/grub/envblk.h: New file.
10169
10170 * util/envblk.c: New file.
10171
10172 * util/grub-editenv.c: New file.
10173
10174 * commands/loadenv.c: New file.
10175
0e9e51ec 101762008-07-01 Pavel Roskin <proski@gnu.org>
10177
d89b7634 10178 * include/multiboot2.h (struct multiboot_tag_module): Use char,
10179 not unsigned char. This fixes warnings and is consistent with
10180 other tags.
10181
bf1835b1 10182 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
10183
8222a04b 10184 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
10185
6a42d99d 10186 * term/tparm.c (analyze): Always set *popcount.
10187
10b159d1 10188 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
10189 cast to fix a warning.
10190
b8789f6c 10191 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
10192 cast to suppress a warning.
10193
29d7e38a 10194 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
10195 grub_fshelp_read_file() expects.
10196
f341f669 10197 * fs/fat.c: Fix UUID calculation on big-endian systems. We
10198 write uuid as a 32-bit value in CPU byte order, so declare and
10199 use it as such.
10200
0e9e51ec 10201 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
10202 long if the format specifier expects it.
10203 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
10204 * partmap/pc.c (pc_partition_map_iterate): Likewise.
10205 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
10206 long to fix a warning.
10207 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
10208 grub_dprintf() arguments to fix warnings.
10209
3aefa857 102102008-06-30 Pavel Roskin <proski@gnu.org>
10211
56c7668b 10212 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
10213 install_bsd_part immediately before core.img is embedded or
10214 modified on disk. This fixes core.img verification if core.img
10215 cannot be embedded.
10216
3aefa857 10217 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
10218 core_path to calculate the blocklist.
10219 Patch from Javier Martín <lordhabbit@gmail.com>
10220
5444088d 102212008-06-29 Robert Millan <rmh@aybabtu.com>
10222
10223 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
10224 block to disk block.
10225 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
10226 Patch from Niels Böhm <bitbucket@arcor.de>
10227
674835c8 102282008-06-29 Robert Millan <rmh@aybabtu.com>
10229
10230 * util/update-grub_lib.in (font_path): Search for fonts in
10231 /boot/grub first, which is more likely to be readable (we aren't
10232 deciding where fonts live, just looking for them).
10233
f527dbc8 102342008-06-26 Pavel Roskin <proski@gnu.org>
10235
6c2d8df6 10236 * util/biosdisk.c (read_device_map): Don't leave dead map
10237 entries for devices failing stat() check.
10238
f527dbc8 10239 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
10240 core_path_dev for the core.img path on the target device.
10241
aebe3d13 102422008-06-26 Robert Millan <rmh@aybabtu.com>
10243
10244 * disk/fs_uuid.c: New file.
10245 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
10246 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
10247 (fs_uuid_mod_LDFLAGS): New variables.
10248 * include/grub/disk.h (grub_disk_dev_id): Add
10249 `GRUB_DISK_DEVICE_UUID_ID'.
10250 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
10251 implement iterate().
10252
37aaf354 102532008-06-26 Robert Millan <rmh@aybabtu.com>
10254
10255 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
10256 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
10257 Linux image includes no initrd.
10258
25ff262a 102592008-06-21 Javier Martín <lordhabbit@gmail.com>
10260
10261 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
10262 call to resolve the core image location that effectively appended the
10263 name twice.
10264
76a2bd44 102652008-06-21 Robert Millan <rmh@aybabtu.com>
10266
10267 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
10268 call from here ...
10269
10270 * util/grub.d/10_hurd.in: ... to here ...
10271 * util/grub.d/10_linux.in: ... and here.
10272
650e1c79 102732008-06-19 Robert Millan <rmh@aybabtu.com>
10274
fe987087 10275 * kern/main.c (grub_main): Export `prefix' variable immediately
650e1c79 10276 after it has been set by grub_machine_set_prefix().
10277
6ce63911 102782008-06-19 Robert Millan <rmh@aybabtu.com>
10279
10280 * commands/search.c (search_label, search_fs_uuid, search_file): Print
10281 search result when not saving to variable, not the other way around.
10282 When saving to variable, abort iteration as soon as a match is found.
10283
73940cec 102842008-06-19 Robert Millan <rmh@aybabtu.com>
10285
10286 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
10287 check for partition that provides /boot/grub. Its logic is flawed,
10288 as it prevents prepare_grub_to_access_device() from being called
10289 multiple times.
10290
3c62a39d 102912008-06-19 Robert Millan <rmh@aybabtu.com>
10292
10293 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
10294 "insmod" command directly when abstraction modules are needed,
fe987087 10295 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
3c62a39d 10296 since it had already been processed).
10297
47395a42 102982008-06-19 Pavel Roskin <proski@gnu.org>
10299
10300 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
10301 changed. This is needed in case GRUB_LIBDIR changes.
10302 * conf/i386-ieee1275.rmk: Likewise.
10303 * conf/i386-linuxbios.rmk: Likewise.
10304 * conf/i386-pc.rmk: Likewise.
10305 * conf/powerpc-ieee1275.rmk: Likewise.
10306
a145ac2d 103072008-06-18 Pavel Roskin <proski@gnu.org>
10308
10309 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
10310 kernel_elf_symlist.c to symlist.c for consistency with other
10311 architectures. Update all users.
10312 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
10313
7847c51e 103142008-06-18 Robert Millan <rmh@aybabtu.com>
10315
10316 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
10317 it in prefix.
10318
10319 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
10320 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
10321 a RAID device, run setup() for all members independently on whether
10322 LVM abstraction is being used.
10323 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
10324 If grub-mkimage has set `*install_dos_part == -2', don't override this
10325 value.
10326 Perform *install_dos_part adjustments independently on whether
10327 we're embedding or not.
10328 Clarify error message when image is too big for embedding.
10329 Remove duplicate *install_dos_part stanza.
10330
b23e5644 103312008-06-17 Robert Millan <rmh@aybabtu.com>
10332
10333 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
10334 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
10335 variables.
10336 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
10337 values in grub_ofconsole_normal_color and
10338 grub_ofconsole_highlight_color (they're not directly related to
10339 background and foreground).
10340 (grub_ofconsole_setcolorstate): Extract background and foreground
10341 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
10342
0aac2f79 103432008-06-17 Robert Millan <rmh@aybabtu.com>
10344
10345 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
10346 /boot/grub for the check in last commit, not /boot (they could be
10347 different partitions).
10348
3cca7ef3 103492008-06-16 Robert Millan <rmh@aybabtu.com>
10350
10351 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
10352 asked to setup access for the same partition that provides /boot,
10353 don't bother using UUIDs since our root already has the value we
10354 want.
10355
347396d8 103562008-06-16 Robert Millan <rmh@aybabtu.com>
10357
10358 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
10359 I2O devices.
10360 Patch from Sven Mueller <sven@debian.org>.
10361
991477f8 103622008-06-16 Robert Millan <rmh@aybabtu.com>
10363
10364 * util/update-grub.in: Check for $EUID instead of $UID.
10365 Reported by Vincent Zweije.
10366
d31a32a1 103672008-06-16 Bean <bean123ch@gmail.com>
10368
fe987087 10369 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
d31a32a1 10370 (grub_ext2_read_block): Likewise.
10371 (grub_ext2_read_inode): Likewise.
10372 (grub_ext2_mount): Likewise.
10373 (grub_ext2_close): Likewise.
10374 (grub_ext3_get_journal): Removed.
10375
fe987087 10376 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
d31a32a1 10377 (grub_reiserfs_read_symlink): Likewise.
10378 (grub_reiserfs_mount): Likewise.
10379 (grub_reiserfs_open): Likewise.
10380 (grub_reiserfs_read): Likewise.
10381 (grub_reiserfs_close): Likewise.
10382 (grub_reiserfs_get_journal): Removed.
10383
10384 * fs/fshelp.c (grub_fshelp_read): Removed.
10385 (grub_fshelp_map_block): Likewise.
10386
10387 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
10388 (grub_fshelp_journal): Likewise.
10389 (grub_fshelp_read): Likewise.
10390 (grub_fshelp_map_block): Likewise.
10391
3540a760 103922008-06-16 Pavel Roskin <proski@gnu.org>
10393
10394 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
10395 floating point anymore.
10396 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
10397
95614c84 103982008-06-15 Pavel Roskin <proski@gnu.org>
10399
10400 * commands/ls.c (grub_ls_list_files): Use integer calculations
10401 for human readable format, avoid floating point use.
10402 * kern/misc.c (grub_ftoa): Remove.
10403 (grub_vsprintf): Remove floating point support.
10404
50465dd6 104052008-06-15 Robert Millan <rmh@aybabtu.com>
10406
fe6b695a 10407 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
50465dd6 10408 devices.
10409 Reported by Max Vozeler.
10410
a9207284 104112008-06-15 Robert Millan <rmh@aybabtu.com>
10412
10413 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
10414 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
10415 skipped later.
10416 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
10417 the beginning of the prefix.
10418
10419 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
10420 It is assumed that if we have a memdisk, grub-mkimage has set
10421 grub_prefix to include the "(memdisk)" drive in it.
10422
a7cbd45a 104232008-06-15 Robert Millan <rmh@aybabtu.com>
10424
10425 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
10426 Initialize keyboard controller after registering the terminal, so that
10427 grub_printf() can be called from grub_keyboard_controller_init().
10428
21cf716a 104292008-06-15 Robert Millan <rmh@aybabtu.com>
10430
10431 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
10432 extent-btree which is written as big endian on disk.
10433 Reported by Alain Greppin <al@chilibi.org>.
10434
23a64d8e 104352008-06-14 Robert Millan <rmh@aybabtu.com>
10436
10437 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
10438 * util/i386/pc/grub-install.in (modules): Likewise.
10439
d687651c 104402008-06-13 Pavel Roskin <proski@gnu.org>
10441
10442 * commands/ls.c (grub_ls_list_files): Fix format warnings.
10443
dfe9ddd4 104442008-06-13 Bean <bean123ch@gmail.com>
10445
10446 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
10447
10448 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
10449
10450 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
10451 to indicate sparse block.
10452
16ae7781 104532008-06-12 Pavel Roskin <proski@gnu.org>
10454
e6d1a308 10455 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
10456 number, grub_fshelp_read() does it for us.
10457
16ae7781 10458 * fs/fshelp.c (grub_fshelp_read): New function. Implement
10459 linear disk read with journal translation.
10460 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
10461 * include/grub/fshelp.h: Declare grub_fshelp_read().
10462
40fd3a2b 104632008-06-09 Pavel Roskin <proski@gnu.org>
10464
10465 * fs/minix.c (grub_minix_mount): Handle error reading
10466 superblock.
10467
f5679726 104682008-06-08 Robert Millan <rmh@aybabtu.com>
10469
10470 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
10471 don't append the RAID prefix afterwards.
10472 Reported by Clint Adams.
10473
ce525529 104742008-06-08 Robert Millan <rmh@aybabtu.com>
10475
10476 Based on description from Pavel:
10477 * kern/disk.c (grub_disk_check_range): Rename to ...
10478 (grub_disk_adjust_range): ... this. Add a comment explaining the
10479 tasks performed by this function.
10480
ad4936a0 104812008-06-08 Robert Millan <rmh@aybabtu.com>
10482
10483 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
10484 `num_serial' (for consistency with other variables).
10485 (struct grub_ntfs_data): Add `uuid' member.
10486 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
10487 (grub_ntfs_uuid): New function.
10488 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
10489
dc20b0f9 104902008-06-07 Pavel Roskin <proski@gnu.org>
10491
10492 * util/biosdisk.c (open_device): Revert last change to the
10493 function, it broke installation. The sector needs to be
10494 different dependent on which device is opened.
10495
c5e3cfba 104962008-06-06 Robert Millan <rmh@aybabtu.com>
10497
10498 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
10499 rest of GRUB, and breakage doesn't happen if its value were modified.
10500
10501 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
10502 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
10503 a constant (same value).
10504 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
10505 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
10506
26a1f8c4 105072008-06-06 Robert Millan <rmh@aybabtu.com>
10508
10509 * util/biosdisk.c (open_device): Do not modify sector offset when
10510 accessing a partition. kern/disk.c already handles this for us.
10511
25d6b327 105122008-06-06 Robert Millan <rmh@aybabtu.com>
10513
10514 * util/grub-emu.c (grub_machine_init): Move code in this function from
10515 here ...
10516 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
10517 segfault in case grub_printf() is called).
10518
10519 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
10520 grub_probe. Update all users not to explicitly add it again.
10521 (grub_device): New variable; contains corresponding device for grubdir.
10522 (fs_module, partmap_module, devabstraction_module): Pass
10523 `--device ${grub_device}' to grub_probe to avoid traversing /dev
10524 every time.
10525
9ece62fb 105262008-06-05 Robert Millan <rmh@aybabtu.com>
10527
10528 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
10529 is found, print it (same layout as with labels).
10530
1ad36d37 105312008-06-04 Robert Millan <rmh@aybabtu.com>
10532
10533 * util/biosdisk.c (get_drive): Rename to ...
10534 (find_grub_drive): ... this. Update all users.
10535
10536 (get_os_disk): Rename to ...
10537 (convert_system_partition_to_system_disk): ... this. Update all users.
10538
10539 (find_drive): Rename to ...
10540 (find_system_device): ... this. Update all users.
10541
e6a30859 105422008-06-04 Robert Millan <rmh@aybabtu.com>
10543
10544 * util/biosdisk.c (get_os_disk): Handle IDA devices.
10545 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10546 (make_device_map): Likewise.
10547
00c108a4 105482008-06-01 Robert Millan <rmh@aybabtu.com>
10549
10550 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
10551 before dereferencing it.
10552
10553 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
10554 union with fat12/fat16-specific ones. Add some new fields, including
10555 `num_serial' for both versions.
10556 (struct grub_fat_data): Add `uuid' member.
10557 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
10558 names. Initialize `data->uuid' using `num_serial'.
10559 (grub_fat_uuid): New function.
10560 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
10561
10562 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
10563 (grub_reiserfs_uuid): New function.
10564 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
10565 member.
10566
10567 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
10568 (grub_xfs_uuid): New function.
10569 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
10570
1385c5bb 105712008-06-01 Robert Millan <rmh@aybabtu.com>
10572
10573 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
10574 code that is backward compatible with pre-uuid search command.
10575
c682dfd7 105762008-05-31 Robert Millan <rmh@aybabtu.com>
10577
10578 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
10579 floppies after everything else, to ensure floppy drive isn't accessed
10580 unnecessarily (patch from Bean).
10581
b7db5d47 105822008-05-31 Robert Millan <rmh@aybabtu.com>
10583
10584 * commands/search.c (search_label, search_fs_uuid, search_file): Do
10585 not print device names when we were asked to set a variable.
10586
6e037aa9 105872008-05-31 Robert Millan <rmh@aybabtu.com>
10588
10589 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
10590 using "cursor-on" and "cursor-off" commands (understood at least by
10591 the Open Firmware flavour on OLPC).
10592
41305bc8 105932008-05-31 Michael Gorven <michael@gorven.za.net>
10594
10595 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
10596 on and off sequences.
10597
69ba137e 105982008-05-31 Robert Millan <rmh@aybabtu.com>
10599
10600 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
10601 * util/update-grub.in: Likewise.
10602
520ae21b 106032008-05-30 Pavel Roskin <proski@gnu.org>
10604
10605 * util/biosdisk.c (linux_find_partition): Simplify logic and
10606 make the code more universal. Keep special processing for
10607 devfs, but use a simple rule for all other devices. If the
10608 device ends with a number, append 'p' and the partition number.
10609 Otherwise, append only the partition number.
10610
5786569b 106112008-05-30 Robert Millan <rmh@aybabtu.com>
10612
10613 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
10614 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
10615 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
10616 the `root' parameter to Linux.
10617
51500452 106182008-05-30 Robert Millan <rmh@aybabtu.com>
10619
10620 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
10621 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
10622 --fs_uuid with --fs-uuid.
10623 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
10624 all filesystems support them).
10625
811d3878 106262008-05-30 Robert Millan <rmh@aybabtu.com>
10627
10628 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
f19dbdb7 10629 grub_printf() flags, since we're printing in units of 2 bytes.
811d3878 10630
cab63c95 106312008-05-30 Robert Millan <rmh@aybabtu.com>
10632
10633 * util/grub.d/00_header.in: Remove obsolete comment referencing
10634 convert_system_path_to_grub_path().
10635 * util/update-grub.in: Likewise.
10636 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
10637 (convert_system_path_to_grub_path): Add a warning message explaining
10638 that this function is deprecated. Rely on is_path_readable_by_grub()
10639 for the readability checks.
10640 (font_path): Use is_path_readable_by_grub() for the readability
10641 check rather than convert_system_path_to_grub_path().
10642
972e2f7a 106432008-05-30 Robert Millan <rmh@aybabtu.com>
10644
10645 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
10646 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
10647 converting it first.
10648 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
10649 grub.cfg for access to font file, and afterwards call it again to set
10650 the root device.
10651
62191274 106522008-05-30 Robert Millan <rmh@aybabtu.com>
10653
10654 * commands/search.c (options): Add --fs_uuid option.
10655 (search_fs_uuid): New function.
10656 (grub_cmd_search): Fix --set argument passing.
10657 Use search_fs_uuid() when requested via --fs_uuid.
10658 (grub_search_init): Update help message.
10659 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
10660 and redeclare it as an array of 16-bit words.
10661 (grub_ext2_uuid): New function.
10662 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
10663 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
10664 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
10665 (GRUB_DEVICE_BOOT_UUID): New variables.
10666 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
10667 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
10668 whenever possible.
10669 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
10670 just assume `root' variable has the right value.
10671 * util/grub.d/10_linux.in: Likewise.
10672 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
10673 via PRINT_FS_UUID.
10674 (main): Recognise `-t fs_uuid' argument.
10675
01b73ec8 106762008-05-30 Robert Millan <rmh@aybabtu.com>
10677
10678 * util/biosdisk.c (map): Redefine structure to hold information
10679 about GRUB drive name.
fe6b695a 10680 (get_drive): Reimplement without assuming (and verifying) BIOS-like
01b73ec8 10681 drive names.
10682 (call_hook): Remove.
10683 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
10684 member. Assume drive has partitions.
10685 (grub_util_biosdisk_open): Access device names via `.device' struct
10686 member.
10687 (open_device): Likewise.
10688 (find_drive): Likewise.
10689 (read_device_map): Adjust map[] usage to match the new struct
10690 definition. Don't check for duplicates (still possible, but not cheap
10691 anymore).
10692 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
10693 (make_device_name): Remove assumption of BIOS-like drive names.
10694
22f16596 106952008-05-30 Pavel Roskin <proski@gnu.org>
10696
10697 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
10698 compiling execute.c doesn't need grub_script.tab.h anymore.
10699 (normal/command.c_DEPENDENCIES): Likewise.
10700 (normal/function.c_DEPENDENCIES): Likewise.
10701 * conf/i386-ieee1275.rmk: Likewise.
10702 * conf/i386-linuxbios.rmk: Likewise.
10703 * conf/i386-pc.rmk: Likewise.
10704 * conf/powerpc-ieee1275.rmk: Likewise.
10705 * conf/sparc64-ieee1275.rmk: Likewise.
10706
528ad8f2 107072008-05-29 Pavel Roskin <proski@gnu.org>
10708
d1dff95d 10709 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
10710 when scanning metadata for volume group name.
10711
528ad8f2 10712 * include/grub/script.h: Don't include grub_script.tab.h. It's
10713 a generated file, which may only be included from the files with
10714 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
10715 use union YYSTYPE, as the later allows forward declaration.
10716 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
10717
47248e08 107182008-05-29 Robert Millan <rmh@aybabtu.com>
10719
10720 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
10721 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
10722 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
10723 (grub_console_checkkey): Add grub_dprintf() call to report unknown
10724 scan codes.
10725
ee632529 107262008-05-29 Robert Millan <rmh@aybabtu.com>
10727
10728 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
10729 control key combinations.
10730
eee96e08 107312008-05-29 Robert Millan <rmh@aybabtu.com>
10732
10733 * util/powerpc/ieee1275/grub-install.in: Move from here ...
10734 * util/ieee1275/grub-install.in: ... to here.
10735 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
10736 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
10737 (grub_install_SOURCES): Likewise.
10738
da9a6a94 107392008-05-29 Robert Millan <rmh@aybabtu.com>
10740
10741 * fs/affs.c: Update copyright year.
10742 * fs/ext2.c: Likewise.
10743 * fs/fshelp.c: Likewise.
10744 * fs/hfsplus.c: Likewise.
10745 * fs/ntfs.c: Likewise.
10746 * fs/xfs.c: Likewise.
10747 * include/grub/fshelp.h: Likewise.
10748 * util/grub-mkdevicemap.c: Likewise.
10749
12e65f3a 107502008-05-28 Robert Millan <rmh@aybabtu.com>
10751
10752 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
10753 might need to be fatfs to support some firmware implementations
10754 (e.g. OFW or EFI).
10755
23023641 107562008-05-28 Robert Millan <rmh@aybabtu.com>
10757
10758 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
10759 devices.
10760 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10761 (make_device_map): Likewise.
10762
887d2619 107632008-05-20 Bean <bean123ch@gmail.com>
10764
10765 * fs/fshelp.c (grub_fshelp_map_block): New function.
10766 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
10767 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
10768
10769 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
10770 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
10771 (grub_fshelp_journal): New structure.
10772 (grub_fshelp_map_block): New function prototype.
10773 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
10774 (grub_fshelp_map_block): Likewise.
10775
10776 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
10777 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
10778 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
10779 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
10780 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
10781 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
10782 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
10783 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
10784 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
10785 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
10786 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
10787 (grub_ext2_sblock): New members for journal support.
10788 (grub_ext3_journal_header): New structure.
10789 (grub_ext3_journal_revoke_header): Likewise.
10790 (grub_ext3_journal_block_tag): Likewise.
10791 (grub_ext3_journal_sblock): Likewise.
10792 (grub_fshelp_node): New members logfile and journal.
10793 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
10794 grub_fshelp_map_block to get real block number.
10795 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
10796 number.
10797 (grub_ext2_read_inode): Likewise.
10798 (grub_ext3_get_journal): New function.
10799 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
10800 (grub_ext2_close): Release memory used by journal.
10801
10802 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
10803 (REISERFS_MAGIC_DESC_BLOCK): New macro.
10804 (grub_reiserfs_transaction_header): Renamed to
10805 grub_reiserfs_description_block, replace field data with real_blocks.
10806 (grub_reiserfs_commit_block): New structure.
10807 (grub_reiserfs_data): New member journal.
10808 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
10809 number.
10810 (grub_reiserfs_read_symlink): Likewise.
10811 (grub_reiserfs_iterate_dir): Likewise.
10812 (grub_reiserfs_open): Likewise.
10813 (grub_reiserfs_read): Likewise.
10814 (grub_reiserfs_get_journal): New function.
10815 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
10816 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
10817 using grub_reiserfs_get_journal.
10818 (grub_reiserfs_close): Release memory used by journal.
10819
10820 * fs/affs.c (grub_affs_read_block): Change block type to
10821 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
10822
10823 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
10824
10825 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
10826
10827 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
10828
10829 * fs/udf.c (grub_udf_read_block): Change block type to
10830 grub_disk_addr_t. Use type cast to avoid warning.
10831
10832 * fs/xfs.c (grub_xfs_read_block): Likewise.
10833
b7c6bed5 108342008-05-16 Christian Franke <franke@computer.org>
10835
10836 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
10837 to ensure that break with ESC will always work.
10838 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
10839 Remove ESC from keyboard queue.
10840
eedf167f 108412008-05-16 Christian Franke <franke@computer.org>
10842
10843 * util/biosdisk.c: [__CYGWIN__] Add includes.
10844 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
10845 (get_os_disk): Move variable declarations to OS specific
10846 parts to avoid warning.
10847 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
10848 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
10849 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
10850 Cygwin.
10851 * util/getroot.c: [__CYGWIN__] Add includes.
10852 (strip_extra_slashes): Fix "/" case.
10853 [__CYGWIN__] (get_win32_path): New function.
10854 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
10855 [__CYGWIN__] (find_root_device): Disable.
10856 [__CYGWIN__] (get_bootsec_serial): New function.
10857 [__CYGWIN__] (find_cygwin_root_device): Likewise.
10858 [__linux__] (grub_guess_root_device): Add early returns to simplify
10859 structure.
10860 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
10861 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
10862 check for Linux only.
10863
a079699e 108642008-05-15 Bean <bean123ch@gmail.com>
10865
10866 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
10867 keyboard hang problem in apple's intel mac.
10868
1cf4059a 108692008-05-09 Robert Millan <rmh@aybabtu.com>
10870
10871 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
10872 devices.
10873 * util/grub-mkdevicemap.c (get_virtio_disk_name)
10874 (make_device_map): Likewise.
10875 Reported by Aurelien Jarno <aurel32@debian.org>
10876
ed759390 108772008-05-07 Ian Campbell <ijc@hellion.org.uk>
10878
10879 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
10880 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
10881 (make_device_map): Output entries for xvd type disks.
10882
b56c4eaa 108832008-05-07 Robert Millan <rmh@aybabtu.com>
10884
10885 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
10886 devices.
10887 * util/grub-mkdevicemap.c (get_cciss_disk_name)
10888 (make_device_map): Likewise.
10889 Reported by Roland Dreier <rdreier@cisco.com>
10890
7f8866ed 108912008-05-07 Robert Millan <rmh@aybabtu.com>
10892
10893 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
10894 grub_strstr() call. Correct a few mistakes in failure path handling.
10895
b0346e0f 108962008-05-06 Robert Millan <rmh@aybabtu.com>
10897
10898 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
10899 Do not print a trailing slash (therefore, the root directory is an
10900 empty string).
10901 (convert_system_path_to_grub_path): Do not remove trailing slash
10902 from make_system_path_relative_to_its_root() output.
10903
10904 * util/i386/pc/grub-install.in: Add trailing slash to output from
10905 make_system_path_relative_to_its_root().
10906
6cf12cbd 109072008-05-06 Robert Millan <rmh@aybabtu.com>
10908
10909 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
10910 ensures that output lines aren't intermangled with those sent to
10911 stderr (via grub_util_info()).
10912 * util/grub-probe.c (grub_refresh): Likewise.
10913 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
10914
0fbb3117 109152008-05-05 Christian Franke <franke@computer.org>
10916
10917 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
10918 Add Cygwin device names.
10919 (get_ide_disk_name) [__CYGWIN__]: Likewise.
10920 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
10921 (check_device): Return error instead of success on empty name.
10922 (make_device_map): Move label inside linux specific code to
10923 prevent compiler warning.
10924
8124cdb7 109252008-04-30 Robert Millan <rmh@aybabtu.com>
10926
10927 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
10928 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
10929 first boot option.
10930 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
10931
094c01d0 109322008-04-29 Robert Millan <rmh@aybabtu.com>
10933
10934 * docs/grub.cfg: New file (example GRUB configuration).
10935
f4b1fc02 109362008-04-26 Robert Millan <rmh@aybabtu.com>
10937
329ce2a5 10938 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
10939 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
10940 and `disk/ieee1275/nand.c'.
f4b1fc02 10941
25f16ec1 109422008-04-25 Bean <bean123ch@gmail.com>
f19dbdb7 10943
25f16ec1 10944 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
10945 i386-linuxbios.
10946
10947 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
10948 change the buffer size to 4096 for cdrom device.
10949
10950 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
10951 and nand.mod.
10952 (_linux_mod_SOURCES): New variable.
10953 (_linux_mod_CFLAGS): Likewise.
10954 (_linux_mod_LDFLAGS): Likewise.
10955 (linux_mod_SOURCES): Likewise.
10956 (linux_mod_CFLAGS): Likewise.
10957 (linux_mod_LDFLAGS): Likewise.
10958 (nand_mod_SOURCES): Likewise.
10959 (nand_mod_CFLAGS): Likewise.
10960 (nand_mod_LDFLAGS): Likewise.
10961
10962 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
10963 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
10964 type property. (nand device in olpc don't have this property)
10965
10966 * include/grub/disk.h (grub_disk_dev_id): New macro
10967 GRUB_DISK_DEVICE_NAND_ID.
10968
10969 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
10970 function prototype.
10971 (grub_rescue_cmd_initrd): Likewise.
10972
10973 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
10974 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
10975 ofw_cif_handler and ofw_idt, adjust padding number.
f19dbdb7 10976
25f16ec1 10977 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
10978 GRUB_MACHINE_IEEE1275 is defined.
10979
10980 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
10981 Use NESTED_FUNC_ATTR attribute on the hook parameter.
10982
10983 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
10984 on nested function heap_init.
10985 (grub_upper_mem): New variable for i386-ieee1275.
10986 (grub_get_extended_memory): New function for i386-ieee1275.
10987 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
10988
10989 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
10990 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
10991 property.
f19dbdb7 10992
25f16ec1 10993 * loader/i386/ieee1275/linux.c: New file.
10994
10995 * loader/i386/ieee1275/linux_normal.c: New file.
10996
10997 * disk/ieee1275/nand.c: New file.
10998
e89d61e9 109992008-04-18 Thomas Schwinge <tschwinge@gnu.org>
11000
11001 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
11002 value.
11003 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
11004
602566f6 110052008-04-18 Robert Millan <rmh@aybabtu.com>
11006
11007 Restructures early code path on ieee1275 to unify grub_main() as
11008 the first C function that is executed in every platform.
11009
11010 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
11011 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
11012 cmain().
11013 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
11014 * kern/ieee1275/cmain.c (cmain): Rename to ...
11015 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
11016 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
11017 at the beginning.
11018
57490c2b 110192008-04-18 Robert Millan <rmh@aybabtu.com>
11020
11021 * util/update-grub.in: Fix syntax error when setting
11022 `GRUB_PRELOAD_MODULES'.
11023 Reported by Stephane Chazelas <stephane@artesyncp.com>
11024
1977517d 110252008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
11026
11027 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
11028 section into account, newer toolchains generate unique build ids
11029 * configure.ac: remove the test for --build-id=none acceptance,
e0c5dacb 11030 we want build ids to be preserved
1977517d 11031 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
11032 far from other sections don't cause the raw binary images grow
11033 size
11034
bfb1f1a2 110352008-04-15 Robert Millan <rmh@aybabtu.com>
11036
11037 * disk/lvm.c: Update copyright year.
11038 * kern/misc.c: Likewise.
11039
01979850 110402008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11041
11042 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
f19dbdb7 11043 there is no memory left for physical volume name.
01979850 11044
0a1150e2 110452008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11046
11047 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
11048 volume name mapping to support bigger than 9 character names properly.
11049
82ead3fe 110502008-04-13 Robert Millan <rmh@aybabtu.com>
11051
11052 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
11053 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
11054
e54a72f5 110552008-04-13 Christian Franke <franke@computer.org>
11056
11057 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
11058 to create a floppy emulation boot CD when non emulation mode
11059 does not work.
11060 Enable Joliet CD filesystem extension.
11061
9fe86034 110622008-04-13 Robert Millan <rmh@aybabtu.com>
11063
11064 * kern/misc.c (grub_strncat): Fix off-by-one error.
11065 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
11066
11067 * kern/env.c (grub_env_context_close): Clear current context, not
11068 previous one.
11069 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
11070
11071 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
11072
7ceeee39 110732008-04-13 Robert Millan <rmh@aybabtu.com>
11074
11075 Improve robustness when handling LVM.
11076
11077 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
f19dbdb7 11078 (and leave `*p' unmodified).
7ceeee39 11079 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
11080 through it.
11081 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
11082 iterating through it.
11083 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
11084 through it.
fe6b695a 11085 (grub_lvm_scan_device): Check the return value (and fail gracefully
7ceeee39 11086 when due) on each grub_lvm_getvalue() or grub_strstr() call.
11087 Don't assume `vg->pvs != NULL' when iterating through it.
11088
58cd3d85 110892008-04-13 Robert Millan <rmh@aybabtu.com>
11090
11091 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
11092 * genmk.rb (partmap): New variable.
11093 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
11094 (#{partmap}): New target rule.
11095 * genpartmaplist.sh: New file.
11096 * Makefile.in (pkglib_DATA): Add partmap.lst.
11097 (partmap.lst): New target rule.
11098 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
11099 modules (including all partition maps), instead of preloading them.
11100
78b51059 111012007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
11102
11103 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
11104 `linux-boot-prober' (if installed) to detect other operating
11105 systems which are installed on the computer and add them to
11106 the boot menu.
11107 * conf/common.rmk: Build and install 30_os-prober.
11108
a91627b4 111092008-04-12 Robert Millan <rmh@aybabtu.com>
11110
11111 * kern/powerpc/ieee1275/init.c: Move from here ...
11112 * kern/ieee1275/init.c: ... to here. Update all users.
11113
11114 * kern/powerpc/ieee1275/cmain.c: Move from here ...
11115 * kern/ieee1275/cmain.c: ... to here. Update all users.
11116
11117 * kern/powerpc/ieee1275/openfw.c: Move from here ...
11118 * kern/ieee1275/openfw.c: ... to here. Update all users.
11119
11120 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
11121 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
11122
322562ea 111232008-04-10 Pavel Roskin <proski@gnu.org>
11124
11125 * configure.ac: Always use "_cv_" in cache variables for
11126 compatibility with Autoconf 2.62.
11127
a02a73c5 111282008-04-07 Robert Millan <rmh@aybabtu.com>
11129
11130 Revert grub/machine/init.h addition by Pavel (since it breaks on
11131 i386-ieee1275 and others):
11132 * util/i386/pc/misc.c: Remove grub/machine/init.h.
11133 * util/powerpc/ieee1275/misc.c: Likewise.
11134
25c024b1 111352008-04-07 Robert Millan <rmh@aybabtu.com>
11136
11137 * util/grub-probe.c (probe): Improve error message.
11138
3cbd2f98 111392008-04-07 Robert Millan <rmh@aybabtu.com>
11140
11141 * util/biosdisk.c (read_device_map): Skip devices that don't exist
11142 (this prevents the presence of a bogus entry from ruining the whole
11143 thing).
11144
87a297bf 111452008-04-06 Pavel Roskin <proski@gnu.org>
11146
36747a62 11147 * util/biosdisk.c: Include grub/util/biosdisk.h.
11148 * util/grub-fstest.c (execute_command): Make static.
11149 * util/grub-mkdevicemap.c (check_device): Likewise.
11150 * util/i386/pc/misc.c: Include grub/machine/init.h.
11151 * util/powerpc/ieee1275/misc.c: Likewise.
11152 * util/lvm.c: Include grub/util/lvm.h.
11153 * util/misc.c: Include grub/kernel.h, grub/misc.h and
11154 grub/cache.h.
11155 * util/raid.c: Include grub/util/raid.h.
11156 (grub_util_getdiskname): Make static.
11157
87a297bf 11158 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
11159 grub_hostfs_fini(), as they are called from grub_init_all() and
11160 grub_fini_all() respectively. This fixes an infinite loop in
11161 grub-fstest due to double registration of hostfs.
11162 Reported by Christian Franke <Christian.Franke@t-online.de>
11163
f6ce7629 111642008-04-05 Pavel Roskin <proski@gnu.org>
11165
11166 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
11167 all 8 functions. Otherwise, probe function 0 only.
11168
070e49e4 111692008-04-04 Pavel Roskin <proski@gnu.org>
11170
8b088a4c 11171 * commands/lspci.c (grub_lspci_iter): Print the bus number
11172 correctly.
11173
4f657021 11174 * commands/lspci.c (grub_pci_classes): Fix typos.
11175 (grub_lspci_iter): Don't print func twice. Print vendor ID
11176 before device ID, as it's normally done.
11177
070e49e4 11178 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
11179 Fix signedness warnings.
11180 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
11181 Likewise.
11182 * util/ieee1275/get_disk_name.c: Include config.h so that
11183 _GNU_SOURCE is defined and getline() is declared. Mark an
11184 unused argument as such. Fix a signedness warning.
11185
ba7328dc 111862008-04-02 Pavel Roskin <proski@gnu.org>
11187
26887f22 11188 * genkernsyms.sh.in: Use more robust assignments for CC and
11189 srcdir. Quote srcdir.
11190 * gensymlist.sh.in: Likewise. Assert at the compile time that
11191 the symbol table is not empty.
11192
ba7328dc 11193 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
11194 * fs/cpio.c (grub_cpio_read): Likewise.
11195
0f582c6b 111962008-04-01 Pavel Roskin <proski@gnu.org>
11197
4b6e1995 11198 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
11199 * disk/host.c (grub_host_open): Likewise.
11200 * disk/loopback.c (grub_loopback_open): Likewise.
11201 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
11202 disk->id as in disk/host.c, not a multi-character constant.
11203
828a2768 11204 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
11205 later is obsolete, potentially dangerous and sets a bad example.
11206 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
11207 * util/misc.c (grub_util_get_image_size): Likewise.
11208
2bb4fb47 11209 * disk/loopback.c (options): Improve help for "--partitions".
11210
0f582c6b 11211 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
11212 options to align them with the short options, e.g. "echo -e".
11213
a33224e0 112142008-03-31 Bean <bean123ch@gmail.com>
11215
11216 * video/reader/png.c (grub_png_data): New member is_16bit and
11217 image_data.
11218 (grub_png_decode_image_header): Detect 16 bit png image.
11219 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
11220 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
11221 (grub_video_reader_png): Release memory occupied by image_data.
11222
11223 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
11224 4096 bytes.
11225 (grub_nfs_mount): Skip the test for sector per cluster.
11226
11227 * include/grub/ntfs.h (MAX_SPC): Removed.
11228
86cb4f54 112292008-03-31 Bean <bean123ch@gmail.com>
11230
11231 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
11232 (grub_probe_SOURCES): Add fs/afs.c.
11233 (grub_fstest_SOURCES): Likewise.
11234 (afs_mod_SOURCES): New variable.
11235 (afs_mod_CFLAGS): Likewise.
11236 (afs_mod_LDFLAGS): Likewise.
11237
11238 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
11239 (grub_emu_SOURCES): Likewise.
11240
11241 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11242
11243 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11244
11245 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11246
11247 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11248
11249 * fs/afs.c: New file.
11250
17c74c21 112512008-03-30 Pavel Roskin <proski@gnu.org>
11252
4cb68e89 11253 * disk/host.c: Include grub/misc.h to fix a warning.
11254 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
11255 warnings about implicit declarations.
11256
8790bb04 11257 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
11258 variable.
11259 * include/grub/i386/loader.h: Change declaration of
11260 grub_linux_boot() to match what grub_loader_set() expects.
11261 * util/getroot.c (grub_guess_root_device): Return const char* to
11262 fix a warning.
11263 * util/grub-probe.c (probe): Fix a warning about uninitialized
11264 abstraction_name variable.
11265 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
11266 second argument as unused to fix a warning.
11267
9a3f3296 11268 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
11269 missing grub_error() call.
11270
0ecef90d 11271 * util/update-grub_lib.in: Define datarootdir, since Autoconf
11272 2.60 and newer uses it to define datadir.
11273
0bf6d401 11274 * commands/sleep.c: Fix warning about implicit declaration.
11275 * disk/memdisk.c: Likewise.
11276 * loader/aout.c: Likewise.
11277 * loader/i386/bsd_normal.c: Likewise.
11278 * util/grub-probe.c: Likewise.
11279
7cdacf97 11280 * commands/i386/cpuid.c (has_longmode): Make static.
11281 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
11282 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
11283
17c74c21 11284 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
11285 GDT. This is more robust, as %ds can change.
11286 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
11287 calling real_to_prot().
11288 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
11289
80a3e68b 112902008-03-28 Pavel Roskin <proski@gnu.org>
11291
11292 * kern/i386/pc/startup.S: Assert that uncompressed functions
11293 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
11294 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
11295 code, as they push parts of the code (error handlers) beyond
11296 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
11297 code as correctness and size.
11298
77bcd272 112992008-03-28 Pavel Roskin <proski@gnu.org>
11300
11301 * kern/i386/pc/startup.S
11302 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
11303 data block address to the real mode, keep offset minimal. This
11304 works around a bug in AWARD BIOS on old Athlon systems, which
11305 makes CD detection hang.
11306
c5dfd43b 113072008-03-26 Pavel Roskin <proski@gnu.org>
11308
11309 * normal/color.c (grub_parse_color_name_pair): Make `name' a
11310 const.
11311 * include/grub/normal.h: Add grub_parse_color_name_pair()
11312 declaration.
11313
bf962df2 113142008-03-24 Bean <bean123ch@gmail.com>
11315
11316 * disk/i386/pc/biosdisk.c (cd_start): Removed.
11317 (cd_count): Removed.
11318 (cd_drive): New variable.
11319 (grub_biosdisk_get_drive): Don't check for (cdN) device.
11320 (grub_biosdisk_call_hook): Likewise.
11321 (grub_biosdisk_iterate): Change cdrom detection method.
11322 (grub_biosdisk_open): Replace cd_start with cd_drive.
11323 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
11324 detect cdrom device.
11325
11326 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
11327 Removed.
11328 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
11329 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
11330 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
11331 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
11332 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
11333 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
11334 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
11335 (grub_biosdisk_cdrp): New structure.
11336 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
11337
11338 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
11339
11340 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
11341 device.
11342
11343 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
11344 New function.
11345
68e7fc7a 113462008-03-20 Robert Millan <rmh@aybabtu.com>
11347
11348 Remove 2 TiB limit in ata.mod.
11349 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
11350 (grub_ata_dumpinfo): Print sector count with 0x%llx.
11351 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
11352 grub_uint64_t instead of grub_uint32_t.
11353
38ad2cf5 113542008-03-05 Bean <bean123ch@gmail.com>
11355
11356 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
11357 (grub_multiboot): Set boot device.
11358
11359 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
11360
2b89344e 113612008-03-02 Bean <bean123ch@gmail.com>
11362
11363 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
11364 symlink_buffer.
11365
87a95d1f 113662008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
11367
11368 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
11369 texinfo.tex.
11370
11371 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
11372 modified.
11373
11374 * docs/fdl.texi: New file.
f19dbdb7 11375
87a95d1f 11376 * docs/mdate-sh: New file. Copied from gnulib.
11377 * docs/texinfo.tex: Likewise.
11378
11379 * config.guess: Updated from gnulib.
11380 * install-sh: Likewise.
11381
7dc15d8e 113822008-02-28 Robert Millan <rmh@aybabtu.com>
11383
11384 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
11385 (aout_mod_SOURCES): New variable.
11386 (aout_mod_CFLAGS): Likewise.
11387 (aout_mod_LDFLAGS): Likewise.
11388
11389 * conf/i386-ieee1275.rmk: Likewise.
11390
b00ab696 113912008-02-28 Robert Millan <rmh@aybabtu.com>
11392
11393 * util/update-grub.in: Reorganise terminal validity check. Accept
11394 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
11395 Based on suggestion by Franklin PIAT.
11396
79ca2d78 113972008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
11398
11399 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
11400 function.
11401 * util/getroot.c (grub_util_check_block_device): New function that
11402 returns the given argument if it is a block device and returns NULL else.
11403 * util/grub-probe.c (argument_is_device): New variable.
11404 (probe): Promote device_name from a variable to an argument. Receive
11405 device_name from grub_util_check_block_device() if path is NULL and from
11406 grub_guess_root_device() else. Do not free() device_name anymore.
f19dbdb7 11407 (options): Introduce new parameter '-d, --device'.
79ca2d78 11408 (main): Add description of the new parameter to the help screen.
11409 Rename path variable to argument. Set argument_is_device if the '-d'
11410 option is given. Pass argument to probe() depending on
11411 argument_is_device.
11412
0d16e571 114132008-02-24 Bean <bean123ch@gmail.com>
11414
11415 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
11416 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
11417 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
11418 (GRUB_ISO9660_VOLDESC_PART): Likewise.
11419 (GRUB_ISO9660_VOLDESC_END): Likewise.
11420 (grub_iso9660_primary_voldesc): New member escape.
11421 (grub_iso9660_data): New member joliet.
11422 (grub_iso9660_convert_string): New function.
11423 (grub_iso9660_mount): Detect joliet extension.
11424 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
11425 (grub_iso9660_iso9660_label): Likewise.
11426
11427 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
11428 (grub_setup_SOURCES): Add fs/udf.c.
11429 (grub_fstest_SOURCES): Likewise.
11430 (udf_mod_SOURCES): New variable.
11431 (udf_mod_CFLAGS): Likewise.
11432 (udf_mod_LDFLAGS): Likewise.
11433
11434 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
11435 (grub_emu_SOURCES): Likewise.
11436
11437 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11438
11439 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11440
11441 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11442
11443 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11444
11445 * fs/udf.c: New file.
11446
8a594a17 114472008-02-24 Robert Millan <rmh@aybabtu.com>
11448
11449 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
11450 (normal/lexer.c_DEPENDENCIES): New variables.
11451 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11452 (normal/lexer.c_DEPENDENCIES): Likewise.
11453 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
11454 (normal/lexer.c_DEPENDENCIES): Likewise.
11455 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
11456 (normal/lexer.c_DEPENDENCIES): Likewise.
11457 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11458 (normal/lexer.c_DEPENDENCIES): Likewise.
11459 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11460 (normal/lexer.c_DEPENDENCIES): Likewise.
11461
2dc33c03 114622008-02-23 Robert Millan <rmh@aybabtu.com>
11463
11464 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
11465 since they were intended to be in hex. This didn't break previously
11466 because of a bug in gpt_partition_map_iterate() (see below).
11467
11468 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
11469 when checking the validity of GPT header.
11470 Remove `partno', since it always provides the same information as `i'.
11471
f6f4cfb0 114722008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
11473
11474 * include/grub/efi/time.h: Fix a wrong comment.
11475
79ff665f 114762008-02-19 Pavel Roskin <proski@gnu.org>
11477
11478 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
11479 message.
11480
d38e24c2 114812008-02-19 Bean <bean123ch@gmail.com>
11482
11483 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
11484 (aout_mod_SOURCES): New variable.
11485 (aout_mod_CFLAGS): Likewise.
11486 (aout_mod_LDFLAGS): Likewise.
11487 (_bsd_mod_SOURCES): New variable.
11488 (_bsd_mod_CFLAGS): Likewise.
11489 (_bsd_mod_LDFLAGS): Likewise.
11490 (bsd_mod_SOURCES): New variable.
11491 (bsd_mod_CFLAGS): Likewise.
11492 (bsd_mod_LDFLAGS): Likewise.
11493
11494 * include/grub/aout.h: New file.
11495
11496 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
11497
11498 * include/grub/i386/bsd.h: New file.
11499
11500 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
11501 to make it public.
11502
11503 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
11504 function is called, so that it's possible to change it inside the hook.
11505 (grub_elf64_load): Likewise.
11506 (grub_elf_file): Don't close the file if elf header is not found.
11507 (grub_elf_close): Close the file if grub_elf_file fails (The new
11508 grub_elf_file won't close it).
11509 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
11510 (grub_elf64_size): Likewise.
11511
11512 * kern/i386/loader.S (grub_unix_real_boot): New function.
11513
11514 * loader/aout.c: New file.
11515
11516 * loader/i386/bsd.c: New file.
11517
11518 * loader/i386/bsd_normal.c: New file.
11519
11520 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
11521
11522 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
fe987087 11523 can test other formats.
d38e24c2 11524
b93bdb0f 115252008-02-19 Robert Millan <rmh@aybabtu.com>
11526
11527 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
11528 (grub_gpt_partition_type_empty): Redefine with macro from
11529 `<grub/gpt_partition.h>'.
11530 (gpt_partition_map_iterate): Adjust partition type comparison.
11531
11532 Export `entry' as partmap-specific `part.data' struct.
11533 (grub_gpt_header, grub_gpt_partentry): Move from here ...
11534
11535 * include/grub/gpt_partition.h (grub_gpt_header)
11536 (grub_gpt_partentry): ... to here (new file).
11537
11538 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
11539
11540 (grub_gpt_partition_type_bios_boot): New const variable, defined
11541 with macro from `<grub/gpt_partition.h>'.
11542
11543 (setup): Replace `first_start' with `embed_region', which keeps
11544 track of the embed region (and is partmap-agnostic).
11545
11546 Replace find_first_partition_start() with find_usable_region(),
11547 which finds a usable region for embedding using partmap-specific
11548 knowledge (supports PC/MSDOS and GPT).
11549
11550 Fix all assumptions that the embed region start at sector 1, using
11551 `embed_region.start' from now on. Similarly, use `embed_region.end'
11552 rather than `first_start' to calculate available size.
11553
11554 In grub_util_info() message, replace "into after the MBR" with an
11555 indication of the specific sector our embed region starts at.
11556
66cb40f6 115572008-02-19 Robert Millan <rmh@aybabtu.com>
11558
11559 * DISTLIST: Replace `commands/ieee1275/halt.c' and
11560 `commands/ieee1275/reboot.c' with `commands/halt.c' and
11561 `commands/reboot.c'.
11562 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11563 (halt_mod_SOURCES): Likewise.
11564 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11565 (halt_mod_SOURCES): Likewise.
11566
b7202015 115672008-02-17 Christian Franke <franke@computer.org>
11568
11569 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
11570
32b0fc49 115712008-02-17 Robert Millan <rmh@aybabtu.com>
11572
11573 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11574 set `first_start' to 0 for non-PC/MSDOS partition maps.
11575
aca63502 115762008-02-16 Robert Millan <rmh@aybabtu.com>
11577
11578 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11579 do not assume partition map is PC/MSDOS before performing checks that
11580 are specific to that layout.
11581
0de8be86 115822008-02-13 Robert Millan <rmh@aybabtu.com>
11583
11584 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
11585 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
11586 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
11587
c3db8364 115882008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
11589
11590 * configure.ac: Only a cosmetic change on the handling of
11591 -fno-stack-protector.
11592
f714229e 115932008-02-12 Alexandre Boeglin <alex@boeglin.org>
11594
c3db8364 11595 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
11596 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
11597 reboot.c.
f714229e 11598 (grub_install_SOURCES): Add halt.mod and reboot.mod.
11599 (halt_mod_SOURCES): New variable.
11600 (halt_mod_CFLAGS): Likewise.
11601 (halt_mod_LDFLAGS): Likewise.
11602 (reboot_mod_SOURCES): Likewise.
11603 (reboot_mod_CFLAGS): Likewise.
11604 (reboot_mod_LDFLAGS): Likewise.
11605
c3db8364 11606 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
11607 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
11608 reboot.c.
f714229e 11609 (halt_mod_SOURCES): Likewise.
11610 (reboot_mod_SOURCES): Likewise.
11611
c3db8364 11612 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
11613 commands/i386/pc/reboot.c by commands/reboot.c.
f714229e 11614 (reboot_mod_SOURCES): Likewise.
11615
11616 * commands/i386/pc/reboot.c: merge this file ...
11617
11618 * commands/ieee1275/reboot.c: ... and this file ...
11619
11620 * commands/reboot.c: ... to this file.
c3db8364 11621 Add some precompiler directive to include the correct header for
11622 each machine.
f714229e 11623
11624 * commands/ieee1275/halt.c: move this file ...
11625
11626 * commands/halt.c: ... to here.
c3db8364 11627 Add some precompiler directive to include the correct header for
11628 each machine.
f714229e 11629
11630 * include/grub/efi/efi.h (grub_reboot): New function declaration.
11631 (grub_halt): Likewise.
11632
11633 * kern/efi/efi.c (grub_reboot): New function.
11634 (grub_halt): Likewise.
11635
c74493e0 116362008-02-12 Robert Millan <rmh@aybabtu.com>
11637
11638 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
11639 /dev (like it is done for /dev/mapper). This doesn't provide support
11640 for EVMS, but at least it is now easy to identify the problem when it
11641 arises.
11642
d0db4b04 116432008-02-11 Robert Millan <rmh@aybabtu.com>
11644
11645 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
11646 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
11647 comparing it with -1, not 0.
11648
bf748642 116492008-02-10 Robert Millan <rmh@aybabtu.com>
11650
11651 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
11652 `disk/lvm.c'.
11653 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11654 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
11655
11656 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
11657 `disk/lvm.c' to the end of the list.
11658 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11659 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
11660
b5db202a 116612008-02-10 Robert Millan <rmh@aybabtu.com>
11662
11663 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
11664 grub_print_error() instead. This will let user know why we're entering
11665 rescue mode.
11666 Based on suggestions from Sam Morris.
11667
83abee31 116682008-02-10 Alexandre Boeglin <alex@boeglin.org>
11669
11670 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
11671 on remaining N args, instead of "--" arg N times.
11672
78d5a08b 116732008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
11674
11675 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
11676 (fill_with_default_glyph): Changed to use unknown_glyph for fill
11677 pattern for unknown glyphs.
11678
68807e5f 116792008-02-09 Robert Millan <rmh@aybabtu.com>
11680
11681 * configure.ac: Probe for `help2man'.
11682 * Makefile.in (builddir): New variable.
11683 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
11684 or otherwise add a few flags/options to it.
11685 (install-local): For every executable utility or script that is
11686 installed, invoke $(HELP2MAN) to install a manpage based on --help
11687 output.
11688
11689 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
11690 that it doesn't prevent --help from working in build tree.
11691
11692 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
11693 with `bug-grub@gnu.org'.
11694 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
11695 * util/update-grub.in (usage): New function.
11696 Implement proper argument check, with support for --help and --version
11697 (as well as existing -y).
11698
116992008-02-09 Christian Franke <franke@computer.org>
0d9ff7f0 11700
11701 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
11702 avoid overwriting previous output.
11703 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
11704
c1962162 117052008-02-09 Robert Millan <rmh@aybabtu.com>
11706
11707 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
11708 drawing the menu.
11709
3dac2e3f 117102008-02-09 Robert Millan <rmh@aybabtu.com>
11711
11712 * commands/sleep.c: New file.
11713 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
11714 (sleep_mod_SOURCES): New variable.
11715 (sleep_mod_CFLAGS): Likewise.
11716 (sleep_mod_LDFLAGS): Likewise.
11717
7a634e08 117182008-02-09 Robert Millan <rmh@aybabtu.com>
11719
11720 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
11721 situations in which we can deduce the RAID size and the superblock
11722 doesn't match it.
11723
b92f0c18 117242008-02-09 Robert Millan <rmh@aybabtu.com>
11725
11726 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
11727 and return a grub_diskmemberlist_t composed of LVM physical volumes.
11728 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
11729
11730 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
11731 and return a grub_diskmemberlist_t composed of physical array members.
11732 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
11733
11734 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
11735 prototype.
11736 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
11737 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
11738 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
11739
11740 * util/grub-probe.c (probe): Move partmap probing code from here ...
11741 (probe_partmap): ... to here.
11742 (probe): Use probe_partmap() once for the disk we're probing, and
11743 additionally, when such disk contains a memberlist() struct member,
11744 once for each disk that is contained in the structure returned by
11745 memberlist().
11746
91a4bf68 117472008-02-09 Robert Millan <rmh@aybabtu.com>
11748
11749 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
11750 environment variable to 'all' in order to obtain debug output from
11751 non-util/ code.
11752 * util/i386/pc/grub-setup.c (main): Likewise.
11753
a96f9caa 117542008-02-08 Robert Millan <rmh@aybabtu.com>
11755
11756 * disk/raid.c (grub_raid_scan_device): Check for
11757 `array->device[sb.this_disk.number]' rather than for
11758 `array->device[sb.this_disk.number]->name', since the latter is not
fe6b695a 11759 guaranteed to be accessible.
a96f9caa 11760
b37a9222 117612008-02-08 Robert Millan <rmh@aybabtu.com>
11762
11763 * disk/raid.c: Update copyright.
11764 * fs/cpio.c: Likewise.
11765 * include/grub/raid.h: Likewise.
11766 * loader/i386/pc/multiboot.c: Likewise.
11767 * util/hostfs.c: Likewise.
11768
5626aee1 117692008-02-08 Robert Millan <rmh@aybabtu.com>
11770
11771 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
11772 to a grub_disk_t array.
11773 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
11774 `device[x]'.
11775 (grub_raid_scan_device): Replace `device[x].name' accesses with
11776 `device[x]->name'. Simplify initialization of `array->device[x]'.
11777
554f0187 117782008-02-08 Robert Millan <rmh@aybabtu.com>
11779
11780 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
11781 grub_dprintf() calls.
11782 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
11783 error message.
11784
1ec8425d 117852008-02-07 Christian Franke <franke@computer.org>
11786
11787 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
11788 instead of fseek and ftell to support large files.
11789 (grub_hostfs_read): Likewise.
11790
f2156fda 117912008-02-07 Robert Millan <rmh@aybabtu.com>
11792
11793 Patch from Jeroen Dekkers.
11794 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
fe6b695a 11795 failure, since successfully reading all array members might not be
f2156fda 11796 required.
11797
9216e0e7 117982008-02-06 Robert Millan <rmh@aybabtu.com>
11799
11800 * util/grub-probe.c (probe): Simplify partmap probing (with the
11801 assumption that the first word up to the underscore equals to
11802 the module name).
11803
b0dfd29a 118042008-02-06 Christian Franke <franke@computer.org>
11805
11806 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
11807 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
11808 last block of a cpio or tar stream.
11809 Check for "TRAILER!!!" instead of any empty data
11810 block to detect last block of a cpio stream.
11811 (grub_cpio_dir): Fix constness of variable np.
11812 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
11813 cpio or tar trailer is detected. This fixes a crash
11814 on open of a non existing file.
11815
c32865bf 118162008-02-05 Bean <bean123ch@gmail.com>
11817
11818 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
11819 address of entry.
11820 (grub_multiboot_load_elf64): Likewise.
11821 (grub_multiboot): Initialize mbi structure.
11822
11823 * util/grub-fstest.c: Don't include unused header file script.h.
11824
fe6b695a 11825 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
c32865bf 11826 of file.
11827 (grub_fstest_SOURCES): Likewise.
11828
409480b7 118292008-02-05 Robert Millan <rmh@aybabtu.com>
11830
11831 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
11832 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
11833 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
11834 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
11835
11836 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
11837 (translation_table): Replace hardcoded values with macros
11838 provided by `<grub/term.h>'.
11839
11840 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
11841 (keyboard_map): Correct/add a few values, with macros provided
11842 by `<grub/term.h>'.
11843 (keyboard_map_shift): Zero values that don't differ from their
11844 `keyboard_map' equivalents.
11845 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
11846 Discard the second scan code that is always sent by Caps lock.
11847 Only use `keyboard_map_shift' when it provides a non-zero value,
11848 otherwise fallback to `keyboard_map'.
11849
99fadbaa 118502008-02-04 Bean <bean123ch@gmail.com>
11851
11852 * Makefile.in (enable_grub_fstest): New variable.
11853
11854 * conf/common.rmk (grub_fstest_init.lst): New rule.
11855 (grub_fstest_init.h): Likewise.
11856 (grub_fstest_init.c): Likewise.
11857 (util/grub-fstest.c_DEPENDENCIES): New variable.
11858 (grub_fstest_SOURCES): Likewise.
11859
11860 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
11861
11862 * util/grub-fstest.c: New file.
11863
bf567c50 118642008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11865
11866 Make grub-setup handle a separate root device.
f19dbdb7 11867
bf567c50 11868 * util/i386/pc/grub-setup.c (setup): Always open the root device,
11869 so that the root device can be compared with the destination
11870 device.
11871 When embedding the core image, if the root and destination devices
11872 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
11873 0xFF.
11874 When not embedding, set ROOT_DRIVE to 0xFF.
f19dbdb7 11875
9be6b98b 118762008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11877
11878 Add support for having a grub directory in a different drive. This
11879 is still only the data handling part.
f19dbdb7 11880
9be6b98b 11881 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
11882 (codestart): Save %dh in GRUB_ROOT_DRIVE.
11883 (grub_root_drive): New variable.
11884
11885 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
11886 instead of GRUB_BOOT_DRIVE to construct a device name. Set
11887 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
11888 as it was.
11889
11890 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
11891
11892 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
11893 macro.
11894 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
11895
11896 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
11897 is bogus, because PXE booting does not specify any drive
11898 correctly.
11899
11900 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
11901 am not sure if this is really correct.
11902
11903 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
11904 is always identical to the boot drive when booting from a CD.
11905
11906 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
11907 longer.
11908 (root_drive): New variable.
11909 (real_start): Unconditionally set %dh to ROOT_DRIVE.
11910 (setup_sectors): Push %dx right after popping it, because %dh will
11911 be modified later.
11912 (copy_buffer): Restore %dx.
11913
e0ca0677 119142008-02-03 Robert Millan <rmh@aybabtu.com>
11915
11916 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
11917 use `cdboot.img' for cdrom images.
11918
3b3f6629 119192008-02-03 Robert Millan <rmh@aybabtu.com>
11920
11921 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
11922 only setup gfxterm when `font' command has succeeded.
11923
d42b3672 119242008-02-03 Robert Millan <rmh@aybabtu.com>
11925
11926 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
11927 (grub_rescue_cmd_multiboot_loader)
11928 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
11929
fa370ea6 119302008-02-03 Pavel Roskin <proski@gnu.org>
11931
e0c5dacb 11932 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
fa370ea6 11933 %edx and %esi from stack only after grub_gate_a20() is called.
11934 grub_gate_a20() clobbers %edx.
11935
f2a76e1d 119362008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11937
11938 * configure.ac (AC_INIT): Bumped to 1.96.
11939
11940 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
11941 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
11942 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
11943 video/readers/png.c.
11944
90fd32d1 119452008-02-03 Bean <bean123ch@gmail.com>
9be665dd 11946
11947 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
11948 (cdboot_img_SOURCES): New variable.
11949 (cdboot_img_ASFLAGS): New variable.
11950 (cdboot_img_LDFLAGS): New variable.
11951
11952 * boot/i386/pc/cdboot.S: New file.
11953
11954 * disk/i386/pc/biosdisk.c (cd_start): New variable.
11955 (cd_count): Likewise.
11956 (grub_biosdisk_get_drive): Add support for cd device.
11957 (grub_biosdisk_call_hook): Likewise.
11958 (grub_biosdisk_iterate): Likewise.
11959 (grub_biosdisk_open): Likewise.
11960 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
11961 (grub_biosdisk_rw): Support reading from cd device.
11962 (GRUB_MOD_INIT): Iterate cd devices.
11963
11964 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
11965 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
11966 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
11967
11968 * kern/i386/pc/init.c (make_install_device): Check for cd device.
11969
4020aa53 119702008-02-02 Robert Millan <rmh@aybabtu.com>
11971
11972 * commands/read.c: New file.
11973 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
11974 (read_mod_SOURCES): New variable.
11975 (read_mod_CFLAGS): Likewise.
11976 (read_mod_LDFLAGS): Likewise.
11977
e03a1132 119782008-02-02 Robert Millan <rmh@aybabtu.com>
11979
11980 * normal/main.c (grub_normal_execute): Check for `menu->size' when
11981 determining whether menu has to be displayed.
11982
58c69220 119832008-02-02 Marco Gerards <marco@gnu.org>
11984
11985 * bus/pci.c: New file.
11986
11987 * include/grub/pci.h: Likewise.
11988
11989 * include/grub/i386/pc/pci.h: Likewise.
11990
11991 * commands/lspci.c: Likewise.
11992
11993 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
11994 `lspci.mod'.
11995 (pci_mod_SOURCES): New variable.
11996 (pci_mod_CFLAGS): Likewise.
11997 (pci_mod_LDFLAGS): Likewise.
11998 (lspci_mod_SOURCES): Likewise.
11999 (lspci_mod_CFLAGS): Likewise.
f19dbdb7 12000 (lspci_mod_LDFLAGS): Likewise.
58c69220 12001
c004e1b4 120022008-02-02 Bean <bean123ch@gmail.com>
12003
12004 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
12005 (grub_ufs_get_file_block): Fix indirect block calculation problem.
12006
12007 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
12008 (grub_xfs_btree_node): New structure.
12009 (grub_xfs_btree_root): New structure.
12010 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
12011 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
12012 (GRUB_XFS_EXTENT_BLOCK): Likewise.
12013 (GRUB_XFS_EXTENT_SIZE): Likewise.
12014 (grub_xfs_read_block): Support btree format type.
12015 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
12016 Use directory block as basic unit.
12017
12018 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
12019
12020 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
12021 __attribute__ ((__regparm__ (1))).
12022
f95562bf 120232008-02-01 Robert Millan <rmh@aybabtu.com>
12024
12025 Correct a mistake in previous commit.
12026
12027 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
12028 top.
12029 (normal/command.c_DEPENDENCIES): New variable.
12030
7d31f41f 120312008-02-01 Robert Millan <rmh@aybabtu.com>
12032
12033 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
12034 top.
12035 (normal/command.c_DEPENDENCIES): New variable.
12036 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
12037 * conf/i386-ieee1275.rmk: Likewise.
12038 * conf/i386-linuxbios.rmk: Likewise.
12039 * conf/i386-pc.rmk: Likewise.
12040 * conf/sparc64-ieee1275.rmk: Likewise.
12041 * conf/powerpc-ieee1275.rmk: Likewise.
12042 (grub_emu_SOURCES): Add `fs/fshelp.c'.
12043
12044 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
12045
60b6be74 120462008-02-01 Robert Millan <rmh@aybabtu.com>
12047
12048 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
12049 call at beginning of function.
12050
078522ab 120512008-01-31 Pavel Roskin <proski@gnu.org>
12052
12053 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
d2c11005 12054 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
12055 (grub_mkrescue_SOURCES): Likewise.
078522ab 12056 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
12057
ccaa8a5f 120582008-01-30 Robert Millan <rmh@aybabtu.com>
12059
12060 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
12061 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
12062 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
12063 (grub_probe_SOURCES): ... to here.
12064
12065 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
12066 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
12067 * conf/i386-ieee1275.rmk: Likewise.
12068 * conf/i386-linuxbios.rmk: Likewise.
12069 * conf/powerpc-ieee1275.rmk: Likewise.
12070
ae5a9cd7 120712008-01-30 Tristan Gingold <gingold@free.fr>
12072
12073 * kern/rescue.c: Silently accept empty lines.
12074
70bc2ef2 120752008-01-29 Bean <bean123ch@gmail.com>
12076
12077 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
12078 (real_code_2): Code cleanup and change comment style.
12079 (move_memory): Avoid using 32-bit address mode.
12080
6a4d50ea 120812008-01-29 Bean <bean123ch@gmail.com>
12082
12083 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
12084 (png_mod_SOURCES): New variable.
12085 (png_mod_CFLAGS): Likewise.
12086 (png_mod_LDFLAGS): Likewise.
12087
12088 * video/readers/png.c: New file.
12089
11cc30ac 120902008-01-28 Robert Millan <rmh@aybabtu.com>
12091
12092 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
12093 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
12094 `ifndef GRUB_MOD_GAP' hack.
12095 * util/elf/grub-mkimage.c (add_segments): Likewise.
12096
3abc589f 120972008-01-27 Robert Millan <rmh@aybabtu.com>
12098
12099 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
12100 `GRUB_MOD_GAP' for platforms in which it's not defined.
962ca133 12101 * util/elf/grub-mkimage.c (add_segments): Likewise.
3abc589f 12102
e1907778 121032008-01-27 Robert Millan <rmh@aybabtu.com>
12104
12105 Get grub-emu to build again (including parallel builds).
12106
12107 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
12108 Split into ...
12109 (util/grub-emu.c_DEPENDENCIES): ... this, ...
12110 (normal/execute.c_DEPENDENCIES): ... this, ...
12111 (grub-emu_DEPENDENCIES): ... and this.
12112
12113 * conf/i386-efi.rmk: Likewise.
12114 * conf/i386-linuxbios.rmk: Likewise.
12115 * conf/i386-ieee1275.rmk: Likewise.
12116 * conf/powerpc-ieee1275.rmk: Likewise.
12117 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
12118
2216b101 121192008-01-27 Robert Millan <rmh@aybabtu.com>
12120
12121 * NEWS: Add a few items.
12122
f75172d9 121232008-01-27 Robert Millan <rmh@aybabtu.com>
12124
12125 Fix parallel builds with grub-emu. Based on earlier commit for
12126 grub-probe and grub-setup.
12127
12128 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12129 (util/grub-emu.c_DEPENDENCIES): ... this.
12130 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12131 (util/grub-emu.c_DEPENDENCIES): ... this.
12132 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12133 (util/grub-emu.c_DEPENDENCIES): ... this.
12134 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12135 (util/grub-emu.c_DEPENDENCIES): ... this.
12136 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12137 (util/grub-emu.c_DEPENDENCIES): ... this.
12138
3f51de77 121392008-01-27 Pavel Roskin <proski@gnu.org>
12140
12141 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
12142 to create a gap between _end and the modules added to the image
12143 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
12144 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
12145 * util/elf/grub-mkimage.c (add_segments): Likewise.
12146
2033f53e 121472008-01-26 Pavel Roskin <proski@gnu.org>
12148
12149 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
12150 just return an error.
12151
22da1f6f 121522008-01-26 Bean <bean123ch@gmail.com>
12153
12154 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
12155 (grub_reiserfs_get_item): Save offset of the next item.
12156 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
12157
2a9525e6 121582008-01-25 Robert Millan <rmh@aybabtu.com>
12159
12160 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
12161 make all filesystem sources appear together (possibly fixing omissions
12162 while at it).
12163 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
12164 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12165 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
12166 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12167
12168 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
12169 add `kern/file.c'.
12170 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
12171 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12172 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
12173 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12174
12175 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
12176 (probe): Add a sanity check to make sure of our ability to read
12177 requested files when probing for filesystem type.
12178
12179 * genmk.rb: Update copyright year (2007).
12180
12181 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
12182 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
12183 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
12184 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
12185 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
12186 : Remove function prototypes.
12187
b95f71b5 121882008-01-25 Robert Millan <rmh@aybabtu.com>
12189
12190 Revert my previous commits (based on wrong assumption of how grub_errno
12191 works).
12192
fe6b695a 12193 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
b95f71b5 12194 * kern/file.c (grub_file_open): Likewise.
12195
d08bbb49 121962008-01-24 Pavel Roskin <proski@gnu.org>
12197
12198 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
12199 that hang if GRUB tries to setup colors.
12200 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
12201 colors for firmwares that don't support it.
12202 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
12203 Recognize Open Hack'Ware, set flags to work around its
12204 limitations.
12205
605e36ed 122062008-01-24 Robert Millan <rmh@aybabtu.com>
12207
12208 * kern/file.c (grub_file_open): Do not account previous failures of
12209 unrelated functions when grub_errno is checked for.
12210 Reported by Oleg Strikov.
12211
bac332a1 122122008-01-24 Bean <bean123ch@gmail.com>
12213
12214 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
12215 (grub_ufs_sblock): New member volume name.
12216 (grub_ufs_find_file): Fix string copy bug.
12217 (grub_ufs_label): Implement this function properly.
12218
12219 * fs/hfs.c (grub_hfs_cnid_type): New enum.
12220 (grub_hfs_iterate_records): Use the correct file number for extents
12221 and catalog file. Fix problem in next index calculation.
12222 (grub_hfs_find_node): Replace recursive function call with loop.
12223 (grub_hfs_iterate_dir): Replace recursive function call with loop.
12224
15c80c09 122252008-01-23 Robert Millan <rmh@aybabtu.com>
12226
12227 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
12228 `<grub/symbol.h>' and `<grub/multiboot.h>'.
12229 (grub_multiboot2_real_boot): New function prototype.
12230
12231 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
12232 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
12233
12234 * kern/i386/ieee1275/init.c (grub_os_area_addr)
12235 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
12236
305338fd 122372008-01-23 Robert Millan <rmh@aybabtu.com>
12238
12239 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
12240 #ifdef'ed out grub_printf().
12241
3ea52685 122422008-01-23 Robert Millan <rmh@aybabtu.com>
12243
12244 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
12245 grub_dprintf calls, since they make "debug=all" mode unusable.
12246 (grub_console_checkkey): Likewise.
12247
5882ae4b 122482008-01-23 Robert Millan <rmh@aybabtu.com>
12249
12250 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
12251 `term/i386/pc/at_keyboard.c'.
12252 (pkglib_MODULES): Add `serial.mod'.
12253 (serial_mod_SOURCES): New variable.
12254 (serial_mod_CFLAGS): Likewise.
12255 (serial_mod_LDFLAGS): Likewise.
12256
12257 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
12258 `<grub/powerpc/ieee1275/console.h>'.
12259 (grub_keyboard_controller_init): New function prototype.
12260 (grub_console_checkkey): Likewise.
12261 (grub_console_getkey): Likewise.
12262
12263 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
12264 keyboard on i386.
12265
12266 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
12267 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
12268
06ab5303 122692008-01-23 Robert Millan <rmh@aybabtu.com>
12270
12271 * kern/i386/pc/init.c (make_install_device): When memdisk image is
12272 present, "(memdisk)/boot/grub" becomes the default prefix.
12273
12274 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
12275 a memdisk tarball with all the modules. Add --overlay=DIR option that
12276 allows users to overlay additional files into the image.
12277
dbb475a4 122782008-01-23 Robert Millan <rmh@aybabtu.com>
12279
12280 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
12281 and `machine/memory.h'.
12282 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
12283 (_multiboot_mod_SOURCES): New variable.
12284 (_multiboot_mod_CFLAGS): Likewise.
12285 (_multiboot_mod_LDFLAGS): Likewise.
12286 (multiboot_mod_SOURCES): Likewise.
12287 (multiboot_mod_CFLAGS): Likewise.
12288 (multiboot_mod_LDFLAGS): Likewise.
12289
12290 * include/grub/i386/ieee1275/loader.h: New file.
12291
12292 * include/grub/i386/ieee1275/machine.h: Likewise.
12293
12294 * include/grub/i386/ieee1275/memory.h: Likewise.
12295
12296 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
12297 variable declaration.
12298 (grub_os_area_size): Likewise.
12299
12300 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
12301 (grub_lower_mem, grub_upper_mem): New variables.
12302 (grub_stop_floppy): New function (just to make
12303 grub_multiboot2_real_boot() happy).
12304
12305 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
12306 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
12307 (grub_stop): New function.
12308 Include `"../realmode.S"' and `"../loader.S"'.
12309
12310 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
12311 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
12312
12313 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
12314 rely on grub_multiboot2_real_boot() for final boot.
12315
25638629 123162008-01-22 Robert Millan <rmh@aybabtu.com>
12317
12318 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
12319 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
12320 device that doesn't look like an SD card.
12321 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
12322 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
12323 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
12324 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
12325 found.
12326
9dad816d 123272008-01-22 Robert Millan <rmh@aybabtu.com>
12328
12329 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
12330 avoid claiming over our own code.
12331
34842f2d 123322008-01-22 Bean <bean123ch@gmail.com>
12333
12334 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
12335 (jpeg_mod_SOURCES): New variable.
12336 (jpeg_mod_CFLAGS): Likewise.
12337 (jpeg_mod_LDFLAGS): Likewise.
12338
12339 * video/readers/jpeg.c : New file.
12340
44023a28 123412008-01-22 Bean <bean123ch@gmail.com>
12342
12343 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
12344 there are no more items.
12345
bc2d8ac6 123462008-01-21 Robert Millan <rmh@aybabtu.com>
12347
12348 * kern/mm.c (grub_mm_init_region): Improve debug message.
12349
261bd4bc 123502008-01-21 Robert Millan <rmh@aybabtu.com>
12351
12352 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
12353 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
12354 address.
12355 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
12356 a C macro.
12357 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
12358 Indicates start of upper memory.
12359 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
12360 (generate_image): Abort when image size is big enough to corrupt
12361 upper memory.
12362
12363 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
12364 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
12365 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12366 instead of hardcoding 0xA0000.
12367 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
12368 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12369 instead of hardcoding 0xA0000.
12370
f970b55e 123712008-01-21 Robert Millan <rmh@aybabtu.com>
12372
12373 * disk/memdisk.c (memdisk_size): New variable.
12374 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
12375 `memdisk_size'.
12376 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
12377 image to dynamic memory.
12378 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
12379 `memdisk_size'. Free memdisk block.
12380
1a8b0526 123812008-01-21 Robert Millan <rmh@aybabtu.com>
12382
12383 Fix detection of very small filesystems (like tar).
12384
12385 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
12386 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
12387 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
12388 a problem with this disk).
12389
6e9b4aab 123902008-01-21 Robert Millan <rmh@aybabtu.com>
12391
12392 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
12393 on grub_biosdisk_rw_standard() error.
12394
0d8837b2 123952008-01-21 Robert Millan <rmh@aybabtu.com>
12396
12397 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
12398 recent changes.
12399 * kern/elf.c: Likewise.
12400 * kern/ieee1275/ieee1275.c: Likewise.
12401 * kern/powerpc/ieee1275/openfw.c: Likewise.
12402 * term/ieee1275/ofconsole.c: Likewise.
12403
ffd36e34 124042008-01-21 Robert Millan <rmh@aybabtu.com>
12405
12406 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
12407
3f0093d0 12408 * include/grub/kernel.h (grub_arch_memdisk_addr)
12409 (grub_arch_memdisk_size): Moved from here ...
ffd36e34 12410
3f0093d0 12411 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
12412 (grub_arch_memdisk_size): ... to here.
ffd36e34 12413
6c391b21 124142008-01-21 Robert Millan <rmh@aybabtu.com>
12415
12416 Mostly based on bugfix from Bean.
12417
12418 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
12419 attribute with hook() parameter.
12420 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
12421 declaration.
12422 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
12423 attribute with hook() parameter.
12424 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
12425 declaration.
12426
55a581dc 124272008-01-21 Robert Millan <rmh@aybabtu.com>
12428
12429 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
12430 (pkglib_MODULES): Add `memdisk.mod'.
12431 (memdisk_mod_SOURCES): New variable.
12432 (memdisk_mod_CFLAGS): Likewise.
12433 (memdisk_mod_LDFLAGS): Likewise.
12434
12435 * disk/memdisk.c: New file.
12436
12437 * include/grub/disk.h (grub_disk_dev_id): Add
12438 `GRUB_DISK_DEVICE_MEMDISK_ID'.
12439
12440 * include/grub/i386/pc/kernel.h
12441 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
12442 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
12443 (grub_kernel_image_size): New variable declaration.
12444 (grub_total_module_size): Likewise.
12445 (grub_memdisk_image_size): Likewise.
12446
12447 * include/grub/i386/pc/memory.h
12448 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
12449
12450 * include/grub/kernel.h: Include `<grub/symbol.h>'.
12451 (grub_arch_memdisk_addr): New variable declaration.
12452 (grub_arch_memdisk_size): Likewise.
12453
12454 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
12455 (grub_arch_memdisk_size): Likewise.
12456
12457 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
12458 (codestart): Replace hardcoded `0x100000' with
12459 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
12460
12461 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
12462 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
12463 not NULL, append the contents of the file it refers to, at the end of
12464 the compressed kernel image. Initialize `grub_memdisk_image_size'
12465 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
12466 (options): Add "memdisk"|'m' option.
12467 (main): Parse --memdisk|-m option, and pass user-provided path as
12468 parameter to generate_image().
12469
3d7f54c9 124702008-01-20 Robert Millan <rmh@aybabtu.com>
12471
12472 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
12473 grub_dprintf() calls from here ...
12474 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
12475
0bf74728 124762008-01-20 Robert Millan <rmh@aybabtu.com>
12477
12478 Fix detection of "real mode" when /options/real-mode? doesn't exist.
12479
12480 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
12481 declaration.
12482 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
12483 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
12484 `GRUB_IEEE1275_FLAG_REAL_MODE'.
fe6b695a 12485 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
0bf74728 12486 property).
12487 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
12488 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
12489
33bf70a7 124902008-01-19 Robert Millan <rmh@aybabtu.com>
12491
fe6b695a 12492 Get rid of confusing function (superseded by
33bf70a7 12493 `grub_ieee1275_get_integer_property')
12494 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
12495 prototype.
12496 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
12497 function.
12498 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
12499 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
fe987087 12500 in native endianness from grub_ieee1275_get_integer_property().
33bf70a7 12501
e2da7d26 125022008-01-19 Robert Millan <rmh@aybabtu.com>
12503
12504 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
12505 command after "shut-down", since implementations differ on which
12506 the command for halt is.
12507
59f1fd8d 125082008-01-19 Robert Millan <rmh@aybabtu.com>
12509
12510 * include/grub/i386/linuxbios/console.h: Add header protection.
12511 (grub_keyboard_controller_init): New function prototype.
12512 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
12513 (KEYBOARD_COMMAND_READ): Likewise.
12514 (KEYBOARD_COMMAND_WRITE): Likewise.
12515 (KEYBOARD_SCANCODE_SET1): Likewise.
12516 (grub_keyboard_controller_write): New function.
12517 (grub_keyboard_controller_read): Likewise.
12518 (grub_keyboard_controller_init): Likewise.
12519
12520 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
12521 (grub_console_init): On coreboot/LinuxBIOS, call
12522 grub_keyboard_controller_init().
12523
5f5a7c15 125242008-01-19 Robert Millan <rmh@aybabtu.com>
12525
12526 PowerPC changes provided by Pavel Roskin.
12527
12528 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
12529 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
12530 don't rely on cmain() doing it.
12531 * kern/i386/ieee1275/startup.S (_start): Store %eax in
12532 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
12533
1210e168 125342008-01-16 Robert Millan <rmh@aybabtu.com>
12535
12536 * include/grub/i386/linuxbios/memory.h
12537 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
12538 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
12539 receive `table_header' as argument. Instead, probe for it in the
12540 known memory ranges where it can be present.
12541 (grub_available_iterate): Do not pass a fixed `table_header' address
12542 to grub_linuxbios_table_iterate().
12543
3d04eab8 125442008-01-15 Robert Millan <rmh@aybabtu.com>
12545
12546 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
12547 * conf/i386-ieee1275.rmk: New file.
12548 * include/grub/i386/ieee1275/console.h: Likewise.
12549 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
12550 * include/grub/i386/ieee1275/kernel.h: Likewise.
12551 * include/grub/i386/ieee1275/time.h: Likewise.
12552 * kern/i386/ieee1275/init.c: Likewise.
12553 * kern/i386/ieee1275/startup.S: Likewise.
12554
d1bc1b73 125552008-01-15 Robert Millan <rmh@aybabtu.com>
12556
12557 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
12558 when pointers are 32-bit (but still do set it to one when they are
12559 64-bit).
12560
66a65807 125612008-01-15 Robert Millan <rmh@aybabtu.com>
12562
12563 * include/grub/ieee1275/ieee1275.h
12564 (grub_ieee1275_get_integer_property): New function prototype.
12565
12566 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
12567 (grub_ieee1275_get_integer_property): New function. Wraps around
fe987087 12568 grub_ieee1275_get_property() to handle endianness.
66a65807 12569
12570 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
12571 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
fe6b695a 12572 where appropriate.
66a65807 12573 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
12574 (grub_map): Likewise.
12575 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
12576
a83ccafd 125772008-01-15 Bean <bean123ch@gmail.com>
12578
12579 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
12580 (grub_script_execute_cmdline): Reset grub_errno.
12581
12582 * normal/main.c (read_config_file): Reset grub_errno.
12583
12584 * normal/parse.y (script_init): New.
12585 (script): Move function and menuentry here.
12586 (delimiter): New.
12587 (command): Add delimiter at the end of command.
12588 (commands): Adjust to match the new command.
12589 (commandblock): Remove grub_script_lexer_record_start.
f19dbdb7 12590 (menuentry): Add grub_script_lexer_record_start, use the new commands.
a83ccafd 12591 (if): Use the new commands.
12592
12593 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
12594
df6ecfc6 125952008-01-15 Robert Millan <rmh@aybabtu.com>
12596
12597 * normal/menu.c (run_menu): Move timeout message from here ...
12598 (print_timeout): ... to here.
12599 (run_menu): Use print_timeout() once during initial draw to print
12600 the whole message, and again in every clock tick to update only
12601 the number of seconds.
12602
87ae25eb 126032008-01-15 Robert Millan <rmh@aybabtu.com>
12604
12605 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
12606 actual size of `available' from grub_ieee1275_get_property(), and
12607 restrict parsing to that bound.
12608
47bf09a4 126092008-01-15 Christian Franke <franke@computer.org>
12610
12611 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
12612 (argp_program_version): Remove variable.
12613 (argp_program_bug_address): Likewise.
12614 (options): Convert from struct argp_option to struct option.
12615 (struct arguments): Remove.
12616 (parse_opt): Remove.
12617 (usage): New function.
12618 (main): Replace struct args members by simple variables.
12619 Replace argp_parse() by getopt_long().
12620 Add switch to evaluate options.
12621 Add missing "(...)" around root_dev in prefix string.
12622
c86f1469 126232008-01-14 Robert Millan <rmh@aybabtu.com>
12624
12625 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
12626 for grub_ieee1275_exit(), in order to improve portability.
12627
e622c559 126282008-01-14 Robert Millan <rmh@aybabtu.com>
12629
12630 * util/grub.d/10_linux.in (prefix): Define.
12631 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
12632
44cb1ec8 126332008-01-13 Pavel Roskin <proski@gnu.org>
12634
12635 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
12636 grub_errno if no errors have been detected.
12637
1eb8c802 126382008-01-12 Robert Millan <rmh@aybabtu.com>
12639
12640 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
12641 (grub_util_get_dev_abstraction): New function prototype.
12642
12643 * util/getroot.c: Include `<grub/util/getroot.h>'
12644 (grub_util_get_grub_dev): Move detection of abstraction type to ...
12645 (grub_util_get_dev_abstraction): ... here (new function).
12646
12647 * util/grub-probe.c: Convert PRINT_* to an enum. Add
12648 `PRINT_ABSTRACTION'.
12649 (probe): Probe for abstraction type when requested.
12650 (main): Understand `--target=abstraction'.
12651
12652 * util/i386/efi/grub-install.in: Add abstraction module to core
12653 image when it is found to be necessary.
12654 * util/i386/pc/grub-install.in: Likewise.
12655 * util/powerpc/ieee1275/grub-install.in: Likewise.
12656
12657 * util/update-grub_lib.in (font_path): Return system path without
12658 converting to GRUB path.
12659 * util/update-grub.in: Convert system path returned by font_path()
12660 to a GRUB path. Use `grub-probe -t abstraction' to determine what
12661 abstraction module is needed for loading fonts (if any). Export
12662 that as `GRUB_PRELOAD_MODULES'.
12663 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
12664 insmod commands).
12665
52bd3de9 126662008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
12667
12668 Remove some unused code from reiserfs.
f19dbdb7 12669
52bd3de9 12670 * fs/reiserfs.c (struct grub_reiserfs_key)
12671 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
12672 (struct grub_reiserfs_node_body): Removed.
12673 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12674 Likewise.
12675 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12676 Likewise.
12677 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12678 Likewise.
12679 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12680 Likewise.
12681 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12682 Likewise.
12683 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
12684 Likewise.
12685 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12686 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12687 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12688
2f80039d 126892008-01-10 Robert Millan <rmh@aybabtu.com>
12690
12691 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
12692 Determines if a file is garbage left by packaging systems, etc.
12693 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
12694 for processing /etc/grub.d scripts.
12695 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
12696 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
12697 as a condition for processing Linux images.
12698
87888032 126992008-01-10 Pavel Roskin <proski@gnu.org>
12700
12701 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
12702 to compile reiserfs.c on PowerPC.
12703
7e54fced 127042008-01-10 Robert Millan <rmh@aybabtu.com>
de9993e0 12705
12706 * kern/device.c (grub_device_iterate): Do not abort device iteration
12707 when one of the devices cannot be opened.
12708 * kern/disk.c (grub_disk_open): Do not account previous failures of
12709 unrelated functions when grub_errno is checked for.
12710
5aa541e6 127112008-01-08 Robert Millan <rmh@aybabtu.com>
12712
12713 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
12714 `! grub_linux_is_bzimage', change order of address comparison to make
12715 it more intuitive, and improve "too big zImage" error message.
12716
7076340d 127172008-01-08 Robert Millan <rmh@aybabtu.com>
12718
12719 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
12720 `$(update-grub_DATA)'.
12721 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
12722 targets.
12723
9ca70333 127242008-01-07 Robert Millan <rmh@aybabtu.com>
12725
12726 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
12727 which instruction is modified by grub-setup during installation
12728 (since it wasn't obvious by only looking at this file).
12729
38ccf575 127302008-01-07 Robert Millan <rmh@aybabtu.com>
12731
12732 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
12733 listing actual TODO items.
12734
f5db4291 127352008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12736
868967cf 12737 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
12738 correctly.
12739 (grub_reiserfs_get_key_offset): Likewise.
12740 (grub_reiserfs_set_key_offset): Likewise.
12741 (grub_reiserfs_set_key_type): Likewise.
fe6b695a 12742 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
868967cf 12743
12744 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
12745 better to remove the bitfield version completely.
f19dbdb7 12746
868967cf 127472008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 12748
f5db4291 12749 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
12750 allocated from the heap, due to the fshelp implementation.
12751 (grub_reiserfs_dir): Free NODE, due to the same reason.
12752
492e6d9d 127532008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12754
12755 Mostly from Vincent Pelletier:
f19dbdb7 12756
492e6d9d 12757 * fs/reiserfs.c: New file.
f19dbdb7 12758
492e6d9d 12759 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
12760 (reiserfs_mod_SOURCES): New variable.
12761 (reiserfs_mod_CFLAGS): Likewise.
12762 (reiserfs_mod_LDFLAGS): Likewise.
12763
12764 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
12765 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
12766 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
12767 normal/color.c.
12768
9ce3e7c1 127692008-01-06 Robert Millan <rmh@aybabtu.com>
12770
12771 * normal/color.c: Remove `<grub/env.h>'.
12772
f3b58148 127732008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
12774
12775 * include/grub/normal.h: Include <grub/env.h>.
12776
7ac3bcfa 127772008-01-05 Robert Millan <rmh@aybabtu.com>
12778
12779 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
12780 usage example with `(hd0,1)'.
fb358190 12781 Reported by Samuel Thibault.
7ac3bcfa 12782
c8ee99d7 127832008-01-05 Robert Millan <rmh@aybabtu.com>
12784
12785 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
12786 (grub_linux_boot_zimage): Rename to ...
12787 (grub_linux_boot): ... this.
12788 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
12789 (grub_linux_boot_zimage): Conditionalize zImage copy.
12790
12791 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
12792 (grub_linux_boot_bzimage): Remove prototype.
12793 (grub_linux_boot_zimage): Rename to ...
12794 (grub_linux_boot): ... this.
12795
12796 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
12797 (grub_linux_boot): Remove function.
12798
0ece25b1 127992008-01-05 Robert Millan <rmh@aybabtu.com>
12800
12801 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
12802 (grub_env_write_color_highlight): Likewise.
12803 (grub_wait_after_message): Likewise.
12804
12805 * normal/color.c: New file.
12806
12807 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12808 (normal_mod_DEPENDENCIES): Likewise.
12809
12810 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12811 (normal_mod_DEPENDENCIES): Likewise.
12812
12813 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12814 (normal_mod_DEPENDENCIES): Likewise.
12815
12816 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12817 (normal_mod_DEPENDENCIES): Likewise.
12818
12819 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
12820 for waiting after a message is printed.
12821 * normal/main.c (read_config_file): Likewise.
12822 (grub_normal_init): Register grub_env_write_color_normal() and
12823 grub_env_write_color_highlight() hooks. Mark `color_normal' and
12824 `color_highlight' variables as global.
12825
12826 * normal/menu.c (grub_wait_after_message): New function.
12827 (grub_color_menu_normal): New variable. Replaces ...
12828 (GRUB_COLOR_MENU_NORMAL): ... this macro.
12829 (grub_color_menu_highlight): New variable. Replaces ...
12830 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
12831 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
12832 `GRUB_TERM_COLOR_STANDARD'.
12833 (print_message): Use `grub_setcolorstate' to reload colors. Rename
12834 `normal_code' and `highlight_code' to `old_color_normal' and
12835 `old_color_highlight', respectively.
12836 (grub_menu_init_page): Update colors when drawing the menu, based on
12837 `menu_color_normal' and `menu_color_highlight' variables.
12838 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
12839 a message is printed.
12840
182dd4e5 128412008-01-05 Robert Millan <rmh@aybabtu.com>
12842
12843 * kern/env.c (grub_env_context_open): Propagate hooks for global
12844 variables to new context.
12845
12846 * kern/main.c (grub_set_root_dev): Export `root' variable.
12847
ddf8f6ad 128482008-01-05 Robert Millan <rmh@aybabtu.com>
12849
12850 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
fe6b695a 12851 discs unconditionally, since udev and others have options to provide
ddf8f6ad 12852 them.
12853
d8b43d9b 128542008-01-05 Robert Millan <rmh@aybabtu.com>
12855
12856 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
12857
2bff2de3 128582008-01-04 Christian Franke <franke@computer.org>
12859
12860 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
12861 of eisa_mmap.
12862
97eab917 128632008-01-03 Pavel Roskin <proski@gnu.org>
12864
12865 * kern/i386/linuxbios/init.c: Put "void" to all function
12866 declarations with no arguments.
12867 * kern/powerpc/ieee1275/init.c: Likewise.
12868 * term/i386/pc/at_keyboard.c: Likewise.
12869 * term/i386/pc/vga_text.c: Likewise.
12870 * util/grub-mkdevicemap.c: Likewise.
12871
b9416d00 128722008-01-02 Robert Millan <rmh@aybabtu.com>
12873
12874 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
12875 message when loaded image is out of bounds.
12876 (grub_multiboot_load_elf64): Likewise.
12877
92695df9 128782008-01-02 Pavel Roskin <proski@gnu.org>
12879
12880 * util/grub.d/10_linux.in: Try version without ".old" when
12881 looking for initrd. It's better to use initrd from the newer
12882 kernel of the same version than no initrd at all.
12883
d98d9cad 128842008-01-01 Robert Millan <rmh@aybabtu.com>
12885
12886 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
12887
dbfdce36 128882008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
12889
f19dbdb7 12890 * include/grub/video.h: Added grub_video_unmap_color and
dbfdce36 12891 grub_video_get_active_render_target.
12892 (grub_video_adapter): Added unmap_color and get_active_render_target.
12893
f19dbdb7 12894 * video/video.c: Added grub_video_unmap_color and
dbfdce36 12895 grub_video_get_active_render_target.
12896 (grub_video_get_info): Changed method to accept NULL pointer as an
12897 argument to allow detection of active video adapter.
12898
12899 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
12900 grub_video_vbe_unmap_color_int.
12901 Added grub_video_vbe_unmap_color and
12902 grub_video_vbe_get_active_render_target.
12903 (grub_video_vbe_adapter): Added unmap_color and
12904 get_active_render_target.
12905
f19dbdb7 12906 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
dbfdce36 12907 with grub_video_vbe_unmap_color_int.
12908
12909 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
12910 (DEFAULT_NORMAL_COLOR): Likewise.
12911 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
12912 (DEFAULT_FG_COLOR): Removed.
12913 (DEFAULT_BG_COLOR): Likewise.
12914 (DEFAULT_CURSOR_COLOR): Changed value.
12915 (grub_virtual_screen): Added standard_color_setting,
12916 normal_color_setting, highlight_color_setting and term_color.
12917 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
12918 (bitmap_width): Added.
12919 (bitmap_height): Likewise.
12920 (bitmap): Likewise.
12921 (set_term_color): Likewise.
12922 (grub_virtual_screen_setup): Changed to use new terminal coloring
12923 settings.
12924 (grub_gfxterm_init): Added init for bitmap.
12925 (grub_gfxterm_fini): Added destroy for bitmap.
12926 (redraw_screen_rect): Updated to use background bitmap and new
12927 terminal coloring.
12928 (scroll_up): Added optimization for case when there is no bitmap.
12929 (grub_gfxterm_cls): Fixed to use correct background color.
12930 (grub_virtual_screen_setcolorstate): Changed to use new terminal
12931 coloring.
12932 (grub_virtual_screen_setcolor): Likewise.
12933 (grub_virtual_screen_getcolor): Added.
12934 (grub_gfxterm_background_image_cmd): Likewise.
12935 (grub_video_term): Added setcolor and getcolor.
12936 (MOD_INIT): Added registration of background_image command.
12937 (MOD_TERM): Added unregistration for background_image command.
12938
c3c20931 129392007-12-30 Pavel Roskin <proski@gnu.org>
12940
12941 * loader/multiboot_loader.c: Fix multiboot command
12942 unregistration. Fix all typos in the word "multiboot".
12943
df266716 129442007-12-29 Pavel Roskin <proski@gnu.org>
94239199 12945
12946 * util/grub.d/10_linux.in: Refactor search for initrd. Add
12947 support for initrd names used in Fedora.
12948
fc6e896c 129492007-12-26 Bean <bean123ch@gmail.com>
12950
12951 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
12952 (cpio_mod_SOURCES): New variable.
12953 (cpio_mod_CFLAGS): Likewise.
12954 (cpio_mod_LDFLAGS): Likewise.
12955
12956 * fs/cpio.c: New file.
12957
12958 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
12959
12960 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
12961
12962 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
12963
12964 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12965
533110ad 129662007-12-25 Robert Millan <rmh@aybabtu.com>
12967
12968 * include/grub/term.h (struct grub_term): Add `getcolor' function.
12969 (grub_getcolor): New function.
12970
12971 * kern/term.c (grub_getcolor): New function.
12972 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
12973 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
12974 (print_entry): Set normal and highlight colors to
12975 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
12976 respectively, before printing and restore them to old
12977 values afterwards.
12978 (grub_menu_init_page): Likewise. Fill an additional colored space
12979 that would otherwise be left blank.
12980
12981 * term/efi/console.c (grub_console_getcolor): New function.
12982 (struct grub_console_term.getcolor): New variable.
12983 * term/i386/pc/console.c (grub_console_getcolor): New function.
12984 (struct grub_console_term.getcolor): New variable.
12985 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
12986 (struct grub_console_term.getcolor): New variable.
12987
12988 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
12989 (struct grub_console_term.setcolor): Remove variable.
12990 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
12991 (struct grub_console_term.setcolor): Remove variable.
12992 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
12993 (struct grub_console_term.setcolor): Remove variable.
12994 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
12995 (struct grub_console_term.setcolor): Remove variable.
12996
4931827f 129972007-12-25 Robert Millan <rmh@aybabtu.com>
12998
12999 * configure.ac: Search for possible unifont.hex locations, and
13000 define UNIFONT_HEX if found.
13001
13002 * Makefile.in (UNIFONT_HEX): Define variable.
13003 (DATA): Rename to ...
13004 (PKGLIB): ... this. Update all users.
13005 (PKGDATA): New variable.
13006 (pkgdata_IMAGES): Rename to ...
13007 (pkglib_IMAGES): ... this. Update all users.
13008 (pkgdata_MODULES): Rename to ...
13009 (pkglib_MODULES): ... this. Update all users.
13010 (pkgdata_PROGRAMS): Rename to ...
13011 (pkglib_PROGRAMS): ... this. Update all users.
13012 (pkgdata_DATA): Rename to ...
13013 (pkglib_DATA): ... this. Update all users.
13014 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
13015 (unicode.pff, ascii.pff): New rules.
13016 (all-local): Add `$(PKGDATA)' dependency.
13017 (install-local): Process `$(PKGDATA)'.
13018
13019 * util/update-grub_lib.in (font_path): Search for *.pff files in
13020 a few more locations, including `${pkgdata}'.
13021
57e57e31 130222007-12-23 Robert Millan <rmh@aybabtu.com>
13023
13024 Patch from Bean <bean123ch@gmail.com>:
13025 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
13026 `size'.
13027
4bc72aa9 130282007-12-21 Bean <bean123ch@gmail.com>
13029
13030 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
13031 (ntfscomp_mod_SOURCES): New variable.
13032 (ntfscomp_mod_CFLAGS): Likewise.
13033 (ntfscomp_mod_LDFLAGS): Likewise.
13034
13035 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
13036 (grub_probe_SOURCES): Likewise.
13037 (grub_emu_SOURCES): Likewise.
13038
13039 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13040 (grub_emu_SOURCES): Likewise.
13041
13042 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13043 (grub_emu_SOURCES): Likewise.
13044
13045 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13046 (grub_emu_SOURCES): Likewise.
13047
13048 * fs/ntfs.c (grub_ntfscomp_func): New variable.
13049 (read_run_list): Renamed to grub_ntfs_read_run_list.
13050 (decomp_nextvcn): Moved to ntfscomp.c.
13051 (decomp_getch): Likewise.
13052 (decomp_get16): Likewise.
13053 (decomp_block): Likewise.
13054 (read_block): Likewise.
13055 (read_data): Partially moved to ntfscomp.c.
13056 (fixup): Change unsigned to grub_uint16_t.
13057 (read_mft): Change unsigned long to grub_uint32_t.
13058 (read_attr): Likewise.
13059 (read_data): Likewise.
13060 (read_run_data): Likewise.
13061 (read_run_list): Likewise.
13062 (read_mft): Likewise.
13063
13064 * fs/ntfscomp.c: New file.
13065
13066 * include/grub/ntfs.h: New file.
13067
af680a87 130682007-12-16 Robert Millan <rmh@aybabtu.com>
13069
13070 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
13071 IDE disk check, since Linux is known to support 20 IDE disks.
13072 Reported by Colin Watson.
13073
84be7599 130742007-12-15 Bean <bean123ch@gmail.com>
13075
13076 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
13077 (lnxboot_img_SOURCES): New variable.
13078 (lnxboot_img_ASFLAGS): Likewise.
13079 (lnxboot_img_LDFLAGS): Likewise.
13080
13081 * boot/i386/pc/lnxboot.S: New file.
13082
6af9db01 130832007-11-24 Pavel Roskin <proski@gnu.org>
13084
13085 * configure.ac: Test if '--build-id=none' is supported by the
13086 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
13087 objcopy to generate incorrect binary files (binutils
13088 2.17.50.0.18-1 as shipped by Fedora 8).
13089 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
13090 linking, so that build ID doesn't break the test.
13091
7361cfe6 130922007-11-24 Pavel Roskin <proski@gnu.org>
13093
13094 * include/grub/i386/time.h: use "void" in the argument list
13095 of grub_cpu_idle().
13096 * include/grub/powerpc/time.h: Likewise.
13097 * include/grub/sparc64/time.h: Likewise.
13098
1593e10c 130992007-11-18 Christian Franke <franke@computer.org>
13100
13101 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
13102 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
13103 This fixes the problem that function keys did not work in grub-emu.
13104
3b8db1a8 131052007-11-18 Christian Franke <franke@computer.org>
13106
13107 * disk/host.c (grub_host_open): Remove attribute unused from
13108 name parameter. Add check for "host". This fixes the problem
13109 that grub-emu does not find partitions.
13110
2e29408d 131112007-11-18 Christian Franke <franke@computer.org>
13112
13113 * util/hostfs.c (is_dir): New function.
13114 (grub_hostfs_dir): Handle missing dirent.d_type case.
13115 (grub_hostfs_read): Add missing fseek().
13116 (grub_hostfs_label): Clear label pointer. This fixes a crash
13117 of grub-emu on "ls (host)".
13118
398cd047 131192007-11-18 Christian Franke <franke@computer.org>
13120
13121 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
13122 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
13123 to 64 bit boundary by default.
13124
c405c391 131252007-11-18 Bean <bean123ch@gmail.com>
13126
13127 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
13128 (hexdump_mod_SOURCES): New variable.
13129 (hexdump_mod_CFLAGS): Likewise.
13130 (hexdump_mod_LDFLAGS): Likewise.
f19dbdb7 13131
c405c391 13132 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13133
13134 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13135
13136 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13137
13138 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13139
13140 * include/grub/hexdump.h: New file.
13141
13142 * commands/hexdump.c: New file.
13143
5cced7fd 131442007-11-10 Robert Millan <rmh@aybabtu.com>
13145
13146 * commands/i386/pc/play.c (beep_off): Switch order of arguments
13147 in grub_outb() calls.
13148 (beep_on): Likewise.
13149
8b714eb0 131502007-11-10 Christian Franke <franke@computer.org>
13151
13152 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
13153 (grub_menu_run): Likewise.
13154
ce0f1839 131552007-11-10 Robert Millan <rmh@aybabtu.com>
13156
13157 * include/grub/i386/efi/machine.h: New file.
13158 * include/grub/i386/linuxbios/machine.h: Likewise.
13159 * include/grub/i386/pc/machine.h: Likewise.
13160 * include/grub/powerpc/ieee1275/machine.h: Likewise.
13161 * include/grub/sparc64/ieee1275/machine.h: Likewise.
13162
13163 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
13164 (serial_hw_io_addr): New variable.
13165 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
13166 instead of `(unsigned short *) 0x400'.
13167
270c237d 131682007-11-10 Bean <bean123ch@gmail.com>
13169
13170 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
13171
a87783bf 131722007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13173
13174 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
13175 (vga_mod_SOURCES): Added.
13176 (vga_mod_CFLAGS): Likewise.
13177 (vga_mod_LDFLAGS): Likewise.
13178
13179 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
13180 grub_outb() calls.
13181 (set_map_mask): Likewise.
13182 (set_read_map): Likewise.
13183 (set_read_address): Likewise.
13184 (vga_font): Removed variable.
13185 (get_vga_glyph): Removed function.
13186 (invalidate_char): Likewise.
13187 (write_char): Changed to use grub_font_get_glyph() for font
13188 information.
13189 (grub_vga_putchar): Likewise.
13190 (grub_vga_getcharwidth): Likewise.
13191
6433b448 131922007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13193
13194 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
13195 flags.
13196 (pxeboot_img_LDFLAGS): Likewise.
13197 (diskboot_img_LDFLAGS): Likewise.
13198 (kernel_img_LDFLAGS): Likewise.
13199
49178511 132002007-11-06 Robert Millan <rmh@aybabtu.com>
13201
13202 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
13203 in grub_outb() calls.
13204 (serial_hw_init): Likewise.
13205
53b052de 132062007-11-05 Robert Millan <rmh@aybabtu.com>
13207
13208 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
13209 spaces. Skip non-regular files.
13210
5ab33bba 132112007-11-05 Robert Millan <rmh@aybabtu.com>
13212
13213 * kern/disk.c (grub_disk_firmware_fini)
13214 (grub_disk_firmware_is_tainted): New variables.
13215
13216 * include/grub/disk.h (grub_disk_firmware_fini)
13217 (grub_disk_firmware_is_tainted): Likewise.
13218
13219 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
13220 (grub_disk_biosdisk_fini): ... to here.
13221 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
13222 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
13223 is set. Register grub_disk_biosdisk_fini() in
13224 `grub_disk_firmware_fini'.
13225
13226 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
13227 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
13228 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
13229 to finish existing firmware disk interface.
13230
13231 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
13232 (ata_mod_SOURCES): New variable.
13233 (ata_mod_CFLAGS): Likewise.
13234 (ata_mod_LDFLAGS): Likewise.
13235
0149ab7c 132362007-11-05 Robert Millan <rmh@aybabtu.com>
13237
13238 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
13239 (grub_ata_wait): Reimplement using grub_millisleep().
13240
13241 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
13242 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
13243
be7ac41e 132442007-11-03 Marco Gerards <marco@gnu.org>
13245
13246 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
13247 (CRTC_ADDR_PORT): New macro.
13248 (CRTC_DATA_PORT): Likewise.
13249 (CRTC_CURSOR): Likewise.
13250 (CRTC_CURSOR_ADDR_HIGH): Likewise.
13251 (CRTC_CURSOR_ADDR_LOW): Likewise.
13252 (update_cursor): New function.
13253 (grub_console_real_putchar): Call `update_cursor'.
13254 (grub_console_gotoxy): Likewise.
13255 (grub_console_cls): Set the default color when clearing the
13256 screen.
13257 (grub_console_setcursor): Implemented.
13258
bb06ab2e 132592007-11-03 Marco Gerards <marco@gnu.org>
13260
13261 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
13262 become activate.
13263 (grub_ata_pio_write): Likewise.
13264
13265 (grub_atapi_identify): Wait after issuing an ATA command.
13266 (grub_atapi_packet): Likewise.
13267 (grub_ata_identify): Likewise.
13268 (grub_ata_readwrite): Likewise.
13269
cf8f780b 132702007-11-03 Marco Gerards <marco@gnu.org>
13271
13272 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
13273 (grub_ata_pio_write): Likewise.
13274 (grub_ata_readwrite): Use `grub_error', instead of
13275 returning `grub_errno'.
13276
ed649e54 132772007-11-03 Marco Gerards <marco@gnu.org>
13278
13279 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
13280 grub_ata_pio_write once for every single sector, instead of for
13281 multiple sectors.
13282
ca25d8f0 132832007-10-31 Robert Millan <rmh@aybabtu.com>
13284
13285 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
13286
13287 * conf/i386-linuxbios.rmk: New file.
13288
13289 * kern/i386/pc/hardware.c: Likewise.
13290 * term/i386/pc/at_keyboard.c: Likewise.
13291 * term/i386/pc/vga_text.c: Likewise.
13292
13293 * include/grub/i386/linuxbios/boot.h: Likewise.
13294 * include/grub/i386/linuxbios/console.h: Likewise.
13295 * include/grub/i386/linuxbios/init.h: Likewise.
13296 * include/grub/i386/linuxbios/kernel.h: Likewise.
13297 * include/grub/i386/linuxbios/loader.h: Likewise.
13298 * include/grub/i386/linuxbios/memory.h: Likewise.
13299 * include/grub/i386/linuxbios/serial.h: Likewise.
13300 * include/grub/i386/linuxbios/time.h: Likewise.
13301
13302 * kern/i386/linuxbios/init.c: Likewise.
13303 * kern/i386/linuxbios/startup.S: Likewise.
13304 * kern/i386/linuxbios/table.c: Likewise.
13305
e911ecc1 133062007-10-31 Marco Gerards <marco@gnu.org>
13307
13308 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
13309 (ata_mod_SOURCES): New variable.
13310 (ata_mod_CFLAGS): Likewise.
13311 (ata_mod_LDFLAGS): Likewise.
13312
13313 * disk/ata.c: New file.
13314
13315 * include/grub/disk.h (grub_disk_dev_id): Add
13316 `GRUB_DISK_DEV_ATA_ID'.
f19dbdb7 13317
7f66d0e0 133182007-10-31 Robert Millan <rmh@aybabtu.com>
13319
13320 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
13321 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
13322
13323 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
13324 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
13325
13326 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
13327 `<grub/types.h>'.
13328
13329 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
13330
5cd7dd46 133312007-10-27 Robert Millan <rmh@aybabtu.com>
13332
3236ca65 13333 * include/grub/types.h (ULONG_MAX): Define macro.
5cd7dd46 13334
2ebfc90f 133352007-10-22 Robert Millan <rmh@aybabtu.com>
13336
13337 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
13338 `"../realmode.S"'.
13339 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
13340
73fcb0f3 133412007-10-22 Robert Millan <rmh@aybabtu.com>
13342
13343 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
13344 (pkgdata_MODULES): Add `biosdisk.mod'.
13345 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
13346 variables.
13347
13348 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
13349 (grub_biosdisk_init): Replace with ...
13350 (GRUB_MOD_INIT(biosdisk)): ... this.
13351 (grub_biosdisk_fini): Replace with ...
13352 (GRUB_MOD_FINI(biosdisk)): ... this.
13353
13354 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
13355 (grub_machine_init): Remove call to grub_biosdisk_init().
13356 (grub_machine_fini): Remove call to grub_machine_fini().
13357
13358 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
13359
3381d274 133602007-10-22 Robert Millan <rmh@aybabtu.com>
13361
13362 * include/grub/time.h: New file.
13363 * include/grub/i386/time.h: Likewise.
13364 * include/grub/powerpc/time.h: Likewise.
13365 * include/grub/sparc64/time.h: Likewise.
13366
13367 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
13368 instances to ...
13369 (KERNEL_MACHINE_TIME_HEADER): ... this.
13370 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13371 instances to ...
13372 (KERNEL_MACHINE_TIME_HEADER): ... this.
13373 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13374 instances to ...
13375 (KERNEL_MACHINE_TIME_HEADER): ... this.
13376
13377 * kern/i386/efi/init.c: Include `<grub/time.h>'.
13378 (grub_millisleep): New function.
13379 * kern/i386/pc/init.c: Include `<grub/time.h>'.
13380 (grub_millisleep): New function.
13381 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
13382 Remove `grub/machine/time.h' include.
13383 (grub_millisleep): New function.
13384 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
13385 Remove `grub/machine/time.h' include.
13386 (grub_millisleep): New function.
13387
13388 * include/grub/misc.h (grub_div_roundup): New function.
13389
13390 * kern/misc.c: Include `<grub/time.h>'.
13391 (grub_millisleep_generic): New function.
13392
13393 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
13394 Add `time.h'.
13395 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
13396 Add `time.h'.
13397 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
13398 `machine/time.h'. Add `time.h'.
13399 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
13400
a39a0312 134012007-10-21 Robert Millan <rmh@aybabtu.com>
13402
13403 * include/grub/misc.h (grub_max): New function.
13404
2aad70e2 134052007-10-21 Robert Millan <rmh@aybabtu.com>
13406
13407 * util/misc.c (grub_util_info): Call fflush() before returning.
13408
54b71c4b 134092007-10-20 Robert Millan <rmh@aybabtu.com>
13410
13411 * genmk.rb (Image): Copy `extra_flags' from here ...
13412 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
13413
13414 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
13415 to `argc' and `args' arguments.
13416
a979f513 134172007-10-17 Robert Millan <rmh@aybabtu.com>
13418
13419 * kern/i386/loader.S: New file.
13420
13421 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
13422 * kern/i386/loader.S (grub_linux_prot_size)... to here.
13423 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
13424 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
13425 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
13426 * kern/i386/loader.S (grub_linux_real_addr)... to here.
13427 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
13428 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
13429 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
13430 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
13431 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
13432 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
13433 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
13434 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
13435
13436 * kern/i386/realmode.S: New file.
13437
13438 * kern/i386/pc/startup.S (protstack): Moved from here ...
13439 * kern/i386/realmode.S (protstack)... to here.
13440 * kern/i386/pc/startup.S (gdt): Moved from here ...
13441 * kern/i386/realmode.S (gdt)... to here.
13442 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
13443 * kern/i386/realmode.S (prot_to_real)... to here.
13444
13445 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
13446 `kern/i386/realmode.S'.
13447
825fc8fd 134482007-10-17 Robert Millan <rmh@aybabtu.com>
13449
13450 * include/grub/i386/loader.h: New file.
13451
13452 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
13453 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13454 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13455 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13456 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
13457 * include/grub/i386/loader.h (grub_linux_prot_size)
13458 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13459 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13460 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13461 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
13462
13463 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
13464
e179b2f4 134652007-10-15 Robert Millan <rmh@aybabtu.com>
13466
13467 * normal/misc.c (grub_normal_print_device_info): Do not probe for
13468 filesystem when dev->disk is unset.
13469 Do probe for filesystem even when dev->disk->has_partitions is set.
13470 In case a filesystem is found, always report it.
13471 In case it isn't, if dev->disk->has_partitions is set, report that
13472 a partition table was found instead of reporting that no filesystem
13473 could be identified.
13474
5db82af6 134752007-10-12 Robert Millan <rmh@aybabtu.com>
13476
13477 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
13478 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
13479
68f6ac74 13480 * include/grub/types.h (grub_host_to_target16): New macro.
13481 (grub_host_to_target32): Likewise.
13482 (grub_host_to_target64): Likewise.
13483 (grub_target_to_host16): Likewise.
13484 (grub_target_to_host32): Likewise.
13485 (grub_target_to_host64): Likewise.
5db82af6 13486
13487 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
13488 Renamed from to ...
13489 (GRUB_MOD_ALIGN): ...this. Update all users.
13490
68f6ac74 13491 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
13492 grub_host_to_target32.
13493 Replace grub_be_to_cpu32 with grub_target_to_host32.
13494 (load_modules): Likewise.
13495 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
13496 Replace grub_be_to_cpu32 with grub_target_to_host32.
13497 Replace grub_cpu_to_be16 with grub_host_to_target16.
13498 Replace grub_cpu_to_be32 grub_host_to_target32.
5db82af6 13499
3cf497cc 135002007-10-12 Robert Millan <rmh@aybabtu.com>
13501
13502 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
13503 * util/elf/grub-mkimage.c: ... here.
13504
13505 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
13506 `util/powerpc/ieee1275/grub-mkimage.c'.
13507
c8cc3692 135082007-10-07 Robert Millan <rmh@aybabtu.com>
adbc4c9d 13509
c8cc3692 13510 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
13511 and make it easier to figure out.
13512 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
13513 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
13514 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
13515 leave us with less than HEAP_MIN_SIZE total heap.
13516 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
adbc4c9d 13517
5c58b791 135182007-10-03 Robert Millan <rmh@aybabtu.com>
13519
13520 * include/grub/i386/io.h: New file.
13521 * commands/i386/pc/play.c (inb): Removed.
13522 (outb): Removed.
13523 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13524 with grub_outb().
afcd2ef8 13525 * term/i386/pc/serial.c (inb): Removed.
13526 (outb): Removed.
13527 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13528 with grub_outb().
13529 * term/i386/pc/vga.c (inb): Removed.
13530 (outb): Removed.
13531 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13532 with grub_outb().
5c58b791 13533
1a477ed6 135342007-10-02 Robert Millan <rmh@aybabtu.com>
13535
13536 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
13537 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13538 Reported by Marcin Kurek.
13539
6b5d80fa 135402007-09-07 Robert Millan <rmh@aybabtu.com>
13541
13542 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
13543 SmartFirmware version updates (as released by Sven Luther), and avoid
13544 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
13545 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
13546 known broken.
13547
5618afbf 135482007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13549
13550 From Hitoshi Ozeki:
13551 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
13552 when merging two regions.
13553
6139dcd9 135542007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13555
508e39ee 13556 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
13557 * normal/completion.c (grub_normal_do_completion): Likewise.
13558 Reported by Hitoshi Ozeki.
13559
135602007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 13561
6139dcd9 13562 Do not use devices at boot in chainloading.
f19dbdb7 13563
6139dcd9 13564 * loader/i386/pc/chainloader.c (boot_drive): New variable.
13565 (boot_part_addr): Likewise.
13566 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
13567 with BOOT_DRIVE and BOOT_PART_ADDR.
13568 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
13569 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
13570
38da6516 135712007-08-29 Robert Millan <rmh@aybabtu.com>
13572
13573 Patch from Simon Peter <dn.tlp@gmx.net>:
13574 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
13575 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
13576 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
13577 util/i386/pc/grub-setup.c_DEPENDENCIES.
13578 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
13579 util/grub-probe.c_DEPENDENCIES.
13580 * conf/powerpc-ieee1275.rmk: Likewise.
13581
29d0928c 135822007-08-28 Robert Millan <rmh@aybabtu.com>
13583
13584 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
13585 to tell grub-mkdevicemap how to name devices.
13586 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
13587 feature).
13588
13589 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
13590 util/i386/get_disk_name.c.
13591 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
13592 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
13593 util/ieee1275/get_disk_name.c.
13594
13595 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
13596
13597 * DISTLIST: Add util/i386/get_disk_name.c and
13598 util/ieee1275/get_disk_name.c.
13599
13600 * util/grub-mkdevicemap.c: Replace device naming logic with
13601 grub_util_get_disk_name() calls.
13602
5a0d3cca 136032007-08-20 Robert Millan <rmh@aybabtu.com>
13604
13605 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
13606 (so that it works for both plural and singular quantities).
13607
8b72db2f 136082007-08-05 Robert Millan <rmh@aybabtu.com>
13609
13610 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
13611 so that [xz] isn't taken into account when determining order.
13612
352466bf 136132007-08-02 Marco Gerards <marco@gnu.org>
13614
13615 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
13616 `include/multiboot2.h', `include/grub/elfload.h',
13617 `include/multiboot.h', `include/grub/multiboot.h',
13618 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
13619 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
13620 `kern/elf.c', `loader/multiboot_loader.c',
13621 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
13622 `loader/i386/pc/multiboot2.c',
13623 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
13624 `util/i386/pc/grub-mkrescue.in'. Remove
13625 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
13626 `include/grub/i386/pc/util/biosdisk.h' and
13627 `include/grub/powerpc/ieee1275/multiboot.h'.
13628
8f096014 136292007-08-02 Bean <bean123ch@gmail.com>
13630
13631 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
13632 (ntfs_mod_SOURCES): New variable.
13633 (ntfs_mod_CFLAGS): Likewise.
13634 (ntfs_mod_LDFLAGS): Likewise.
13635
13636 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
13637 (grub_probe_SOURCES): Likewise.
13638 (grub_emu_SOURCES): Likewise.
13639
13640 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13641 (grub_emu_SOURCES): Likewise.
13642
13643 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13644 (grub_emu_SOURCES): Likewise.
f19dbdb7 13645
8f096014 13646 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
13647
13648 * fs/ntfs.c: New file.
13649
9959f7db 136502007-08-02 Bean <bean123ch@gmail.com>
13651
13652 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
13653
13654 * file.h (grub_file): Likewise.
13655
13656 * fshelp.h (grub_fshelp_read_file): Likewise.
13657
13658 * util/i386/pc/grub-setup.c (setup): Likewise.
13659 (save_first_sector): Likewise.
13660 (save_blocklists): Likewise.
f19dbdb7 13661
9959f7db 13662 * fs/affs.c (grub_affs_read_file): Likewise.
13663
13664 * fs/ext2.c (grub_ext2_read_file): Likewise.
13665
13666 * fs/fat.c (grub_fat_read_data): Likewise.
13667
13668 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
13669
13670 * fs/hfs.c (grub_hfs_read_file): Likewise.
13671
13672 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
13673
13674 * fs/jfs.c (grub_jfs_read_file): Likewise.
13675
13676 * fs/minix.c (grub_minix_read_file): Likewise.
13677
13678 * fs/sfs.c (grub_sfs_read_file): Likewise.
13679
13680 * fs/ufs.c (grub_ufs_read_file): Likewise.
f19dbdb7 13681
9959f7db 13682 * fs/xfs.c (grub_xfs_read_file): Likewise.
13683
13684 * command/blocklist.c (read_blocklist): Likewise.
13685 (print_blocklist): Likewise.
13686
0a203f83 136872007-08-02 Marco Gerards <marco@gnu.org>
13688
13689 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
13690 `util/hostfs.c'.
13691
13692 * disk/host.c: New file.
13693
13694 * util/hostfs.c: Likewise.
13695
13696 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
13697 return `GRUB_ERR_BAD_FS'.
13698 * fs/sfs.c (grub_sfs_mount): Likewise.
13699 * fs/xfs.c (grub_xfs_mount): Likewise.
13700
13701 * include/grub/disk.h (enum grub_disk_dev_id): Add
13702 `GRUB_DISK_DEVICE_HOST_ID'.
13703
13704 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
13705
e5dfe777 137062007-07-24 Jerone Young <jerone@gmail.com>
13707
f19dbdb7 13708 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
e5dfe777 13709 modules for compilation.
13710 * conf/powerpc-ieee1275.rmk: Likewise.
13711
13712 * include/multiboot.h: Move multiboot definitions to one file. Rename
13713 many definitions to not get grub specific.
13714 * include/multiboot2.h: Create header with multiboot 2 definitions.
13715 * include/grub/multiboot.h: Header for grub specific function
13716 prototypes and definitions.
13717 * include/grub/multiboot2.h: Likewise.
13718 * include/grub/multiboot_loader.h: Likewise.
13719 * include/grub/i386/pc/multiboot.h: Removed.
13720 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
13721
13722 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
13723 and 2 to allow for one multiboot and module commands.
13724 * loader/multiboot2.c: Add multiboot2 functionality.
13725 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
13726 and definition names.
13727 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
13728 2 functions.
13729 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
13730 ieee1275 specific multiboot2 code.
13731
13732 * kern/i386/pc/startup.S: Change headers and definition names for
13733 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
13734
daf0f0ba 137352007-07-22 Robert Millan <rmh@aybabtu.com>
13736
13737 * geninitheader.sh: Process file specified in first parameter rather
13738 than hardcoding grub_modules_init.lst.
fe6b695a 13739 * geninit.sh: Likewise. Also, construct header name dynamically rather
daf0f0ba 13740 than hardcoding grub_modules_init.h.
13741
13742 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
13743 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
13744 grub_probe_init.[ch] and grub_setup_init.[ch].
13745
13746 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
13747 grub_modules_init.h with grub_emu_init.h.
13748 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
13749 grub_probe_init.[ch] files.
13750 * conf/i386-efi.rmk: Likewise.
13751 * conf/i386-pc.rmk: Likewise.
13752 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
13753 grub_setup_init.[ch] files.
13754
13755 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
13756 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
13757 to initialize modules rather than a list of hardcoded functions.
13758 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
13759 grub_init_all() to initialize modules rather than a list of hardcoded
13760 functions.
13761
54cdc1cc 137622007-07-22 Robert Millan <rmh@aybabtu.com>
13763
13764 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
13765 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
13766
ad0686cc 137672007-07-22 Robert Millan <rmh@aybabtu.com>
13768
13769 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
13770 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
13771 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
13772 flag when running on SmartFirmware.
13773 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
13774 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
13775 was set.
13776
13777 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
13778 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
13779 rather than decreasing it.
13780
13781 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
13782 there's not enough space to do it, fail in the same way as when it
13783 can't be done because there are no partitions.
13784
13785 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
13786 when nvsetenv failed.
13787
969c02ec 137882007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13789
13790 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
13791 because this rule is automatically generated.
13792 (grub-mkrescue): Removed for the same reason as above.
13793
5a79f472 137942007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13795
13796 Migrate to GNU General Public License Version 3.
f19dbdb7 13797
5a79f472 13798 * COPYING: Replaced with the plain text version of GPLv3.
13799
13800 * config.guess: Updated from gnulib.
13801 * config.sub: Likewise.
13802
13803 * geninit.sh: Output a GPLv3 copyright notice.
13804 * geninitheader.sh: Likewise.
13805 * genmodsrc.sh: Likewise.
13806 * gensymlist.sh.in: Likewise.
13807
13808 * boot/i386/pc/boot.S: Upgraded to GPLv3.
13809 * boot/i386/pc/diskboot.S: Likewise.
13810 * boot/i386/pc/pxeboot.S: Likewise.
13811 * commands/blocklist.c: Likewise.
13812 * commands/boot.c: Likewise.
13813 * commands/cat.c: Likewise.
13814 * commands/cmp.c: Likewise.
13815 * commands/configfile.c: Likewise.
13816 * commands/echo.c: Likewise.
13817 * commands/help.c: Likewise.
13818 * commands/ls.c: Likewise.
13819 * commands/search.c: Likewise.
13820 * commands/terminal.c: Likewise.
13821 * commands/test.c: Likewise.
13822 * commands/videotest.c: Likewise.
13823 * commands/i386/cpuid.c: Likewise.
13824 * commands/i386/pc/halt.c: Likewise.
13825 * commands/i386/pc/play.c: Likewise.
13826 * commands/i386/pc/reboot.c: Likewise.
13827 * commands/i386/pc/vbeinfo.c: Likewise.
13828 * commands/i386/pc/vbetest.c: Likewise.
13829 * commands/ieee1275/halt.c: Likewise.
13830 * commands/ieee1275/reboot.c: Likewise.
13831 * commands/ieee1275/suspend.c: Likewise.
13832 * disk/loopback.c: Likewise.
13833 * disk/lvm.c: Likewise.
13834 * disk/raid.c: Likewise.
13835 * disk/efi/efidisk.c: Likewise.
13836 * disk/i386/pc/biosdisk.c: Likewise.
13837 * disk/ieee1275/ofdisk.c: Likewise.
13838 * font/manager.c: Likewise.
13839 * fs/affs.c: Likewise.
13840 * fs/ext2.c: Likewise.
13841 * fs/fat.c: Likewise.
13842 * fs/fshelp.c: Likewise.
13843 * fs/hfs.c: Likewise.
13844 * fs/hfsplus.c: Likewise.
13845 * fs/iso9660.c: Likewise.
13846 * fs/jfs.c: Likewise.
13847 * fs/minix.c: Likewise.
13848 * fs/sfs.c: Likewise.
13849 * fs/ufs.c: Likewise.
13850 * fs/xfs.c: Likewise.
13851 * hello/hello.c: Likewise.
13852 * include/grub/acorn_filecore.h: Likewise.
13853 * include/grub/arg.h: Likewise.
13854 * include/grub/bitmap.h: Likewise.
13855 * include/grub/boot.h: Likewise.
13856 * include/grub/cache.h: Likewise.
13857 * include/grub/device.h: Likewise.
13858 * include/grub/disk.h: Likewise.
13859 * include/grub/dl.h: Likewise.
13860 * include/grub/elfload.h: Likewise.
13861 * include/grub/env.h: Likewise.
13862 * include/grub/err.h: Likewise.
13863 * include/grub/file.h: Likewise.
13864 * include/grub/font.h: Likewise.
13865 * include/grub/fs.h: Likewise.
13866 * include/grub/fshelp.h: Likewise.
13867 * include/grub/gzio.h: Likewise.
13868 * include/grub/hfs.h: Likewise.
13869 * include/grub/kernel.h: Likewise.
13870 * include/grub/loader.h: Likewise.
13871 * include/grub/lvm.h: Likewise.
13872 * include/grub/misc.h: Likewise.
13873 * include/grub/mm.h: Likewise.
13874 * include/grub/net.h: Likewise.
13875 * include/grub/normal.h: Likewise.
13876 * include/grub/parser.h: Likewise.
13877 * include/grub/partition.h: Likewise.
13878 * include/grub/pc_partition.h: Likewise.
13879 * include/grub/raid.h: Likewise.
13880 * include/grub/rescue.h: Likewise.
13881 * include/grub/script.h: Likewise.
13882 * include/grub/setjmp.h: Likewise.
13883 * include/grub/symbol.h: Likewise.
13884 * include/grub/term.h: Likewise.
13885 * include/grub/terminfo.h: Likewise.
13886 * include/grub/tparm.h: Likewise.
13887 * include/grub/types.h: Likewise.
13888 * include/grub/video.h: Likewise.
13889 * include/grub/efi/api.h: Likewise.
13890 * include/grub/efi/chainloader.h: Likewise.
13891 * include/grub/efi/console.h: Likewise.
13892 * include/grub/efi/console_control.h: Likewise.
13893 * include/grub/efi/disk.h: Likewise.
13894 * include/grub/efi/efi.h: Likewise.
13895 * include/grub/efi/pe32.h: Likewise.
13896 * include/grub/efi/time.h: Likewise.
13897 * include/grub/i386/linux.h: Likewise.
13898 * include/grub/i386/setjmp.h: Likewise.
13899 * include/grub/i386/types.h: Likewise.
13900 * include/grub/i386/efi/kernel.h: Likewise.
13901 * include/grub/i386/efi/loader.h: Likewise.
13902 * include/grub/i386/efi/time.h: Likewise.
13903 * include/grub/i386/pc/biosdisk.h: Likewise.
13904 * include/grub/i386/pc/boot.h: Likewise.
13905 * include/grub/i386/pc/chainloader.h: Likewise.
13906 * include/grub/i386/pc/console.h: Likewise.
13907 * include/grub/i386/pc/init.h: Likewise.
13908 * include/grub/i386/pc/kernel.h: Likewise.
13909 * include/grub/i386/pc/loader.h: Likewise.
13910 * include/grub/i386/pc/memory.h: Likewise.
13911 * include/grub/i386/pc/multiboot.h: Likewise.
13912 * include/grub/i386/pc/serial.h: Likewise.
13913 * include/grub/i386/pc/time.h: Likewise.
13914 * include/grub/i386/pc/vbe.h: Likewise.
13915 * include/grub/i386/pc/vbeblit.h: Likewise.
13916 * include/grub/i386/pc/vbefill.h: Likewise.
13917 * include/grub/i386/pc/vbeutil.h: Likewise.
13918 * include/grub/i386/pc/vga.h: Likewise.
13919 * include/grub/ieee1275/ieee1275.h: Likewise.
13920 * include/grub/ieee1275/ofdisk.h: Likewise.
13921 * include/grub/powerpc/libgcc.h: Likewise.
13922 * include/grub/powerpc/setjmp.h: Likewise.
13923 * include/grub/powerpc/types.h: Likewise.
13924 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
13925 * include/grub/powerpc/ieee1275/console.h: Likewise.
13926 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
13927 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
13928 * include/grub/powerpc/ieee1275/loader.h: Likewise.
13929 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
13930 * include/grub/powerpc/ieee1275/time.h: Likewise.
13931 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
13932 * include/grub/sparc64/libgcc.h: Likewise.
13933 * include/grub/sparc64/setjmp.h: Likewise.
13934 * include/grub/sparc64/types.h: Likewise.
13935 * include/grub/sparc64/ieee1275/console.h: Likewise.
13936 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
13937 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
13938 * include/grub/sparc64/ieee1275/time.h: Likewise.
13939 * include/grub/util/biosdisk.h: Likewise.
13940 * include/grub/util/getroot.h: Likewise.
13941 * include/grub/util/lvm.h: Likewise.
13942 * include/grub/util/misc.h: Likewise.
13943 * include/grub/util/raid.h: Likewise.
13944 * include/grub/util/resolve.h: Likewise.
13945 * io/gzio.c: Likewise.
13946 * kern/device.c: Likewise.
13947 * kern/disk.c: Likewise.
13948 * kern/dl.c: Likewise.
13949 * kern/elf.c: Likewise.
13950 * kern/env.c: Likewise.
13951 * kern/err.c: Likewise.
13952 * kern/file.c: Likewise.
13953 * kern/fs.c: Likewise.
13954 * kern/loader.c: Likewise.
13955 * kern/main.c: Likewise.
13956 * kern/misc.c: Likewise.
13957 * kern/mm.c: Likewise.
13958 * kern/parser.c: Likewise.
13959 * kern/partition.c: Likewise.
13960 * kern/rescue.c: Likewise.
13961 * kern/term.c: Likewise.
13962 * kern/efi/efi.c: Likewise.
13963 * kern/efi/init.c: Likewise.
13964 * kern/efi/mm.c: Likewise.
13965 * kern/i386/dl.c: Likewise.
13966 * kern/i386/efi/init.c: Likewise.
13967 * kern/i386/efi/startup.S: Likewise.
13968 * kern/i386/pc/init.c: Likewise.
13969 * kern/i386/pc/lzo1x.S: Likewise.
13970 * kern/i386/pc/startup.S: Likewise.
13971 * kern/ieee1275/ieee1275.c: Likewise.
13972 * kern/powerpc/cache.S: Likewise.
13973 * kern/powerpc/dl.c: Likewise.
13974 * kern/powerpc/ieee1275/cmain.c: Likewise.
13975 * kern/powerpc/ieee1275/crt0.S: Likewise.
13976 * kern/powerpc/ieee1275/init.c: Likewise.
13977 * kern/powerpc/ieee1275/openfw.c: Likewise.
13978 * kern/sparc64/cache.S: Likewise.
13979 * kern/sparc64/dl.c: Likewise.
13980 * kern/sparc64/ieee1275/init.c: Likewise.
13981 * kern/sparc64/ieee1275/openfw.c: Likewise.
13982 * loader/efi/chainloader.c: Likewise.
13983 * loader/efi/chainloader_normal.c: Likewise.
13984 * loader/i386/efi/linux.c: Likewise.
13985 * loader/i386/efi/linux_normal.c: Likewise.
13986 * loader/i386/pc/chainloader.c: Likewise.
13987 * loader/i386/pc/chainloader_normal.c: Likewise.
13988 * loader/i386/pc/linux.c: Likewise.
13989 * loader/i386/pc/linux_normal.c: Likewise.
13990 * loader/i386/pc/multiboot.c: Likewise.
13991 * loader/i386/pc/multiboot_normal.c: Likewise.
13992 * loader/powerpc/ieee1275/linux.c: Likewise.
13993 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
13994 * normal/arg.c: Likewise.
13995 * normal/cmdline.c: Likewise.
13996 * normal/command.c: Likewise.
13997 * normal/completion.c: Likewise.
13998 * normal/execute.c: Likewise.
13999 * normal/function.c: Likewise.
14000 * normal/lexer.c: Likewise.
14001 * normal/main.c: Likewise.
14002 * normal/menu.c: Likewise.
14003 * normal/menu_entry.c: Likewise.
14004 * normal/misc.c: Likewise.
14005 * normal/parser.y: Likewise.
14006 * normal/script.c: Likewise.
14007 * normal/i386/setjmp.S: Likewise.
14008 * normal/powerpc/setjmp.S: Likewise.
14009 * normal/sparc64/setjmp.S: Likewise.
14010 * partmap/acorn.c: Likewise.
14011 * partmap/amiga.c: Likewise.
14012 * partmap/apple.c: Likewise.
14013 * partmap/gpt.c: Likewise.
14014 * partmap/pc.c: Likewise.
14015 * partmap/sun.c: Likewise.
14016 * term/gfxterm.c: Likewise.
14017 * term/terminfo.c: Likewise.
14018 * term/efi/console.c: Likewise.
14019 * term/i386/pc/console.c: Likewise.
14020 * term/i386/pc/serial.c: Likewise.
14021 * term/i386/pc/vesafb.c: Likewise.
14022 * term/i386/pc/vga.c: Likewise.
14023 * term/ieee1275/ofconsole.c: Likewise.
14024 * util/biosdisk.c: Likewise.
14025 * util/console.c: Likewise.
14026 * util/genmoddep.c: Likewise.
14027 * util/getroot.c: Likewise.
14028 * util/grub-emu.c: Likewise.
14029 * util/grub-mkdevicemap.c: Likewise.
14030 * util/grub-probe.c: Likewise.
14031 * util/lvm.c: Likewise.
14032 * util/misc.c: Likewise.
14033 * util/raid.c: Likewise.
14034 * util/resolve.c: Likewise.
14035 * util/update-grub.in: Likewise.
14036 * util/update-grub_lib.in: Likewise.
14037 * util/grub.d/00_header.in: Likewise.
14038 * util/grub.d/10_hurd.in: Likewise.
14039 * util/grub.d/10_linux.in: Likewise.
14040 * util/i386/efi/grub-install.in: Likewise.
14041 * util/i386/efi/grub-mkimage.c: Likewise.
14042 * util/i386/pc/grub-install.in: Likewise.
14043 * util/i386/pc/grub-mkimage.c: Likewise.
14044 * util/i386/pc/grub-mkrescue.in: Likewise.
14045 * util/i386/pc/grub-setup.c: Likewise.
14046 * util/i386/pc/misc.c: Likewise.
14047 * util/powerpc/ieee1275/grub-install.in: Likewise.
14048 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
14049 * util/powerpc/ieee1275/misc.c: Likewise.
14050 * video/bitmap.c: Likewise.
14051 * video/video.c: Likewise.
14052 * video/i386/pc/vbe.c: Likewise.
14053 * video/i386/pc/vbeblit.c: Likewise.
14054 * video/i386/pc/vbefill.c: Likewise.
14055 * video/i386/pc/vbeutil.c: Likewise.
14056 * video/readers/tga.c: Likewise.
14057
3572d015 140582007-07-02 Robert Millan <rmh@aybabtu.com>
14059
14060 * conf/i386-efi.rmk: Replace obsolete reference to
14061 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
14062 with util/getroot.c.
14063 * conf/powerpc-ieee1275.rmk: Likewise.
14064 * conf/sparc64-ieee1275.rmk: Likewise.
14065
14066 * util/grub-emu.c (main): Fix unchecked pointer handling.
14067
2c2a681b 140682007-07-02 Robert Millan <rmh@aybabtu.com>
14069
14070 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
14071 invocation to fail, in order to support partition-less media.
14072
14073 * util/i386/pc/grub-install.in: Likewise.
14074
14075 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
14076 which fs or partmap modules are needed (akin to its sister scripts).
14077
14078 Also use grub-probe to get rid of unportable /proc/mounts check.
14079
14080 Print the same informational message that the other scripts do, before
fe6b695a 14081 exiting.
2c2a681b 14082
6193defe 140832007-06-23 Robert Millan <rmh@aybabtu.com>
14084
fe6b695a 14085 * util/update-grub_lib.in (font_path): New function. Determine whether
6193defe 14086 a font file can be found and, if so, echo the GRUB path to it.
14087
14088 * util/update-grub.in: Handle multiple terminals depending on user
14089 input, platform availability and font file presence. Propagate
14090 variables of our findings to /etc/grub.d/ children.
14091
14092 * util/grub.d/00_header.in: Handle multiple terminals, based on
14093 environment setup by update-grub.
14094
eface1dc 140952007-06-23 Robert Millan <rmh@aybabtu.com>
14096
ba50d28f 14097 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
eface1dc 14098
bf697e28 140992007-06-21 Robert Millan <rmh@aybabtu.com>
14100
14101 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
14102 indicate end of data section in kernel image.
14103 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
14104 GRUB_KERNEL_MACHINE_DATA_END.
14105
14106 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
14107 space for it.
14108 * kern/i386/efi/startup.S: Likewise.
14109
14110 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
14111 during image generation. Implement --prefix option to override this
14112 patch.
14113 * util/i386/efi/grub-mkimage.c: Likewise.
14114
14115 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
14116 code to make path relative to its root into a separate function.
14117
14118 * util/i386/pc/grub-install.in: Use newly provided
14119 make_system_path_relative_to_its_root() to convert ${grubdir}, then
14120 pass the result to grub-install --prefix.
14121
baa574b4 141222007-06-13 Robert Millan <rmh@aybabtu.com>
14123
14124 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
14125 DEFAULT_DEVICE_MAP.
14126 * util/grub-emu.c: Use above definitions from misc.h instead of
14127 defining them.
14128 * util/grub-mkdevicemap.c: Likewise.
14129 * util/i386/pc/grub-setup.c: Likewise.
14130 * util/grub-probe.c: Likewise.
14131 (probe): Abort with grub_util_error() when either
14132 grub_guess_root_device or grub_util_get_grub_dev fails.
14133
0215dcbf 141342007-06-12 Robert Millan <rmh@aybabtu.com>
14135
14136 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
14137 "pager" assignment.
14138 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
14139 "pcdata".
14140 * util/grub-probe.c (probe): Likewise for "drive_name".
14141
8af2ab7b 141422007-06-11 Robert Millan <rmh@aybabtu.com>
14143
14144 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
14145 not just the cdrom one.
14146
59d31694 141472007-06-11 Robert Millan <rmh@aybabtu.com>
14148
14149 * util/i386/pc/grub-mkrescue.in: Add "set -e".
14150 Add --pkglibdir=DIR option to override pkglibdir.
14151 Mention --image-type=TYPE in help output.
14152 Fix --grub-mkimage (it was a no-op).
fe6b695a 14153 Abort gracefully when no parameter is given.
59d31694 14154
7ee367e4 141552007-06-11 Robert Millan <rmh@aybabtu.com>
14156
14157 * util/i386/pc/grub-mkrescue.in: New file.
14158 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
14159 * Makefile.in: Handle bin_SCRIPTS.
14160
29b0ed46 141612007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
14162
14163 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
14164 list of video modes.
14165
c0f90770 141662007-06-06 Robert Millan <rmh@aybabtu.com>
14167
14168 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
14169 file doesn't exist, or if it is in a filesystem grub can't read.
14170
14171 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
14172 not abort if GRUB_DRIVE could not be defined. Rearrange generated
14173 header comment to fit in 80 columns when the variables are resolved.
14174
14175 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
14176 could be identified by update-grub. Remove redundant check for
fe6b695a 14177 unifont.pff existence (since convert_system_path_to_grub_path now
c0f90770 14178 handles that).
14179
fb36dc26 141802007-06-04 Robert Millan <rmh@aybabtu.com>
14181
14182 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
14183
14184 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
14185
14186 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
14187
0c68c93e 141882007-06-04 Robert Millan <rmh@aybabtu.com>
14189
14190 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
14191
14192 * include/grub/partition.h: Declare grub_apple_partition_map_init and
14193 grub_apple_partition_map_fini.
14194
14195 * util/biosdisk.c
14196 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
14197 to access >2 TiB disks).
14198
14199 Print disk->total_sectors with %llu instead of %lu, since this
14200 variable is always 64-bit (prevents wrong disk size from being displayed
14201 on either >2 TiB disk or big-endian CPU).
14202
14203 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
14204 into a generic case that supports all (sane) partition maps.
14205
14206 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
14207 breaks big-endian.
14208
14209 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
14210 and grub_apple_partition_map_fini() after that.
14211
0f23eb74 142122007-06-01 Robert Millan <rmh@aybabtu.com>
14213
14214 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
14215
14216 * util/grub.d/00_header.in: Only enable gfxterm when
14217 convert_system_path_to_grub_path() succeeds.
14218
42c71976 142192007-05-20 Robert Millan <rmh@aybabtu.com>
14220
14221 * util/update-grub_lib.in: New file.
14222 * DISTLIST: Add update-grub_lib.in.
14223 * conf/common.rmk: Generate update-grub_lib and install it in
14224 $(lib_DATA).
14225 * Makefile.in: Add install routine for $(lib_DATA).
14226
14227 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
14228 function provided by update-grub_lib to support arbitrary paths of
14229 unifont.pff.
14230 * util/update-grub.in: Use convert_system_path_to_grub_path() to
14231 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
14232
5beb2291 142332007-05-19 Robert Millan <rmh@aybabtu.com>
14234
14235 * commands/i386/cpuid.c: New module.
14236 * DISTLIST: Add it.
14237 * conf/i386-efi.rmk: Enable cpuid.mod.
14238 * conf/i386-pc.rmk: Likewise.
14239
7262eca1 142402007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14241
14242 * kern/disk.c (grub_disk_read): Check return value of
14243 grub_realloc().
14244
260ba823 142452007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14246
14247 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
14248 arrays.
14249 * disk/raid.c (grub_raid_open): Likewise.
14250
1ecb6cf2 142512007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14252
14253 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
14254 stack instead of on the heap.
14255
14256 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
14257 before doing a read on it.
14258
14259 * configure.ac: Only use -fno-stack-protector for the target
14260 environment.
f19dbdb7 14261
21c8cbb1 142622007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14263
14264 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
14265 __attribute_ ((unused)) to mode_type argument.
14266
14267 * util/getroot.c (grub_guess_root_device): Fix #endif.
f19dbdb7 14268
21c8cbb1 14269 * kern/misc.c (memcmp): Fix prototype.
14270
14271 * include/grub/partition.h [GRUB_UTIL]
14272 (grub_gpt_partition_map_init): Add prototype.
14273 (grub_gpt_partition_map_fini): Likewise.
14274
14275 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
14276 at the right place.
14277
14278 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
14279 (grub_fat_read_data): Likewise.
14280 (grub_fat_find_dir): Likewise.
14281
14282 * font/manager.c (find_glyph): Make table a const.
14283 (grub_font_get_glyph): Remove bitmap from if statement.
f19dbdb7 14284
849d55d3 142852007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
14286
14287 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
14288 code, first search for device in /dev/mapper, then in /dev.
14289 (grub_util_get_grub_dev): New function.
14290 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
14291 prototype.
14292 * util/grub-probe.c (probe): Remove check for RAID, call
14293 grub_util_get_grub_dev() instead of
14294 grub_util_biosdisk_get_grub_dev().
14295 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
14296 grub_util_biosdisk_get_grub_dev().
14297 * util/i386/pc/grub-setup.c (main): Likewise.
14298
8fff7c2f 142992007-05-16 Robert Millan <rmh@aybabtu.com>
14300
14301 * DISTLIST: Update for the latest changes.
14302 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
14303 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
14304 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
14305 grub/util/biosdisk.h.
14306 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
14307 grub/util/biosdisk.h.
14308
48e12b52 143092007-05-16 Robert Millan <rmh@aybabtu.com>
14310
14311 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
14312
46b9d128 143132007-05-16 Robert Millan <rmh@aybabtu.com>
14314
14315 * util/i386/efi/grub-install.in: New.
14316 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
14317 newly added grub-install.
14318 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
14319 include.
14320 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
14321 grub/util/biosdisk.h.
14322 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
14323 grub/util/biosdisk.h.
14324
2d1a40a9 143252007-05-16 Robert Millan <rmh@aybabtu.com>
14326
14327 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
14328 * include/grub/util/biosdisk.h: ... here.
14329 * util/i386/pc/biosdisk.c: Moved to ...
14330 * util/biosdisk.c: ... here.
14331 * util/i386/pc/getroot.c: Moved to ...
14332 * util/getroot.c: ... here.
14333 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
14334 * util/grub-mkdevicemap.c: ... here.
14335 * util/i386/pc/grub-probe.c: Moved to ...
14336 * util/grub-probe.c: ... here.
14337
9e26e3bc 143382007-05-15 Robert Millan <rmh@aybabtu.com>
14339
14340 * util/update-grub.in: Remove duplicated line in grub.cfg header
14341 message.
14342
57f96397 143432007-05-13 Robert Millan <rmh@aybabtu.com>
14344
14345 * util/update-grub.in: Fix a few assumptions about the devices holding
14346 /, /boot and /boot/grub being the same.
14347 * util/grub.d/00_header.in: Likewise.
14348 * util/grub.d/10_hurd.in: Likewise.
14349 * util/grub.d/10_linux.in: Likewise.
14350
14351 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
14352 patterns. Use that to define the `.old' suffix as older than `'.
14353
14354 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
14355
14356 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
14357 the grub.cfg header message.
14358
2e610d62 143592007-05-11 Robert Millan <rmh@aybabtu.com>
14360
14361 * util/update-grub.in: Create device.map if it doesn't already exist,
14362 before attempting to run grub-probe.
14363 Check for grub-probe and grub-mkdevicemap with the same code
14364 grub-install is using.
14365 Remove test mode.
14366
3f6a10ef 143672007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
14368
14369 * Makefile.in: Add the datarootdir autoconf variable.
14370
02e7b75e 143712007-05-09 Robert Millan <rmh@aybabtu.com>
14372
14373 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
f19dbdb7 14374 fail gracefully if dev->disk->partition == NULL.
02e7b75e 14375
75f396cc 143762007-05-07 Robert Millan <rmh@aybabtu.com>
14377
14378 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
14379 determine partition map module.
14380 * util/i386/pc/grub-install.in: Use this feature to decide which
14381 partition module to load, instead of hardcoding pc and gpt.
14382
da65cb36 143832007-05-07 Robert Millan <rmh@aybabtu.com>
14384
14385 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
14386 source directory differs from build directory.
14387
b57d6a91 143882007-05-05 Robert Millan <rmh@aybabtu.com>
14389
14390 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
14391 initialisation.
14392
509d00f1 143932007-05-05 Robert Millan <rmh@aybabtu.com>
14394
14395 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
14396
c48f23ef 143972007-05-05 Robert Millan <rmh@aybabtu.com>
14398
14399 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
14400 command-line arguments via ${GRUB_CMDLINE_LINUX}.
14401
20b97658 144022007-05-05 Robert Millan <rmh@aybabtu.com>
14403
14404 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
14405 (grub_probe_SOURCES): Likewise.
14406 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
14407 GPT and initialize dos_part and bsd_part accordingly.
14408 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
14409 install_bsd_part.
14410 (main): Activate gpt module for use during partition identification,
14411 and deactivate it afterwards.
14412 * util/i386/pc/grub-install.in: Add gpt module to core.img.
14413 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
14414 partition identification, and deactivate it afterwards.
14415
99123174 144162007-05-05 Robert Millan <rmh@aybabtu.com>
14417
14418 * term/i386/pc/console.c (grub_console_fini): Call
14419 grub_term_set_current() before grub_term_unregister().
14420
ebd97f6e 144212007-05-04 Robert Millan <rmh@aybabtu.com>
14422
14423 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
14424 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
14425 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
14426 and update-grub_DATA.
14427 * conf/common.rmk: Build and install update-grub components.
14428 * conf/common.mk: Regenerate.
14429 * util/update-grub.in: New. Core of update-grub.
14430 * util/grub.d/00_header.in: New. Generates grub.cfg header.
14431 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
14432 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
14433 * util/grub.d/README: New. Document grub.d directory layout.
14434
b06a264d 144352007-05-01 Robert Millan <rmh@aybabtu.com>
14436
14437 * util/grub-emu.c: Move initialization functions
14438 grub_util_biosdisk_init() and grub_init_all() before
14439 grub_util_biosdisk_get_grub_dev(), which relies on them.
14440
41f0050e 144412007-04-19 Robert Millan <rmh@aybabtu.com>
14442
14443 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
14444 it is used later.
14445
04582bb3 144462007-04-18 Jerone Young <jerone@gmail.com>
14447
f19dbdb7 14448 * kernel/elf.c: Add missing parenthesis for conditional statement
04582bb3 14449 stanza.
14450
08db4632 144512007-04-10 Jerone Young <jerone@gmail.com>
49892fdf 14452
08db4632 14453 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
14454 continue on and look for device node with real device name.
14455
801b76be 144562007-04-10 Jerone Young <jerone@gmail.com>
f19dbdb7 14457
fe6b695a 14458 * configure.ac: Add argument for autoconf to use transformation
1d543c3e 14459 ability.
14460 * Makefile.in: Add autoconf package transformation code.
14461 * util/i386/pc/grub-install.in: Likewise.
14462 * util/powerpc/ieee1275/grub-install.in: Likewise.
14463
6795c4e1 144642007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
14465
14466 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
14467 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
14468 (EXT2_REVISION): Likewise.
14469 (EXT2_INODE_SIZE): Likewise.
14470 (struct grub_ext2_block_group): Added a missing member
14471 "used_dirs".
14472 (grub_ext2_read_inode): Divide by the inode size in a superblock
14473 instead of 128 to obtain INODES_PER_BLOCK.
14474 Use the macro EXT2_INODE_SIZE instead of directly using
14475 SBLOCK->INODE_SIZE.
14476
d70af616 144772007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
14478
14479 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
14480 superblock instead of the structure size to compute an
14481 offset. This fixes the problem that GRUB could not read a
14482 filesystem when inode size is different from 128-byte.
14483
3b801603 144842007-03-05 Marco Gerards <marco@gnu.org>
14485
14486 * normal/main.c (read_config_file): When "menu" is not set, create
14487 an initial context.
14488
4785bfe4 144892007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14490
14491 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
14492 (HEAP_LIMIT): New macro.
14493 (grub_claim_heap): Claim memory up to `heaplimit'.
14494
a0cbb023 144952007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14496
14497 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
14498 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
14499 (_start): Likewise.
14500 (grub_arch_modules_addr): Return address after `_end'.
14501 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
14502 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
14503 (add_segments): Calculate `_end' from phdr size and location.
14504 (ALIGN_UP): Moved to ...
14505 * include/grub/misc.h: here.
14506 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
14507 New macro.
14508 (GRUB_IEEE1275_MODULE_BASE): Removed.
14509
fd7d8eba 145102007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14511
14512 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
14513 loop boundary.
14514
9b09e6fc 145152007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14516
14517 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
14518 All users updated.
14519 (grub_elf64_load_hook_t): Likewise.
14520 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
14521 debug output.
14522
3ce27299 145232007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14524
14525 * kern/mm.c: Update copyright.
14526 (grub_mm_debug): Correct syntax error.
14527 (grub_mm_dump_free): New function.
14528 (grub_debug_free): Call `grub_free'.
14529 * include/grub/mm.h: Update copyright.
14530 (grub_mm_dump_free): Add declaration.
14531
077d5fee 145322007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14533
14534 * include/grub/ieee1275/ieee1275.h: Update copyright.
14535 * kern/powerpc/ieee1275/init.c: Likewise.
14536 * kern/powerpc/ieee1275/openfw.c: Likewise.
14537
14538 * loader/powerpc/ieee1275/linux.c: Likewise.
14539 * include/grub/elfload.h: Likewise.
14540 * kern/elf.c: Likewise.
14541 (grub_elf32_load): Pass `base' and `size' parameters. Update all
14542 callers.
14543 (grub_elf64_load): Likewise.
14544 (grub_elf32_load_segment): Move to a nested function.
14545 (grub_elf64_load_segment): Likewise.
14546
dc946850 145472007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14548
14549 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
14550 prototype.
14551 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
14552 (grub_heap_len): Likewise.
14553 (HEAP_SIZE): New macro.
14554 (grub_claim_heap): New function.
14555 (grub_machine_init): Don't claim heap directly. Call
14556 `grub_claim_heap'.
14557 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
14558 (grub_available_iterate): New function.
14559
baa2a121 145602007-02-03 Thomas Schwinge <tschwinge@gnu.org>
14561
14562 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
14563 * configure.ac: Use it for testing the HOST and TARGET compilers.
14564
4fe9862e 145652006-12-13 Thomas Schwinge <tschwinge@gnu.org>
14566
14567 * Makefile.in (enable_grub_emu): New variable.
14568 * configure.ac (--enable-grub-emu): New option.
14569 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
14570 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
14571 * conf/i386-pc.rmk: Likewise.
14572 * conf/powerpc-ieee1275.rmk: Likewise.
14573 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
14574
a8aa5762 145752006-12-12 Marco Gerards <marco@gnu.org>
14576
14577 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
14578
14579 * kern/env.c (grub_env_unset): Don't free the member `value' when
14580 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
14581 pointer.
14582
14583 * normal/main.c (current_menu): Removed.
14584 (free_menu): Unset the `menu' environment variable.
14585 (grub_normal_menu_addentry): Make use of the environment variable
14586 `menu', instead of using the global `current_menu'. Allocate
14587 memory for the sourcecode of this entry.
14588 (read_config_file): New argument `nested', changed all callers.
14589 Only in the case of a new context, initialize a new menu. Set the
14590 `menu' environment variable.
14591 (grub_normal_execute): Don't set and unset the environment
14592 variable `menu' here anymore. Only free the menu when leaving the
14593 context.
14594
14595 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
14596 leak.
14597
957b3a3e 145982006-12-11 Marco Gerards <marco@gnu.org>
14599
14600 * normal/menu_entry.c (run): Fix off by one bug so the last line
14601 is executed. Move the loader check to outside the loop.
14602
ef875714 146032006-12-08 Hollis Blanchard <hollis@penguinppc.org>
14604
14605 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
14606
4e739985 146072006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
14608
14609 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
14610 the number of sectors. Reported by Andrey Shuvikov
14611 <mr_hyro@yahoo.com>.
f19dbdb7 14612
790707f2 146132006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
14614
14615 * kern/disk.c (grub_disk_read): When there is a read error, always
14616 try to read only the necessary data.
f19dbdb7 14617
790707f2 14618 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
14619 disk/raid.c.
14620 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
14621 prototype.
14622 [GRUB_UTIL] (grub_raid_fini): Likewise.
14623 [GRUB_UTIL] (grub_lvm_init): Likewise.
f19dbdb7 14624 [GRUB_UTIL] (grub_lvm_fini): Likewise.
790707f2 14625 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
14626 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
14627 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
14628 and grub_raid_fini().
f19dbdb7 14629
03e58196 146302006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
14631
14632 * include/grub/types.h (__unused): Rename to UNUSED.
14633 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
14634 (grub_elf64_size): Likewise.
f19dbdb7 14635
ae4f23bf 146362006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14637
14638 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
14639 grub_error_push and grub_error_pop in the error-handling path.
14640 (grub_elf32_load_segment): Only call grub_file_read with non-zero
14641 length.
14642
2166cc83 146432006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14644
14645 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
14646 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
14647 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
14648 (kernel_elf_SOURCES): Likewise.
14649 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
14650 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
14651 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14652 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14653 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
14654 (elf_mod_SOURCES): New variable.
14655 (elf_mod_CFLAGS): Likewise.
14656 (elf_mod_LDFLAGS): Likewise.
14657 * include/grub/types.h (__unused): New macro.
14658 * include/grub/elfload.h: New file.
14659 * kern/elf.c: Likewise.
14660 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
14661 (ELF32_LOADMASK): New macro.
14662 (ELF64_LOADMASK): Likewise.
14663 (vmlinux): Removed.
14664 (grub_linux_load32): New function.
14665 (grub_linux_load64): Likewise.
14666 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
14667 Use grub_elf_t instead of grub_file_t.
14668
a09d5aa5 146692006-11-02 Hollis Blanchard <hollis@penguinppc.org>
14670
14671 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
14672 `catch_result' to struct set_color_args.
14673
d976fc51 146742006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
14675
14676 * normal/menu.c: Include grub/script.h.
14677 * normal/menu_entry.c: Likewise.
14678 * include/grub/normal.h: Do not include grub/script.h.
14679
67507549 146802006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14681
14682 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
14683
69203a99 146842006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14685
14686 * kern/disk.c (grub_disk_open): Print debug messages when opening a
14687 disk.
14688 (grub_disk_close): Print debug messages when closing a disk.
14689 (grub_disk_read): Print debug messages when disk read fails.
14690 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
14691 filesystem type.
14692 * kern/partition.c: Include misc.h.
14693 (grub_partition_iterate): Print debug messages when detecting
14694 partition type.
14695
e2b8278c 146962006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14697
14698 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
14699 is negative.
14700 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
14701
97b2f2ff 147022006-10-26 Hollis Blanchard <hollis@penguinppc.org>
14703
14704 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
14705 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
14706
6555d655 147072006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
14708
14709 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
14710 instead of sizeof(lv). Patch by Michael Guntsche.
14711
4d42b77f 147122006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
14713
14714 * disk/lvm.c: Rename VGS to VG_LIST.
14715 (grub_lvm_iterate): Change VGS->LV to VG-LV.
14716 (grub_lvm_open): Likewise.
14717 Thanks to Michael Guntsche for finding this bug.
14718
5d74d927 147192006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14720
14721 * configure.ac (AC_INIT): Bumped to 1.95.
14722
a1bb27e4 147232006-10-14 Robert Millan <rmh@aybabtu.com>
14724
14725 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
14726 with "/dev/.static/dev/md".
14727
e0994b8b 147282006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14729
14730 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
14731 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
14732 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
14733 DRIVE_NAME are always freed.
14734
14735 * util/i386/pc/biosdisk.c (make_device_name): Add one into
14736 DOS_PART, as a DOS partition is counted from one instead of zero
14737 now. Reported by Robert Millan.
14738
ddd5cee9 147392006-10-14 Robert Millan <rmh@aybabtu.com>
14740
14741 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
14742 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
14743 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
14744 string returned by grub_guess_root_device.
14745 * util/i386/pc/grub-setup.c: Likewise.
14746 * util/i386/pc/grub-probefs.c: Likewise.
14747
14748 * util/i386/pc/grub-probefs.c: Rename to ...
14749 * util/i386/pc/grub-probe.c: ... this.
14750 * DISTLIST: Remove grub-probefs, add grub-probe.
14751 * conf/i386-efi.rmk: Likewise.
14752 * conf/i386-pc.rmk: Likewise.
14753 * util/i386/pc/grub-install.in: Likewise.
14754
14755 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
14756 choose which information we want to print.
14757
2b002173 147582006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14759
14760 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
14761 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
14762 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
14763 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
14764 video/readers/tga.c and video/i386/pc/vbeutil.c.
14765
147662006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
14767
14768 Added support for RAID and LVM.
f19dbdb7 14769
2b002173 14770 * disk/lvm.c: New file.
14771 * disk/raid.c: Likewise.
14772 * include/grub/lvm.h: Likewise.
f19dbdb7 14773 * include/grub/raid.h: Likewise.
2b002173 14774 * include/grub/util/lvm.h: Likewise.
14775 * include/grub/util/raid.h: Likewise.
14776 * util/lvm.c: Likewise.
14777 * util/raid.c: Likewise.
14778
14779 * include/grub/disk.h (grub_disk_dev_id): Add
14780 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
14781 (grub_disk_get_size): New prototype.
14782 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
14783 returns a partition.
14784 (grub_disk_get_size): New function.
f19dbdb7 14785
2b002173 14786 * kern/i386/pc/init.c (make_install_device): Copy the prefix
14787 verbatim if grub_install_dos_part is -2.
14788
14789 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
14790 and LVM devices.
14791
14792 * util/i386/pc/grub-setup.c (setup): New argument
14793 MUST_EMBED. Force embedding of GRUB when the argument is
14794 true. Close FILE before returning.
14795 (main): Add support for RAID and LVM.
f19dbdb7 14796
2b002173 14797 * conf/common.rmk: Add RAID and LVM modules.
14798 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
14799 util/lvm.c.
14800 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
14801
14802 * kern/misc.c (grub_strstr): New function.
14803 * include/grub/misc.h (grub_strstr): New prototype.
14804
050548d0 148052006-10-10 Tristan Gingold <tristan.gingold@bull.net>
14806
14807 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
14808
da849d2d 148092006-10-05 Tristan Gingold <tristan.gingold@bull.net>
14810
14811 * kern/misc.c (grub_strtoull): Guess the base only if not
14812 specified.
14813
97b2f2ff 148142006-10-01 Hollis Blanchard <hollis@penguinppc.org>
4f0acd39 14815
14816 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
14817 PowerMac support.
14818
97b2f2ff 148192006-10-01 Hollis Blanchard <hollis@penguinppc.org>
fba51f48 14820
14821 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
14822
14823 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
14824 Remove `flags' argument. All callers changed.
14825 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
14826 (IEEE1275_IHANDLE_INVALID): New variable.
14827 (IEEE1275_CELL_INVALID): New variable.
14828 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
14829 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
14830 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
14831 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
14832 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
14833 codes from Open Firmware. All callers updated.
14834 (grub_ieee1275_next_property): Directly return Open Firmware return
14835 code.
14836 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
14837 Standardize error checking from `grub_ieee1275_get_property'.
14838 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
14839 `devalias' to `aliases'. Correct comments. Consolidate error paths.
14840
97b2f2ff 148412006-10-01 Hollis Blanchard <hollis@penguinppc.org>
cc6d3df3 14842
14843 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
14844 `instance_to_package_args' to `instance_to_path_args'.
14845
14846 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
14847 `grub_ieee1275_chosen'.
14848
14849 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
14850 `grub_ieee1275_interpret'.
14851
97b2f2ff 148522006-09-25 Hollis Blanchard <hollis@penguinppc.org>
02bb8acc 14853
14854 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
14855
97b2f2ff 148562006-09-25 Hollis Blanchard <hollis@penguinppc.org>
663b72f0 14857
14858 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
14859 (__cmpdi): Likewise.
14860
14861 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
14862 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
14863 `grub_ssize_t'.
14864
02bb8acc 14865 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
663b72f0 14866
14867 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
14868 to type `grub_ssize_t'.
14869 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
14870
7f9a8531 148712006-09-22 Marco Gerards <marco@gnu.org>
14872
14873 * normal/script.c (grub_script_create_cmdmenu): Skip leading
14874 newlines.
14875
b5ef1102 148762006-09-22 Marco Gerards <marco@gnu.org>
14877
14878 * commands/echo.c: New file.
14879
14880 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
14881
14882 * conf/common.rmk (echo_mod_SOURCES): New variable.
14883 (echo_mod_CFLAGS): Likewise.
14884 (echo_mod_LDFLAGS): Likewise.
14885
2cff3677 148862006-09-22 Marco Gerards <marco@gnu.org>
14887
14888 * normal/main.c (get_line): Malloc memory instead of using
14889 preallocated memory. Removed the arguments `cmdline' and
14890 `max_len'. Updated all callers.
14891
6ba4688b 148922006-09-22 Marco Gerards <marco@gnu.org>
14893
14894 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
14895 (normal_mod_DEPENDENCIES): Likewise.
14896
14897 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
14898 (normal_mod_DEPENDENCIES): Likewise.
14899
14900 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
14901
e02ac02c 149022006-09-22 Johan Rydberg <jrydberg@gnu.org>
14903
14904 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
14905 programs.
14906 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
14907 (normal_mod_DEPENDENCIES): Likewise.
14908 * conf/i386-pc.mk: Regenerate.
14909 * conf/i386-efi.mk: Likewise
14910 * conf/common.mk: Likewise.
14911 * conf/powerpc-ieee1275.mk: Likewise.
14912 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 14913
8d252e44 149142006-09-22 Robert Millan <rmh@aybabtu.com>
14915
14916 Sync with i386 version.
14917 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
14918 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
14919
209bf7ac 149202006-09-21 Robert Millan <rmh@aybabtu.com>
14921
14922 Import from GRUB Legacy (lib/device.c):
14923 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
14924 (init_device_map) [__linux__]: Add support for I2O devices.
14925
6b146090 149262006-09-14 Marco Gerards <marco@gnu.org>
14927
14928 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
14929 `-melf_i386'.
14930
e38600a8 149312006-09-14 Robert Millan <rmh@aybabtu.com>
2952da5d 14932
14933 * util/i386/pc/grub-install.in: Skip menu.lst when removing
14934 /boot/grub/*.lst.
78fa1790 14935
2952da5d 14936 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
6b146090 14937
2952da5d 14938 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
14939 before adding it to device.map.
14940
01b82a64 149412006-08-15 Johan Rydberg <jrydberg@gnu.org>
14942
fe6b695a 14943 * genmk.rb: Let GCC generate dependencies the first time it
01b82a64 14944 compiles a file; using the -MD option.
14945 * conf/common.mk: Regenerate.
14946 * conf/i386-pc.mk: Likewise.
14947 * conf/i386-efi.mk: Likewise.
14948 * conf/powerpc-ieee1275.mk: Likewise.
14949 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 14950
1064790d 149512006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
14952
14953 Move the prototypes of grub_setjmp and grub_longjmp to
14954 cpu/setjmp.h, so that each architecture may specify different
14955 attributes.
f19dbdb7 14956
1064790d 14957 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
14958 (grub_longjmp): Likewise.
14959 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
14960 (grub_longjmp): Likewise.
14961 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
14962 (grub_longjmp): Likewise.
14963
14964 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
14965 [!GRUB_UTIL] (grub_longjmp): Removed.
14966
29dda3ed 149672006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
14968
14969 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
14970 "color!" method does not return any value.
14971
ad2a06ed 149722006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
14973
14974 * include/grub/bitmap.h: New file.
14975
14976 * include/grub/i386/pc/vbeutil.h: Likewise.
14977
14978 * video/bitmap.c: Likewise.
14979
14980 * video/readers/tga.c: Likewise.
14981
14982 * video/i386/pc/vbeutil.c: Likewise.
14983
14984 * commands/videotest.c: Code cleanup and updated to reflect to new
14985 video API.
14986
14987 * term/gfxterm.c: Likewise.
14988
14989 * video/video.c: Likewise.
14990
14991 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
14992 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
14993 (bitmap_mod_SOURCES): New entry.
14994 (bitmap_mod_CFLAGS): Likewise.
14995 (bitmap_mod_LDFLAGS): Likewise.
14996 (tga_mod_SOURCES): Likewise.
14997 (tga_mod_CFLAGS): Likewise.
14998 (tga_mod_LDFLAGS): Likewise.
14999
15000 * include/grub/video.h (grub_video_blit_operators): New enum type.
15001 (grub_video_render_target): Changed as forward declaration and moved
15002 actual definition to be video driver specific.
15003 (grub_video_adapter.blit_bitmap): Added blitting operator.
15004 (grub_video_adapter.blit_render_target): Likewise.
15005 (grub_video_blit_bitmap): Likewise.
15006 (grub_video_blit_render_target): Likewise.
15007
15008 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
15009 driver specific render target definition.
15010 (grub_video_vbe_map_rgba): Added driver internal helper.
15011 (grub_video_vbe_unmap_color): Updated to use
15012 grub_video_i386_vbeblit_info.
15013 (grub_video_vbe_get_video_ptr): Likewise.
15014
15015 * include/grub/i386/pc/vbeblit.h
15016 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
15017 grub_video_i386_vbeblit_info.
15018 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
15019 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
15020 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
15021 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
15022 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
15023 (grub_video_i386_vbeblit_index_index): Likewise.
15024 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
15025 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
15026 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
15027 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
15028 operator.
15029 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
15030 operator.
15031
15032 * video/i386/pc/vbeblit.c: Updated to reflect changes on
15033 include/grub/i386/pc/vbeblit.h.
15034
15035 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
15036 Updated to use grub_video_i386_vbeblit_info.
15037 (grub_video_i386_vbefill_R8G8B8): Likewise.
15038 (grub_video_i386_vbefill_index): Likewise.
15039 (grub_video_i386_vbefill): Added generic filler.
15040
15041 * video/i386/pc/vbefill.c: Updated to reflect changes on
15042 include/grub/i386/pc/vbefill.h.
15043
15044 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
15045 grub_video_i386_vbeblit_info.
15046 (grub_video_vbe_unmap_color): Likewise.
15047 (grub_video_vbe_blit_glyph): Likewise.
15048 (grub_video_vbe_scroll): Likewise.
15049 (grub_video_vbe_draw_pixel): Removed function.
15050 (grub_video_vbe_get_pixel): Likewise.
15051 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
15052 updated code to use it.
15053 (common_blitter): Added common blitter for render target and bitmap.
15054 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
15055 (grub_video_vbe_blit_render_target): Likewise.
15056
bc8c036d 150572006-07-30 Johan Rydberg <jrydberg@gnu.org>
15058
15059 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
15060 is in text mode if there is no console control protocol instance
15061 available.
15062
684a8eff 150632006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15064
15065 * include/grub/video.h: Code cleanup.
15066
15067 * include/grub/i386/pc/vbe.h: Likewise.
15068
15069 * video/i386/pc/vbe.c: Likewise.
15070
15071 * video/i386/pc/vbeblit.c: Likewise.
15072
15073 * video/i386/pc/vbefill.c: Likewise.
15074
15075 * video/video.c: Likewise. Also added more comments.
15076
5915059b 150772006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15078
15079 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
15080 (struct grub_biosdisk_dap): Likewise.
15081
15082 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
15083 linkage settings for all functions.
15084
90ce5d56 150852006-07-12 Marco Gerards <marco@gnu.org>
15086
15087 * configure.ac (--enable-mm-debug): Fix typo.
15088
15089 * genkernsyms.sh.in: Use proper quoting for `CC'.
15090
43e7f879 150912006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
15092
15093 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
15094 (normal_mod_ASFLAGS): Remove "-m32".
15095
4889bdec 150962006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
15097
15098 * util/misc.c: Include config.h.
15099 [!HAVE_MEMALIGN]: Do not include malloc.h.
15100 (grub_memalign): Use posix_memalign, if present. Then, use
15101 memalign, if present. Otherwise, emit an error.
15102
15103 * util/grub-emu.c: Do not include malloc.h.
15104
15105 * include/grub/util/misc.h: Include unistd.h. This is required for
15106 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
15107 D. Eades III <hde@foobar-qux.org>.
15108
15109 * configure.ac (AC_GNU_SOURCE): Added.
15110 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
15111 type.
15112
fd39d4da 151132006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
15114
15115 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
15116 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
15117
b786f3b5 151182006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
15119
15120 * include/grub/types.h (grub_host_addr_t): Rename to
15121 grub_target_addr_t.
15122 (grub_host_off_t): Rename to grub_target_off_t.
15123 (grub_host_size_t): Rename to grub_target_size_t.
15124 (grub_host_ssize_t): Rename to grub_target_ssize_t.
15125 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
15126
15127 * include/grub/kernel.h (struct grub_module_header): Change type
15128 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
15129 (grub_module_info): Likewise.
f19dbdb7 15130
051988bb 151312006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15132
15133 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
15134 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
15135 Velazquez <jesus.velazquez@gmail.com>.
15136
deae281b 151372006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15138
15139 Count partitions from 1 instead of 0 in the string representation
15140 of partitions. Still use 0-based internally.
f19dbdb7 15141
deae281b 15142 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
15143 (sun_partition_map_iterate): Use grub_partition_t instead of
15144 struct grub_partition *. Cast DESC->START_CYLINDER to
15145 grub_uint64_t after converting the endian.
15146 (sun_partition_map_probe): Subtract 1 for PARTNUM.
15147 (sun_partition_map_get_name): Add 1 to P->INDEX.
15148
15149 * partmap/pc.c (grub_partition_parse): Subtract 1 for
15150 PCDATA->DOS_PART.
15151 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
15152
15153 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
15154 zero instead of one.
15155 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
15156 (gpt_partition_map_get_name): Add 1 into P->INDEX.
15157
15158 * partmap/apple.c (apple_partition_map_iterate): Change the type
15159 of POS to unsigned.
15160 (apple_partition_map_probe): Subtract 1 for PARTNUM.
15161 (apple_partition_map_get_name): Add 1 into P->INDEX.
15162
15163 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
15164 of POS to unsigned.
15165 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
15166 calculate the offset of a partition.
15167 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
15168 (amiga_partition_map_get_name): Add 1 into P->INDEX.
15169
15170 * partmap/acorn.c (acorn_partition_map_find): Change the type of
15171 SECTOR to grub_disk_addr_t.
15172 (acorn_partition_map_iterate): Likewise.
15173 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
15174 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
15175 top.
15176 (acorn_partition_map_get_name): Add 1 into P->INDEX.
15177
15178 * kern/i386/pc/init.c (make_install_device): Add 1 into
15179 GRUB_INSTALL_DOS_PART.
15180
15181 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
15182 conditional.
15183
524a1e6a 151842006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15185
15186 Clean up the code to support 64-bit addressing in disks and
15187 files. This change is not enough for filesystems yet.
f19dbdb7 15188
524a1e6a 15189 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
15190 type of "start" to grub_uint64_t.
15191 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
15192 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
15193 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
15194 convert addresses.
15195
15196 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
15197 to grub_disk_addr_t.
15198
15199 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
15200 string.
15201
15202 * partmap/pc.c (pc_partition_map_iterate): Likewise.
15203
15204 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
15205 to char *.
15206
15207 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
15208
15209 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
15210
15211 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
15212
15213 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
15214 to grub_off_t, to detect an error from grub_file_seek.
15215 (grub_multiboot_load_elf32): Likewise.
15216
15217 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
15218 maximum unsigned long value when an overflow is detected.
15219 (grub_strtoull): New function.
15220 (grub_divmod64): Likewise.
15221 (grub_lltoa): use grub_divmod64.
15222
15223 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
15224 grub_disk_addr_t.
15225 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
15226 the pointer to next character. Use grub_strtoull instead of
15227 grub_strtoul.
15228 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
15229 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
15230 respectively.
15231
fe6b695a 15232 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
524a1e6a 15233 return value is signed.
15234 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
15235 test if OFFSET is less than zero, as OFFSET is unsigned now.
15236
15237 * kern/disk.c (struct grub_disk_cache): Change the type of
15238 "sector" to grub_disk_addr_t.
15239 (grub_disk_cache_get_index): Change the type of SECTOR to
15240 grub_disk_addr_t. Calculate the hash with SECTOR casted to
15241 unsigned after shifting.
15242 (grub_disk_cache_invalidate): Change the type of SECTOR to
15243 grub_disk_addr_t.
15244 (grub_disk_cache_unlock): Likewise.
15245 (grub_disk_cache_store): Likewise.
15246 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
15247 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
15248 grub_disk_addr_t and grub_uint64_t, respectively.
15249 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
15250 body, as the value of OFFSET is tweaked by
15251 grub_disk_check_range. Change the types of START_SECTOR, LEN and
15252 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
15253 respectively.
15254 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
15255 body, as the value of OFFSET is tweaked by
15256 grub_disk_check_range. Change the types of LEN and N to
15257 grub_size_t.
15258
15259 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
15260 and "saved_offset" to grub_off_t.
15261 (test_header): Cast BUF to char *.
15262 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
15263 to char *.
15264 (grub_gzio_read): Change the types of OFFSET and SIZE to
15265 grub_off_t and grub_size_t, respectively.
15266
15267 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
15268 Removed.
15269 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
15270 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
15271 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
15272 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
15273 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
15274
15275 * include/grub/types.h (grub_off_t): Unconditionally set to
15276 grub_uint64_t.
15277 (grub_disk_addr_t): Changed to grub_uint64_t.
15278
15279 * include/grub/partition.h (struct grub_partition): Change the
15280 types of "start", "len" and "offset" to grub_disk_addr_t,
15281 grub_uint64_t and grub_disk_addr_t, respectively.
15282 (grub_partition_get_start): Return grub_disk_addr_t.
15283 (grub_partition_get_len): Return grub_uint64_t.
15284
15285 * include/grub/misc.h (grub_strtoull): New prototype.
15286 (grub_divmod64): Likewise.
15287
15288 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
15289 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
15290 grub_off_t, respectively.
15291 All callers and references changed.
15292
15293 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
15294 grub_size_t in "read".
15295 All callers and references changed.
15296
15297 * include/grub/file.h (struct grub_file): Change the types of
15298 "offset" and "size" to grub_off_t and grub_off_t,
15299 respectively. Change the type of SECTOR to grub_disk_addr_t in
15300 "read_hook".
15301 (grub_file_read): Change the type of LEN to grub_size_t.
15302 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
15303 grub_off_t.
15304 (grub_file_size): Return grub_off_t.
15305 (grub_file_tell): Likewise.
15306 All callers and references changed.
15307
15308 * include/grub/disk.h (struct grub_disk_dev): Change the types of
15309 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
15310 "write".
15311 (struct grub_disk): Change the type of "total_sectors" to
15312 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
f19dbdb7 15313 "read_hook".
524a1e6a 15314 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
15315 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
15316 (grub_disk_write): Likewise.
15317 All callers and references changed.
15318
15319 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
15320 char * for grub_strncmp to silence gcc.
15321 (grub_iso9660_mount): Likewise.
15322 (grub_iso9660_mount): Likewise.
15323 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
15324 return statement.
15325 (grub_iso9660_iterate_dir): Likewise.
15326 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
15327
15328 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
15329 LEN to grub_disk_addr_t and grub_size_t, respectively.
15330
15331 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
15332
15333 * fs/jfs.c (grub_jfs_read_file): Likewise.
15334
15335 * fs/minix.c (grub_jfs_read_file): Likewise.
15336
15337 * fs/sfs.c (grub_jfs_read_file): Likewise.
15338
15339 * fs/ufs.c (grub_jfs_read_file): Likewise.
15340
15341 * fs/xfs.c (grub_jfs_read_file): Likewise.
15342
15343 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
15344 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
15345 respectively.
15346
15347 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
15348 BLKNR to -1 instead of returning GRUB_ERRNO.
15349 (grub_ext2_read_file): Change the types of SECTOR and
15350 LEN to grub_disk_addr_t and grub_size_t, respectively.
15351
15352 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
15353 LEN to grub_disk_addr_t and grub_size_t, respectively.
15354
15355 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
15356 grub_file_read.
15357
15358 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
15359 string. Do not cast SECTOR explicitly.
15360
15361 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
15362 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
15363 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
15364 grub_disk_addr_t and grub_size_t, respectively. If the sector is
15365 over 2TB and LBA mode is not supported, raise an error.
15366 (get_safe_sectors): New function.
15367 (grub_biosdisk_read): Use get_safe_sectors.
15368 (grub_biosdisk_write): Likewise.
15369
15370 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
15371 (grub_efidisk_write): Likewise.
15372
15373 * disk/loopback.c (delete_loopback): Cosmetic changes.
15374 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
15375 correctly.
15376 (grub_loopback_open): Likewise.
15377 (grub_loopback_read): Likewise. Also, change the type of POS to
15378 grub_off_t, and fix the usage of grub_memset.
15379
15380 * commands/i386/pc/play.c: Include grub/machine/time.h.
15381
15382 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
15383 print FILE->SIZE.
15384
15385 * commands/configfile.c: Include grub/env.h.
15386
15387 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
15388 GRUB_ERRNO directly instead. Change the type of POS to
15389 grub_off_t. Follow the coding standard.
15390
15391 * commands/blocklist.c: Include grub/partition.h.
15392 (grub_cmd_blocklist): Return an error if the underlying device is
15393 not a disk. Take the starting sector of a partition into account,
15394 if a partition is used.
15395
15396 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
15397 a length field.
15398 (lba_mode): Support 64-bit addresses.
15399 (chs_mode): Likewise.
15400 (copy_buffer): Adapted to the new offsets of a length field and a
15401 segment field.
15402 (blocklist_default_start): Allocate 64-bit space.
15403
15404 * boot/i386/pc/boot.S (force_lba): Removed.
15405 (boot_drive): Moved to under KERNEL_SECTOR.
fe987087 15406 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
524a1e6a 15407 space.
15408 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
15409 is useless.
15410 (lba_mode): Refactored to support a 64-bit address. More size
15411 optimization.
15412 (setup_sectors): Likewise.
15413
53af98ad 154142006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15415
15416 * DISTLIST: Added include/grub/i386/linux.h. Removed
15417 include/grub/i386/pc/linux.h
15418
15419 * configure.ac (AC_INIT): Bumped to 1.94.
15420
15421 * config.guess: Updated from gnulib.
15422 * config.sub: Likewise.
15423 * install-sh: Likewise.
15424 * mkinstalldirs: Likewise.
15425
b4c1940a 154262006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15427
15428 * conf/common.rmk (grub_modules_init.lst): Depended on
15429 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
15430 MODSRCFILES.
15431
15432 * genmk.rb (PModule::rule): Reverted the previous change.
15433
cfca1cfd 154342006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15435
15436 * conf/common.rmk (grub_modules_init.lst): Depends on
15437 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
15438 that the target does not exist before producing.
15439 (grub_modules_init.h): Remove the target before generating.
15440 (grub_emu_init.c): Likewise.
15441
15442 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
15443
aa6d7826 154442006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
15445
15446 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
15447 for the target-specific tests. Make sure that we also have the
15448 up-to-date target variables for those tests.
15449
26c607b9 154502006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15451
15452 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
15453 (PModule::rule): Likewise.
15454
0162321a 154552006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15456
15457 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
15458 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
15459 target-specific flags should be prefixed.
15460 (PModule::rule): Likewise.
15461
6c826348 154622006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
15463
15464 * configure.ac (CMP): Check if cmp is available explicitly.
15465
b977bf01 154662006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
15467
15468 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
15469 (target_cpu): New variable.
15470 (pkglibdir): Use target_cpu instead of host_cpu.
f19dbdb7 15471
b977bf01 15472 * util/i386/pc/grub-install.in (host_cpu): Removed.
15473 (target_cpu): New variable.
15474 (pkglibdir): Use target_cpu instead of host_cpu.
15475
15476 * util/genmoddep.c: Removed.
f19dbdb7 15477
b977bf01 15478 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
15479 instead of GRUB_HOST_SIZEOF_VOID_P.
15480 * kern/dl.c: Likewise.
15481
15482 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
15483 ...
15484 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15485 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15486 (GRUB_TARGET_SIZEOF_LONG): ... this.
15487 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15488 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15489 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15490 to ...
15491 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15492 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15493 (GRUB_TARGET_SIZEOF_LONG): ... this.
15494 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15495 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15496 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15497 to ...
15498 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15499 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15500 (GRUB_TARGET_SIZEOF_LONG): ... this.
15501 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15502 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15503
15504 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
15505 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
15506 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
15507 instead of GRUB_HOST_SIZEOF_LONG.
15508 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
15509 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
15510 GRUB_CPU_WORDS_BIGENDIAN.
15511 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
15512 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
15513 grub_host_ssize_t.
15514
15515 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
15516 (genmoddep_SOURCES): Likewise.
15517 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
15518 (genmoddep_SOURCES): Likewise.
15519 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
15520 (genmoddep_SOURCES): Likewise.
15521 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
15522 Likewise.
15523 (genmoddep_SOURCES): Likewise.
15524
15525 * genmoddep.awk: New file.
15526
15527 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
15528 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
15529 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
15530 (PModule::rule): Likewise.
15531 (Program::rule): Likewise.
15532 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
15533 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
15534 respectively.
15535
15536 * configure.ac: Rewritten intensively to use host and target
15537 instead of build and host, respectively.
15538
15539 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
15540 (host_cpu): Removed.
15541 (target_cpu): New variable.
15542 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
15543 (BUILD_CC): Removed.
15544 (BUILD_CFLAGS): Likewise.
15545 (BUILD_CPPFLAGS): Likewise.
15546 (TARGET_CC): New variable.
15547 (TARGET_CFLAGS): Likewise.
15548 (TARGET_CPPFLAGS): Likewise.
15549 (TARGET_LDFLAGS): Likewise.
15550 (AWK): Likewise.
15551 (include): Use target_cpu instead of host_cpu.
15552 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
f19dbdb7 15553
b977bf01 15554 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
15555
f09771a1 155562006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
15557
15558 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
15559 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
15560 field 'false' to 'exec_on_false'.
15561 (grub_script_create_cmdif): Renamed argument names to reflect above
15562 changes.
15563
15564 * normal/execute.c (grub_script_execute_cmdif): Likewise.
15565
15566 * normal/script.c (grub_script_create_cmdif): Likewise.
15567
118f4fb3 155682006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
15569
15570 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
15571 top.
15572 (grub_hfsplus_btree_recptr): Likewise.
15573 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
15574 FILEBLOCK both to pass a block number and store next block
15575 number.
15576 (grub_hfsplus_read_block): Rewritten heavily to support an extent
15577 overflow file correctly. Specify errors appropriately, because
15578 fshelp expects that GRUB_ERRNO is set when fails. Reuse
15579 grub_hfsplus_btree_recptr to get the pointer to a found key.
15580 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
15581 is found.
15582
15583 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
15584 linux.mod.
15585 (_linux_mod_SOURCES): New variable.
15586 (_linux_mod_CFLAGS): Likewise.
15587 (_linux_mod_LDFLAGS): Likewise.
15588 (linux_mod_SOURCES): Likewise.
15589 (linux_mod_CFLAGS): Likewise.
15590 (linux_mod_LDFLAGS): Likewise.
15591
15592 * DISTLIST: Added loader/i386/efi/linux.c,
15593 loader/i386/efi/linux_normal.c and
15594 include/grub/i386/efi/loader.h.
15595
15596 * loader/i386/efi/linux.c: New file.
15597 * loader/i386/efi/linux_normal.c: Likewise.
15598 * include/grub/i386/efi/loader.h: Likewise.
15599
89a7d726 156002006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
15601
15602 * commands/blocklist.c: New file.
15603
15604 * DISTLIST: Added commands/blocklist.c.
15605
15606 * term/efi/console.c (grub_console_highlight_color): Use a lighter
43b553ad 15607 color for the background, and a darker color for the foreground.
89a7d726 15608 (grub_console_checkkey): Return READ_KEY.
15609 (grub_console_cls): Set the background to
15610 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
15611
15612 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
15613
15614 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
15615 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
15616
15617 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
15618 prototype.
15619
15620 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
15621 BG. The spec is wrong again.
15622
15623 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
15624 prototype.
15625 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
15626
15627 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
15628 commands/blocklist.c.
15629 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
f19dbdb7 15630
89a7d726 15631 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
15632 (blocklist_mod_SOURCES): New variable.
15633 (blocklist_mod_CFLAGS): Likewise.
15634 (blocklist_mod_LDFLAGS): Likewise.
15635
75c8f258 156362006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
15637
15638 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
15639 duplication.
15640 (lba_mode): Use %eax more intensively to reduce the code size.
15641
da2eb181 156422006-05-20 Marco Gerards <marco@gnu.org>
15643
15644 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
15645
15646 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
15647 for `menuentry'.
15648 (script): Accept leading newlines.
15649 (newlines): New rule to describe 0 or more newlines.
15650 (commands): Accept `command' with trailing newline. Fixed the
15651 order in which arguments were passed to `grub_script_add_cmd'.
15652 Accept commands separated by newlines.
15653 (function): Changed to accept newlines.
15654 (menuentry) Rewritten.
15655
15656 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
15657 front of the list, instead of to the end.
15658
577b4050 156592006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
15660
15661 * util/i386/pc/grub-install.in (bindir): New variable.
15662 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
15663 Shaver <lbgwjl@gmail.com>.
15664
0d6e1189 156652006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
15666
15667 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
15668 grub/machine/linux.h
15669 * loader/i386/pc/linux.c: Likewise.
15670
15671 * include/grub/i386/pc/linux.h: Moved to ...
15672 * include/grub/i386/linux.h: ... here.
15673
15674 * include/grub/i386/linux.h (struct linux_kernel_params): New
15675 struct.
f19dbdb7 15676
31b86e9f 156772006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
15678
15679 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
15680 checking.
15681 (grub_video_vbe_blit_glyph): Likewise.
15682 (grub_video_vbe_blit_bitmap): Likewise.
15683 (grub_video_vbe_blit_render_target): Likewise.
15684
83b984de 156852006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
15686
15687 * configure.ac (--with-platform): Properly quote the square
15688 brackets.
15689
5f0413bd 156902006-05-08 Marco Gerards <marco@gnu.org>
15691
15692 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
15693 this...
15694 (kernel_elf_HEADERS): ...to this. Updated all users.
15695 (grubof_symlist.c): Renamed from this...
15696 (kernel_elf_symlist.c): ...to this. Updated all users.
15697 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15698 (grubof_SOURCES): Renamed from this...
15699 (kernel_elf_SOURCES): ...to this.
15700 (grubof_HEADERS): Renamed from this...
15701 (kernel_elf_HEADERS): ...to this.
15702 (grubof_CFLAGS): Renamed from this...
15703 (kernel_elf_CFLAGS): ...to this.
15704 (grubof_ASFLAGS): Renamed from this...
15705 (kernel_elf_ASFLAGS): ...to this.
15706 (grubof_LDFLAGS): Renamed from this...
15707 (kernel_elf_LDFLAGS): ...to this.
15708
15709 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
15710 this...
15711 (kernel_elf_HEADERS): ...to this. Updated all users.
15712 (grubof_symlist.c): Renamed from this...
15713 (kernel_elf_symlist.c): ...to this. Updated all users.
15714 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15715 (grubof_SOURCES): Renamed from this...
15716 (kernel_elf_SOURCES): ...to this.
15717 (grubof_HEADERS): Renamed from this...
15718 (kernel_elf_HEADERS): ...to this.
15719 (grubof_CFLAGS): Renamed from this...
15720 (kernel_elf_CFLAGS): ...to this.
15721 (grubof_ASFLAGS): Renamed from this...
15722 (kernel_elf_ASFLAGS): ...to this.
15723 (grubof_LDFLAGS): Renamed from this...
15724 (kernel_elf_LDFLAGS): ...to this.
15725
15726 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
15727 `kernel.elf' instead of `grubof'.
15728
05568c2e 157292006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
15730
15731 Add --with-platform to configure. Use pkglibdir instead of
15732 pkgdatadir. This is reported by Roger Leigh.
15733
15734 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
15735 (host_vendor): Likewise.
15736 (host_os): Likewise.
15737 (pkgdatadir): Likewise.
15738 (platform): New variable.
15739 (pkglibdir): Likewise.
15740 Use PKGLIBDIR instead of PKGDATADIR.
f19dbdb7 15741
05568c2e 15742 * util/i386/pc/grub-install.in (datadir): Removed.
15743 (host_vendor): Likewise.
15744 (host_os): Likewise.
15745 (pkgdatadir): Likewise.
15746 (platform): New variable.
15747 (pkglibdir): Likewise.
15748 Use PKGLIBDIR instead of PKGDATADIR.
15749
15750 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
15751 instead of GRUB_DATADIR.
15752 (main): Likewise.
15753 * util/i386/pc/grub-mkimage.c (usage): Likewise.
15754 (main): Likewise.
15755 * util/i386/efi/grub-mkimage.c (usage): Likewise.
15756 (main): Likewise.
15757
15758 * configure.ac (--with-platform): New option.
15759 Use PLATFORM instead of HOST_VENDOR to specify a platform.
15760
15761 * Makefile.in: Include a makefile based on PLATFORM instead of
15762 HOST_VENDOR.
15763 (pkgdatadir): Not appended by the machine type.
15764 (pkglibdir): Appended by the machine type.
15765 (host_vendor): Removed.
15766 (platform): New variable.
15767 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
15768 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
15769 (uninstall): Likewise.
15770
4e93851c 157712006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
15772
15773 Use the environment context in the menu. Remove the commands
15774 "default" and "timeout", and use variables instead.
f19dbdb7 15775
4e93851c 15776 * normal/menu.c: Include grub/env.h.
15777 (print_entry): Cast TITLE to silence gcc.
15778 (get_timeout): New function.
15779 (set_timeout): Likewise.
15780 (get_entry_number): Likewise.
15781 (run_menu): Use a default entry, a fallback entry and a timeout
15782 in the environment variables "default", "fallback" and
15783 "timeout". Also, tweak the default entry if it is not within the
15784 current menu entries.
15785 (grub_menu_run): Use a fallback entry in the environment variable
15786 "fallback".
15787
15788 * normal/main.c (read_config_file): Do not initialize
15789 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
15790 NEWMENU->TIMEOUT.
15791 (grub_normal_execute): Use a data slot to store the menu.
15792
15793 * include/grub/normal.h (struct grub_menu): Removed default_entry,
15794 fallback_entry and timeout.
15795 (struct grub_menu_list): Removed.
15796 (grub_menu_list_t): Likewise.
15797 (struct grub_context): Likewise.
15798 (grub_context_t): Likewise.
15799 (grub_context_get): Likewise.
15800 (grub_context_get_current_menu): Likewise.
15801 (grub_context_push_menu): Likewise.
15802 (grub_context_pop_menu): Likewise.
15803 (grub_default_init): Likewise.
15804 (grub_default_fini): Likewise.
15805 (grub_timeout_init): Likewise.
15806 (grub_timeout_fini): Likewise.
15807
15808 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
15809 and timeout.mod.
15810 (normal_mod_SOURCES): Removed normal/context.c.
15811
15812 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
15813 commands/default.c, commands/timeout.c and normal/context.c.
15814 (normal_mod_SOURCES): Removed normal/context.c.
15815
15816 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
15817 commands/timeout.c and normal/context.c.
15818 (normal_mod_SOURCES): Removed normal/context.c.
15819
15820 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
15821 commands/default.c, commands/timeout.c and normal/context.c.
15822 (normal_mod_SOURCES): Removed normal/context.c.
15823
15824 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
15825 timeout.mod.
15826 (default_mod_SOURCES): Removed.
15827 (default_mod_CFLAGS): Likewise.
15828 (default_mod_LDFLAGS): Likewise.
15829 (timeout_mod_SOURCES): Removed.
15830 (timeout_mod_CFLAGS): Likewise.
15831 (timeout_mod_LDFLAGS): Likewise.
15832
15833 * DISTLIST: Removed commands/default.c, commands/timeout.c and
15834 normal/context.c.
15835
15836 * commands/default.c: Removed.
15837 * commands/timeout.c: Likewise.
15838 * normal/context.c: Likewise.
15839
1eb9cc1d 158402006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
15841
15842 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
15843
385bd9c1 158442006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
15845
15846 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
15847 "next" to "prev" for readability.
15848 (struct grub_env_sorted_var): New struct.
15849 (grub_env_context): Renamed to ...
15850 (initial_context): ... this.
15851 (grub_env_var_context): Renamed to ...
15852 (current_context): ... this.
15853 (grub_env_find): Look only at CURRENT_CONTEXT.
15854 (grub_env_context_open): Rewritten to copy exported variables from
15855 previous context.
15856 (grub_env_context_close): Rewritten according to the new
15857 scheme. Also, add an assertion to prevent the initial context from
15858 removed.
15859 (grub_env_insert): Removed the code for the sorted list.
15860 (grub_env_remove): Likewise.
15861 (grub_env_export): Simply mark the variable with
15862 GRUB_ENV_VAR_GLOBAL.
15863 (grub_env_set): A cosmetic change for naming consistency.
15864 (grub_env_get): Likewise.
15865 (grub_env_unset): Likewise.
15866 (grub_env_iterate): Rewritten to sort variables within this
15867 function.
15868 (grub_register_variable_hook): Fixed for naming consistency. Call
15869 grub_env_find again, only if NAME is not found at the first time.
15870 (mangle_data_slot_name): New function.
15871 (grub_env_set_data_slot): Likewise.
15872 (grub_env_get_data_slot): Likewise.
15873 (grub_env_unset_data_slot): Likewise.
15874
15875 * include/grub/env.h (grub_env_var_type): New enum.
15876 (GRUB_ENV_VAR_LOCAL): New constant.
15877 (GRUB_ENV_VAR_GLOBAL): Likewise.
15878 (GRUB_ENV_VAR_DATA): Likewise.
15879 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
15880 "type".
15881 (grub_env_set): Replace VAR with NAME for consistency.
15882 (grub_register_variable_hook): Likewise.
15883 (grub_env_export): Specify the name of the argument.
15884 (grub_env_set_data_slot): New prototype.
15885 (grub_env_get_data_slot): Likewise.
15886 (grub_env_unset_data_slot): Likewise.
15887
7f362539 158882006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
15889
15890 Extend the loader so that GRUB can accept a loader which comes
15891 back to GRUB when a loaded image exits. Also, this change adds
15892 support for a chainloader on EFI.
f19dbdb7 15893
7f362539 15894 * term/efi/console.c: Include grub/misc.h.
15895 (grub_console_checkkey): Display a scan code on the top for
15896 debugging. This will be removed once the EFI port gets stable.
15897 Correct the scan code mapping.
15898
15899 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
15900 allocate memory from larger regions, in order to reduce the number
15901 of allocated regions. Otherwise, the MacOSX loader panics.
15902 (filter_memory_map): Avoid less than 1MB for compatibility with
15903 other loaders.
15904 (add_memory_regions): Allocate from the tail of a region, if
15905 possible, to avoid allocating a region near to 1MB, for the MacOSX
15906 loader.
15907
15908 * kern/efi/init.c (grub_efi_set_prefix): Specify
15909 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
15910
15911 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
15912 argument IMAGE_HANDLE and specify it to get a loaded image.
15913 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
15914 grub_efi_get_loaded_image.
fe6b695a 15915 (grub_efi_get_filename): Divide the length by the size of
7f362539 15916 grub_efi_char16_t.
15917 (grub_efi_get_device_path): New function.
15918 (grub_efi_print_device_path): Print End Device Path nodes. Divide
15919 the length by the size of grub_efi_char16_t for a file path device
15920 path node.
15921
15922 * kern/loader.c (grub_loader_noreturn): New variable.
15923 (grub_loader_set): Accept a new argument NORETURN. Set
15924 GRUB_LOADER_NORETURN to NORETURN.
15925 All callers changed.
15926 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
15927 grub_machine_fini.
15928
15929 * include/grub/efi/efi.h (grub_efi_get_device_path): New
15930 prototype.
15931 (grub_efi_get_loaded_image): Take an argument to specify an image
15932 handle.
15933
15934 * include/grub/loader.h (grub_loader_set): Added one more argument
15935 NORETURN.
15936
15937 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
15938 instead of grub_efi_open_protocol.
15939 (grub_efidisk_get_device_name): Likewise.
15940 (grub_efidisk_close): Print a newline.
15941 (grub_efidisk_get_device_handle): Fixed to use
15942 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
15943 GRUB_EFI_DEVICE_PATH_TYPE.
15944
15945 * disk/efi/efidisk.c (device_path_guid): Moved to ...
15946 * kern/efi/efi.c (device_path_guid): ... here.
15947
15948 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
15949 chain.mod.
15950 (kernel_mod_HEADERS): Added efi/disk.h.
15951 (_chain_mod_SOURCES): New variable.
15952 (_chain_mod_CFLAGS): Likewise.
15953 (_chain_mod_LDFLAGS): Likewise.
15954 (chain_mod_SOURCES): Likewise.
15955 (chain_mod_CFLAGS): Likewise.
15956 (chain_mod_LDFLAGS): Likewise.
15957
15958 * DISTLIST: Added include/grub/efi/chainloader.h,
15959 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
15960
15961 * include/grub/efi/chainloader.h: New file.
15962 * loader/efi/chainloader.c: Likewise.
15963 * loader/efi/chainloader_normal.c: Likewise.
15964
c0111d6e 159652006-04-30 Marco Gerards <marco@gnu.org>
15966
15967 * commands/configfile.c (grub_cmd_source): New function.
15968 (GRUB_MOD_INIT): Register the commands `source' and `.'.
15969 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
15970
df5341da 159712006-04-30 Marco Gerards <marco@gnu.org>
15972
15973 * normal/execute.c (grub_script_execute_cmd): Change the return
15974 type to `grub_err_t'. Correctly return the error.
15975 (grub_script_execute_cmdline): In case a command line is not a
15976 command or a function, try to interpret it as an assignment.
15977
f85934bd 159782006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
15979
15980 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
15981 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
15982 skip a node whose name is obviously invalid as UTF-16,
15983 i.e. contains a NUL character. Stop the iteration when the last
15984 directory entry is found. Instead of using the return value of
15985 grub_hfsplus_btree_iterate_node, store the value in RET and use
15986 it, because the iterator can be stopped by the last directory
15987 entry.
15988
8f8a2cf8 159892006-04-30 Marco Gerards <marco@gnu.org>
15990
15991 * include/grub/env.h (grub_env_export): New prototype. Reported
15992 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
15993
a27e84ce 159942006-04-30 Marco Gerards <marco@gnu.org>
15995
15996 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
15997 size of the extents in a catalog file record.
15998
eaef0553 159992006-04-29 Marco Gerards <marco@gnu.org>
16000
16001 * commands/configfile.c (grub_cmd_configfile): Execute the
16002 configfile within its own context.
16003
16004 * include/grub/env.h (grub_env_context_open): New prototype.
16005 (grub_env_context_close): Likewise.
16006
16007 * kern/env.c (grub_env): Removed.
16008 (grub_env_sorted): Likewise.
16009 (grub_env_context): New variable.
16010 (grub_env_var_context): Likewise.
16011 (grub_env_find): Search both the active context and the global
16012 context.
16013 (grub_env_context_open): New function.
16014 (grub_env_context_close): Likewise.
16015 (grub_env_insert): Likewise.
16016 (grub_env_remove): Likewise.
16017 (grub_env_export): Likewise.
16018 (grub_env_set): Changed to use helper functions to avoid code
16019 duplication.
16020 (grub_env_iterate): Rewritten so both the current context and the
16021 global context are being used.
16022
16023 * normal/command.c (export_command): New function.
16024 (grub_command_init): Register the `export' function.
16025
7b455f4d 160262006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
16027
16028 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
16029 explicitly to suppress gcc's warnings.
16030 * fs/fat.c (grub_fat_find_dir): Likewise.
16031 (grub_fat_label): Likewise.
16032 * fs/xfs.c (grub_xfs_read_inode): Likewise.
16033 (grub_xfs_mount): Likewise.
16034 (grub_xfs_label): Likewise.
16035 * fs/affs.c (grub_affs_mount): Likewise.
16036 (grub_affs_label): Likewise.
16037 (grub_affs_iterate_dir): Likewise.
16038 * fs/sfs.c (grub_sfs_mount): Likewise.
16039 (grub_sfs_iterate_dir): Likewise.
16040 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
16041 * fs/hfs.c (grub_hfs_mount): Likewise.
16042 (grub_hfs_cmp_catkeys): Likewise.
16043 (grub_hfs_find_dir): Likewise.
16044 (grub_hfs_dir): Likewise.
16045 (grub_hfs_label): Likewise.
16046 * fs/jfs.c (grub_jfs_mount): Likewise.
16047 (grub_jfs_opendir): Likewise.
16048 (grub_jfs_getent): Likewise.
16049 (grub_jfs_lookup_symlink): Likewise.
16050 (grub_jfs_label): Likewise.
16051 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
16052 (grub_hfsplus_iterate_dir): Likewise.
16053 (grub_hfsplus_btree_iterate_node): Made static.
16054
16055 * util/grub-emu.c (prefix): New variable.
16056 (grub_machine_set_prefix): New function.
16057 (main): Do not set the environment variable "prefix" here. Only
16058 set PREFIX, which is used later by grub_machine_set_prefix.
16059
16060 * include/grub/video.h: Do not include grub/symbol.h.
16061 (grub_video_register): Not exported. This symbol is not defined in
16062 the kernel.
16063 (grub_video_unregister): Likewise.
16064 (grub_video_iterate): Likewise.
16065 (grub_video_setup): Likewise.
16066 (grub_video_restore): Likewise.
16067 (grub_video_get_info): Likewise.
16068 (grub_video_get_blit_format): Likewise.
16069 (grub_video_set_palette): Likewise.
16070 (grub_video_get_palette): Likewise.
16071 (grub_video_set_viewport): Likewise.
16072 (grub_video_get_viewport): Likewise.
16073 (grub_video_map_color): Likewise.
16074 (grub_video_map_rgb): Likewise.
16075 (grub_video_map_rgba): Likewise.
16076 (grub_video_fill_rect): Likewise.
16077 (grub_video_blit_glyph): Likewise.
16078 (grub_video_blit_bitmap): Likewise.
16079 (grub_video_blit_render_target): Likewise.
16080 (grub_video_scroll): Likewise.
16081 (grub_video_swap_buffers): Likewise.
16082 (grub_video_create_render_target): Likewise.
16083 (grub_video_delete_render_target): Likewise.
16084 (grub_video_set_active_render_target): Likewise.
16085
16086 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
16087 Undefined.
16088 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
16089
16090 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
16091 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16092 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16093 instead of $(srcdir)/genkernsyms.sh.
16094
16095 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
16096 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16097 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16098 instead of $(srcdir)/genkernsyms.sh.
16099
16100 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
16101 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16102 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16103 instead of $(srcdir)/genkernsyms.sh.
16104
16105 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
16106 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16107 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16108 instead of $(srcdir)/genkernsyms.sh.
16109
16110 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
16111 genkernsyms.sh.
16112
16113 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
16114 genkernsyms.sh.
16115 (gensymlist.sh): New target.
16116 (genkernsyms.sh): Likewise.
16117
16118 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
16119 genkernsyms.sh.in and gensymlist.sh.in.
16120
16121 * genkernsyms.sh: Removed.
16122 * gensymlist.sh: Likewise.
f19dbdb7 16123
7b455f4d 16124 * genkernsyms.sh.in: New file.
16125 * gensymlist.sh.in: Likewise.
16126
1885bb27 161272006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16128
16129 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
16130 clobber "prefix", since we may have already set it manually.
16131
71538dff 161322006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16133
16134 * kern/misc.c (abort): New alias for grub_abort.
16135
2965c7cc 161362006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
16137
16138 A new machine-specific function "grub_machine_set_prefix" is
16139 defined. This is called after loading modules, so that a prefix
16140 initialization can use modules. Also, this change adds an
16141 intensive debugging feature for the memory manager via the
16142 configure option "--enable-mm-debug".
f19dbdb7 16143
2965c7cc 16144 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
16145 PART.LEN.
16146
16147 * kern/sparc64/ieee1275/init.c (abort): Removed.
16148 (grub_stop): Likewise.
16149 (grub_exit): New function.
16150 (grub_set_prefix): Renamed to ...
16151 (grub_machine_set_prefix): ... this.
16152 (grub_machine_init): Do not call grub_set_prefix.
16153
16154 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
16155 (grub_machine_set_prefix): ... this.
16156 (grub_machine_init): Do not call grub_set_prefix.
16157
16158 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
16159 (grub_machine_init): Do not set the prefix here.
16160
16161 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
16162
16163 * kern/efi/init.c: Include grub/mm.h.
16164 (grub_efi_set_prefix): New function.
16165
16166 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
16167 (grub_efi_get_filename): New function.
16168 (grub_print_device_path): Renamed to ...
16169 (grub_efi_print_device_path): ... this.
16170
16171 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
16172 [MM_DEBUG] (grub_realloc): Likewise.
16173 [MM_DEBUG] (grub_free): Likewise.
16174 [MM_DEBUG] (grub_memalign): Likewise.
16175 [MM_DEBUG] (grub_mm_debug): New variable.
16176 [MM_DEBUG] (grub_debug_malloc): New function.
16177 [MM_DEBUG] (grub_debug_free): New function.
16178 [MM_DEBUG] (grub_debug_realloc): New function.
16179 [MM_DEBUG] (grub_debug_memalign): New function.
16180
16181 * kern/misc.c (grub_abort): Print a newline to distinguish
16182 the message.
16183
16184 * kern/main.c (grub_main): Call grub_machine_set_prefix and
16185 grub_set_root_dev after loading modules. This is necessary when
16186 setting a prefix depends on modules.
16187
16188 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
16189 (grub_efi_print_device_path): ... this.
16190 (grub_efi_get_filename): New prototype.
16191 (grub_efi_set_prefix): Likewise.
16192
16193 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
16194 and grub/disk.h.
16195 (grub_efidisk_get_device_handle): New prototype.
16196 (grub_efidisk_get_device_name): Likewise.
16197
16198 * include/grub/mm.h: Include config.h.
16199 (MM_DEBUG): Removed.
16200 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
16201 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
16202 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
16203 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
16204 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
16205 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
16206 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
16207 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
16208 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
16209
16210 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
16211
16212 * disk/efi/efidisk.c: Include grub/partition.h.
16213 (iterate_child_devices): New function.
16214 (add_device): First, compare only last device path nodes, so that
16215 devices are sorted by the types.
16216 (grub_efidisk_get_device_handle): New function.
16217 (grub_efidisk_get_device_name): Likewise.
16218
16219 * configure.ac (--enable-mm-debug): New option to enable the
16220 memory manager debugging feature. This makes the binary much
16221 bigger, so is disabled by default.
16222
9cacaa17 162232006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
16224
16225 Use grub_abort instead of grub_stop, and grub_exit must be
16226 define in each architecture now. Also, this change adds support
16227 for EFI disks.
f19dbdb7 16228
9cacaa17 16229 * util/i386/pc/grub-probefs.c: Include grub/term.h.
16230 (grub_getkey): New function.
16231 (grub_term_get_current): Likewise.
16232
16233 * util/i386/pc/grub-setup.c: Include grub/term.h.
16234 (grub_getkey): New function.
16235 (grub_term_get_current): Likewise.
16236
16237 * util/misc.c (grub_stop): Renamed to ...
16238 (grub_exit): ... this.
16239
16240 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
16241 (grub_exit): ... this.
16242 (grub_machine_init): Use grub_abort instead of abort.
16243 (grub_stop): Removed.
16244
16245 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
16246 abort.
16247
16248 * kern/i386/pc/startup.S (grub_exit): New function.
16249 (cold_reboot): New label.
16250
16251 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
16252 (grub_efi_init): Call grub_efidisk_init.
16253 (grub_efi_fini): Call grub_efidisk_fini.
16254
16255 * kern/efi/efi.c: Include grub/mm.h.
16256 (grub_efi_console_control_guid): Renamed to ...
16257 (console_control_guid): ... this.
16258 (grub_efi_loaded_image_guid): Renamed to ...
16259 (loaded_image_guid): ... this.
16260 (grub_efi_locate_handle): New function.
16261 (grub_efi_open_protocol): Likewise.
16262 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
16263 GRUB_EFI_CONSOLE_CONTROL_GUID.
16264 (grub_efi_exit): Removed.
16265 (grub_stop): Likewise.
16266 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
16267 (grub_exit): New function.
16268 (grub_print_device_path): Likewise.
16269
16270 * kern/rescue.c (grub_rescue_cmd_exit): New function.
16271 (grub_enter_rescue_mode): Register "exit".
16272
16273 * kern/misc.c (grub_real_dprintf): A cosmetic change.
16274 (grub_abort): New function.
16275
16276 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
16277
16278 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
16279
16280 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
16281
16282 * include/grub/efi/efi.h (grub_efi_exit): Removed.
16283 (grub_print_device_path): New prototype.
16284 (grub_efi_locate_handle): Likewise.
16285 (grub_efi_open_protocol): Likewise.
16286
16287 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
16288 * disk/efi/efidisk.c: Likewise.
16289
16290 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
16291
16292 * include/grub/efi/console_control.h
16293 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
16294
16295 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
16296 last 8 bytes as an array.
16297 (GRUB_EFI_DISK_IO_GUID): New macro.
16298 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
16299 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
16300 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
16301 grub_uint8_t.
16302 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
16303 (struct grub_efi_device_path): Rename the member "sub_type" to
16304 "subtype".
16305 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
16306 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
16307 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
16308 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
16309 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
16310 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
16311 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
16312 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
16313 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
16314 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
16315 (struct grub_efi_pci_device_path): New structure.
16316 (grub_efi_pci_device_path_t): New type.
16317 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
16318 (struct grub_efi_pccard_device_path): New structure.
16319 (grub_efi_pccard_device_path_t): New type.
16320 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
16321 (struct grub_efi_memory_mapped_device_path): New structure.
16322 (grub_efi_memory_mapped_device_path_t): New type.
16323 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
16324 (struct grub_efi_vendor_device_path): New structure.
16325 (grub_efi_vendor_device_path_t): New type.
16326 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
16327 (struct grub_efi_controller_device_path): New structure.
16328 (grub_efi_controller_device_path_t): New type.
16329 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
16330 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
16331 (struct grub_efi_acpi_device_path): New structure.
16332 (grub_efi_acpi_device_path_t): New type.
16333 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
16334 (struct grub_efi_expanded_acpi_device_path): New structure.
16335 (grub_efi_expanded_acpi_device_path_t): New type.
16336 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
16337 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
16338 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
16339 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
16340 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
16341 (struct grub_efi_atapi_device_path): New structure.
16342 (grub_efi_atapi_device_path_t): New type.
16343 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
16344 (struct grub_efi_fibre_channel_device_path): New structure.
16345 (grub_efi_fibre_channel_device_path_t): New type.
16346 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
16347 (struct grub_efi_1394_device_path): New structure.
16348 (grub_efi_1394_device_path_t): New type.
16349 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
16350 (struct grub_efi_usb_device_path): New structure.
16351 (grub_efi_usb_device_path_t): New type.
16352 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
16353 (struct grub_efi_usb_class_device_path): New structure.
16354 (grub_efi_usb_class_device_path_t): New type.
16355 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
16356 (struct grub_efi_i2o_device_path): New structure.
16357 (grub_efi_i2o_device_path_t): New type.
16358 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
16359 (struct grub_efi_mac_address_device_path): New structure.
16360 (grub_efi_mac_address_device_path_t): New type.
16361 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
16362 (struct grub_efi_ipv4_device_path): New structure.
16363 (grub_efi_ipv4_device_path_t): New type.
16364 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
16365 (struct grub_efi_ipv6_device_path): New structure.
16366 (grub_efi_ipv6_device_path_t): New type.
16367 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
16368 (struct grub_efi_infiniband_device_path): New structure.
16369 (grub_efi_infiniband_device_path_t): New type.
16370 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
16371 (struct grub_efi_uart_device_path): New structure.
16372 (grub_efi_uart_device_path_t): New type.
16373 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
16374 (struct grub_efi_vendor_messaging_device_path): New structure.
16375 (grub_efi_vendor_messaging_device_path_t): New type.
16376 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
16377 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
16378 (struct grub_efi_hard_drive_device_path): New structure.
16379 (grub_efi_hard_drive_device_path_t): New type.
16380 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
16381 (struct grub_efi_cdrom_device_path): New structure.
16382 (grub_efi_cdrom_device_path_t): New type.
16383 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
16384 (struct grub_efi_vendor_media_device_path): New structure.
16385 (grub_efi_vendor_media_device_path_t): New type.
16386 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
16387 (struct grub_efi_file_path_device_path): New structure.
16388 (grub_efi_file_path_device_path_t): New type.
16389 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
16390 (struct grub_efi_protocol_device_path): New structure.
16391 (grub_efi_protocol_device_path_t): New type.
16392 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
16393 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
16394 (struct grub_efi_bios_device_path): New structure.
16395 (grub_efi_bios_device_path_t): New type.
16396 (struct grub_efi_disk_io): New structure.
16397 (grub_efi_disk_io_t): New type.
16398 (struct grub_efi_block_io_media): New structure.
16399 (grub_efi_block_io_media_t): New type.
16400 (struct grub_efi_block_io): New structure.
16401 (grub_efi_block_io_t): New type.
16402
16403 * include/grub/misc.h (grub_stop): Removed.
16404 (grub_exit): New prototype.
16405 (grub_abort): Likewise.
16406
16407 * include/grub/disk.h (enum grub_disk_dev_id): Added
16408 GRUB_DISK_DEVICE_EFIDISK_ID.
16409
16410 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
16411 disk/efi/efidisk.c.
16412 (kernel_syms.lst): Remove the target if an error occurs.
16413
49986a9f 164142006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
16415
16416 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
16417 as it was simply too buggy.
16418
970d3b8a 164192006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
16420
16421 * kern/misc.c (grub_lltoa): New function.
16422 (grub_vsprintf): Added support for the long long suffix,
16423 i.e. "ll".
16424
ff04ec24 164252006-04-20 Hollis Blanchard <hollis@penguinppc.org>
16426
16427 * Makefile.in (LDFLAGS): Add variable.
16428 (LD): Remove variable.
16429 * configure.ac: Add -m32 to LDFLAGS.
16430 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
16431 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
16432 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
16433 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
16434 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
16435 variables.
16436 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
16437 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
16438 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
16439
37e5e1a4 164402006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
16441
16442 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
16443 length for unknown glyph.
16444
c352d8dd 164452006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
16446
2eab1c0d 16447 Add support for pre-loaded modules into the EFI port.
f19dbdb7 16448
2eab1c0d 16449 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
16450 completely. Accept one more argument DIR. The caller has changed.
16451
16452 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
16453
16454 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
16455 (grub_efi_loaded_image_guid): New variable.
16456 (grub_efi_get_loaded_image): New function.
16457 (grub_arch_modules_addr): Likewise.
16458
16459 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
16460 prototype.
16461
16462 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
16463 (struct grub_efi_loaded_image): New structure.
16464 (grub_efi_loaded_image_t): New type.
16465
164662006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 16467
c352d8dd 16468 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
16469 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
16470 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
16471
6d01d6b4 164722006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
16473
16474 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
16475
976a4ea0 164762006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
16477
16478 * DISTLIST: Added include/grub/efi/console.h,
16479 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
16480 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16481
16482 * include/grub/efi/console.h: New file.
16483 * include/grub/efi/time.h: Likewise.
16484 * include/grub/i386/efi/kernel.h: Likewise.
16485 * kern/efi/init.c: Likewise.
16486 * kern/efi/mm.c: Likewise.
16487 * term/efi/console.c: Likewise.
f19dbdb7 16488
976a4ea0 16489 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
16490 (grub_stop): Removed.
16491 (grub_get_rtc): Likewise.
16492 (grub_machine_init): Simply call grub_efi_init.
16493 (grub_machine_fini): Call grub_efi_fini.
16494
16495 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
16496 (grub_efi_output_string): Removed.
16497 (grub_efi_stall): New function.
16498 (grub_stop): Likewise.
16499 (grub_get_rtc): Likewise.
16500
16501 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
16502 (grub_efi_stall): New prototype.
16503 (grub_efi_allocate_pages): Likewise.
16504 (grub_efi_free_pages): Likewise.
16505 (grub_efi_get_memory_map): Likewise.
16506 (grub_efi_mm_init): Likewise.
16507 (grub_efi_mm_fini): Likewise.
16508 (grub_efi_init): Likewise.
16509 (grub_efi_fini): Likewise.
16510
16511 * include/grub/i386/efi/time.h: Do not include
16512 grub/symbol.h. Include grub/efi/time.h.
16513 (GRUB_TICKS_PER_SECOND): Removed.
16514 (grub_get_rtc): Likewise.
16515
16516 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
16517 Added padding. The EFI spec is buggy.
16518 (GRUB_EFI_BLACK): New macro.
16519 (GRUB_EFI_BLUE): Likewise.
16520 (GRUB_EFI_GREEN): Likewise.
16521 (GRUB_EFI_CYAN): Likewise.
16522 (GRUB_EFI_RED): Likewise.
16523 (GRUB_EFI_MAGENTA): Likewise.
16524 (GRUB_EFI_BROWN): Likewise.
16525 (GRUB_EFI_LIGHTGRAY): Likewise.
16526 (GRUB_EFI_BRIGHT): Likewise.
16527 (GRUB_EFI_DARKGRAY): Likewise.
16528 (GRUB_EFI_LIGHTBLUE): Likewise.
16529 (GRUB_EFI_LIGHTGREEN): Likewise.
16530 (GRUB_EFI_LIGHTCYAN): Likewise.
16531 (GRUB_EFI_LIGHTRED): Likewise.
16532 (GRUB_EFI_LIGHTMAGENTA): Likewise.
16533 (GRUB_EFI_YELLOW): Likewise.
16534 (GRUB_EFI_WHITE): Likewise.
16535 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
16536 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
16537 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
16538 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
16539 (GRUB_EFI_BACKGROUND_RED): Likewise.
16540 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
16541 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
16542 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
16543 (GRUB_EFI_TEXT_ATTR): Likewise.
16544
16545 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
16546 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16547 (kernel_mod_HEADERS): Added efi/time.h.
16548
83709125 165492006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
16550
16551 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
16552 include/grub/efi/api.h, include/grub/efi/console_control.h,
16553 include/grub/efi/efi.h, include/grub/efi/pe32.h,
16554 include/grub/i386/efi/time.h, kern/efi/efi.c,
16555 kern/i386/efi/init.c, kern/i386/efi/startup.S,
16556 and util/i386/efi/grub-mkimage.c.
16557
16558 * Makefile.in (RMKFILES): Added i386-efi.rmk.
16559
16560 * genmk.rb (PModule#rule): Do not export symbols if
16561 #{prefix}_EXPORTS is set to "no".
16562
16563 * conf/i386-efi.mk: New file.
16564 * conf/i386-efi.rmk: Likewise.
16565 * include/grub/efi/api.h: Likewise.
16566 * include/grub/efi/console_control.h: Likewise.
16567 * include/grub/efi/efi.h: Likewise.
16568 * include/grub/efi/pe32.h: Likewise.
16569 * include/grub/i386/efi/time.h: Likewise.
16570 * kern/efi/efi.c: Likewise.
16571 * kern/i386/efi/init.c: Likewise.
16572 * kern/i386/efi/startup.S: Likewise.
16573 * util/i386/efi/grub-mkimage.c: Likewise.
16574
165752006-04-17 Marco Gerards <marco@gnu.org>
bfa2bd9e 16576
16577 * include/grub/script.h: Include <grub/parser.h> and
16578 "grub_script.tab.h".
16579 (struct grub_lexer_param): New struct.
16580 (struct grub_parser_param): Likewise.
16581 (grub_script_create_arglist): Pass the state in an argument.
16582 (grub_script_add_arglist): Likewise.
16583 (grub_script_create_cmdline): Likewise.
16584 (grub_script_create_cmdblock): Likewise.
16585 (grub_script_create_cmdif): Likewise.
16586 (grub_script_create_cmdmenu): Likewise.
16587 (grub_script_add_cmd): Likewise.
16588 (grub_script_arg_add): Likewise.
16589 (grub_script_lexer_ref): Likewise.
16590 (grub_script_lexer_deref): Likewise.
16591 (grub_script_lexer_record_start): Likewise.
16592 (grub_script_lexer_record_stop): Likewise.
16593 (grub_script_mem_record): Likewise.
16594 (grub_script_mem_record_stop): Likewise.
16595 (grub_script_malloc): Likewise.
16596 (grub_script_yylex): Likewise.
16597 (grub_script_yyparse): Likewise.
16598 (grub_script_yyerror): Likewise.
16599 (grub_script_yylex): Likewise.
16600 (grub_script_lexer_init): Return the state.
16601
16602 * normal/lexer.c (grub_script_lexer_state): Removed variable.
16603 (grub_script_lexer_done): Likewise.
16604 (grub_script_lexer_getline): Likewise.
16605 (grub_script_lexer_refs): Likewise.
16606 (script): Likewise.
16607 (newscript): Likewise.
16608 (record): Likewise.
16609 (recording): Likewise.
16610 (recordpos): Likewise.
16611 (recordlen): Likewise.
16612 (grub_script_lexer_init): Return the state instead of setting
16613 global variables.
16614 (grub_script_lexer_ref): Use the newly added argument for state
16615 instead of globals.
16616 (grub_script_lexer_deref): Likewise.
16617 (grub_script_lexer_record_start): Likewise.
16618 (grub_script_lexer_record_stop): Likewise.
16619 (recordchar): Likewise.
16620 (nextchar): Likewise.
16621 (grub_script_yylex2): Likewise.
16622 (grub_script_yylex): Likewise.
16623 (grub_script_yyerror): Likewise.
16624
16625 * normal/parser.y (func_mem): Removed variable.
16626 (menu_entry): Likewise.
16627 (err): Likewise.
16628 (%lex-param): New parser option.
16629 (%parse-param): Likewise.
16630 (script): Always return the AST.
16631 (argument): Pass the state around.
16632 (arguments): Likewise.
16633 (grubcmd): Likewise.
16634 (commands): Likewise.
16635 (function): Likewise.
16636 (menuentry): Likewise.
16637 (if_statement): Likewise.
16638 (if): Likewise.
16639
16640 * normal/script.c (grub_script_memused): Removed variable.
16641 (grub_script_parsed): Likewise.
16642 (grub_script_malloc): Added a state argument. Use that instead of
16643 global variables.
16644 (grub_script_mem_record): Likewise.
16645 (grub_script_mem_record_stop): Likewise.
16646 (grub_script_arg_add): Likewise.
16647 (grub_script_add_arglist): Likewise.
16648 (grub_script_create_cmdline): Likewise.
16649 (grub_script_create_cmdif): Likewise.
16650 (grub_script_create_cmdmenu): Likewise.
16651 (grub_script_add_cmd): Likewise.
16652 (grub_script_parse): Setup the state before calling the parser.
f19dbdb7 16653
e2a8c904 166542006-04-16 Marco Gerards <marco@gnu.org>
6de2ee99 16655
16656 * normal/command.c (grub_command_init): Remove the title command.
16657
16658 * normal/lexer.c (grub_script_yylex): Renamed from this...
16659 (grub_script_yylex2): ... to this.
16660 (grub_script_yylex): New function. Temporary
16661 introduced to filter some tokens.
16662 (grub_script_yyerror): Print a newline.
16663
16664 * normal/main.c (read_config_file): Output information about the
16665 lines that contain errors. Wait for a key after all lines have
16666 been processed. Don't return an empty menu.
16667
16668 * normal/parser.y (func_mem): Don't initialize.
16669 (menu_entry): Likewise.
16670 (err): New variable.
16671 (script): Don't return anything when an error was encountered.
16672 (ws, returns): Removed rules.
16673 (argument): Disabled concatenated variable support.
16674 (arguments): Remove explicit separators.
16675 (grubcmd): Likewise.
16676 (function): Likewise.
16677 (menuentry): Likewise.
16678 (if): Likewise.
16679 (commands): Likewise. Add error handling.
16680
16681 * normal/script.c (grub_script_create_cmdline): If
16682 `grub_script_parsed' is 0, assume the parser encountered an error.
16683
c9a86192 166842006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
16685
16686 * configure.ac: Add support for EFI. Fix the typo
16687 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
16688
70f3b243 166892006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16690
16691 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
16692 foreign multibyte characters should be shown correctly.
16693
65f201ad 166942006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16695
16696 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
16697 calculation.
16698 (read_config_file): Made it to close file before returning.
16699
b4b93674 167002006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
16701
16702 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
16703 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
16704 video/i386/pc/vbefill.c.
16705
16706 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
16707 video/i386/pc/vbefill.c.
16708
16709 * include/grub/video.h (grub_video_blit_format): New enum.
16710 (grub_video_mode_info): Added new member blit_format.
16711 (grub_video_get_blit_format): New function prototype.
16712
16713 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
16714 function prototype.
16715 (grub_video_vbe_map_rgb): Likewise.
16716 (grub_video_vbe_unmap_color): Likewise.
16717
16718 * include/grub/i386/pc/vbeblit.h: New file.
16719
16720 * include/grub/i386/pc/vbefill.h: New file.
16721
16722 * video/video.c (grub_video_get_blit_format): New function.
16723 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
16724 (grub_video_vbe_map_rgb): Likewise.
16725 (grub_video_vbe_unmap_color): Likewise.
16726
16727 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
16728 optimized fills.
16729 (grub_video_vbe_blit_render_target): Changed to use more optimized
16730 blits.
16731 (grub_video_vbe_setup): Added detection for optimized settings.
16732 (grub_video_vbe_create_render_target): Likewise.
16733
16734 * video/i386/pc/vbeblit.c: New file.
16735
16736 * video/i386/pc/vbefill.c: New file.
16737
c2379b9c 167382006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
16739
16740 * font/manager.c (grub_font_get_glyph): Removed font fixup from
16741 here...
16742
16743 * util/unifont2pff.rb: ... and moved it to here. Improved argument
16744 parsing to support both hex and dec ranges. If filename was missing
16745 show usage information.
16746
bd0d7896 167472006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
16748
16749 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
16750 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
16751
16752 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
16753 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
16754 (video_mod_SOURCES): Added.
16755 (video_mod_CFLAGS): Likewise.
16756 (video_mod_LDFLAGS): Likewise.
16757 (gfxterm_mod_SOURCES): Likewise.
16758 (gfxterm_mod_CFLAGS): Likewise.
16759 (gfxterm_mod_LDFLAGS): Likewise.
16760 (videotest_mod_SOURCES): Likewise.
16761 (videotest_mod_CFLAGS): Likewise.
16762 (videotest_mod_LDFLAGS): Likewise.
16763 (vesafb_mod_SOURCES): Removed.
16764 (vesafb_mod_CFLAGS): Likewise.
16765 (vesafb_mod_LDFLAGS): Likewise.
16766 (vga_mod_SOURCES): Likewise.
16767 (vga_mod_CFLAGS): Likewise.
16768 (vga_mod_LDFLAGS): Likewise.
16769
16770 * commands/videotest.c: New file.
16771
16772 * font/manager.c (fill_with_default_glyph): Modified to use
16773 grub_font_glyph.
16774 (grub_font_get_glyph): Likewise.
16775 (fontmanager): Renamed from this...
16776 (font_manager): ... to this.
16777
16778 * include/grub/font.h (grub_font_glyph): Added new structure.
16779 (grub_font_get_glyph): Modified to use grub_font_glyph.
16780
16781 * include/grub/misc.h (grub_abs): Added as inline function.
16782
16783 * include/grub/video.h: New file.
16784
16785 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
16786 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
16787 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
16788 (grub_vbe_get_controller_info): Renamed from this...
16789 (grub_vbe_bios_get_controller_info): ... to this.
16790 (grub_vbe_get_mode_info): Renamed from this...
16791 (grub_vbe_bios_get_mode_info): ... to this.
16792 (grub_vbe_set_mode): Renamed from this...
16793 (grub_vbe_bios_set_mode): ... to this.
16794 (grub_vbe_get_mode): Renamed from this...
16795 (grub_vbe_bios_get_mode): ... to this.
16796 (grub_vbe_set_memory_window): Renamed from this...
16797 (grub_vbe_bios_set_memory_window): ... to this.
16798 (grub_vbe_get_memory_window): Renamed from this...
16799 (grub_vbe_bios_get_memory_window): ... to this.
16800 (grub_vbe_set_scanline_length): Renamed from this...
16801 (grub_vbe_set_scanline_length): ... to this.
16802 (grub_vbe_get_scanline_length): Renamed from this...
16803 (grub_vbe_bios_get_scanline_length): ... to this.
16804 (grub_vbe_set_display_start): Renamed from this...
16805 (grub_vbe_bios_set_display_start): ... to this.
16806 (grub_vbe_get_display_start): Renamed from this...
16807 (grub_vbe_bios_get_display_start): ... to this.
16808 (grub_vbe_set_palette_data): Renamed from this...
16809 (grub_vbe_bios_set_palette_data): ... to this.
16810 (grub_vbe_set_pixel_rgb): Removed.
16811 (grub_vbe_set_pixel_index): Likewise.
16812
16813 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
16814 from this...
16815 (grub_vbe_bios_get_controller_info): ... to this.
16816 (grub_vbe_get_mode_info): Renamed from this...
16817 (grub_vbe_bios_get_mode_info): ... to this.
16818 (grub_vbe_set_mode): Renamed from this...
16819 (grub_vbe_bios_set_mode): ... to this.
16820 (grub_vbe_get_mode): Renamed from this...
16821 (grub_vbe_bios_get_mode): ... to this.
16822 (grub_vbe_set_memory_window): Renamed from this...
16823 (grub_vbe_bios_set_memory_window): ... to this.
16824 (grub_vbe_get_memory_window): Renamed from this...
16825 (grub_vbe_bios_get_memory_window): ... to this.
16826 (grub_vbe_set_scanline_length): Renamed from this...
16827 (grub_vbe_set_scanline_length): ... to this.
16828 (grub_vbe_get_scanline_length): Renamed from this...
16829 (grub_vbe_bios_get_scanline_length): ... to this.
16830 (grub_vbe_set_display_start): Renamed from this...
16831 (grub_vbe_bios_set_display_start): ... to this.
16832 (grub_vbe_get_display_start): Renamed from this...
16833 (grub_vbe_bios_get_display_start): ... to this.
16834 (grub_vbe_set_palette_data): Renamed from this...
16835 (grub_vbe_bios_set_palette_data): ... to this.
16836 (grub_vbe_bios_get_controller_info): Fixed problem with registers
16837 getting corrupted after calling it. Added more pushes and pops.
16838 (grub_vbe_bios_set_mode): Likewise.
16839 (grub_vbe_bios_get_mode): Likewise.
16840 (grub_vbe_bios_get_memory_window): Likewise.
16841 (grub_vbe_bios_set_scanline_length): Likewise.
16842 (grub_vbe_bios_get_scanline_length): Likewise.
16843 (grub_vbe_bios_get_display_start): Likewise.
16844 (grub_vbe_bios_set_palette_data): Likewise.
16845
16846 * normal/cmdline.c (cl_set_pos): Refresh the screen.
16847 (cl_insert): Likewise.
16848 (cl_delete): Likewise.
16849
16850 * term/gfxterm.c: New file.
16851
16852 * term/i386/pc/vesafb.c: Removed file.
16853
16854 * video/video.c: New file.
16855
16856 * video/i386/pc/vbe.c (real2pm): Added new function.
16857 (grub_video_vbe_draw_pixel): Likewise.
16858 (grub_video_vbe_get_video_ptr): Likewise.
16859 (grub_video_vbe_get_pixel): Likewise
16860 (grub_video_vbe_init): Likewise.
16861 (grub_video_vbe_fini): Likewise.
16862 (grub_video_vbe_setup): Likewise.
16863 (grub_video_vbe_get_info): Likewise.
16864 (grub_video_vbe_set_palette): Likewise.
16865 (grub_video_vbe_get_palette): Likewise.
16866 (grub_video_vbe_set_viewport): Likewise.
16867 (grub_video_vbe_get_viewport): Likewise.
16868 (grub_video_vbe_map_color): Likewise.
16869 (grub_video_vbe_map_rgb): Likewise.
16870 (grub_video_vbe_map_rgba): Likewise.
16871 (grub_video_vbe_unmap_color): Likewise.
16872 (grub_video_vbe_fill_rect): Likewise.
16873 (grub_video_vbe_blit_glyph): Likewise.
16874 (grub_video_vbe_blit_bitmap): Likewise.
16875 (grub_video_vbe_blit_render_target): Likewise.
16876 (grub_video_vbe_scroll): Likewise.
16877 (grub_video_vbe_swap_buffers): Likewise.
16878 (grub_video_vbe_create_render_target): Likewise.
16879 (grub_video_vbe_delete_render_target): Likewise.
16880 (grub_video_vbe_set_active_render_target): Likewise.
16881 (grub_vbe_set_pixel_rgb): Remove function.
16882 (grub_vbe_set_pixel_index): Likewise.
16883 (index_color_mode): Remove static variable.
16884 (active_mode): Likewise.
16885 (framebuffer): Likewise.
16886 (bytes_per_scan_line): Likewise.
16887 (grub_video_vbe_adapter): Added new static variable.
16888 (framebuffer): Likewise.
16889 (render_target): Likewise.
16890 (initial_mode): Likewise.
16891 (mode_in_use): Likewise.
16892 (mode_list): Likewise.
16893
5f97350b 168942006-03-10 Marco Gerards <marco@gnu.org>
16895
16896 * configure.ac (AC_INIT): Bumped to 1.93.
16897
16898 * DISTLIST: Added `include/grub/hfs.h'.
16899
a3c5c6f8 169002006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
16901
16902 * boot/i386/pc/boot.S (general_error): Before looping, try INT
16903 18H, which might help the BIOS falling back to next boot media.
16904
6de53d26 169052006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
16906
16907 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
16908 Poe Chen <poe.poechen@gmail.com>.
16909
77c4a393 169102006-01-17 Marco Gerards <marco@gnu.org>
16911
16912 * include/grub/normal.h: Include <grub/script.h>.
16913 (grub_command_list): Removed struct.
16914 (grub_command_list_t): Removed type.
16915 (grub_menu_entry): Remove members `num' and `command_list'. Add
16916 members `commands' and `sourcecode'.
16917 * include/grub/script.h: Add inclusion guards.
16918 (grub_script_cmd_menuentry): New struct.
16919 (grub_script_execute_menuentry): New prototype.
16920 (grub_script_lexer_record_start): Likewise.
16921 (grub_script_lexer_record_stop): Likewise.
16922 * normal/execute.c (grub_script_execute_menuentry): New function.
16923 * normal/lexer.c (record, recording, recordpos, recordlen): New
16924 variables.
16925 (grub_script_lexer_record_start): New function.
16926 (grub_script_lexer_record_stop): Likewise.
16927 (recordchar): Likewise.
16928 (nextchar): Likewise.
16929 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
16930 2048 as the buffer size. Add the tokens `menuentry' and `@'.
16931 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
16932 (current_menu): New variable.
16933 (free_menu): Mainly rewritten.
16934 (grub_normal_menu_addentry): New function.
16935 (read_config_file): Rewritten.
16936 * normal/menu.c (run_menu_entry): Mainly rewritten.
fe987087 16937 * normal/menu_entry.c (make_screen): Rewritten the code to insert
77c4a393 16938 the menu entry.
16939 (run): Mainly rewritten.
16940 * normal/parser.y (menu_entry): New variable.
16941 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
16942 (menuentry): New rule.
16943 (command): Add `menuentry'.
16944 (if_statement): Allow additional returns before `fi'.
16945 * normal/script.c (grub_script_create_cmdmenu): New function.
16946
144f1f98 169472006-01-03 Marco Gerards <marco@gnu.org>
16948
16949 * INSTALL: GNU Bison is required.
16950 * configure.ac: Rewritten the test to detect Bison.
16951 * Makefile.in (YACC): New variable. Reported by Xun Sun
16952 <xun.sun.cn@gmail.com>.
16953
af4b2d89 169542006-01-03 Marco Gerards <marco@gnu.org>
16955
16956 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
16957 the HFS+ filesystem to filesystem blocks.
16958 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
16959 GCC warning is silenced.
16960
15643b71 169612006-01-03 Marco Gerards <marco@gnu.org>
16962
16963 * partmap/apple.c (apple_partition_map_iterate): Convert the data
16964 read from disk from big endian to host byte order.
16965
00905879 169662006-01-03 Hollis Blanchard <hollis@penguinppc.org>
16967
16968 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
16969 documentation.
16970 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
16971 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
16972 embedded HFS+ filesystem.
16973 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
16974 (grub_hfs_sblock): Move from here...
16975 * include/grub/hfs.h: To here... New file.
16976 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
16977 documentation.
16978 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
16979 New macros.
16980 (grub_hfsplus_volheader): Change type of member `magic' to
16981 `grub_uint16_t'.
16982 (grub_hfsplus_data): Add new member `embedded_offset'.
16983 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
16984 returned block.
16985 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
16986 Calculate the offset.
16987
8899bc3e 169882005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
16989
16990 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
16991 Removed.
16992 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
16993
ae8c0277 169942005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
16995
16996 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
16997 ENV->NAME is NULL after allocating ENV->VALUE.
16998
07084456 169992005-12-25 Marco Gerards <marco@gnu.org>
17000
17001 * kern/env.c (grub_env_set): Rewritten the error handling code.
17002
4750f5f1 170032005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17004
17005 * geninit.sh: Made more robust, and more portable.
17006
50214199 170072005-12-25 Marco Gerards <marco@gnu.org>
17008
17009 Add support for Apple HFS+ filesystems.
f19dbdb7 17010
50214199 17011 * fs/hfsplus.c: New file.
17012
17013 * DISTLIST: Added `fs/hfsplus.c'.
17014
17015 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
17016 (hfsplus_mod_SOURCES): New variable.
17017 (hfsplus_mod_CFLAGS): Likewise.
17018 (hfsplus_mod_LDFLAGS): Likewise.
17019 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
17020 (grub_setup_SOURCES): Likewise.
17021 (grub_mkdevicemap_SOURCES): Likewise.
17022 (grub_emu_SOURCES): Likewise.
17023 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
17024
17025 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
17026
17027 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
17028
befaed6c 170292005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17030
17031 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
17032 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
17033 include/grub/parser.h, include/grub/script.h, kern/parser.c,
17034 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
17035 normal/lexer.c, normal/parser.y, normal/script.c, and
17036 partmap/gpt.c.
17037 Removed kern/sparc64/cache.c.
17038
17039 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
17040 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
17041 grub_emu_init.c.
17042
17043 * configure.ac (AC_INIT): Bumped to 1.92.
17044
6a124103 170452005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
17046
17047 * kern/err.c (grub_error_push): Added new function to support error
17048 stacks.
17049 (grub_error_pop): Likewise.
17050 (grub_error_stack_items): New local variable to support error stacks.
17051 (grub_error_stack_pos): Likewise.
17052 (grub_error_stack_assert): Likewise.
17053 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
17054 stack depth.
17055 (grub_print_error): Added support to print errors from error stack.
17056
17057 * include/grub/err.h (grub_error_push): Added function prototype.
17058 (grub_error_pop): Likewise.
17059
be973c1b 170602005-12-09 Hollis Blanchard <hollis@penguinppc.org>
17061
17062 * configure.ac: Accept `powerpc64' as host_cpu.
17063 (amd64): Rename to `biarch32'.
17064
17065 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
17066 non-cacheline-aligned addresses.
17067
17068 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
17069 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
17070 if `size' is non-zero.
17071
b04216ab 170722005-12-03 Marco Gerards <mgerards@xs4all.nl>
17073
17074 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
17075 and `cd' to make sure the filename is not prefixed with a
17076 directory name.
17077 (pkgdata_MODULES): Add `gpt.mod'.
17078 (gpt_mod_SOURCES): New variable.
17079 (gpt_mod_CFLAGS): Likewise.
17080 (gpt_mod_LDFLAGS): Likewise.
17081
17082 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
17083
17084 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
17085 New macro.
17086
17087 * partmap/gpt.c: New file.
17088
17089 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
17090 GPT partition map is detected.
17091
41730ed9 170922005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
17093
17094 * commands/i386/pc/play.c: New file.
17095 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
17096 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
17097 macros.
f19dbdb7 17098
95dc3643 170992005-11-27 Marco Gerards <mgerards@xs4all.nl>
17100
17101 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
17102 ((unused))' to silence gcc warning.
17103
1569ec51 171042005-11-26 Hollis Blanchard <hollis@penguinppc.org>
17105
17106 * configure.ac: Correct `AC_PROG_YACC' test.
17107
9abde152 171082005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17109
17110 * util/powerpc/ieee1275/grub-install.in: Run the mount point
17111 check before installing files.
17112
44b83271 171132005-11-22 Mike Small <smallm@panix.com>
17114
17115 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
17116 number regex so multidigit numbers are recognized correctly.
17117
171182005-11-22 Mike Small <smallm@panix.com>
17119
17120 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
17121 debugging message before attempting to claim memory.
17122 (grub_rescue_cmd_initrd): Add a claim debugging message and try
17123 multiple addresses in case of failure.
17124
9c12956b 171252005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17126
17127 * term/tparm.c (get_space): Remove empty `if' statement.
17128
17129 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
17130
17131 * kern/parser.c (check_varstate): Rename `state' to 's'.
17132
aeaf81d9 171332005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17134
17135 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
17136 variable definitions to the beginning of each function. Sort stack
17137 variables by size.
17138 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
17139 `buf' argument to `char *'.
17140
79bbb63f 171412005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17142
17143 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
17144 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17145 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
79bbb63f 17146 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17147 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17148 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17149 configfile.mod, search.mod, gzio.mod and test.mod.
17150 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17151 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17152 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17153 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17154 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17155 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17156 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17157 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17158 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17159 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17160 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17161 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17162 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17163 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17164 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17165 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17166 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17167 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17168 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17169 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17170 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17171 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17172 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
17173
17174 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
17175 `grep --include'.
17176 (pkgdata_MODULES): Add test.mod.
17177
233b1628 171782005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17179
17180 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
17181 appending to variables with "+=".
17182 (PModule): Use full pathname to generate *.lst filenames.
17183
17184 * Makefile.in: Fixed list rules moved from genmk.rb.
17185 (.DELETE_ON_ERROR): New special target.
17186 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
17187
17188 * conf/i386-pc.rmk: Include conf/common.mk.
17189 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17190 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
233b1628 17191 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17192 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17193 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17194 configfile.mod, search.mod, gzio.mod and test.mod.
17195 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17196 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17197 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17198 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17199 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17200 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17201 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17202 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17203 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17204 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17205 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17206 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17207 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17208 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17209 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17210 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17211 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17212 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17213 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17214 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17215 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17216 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17217 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
17218 here...
17219 * conf/common.rmk: ... to here. New file.
17220
17221 * conf/common.mk: New file.
17222
16f820c8 172232005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
17224
17225 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
17226 (grub_script.tab.c): ... here.
17227
17228 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
17229 (grub_script.tab.c): ... here.
17230
17231 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
17232 (grub_script.tab.c): ... here.
17233
17234 * normal/command.c (grub_command_find): Fixed a memory leak of
17235 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
17236
63ba1554 172372005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17238
17239 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
17240 "@" which marks the start of a comment on ARM.
17241 (VARIABLE): Likewise.
17242
7f67dc13 172432005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17244
79bbb63f 17245 Add support for Linux/ADFS partition tables.
7f67dc13 17246
17247 * partmap/acorn.c: New file.
17248
17249 * include/grub/acorn_filecore.h: Likewise.
17250
17251 * DISTLIST: Added `partmap/acorn.c' and
17252 `include/grub/acorn_filecore.h'.
f19dbdb7 17253
7f67dc13 17254 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17255 `partmap/acorn.c'.
17256 (pkgdata_MODULES): Add `acorn.mod'.
17257 (acorn_mod_SOURCES): New variable.
17258 (acorn_mod_CFLAGS): Likewise.
17259
17260 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17261 `partmap/acorn.c'.
17262 (pkgdata_MODULES): Add `acorn.mod'.
17263 (acorn_mod_SOURCES): New variable.
17264 (acorn_mod_CFLAGS): Likewise.
17265
17266 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
17267 (pkgdata_MODULES): Add `acorn.mod'.
17268 (acorn_mod_SOURCES): New variable.
17269 (acorn_mod_CFLAGS): Likewise.
17270 (acorn_mod_LDFLAGS): Likewise.
17271
17272 * include/types.h (grub_disk_addr_t): New typedef.
17273
6d099807 172742005-11-13 Marco Gerards <mgerards@xs4all.nl>
17275
17276 * geninit.sh: New file.
17277
17278 * geninitheader.sh: Likewise.
17279
17280 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
17281 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
17282 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
17283 * commands/configfile.c (grub_configfile_init)
17284 (grub_configfile_fini): Likewise.
17285 * commands/default.c (grub_default_init, grub_default_fini):
17286 Likewise.
17287 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
17288 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
17289 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
17290 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
17291 Likewise.
17292 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
17293 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
17294 Likewise.
17295 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
fe6b695a 17296 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
6d099807 17297 Likewise.
17298 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
17299 Likewise.
fe6b695a 17300 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
6d099807 17301 Likewise.
17302 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
17303 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
17304 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
17305 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
17306 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
17307 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
17308 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
17309 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
17310 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
17311 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
17312 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
17313 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
17314 * partmap/amiga.c (grub_amiga_partition_map_init)
17315 (grub_amiga_partition_map_fini): Likewise.
17316 * partmap/apple.c (grub_apple_partition_map_init)
17317 (grub_apple_partition_map_fini): Likewise.
17318 * partmap/pc.c (grub_pc_partition_map_init)
17319 (grub_pc_partition_map_fini): Likewise.
17320 * partmap/sun.c (grub_sun_partition_map_init,
17321 grub_sun_partition_map_fini): Likewise.
17322 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
17323 Likewise.
17324
17325 * util/grub-emu.c: Include <grub_modules_init.h>.
17326 (main): Don't initialize and de-initialize any modules directly,
17327 use `grub_init_all' and `grub_fini_all' instead.
17328
17329 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
17330 `grub_vesafb_mod_init'.
17331 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
17332 all users.
17333 * term/i386/pc/vga.c (grub_vga_init): Renamed to
17334 `grub_vga_mod_init'. Updated all users.
17335 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
f19dbdb7 17336
6d099807 17337 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
17338 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
17339 rules.
17340
17341 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
17342 Generate a function to initialize the module in utilities.
17343 Updated all callers.
17344 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
17345 initialize the module in utilities. Updated all callers.
17346
9046bcf0 173472005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17348
17349 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
17350 escape sequence and a literal ^L to clear the screen.
17351
17352 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
17353 when returning from Open Firmware.
17354
d13ea639 173552005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17356
17357 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
17358 (grub_ofconsole_height): Likewise.
17359 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
17360 manually insert a '\n'.
17361 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
17362 `grub_ofconsole_height'. Return early if these are already set.
17363
a8fcf206 173642005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
17365
17366 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17367 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
17368 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
17369 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
17370 and `normal/script.c'.
17371 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17372 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17373 (test_mod_SOURCES): New variable.
17374 (test_mod_CFLAGS): Likewise.
17375 (test_mod_LDFLAGS): Likewise.
17376 (pkgdata_MODULES): Add `test.mod'.
17377 (grub_script.tab.c): New rule.
17378 (grub_script.tab.h): Likewise.
17379
b6b32745 173802005-11-07 Marco Gerards <mgerards@xs4all.nl>
17381
17382 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17383 `commands/test.c', `normal/execute.c', `normal/lexer.c',
17384 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17385 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17386 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17387 (test_mod_SOURCES): New variable.
17388 (test_mod_CFLAGS): Likewise.
17389 (pkgdata_MODULES): Add `test.mod'.
17390 (grub_script.tab.c): New rule.
17391 (grub_script.tab.h): Likewise.
17392
daac212a 173932005-11-06 Marco Gerards <mgerards@xs4all.nl>
17394
17395 Add initial scripting support.
17396
17397 * commands/test.c: New file.
17398 * include/grub/script.h: Likewise.
17399 * normal/execute.c: Likewise.
17400 * normal/function.c: Likewise.
17401 * normal/lexer.c: Likewise.
17402 * normal/parser.y: Likewise.
17403 * normal/script.c: Likewise.
17404
17405 * configure.ac: Add `AC_PROG_YACC' test.
f19dbdb7 17406
daac212a 17407 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
17408 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
17409 `normal/function.c' and `normal/script.c'.
17410 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17411 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
b6b32745 17412 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
17413 variables.
daac212a 17414 (pkgdata_MODULES): Add `test.mod'.
17415 (grub_script.tab.c): New rule.
17416 (grub_script.tab.h): Likewise.
17417
17418 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
17419
17420 * include/grub/normal.h (grub_test_init): New prototype.
17421 (grub_test_fini): Likewise.
f19dbdb7 17422
daac212a 17423 * normal/command.c: Include <grub/script.h>.
17424 (grub_command_execute): Rewritten.
f19dbdb7 17425
daac212a 17426 * util/grub-emu.c (main): Call `grub_test_init' and
17427 `grub_test_fini'.
17428
77500b2b 174292005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17430
17431 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
17432 to 0.
17433 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
17434 there are no pending characters.
17435
e45deb9e 174362005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17437
17438 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
17439 `grub_strndup' to drop device arguments. Replace unnecessary
17440 `grub_strndup' with `grub_strdup'.
17441
4ce32619 174422005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17443
17444 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
17445 `debug' environment variable has been set.
17446
174472005-11-02 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 17448
4ce32619 17449 * Makefile.in (install-local): Use $(DATA).
17450 (uninstall): Likewise.
17451 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
17452 (sbin_UTILITIES): ... to here.
17453 (sbin_SCRIPTS): New variable.
17454 (grub_install_SOURCES): New variable.
17455 * util/powerpc/ieee1275/grub-install.in: New file.
17456 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
17457 variable.
17458 (add_segments): Call `grub_util_get_path'.
17459
25fe6f03 174602005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
17461
17462 From Timothy Baldwin:
17463 * commands/ls.c (grub_ls_list_files): Close FILE with
17464 grub_file_close.
17465 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
17466
04ccf3ec 174672005-10-24 Marco Gerards <mgerards@xs4all.nl>
17468
17469 * include/grub/parser.h: New file.
17470
17471 * kern/parser.c: Likewise.
17472
17473 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
17474 (grub_setup_SOURCES): Likewise.
17475 (grub_probefs_SOURCES): Likewise.
17476 (grub_emu_SOURCES): Likewise.
17477 (kernel_img_HEADERS): Add `parser.h'.
17478
17479 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17480 (grub_emu_SOURCES): Add `kern/parser.c'.
17481 (grubof_SOURCES): Likewise.
17482
17483 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17484 (grubof_SOURCES): Add `kern/parser.c'.
17485
17486 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
17487
17488 * kern/misc.c (grub_split_cmdline): Removed function.
17489
17490 * kern/rescue.c: Include <grub/parser.h>.
17491 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
17492 of `grub_split_cmdline'.
17493
17494 * normal/command.c: Include <grub/parser.h>.
17495 (grub_command_execute): Use `grub_parser_split_cmdline' instead
17496 of `grub_split_cmdline'.
17497
17498 * normal/completion.c: Include <grub/parser.h>.
17499 (cmdline_state): New variable.
17500 (iterate_dir): End the filename with a quote depending on the
17501 command line state.
17502 (get_state): new function.
17503 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
17504 split the arguments and determine the current argument. When the
17505 argument string is not quoted, escape all spaces.
17506
6d8f4b0e 175072005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17508
17509 * normal/sparc64/setjmp.S: New file.
17510
15cf03ed 175112005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17512
17513 * include/grub/sparc64/libgcc.h: New file.
17514 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
17515 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
17516 normal/sparc64/setjmp.c.
17517
03e8661a 175182005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17519
17520 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
17521 * kern/sparc64/cache.S: New file.
17522 * kern/sparc64/cache.c: Removed.
17523 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
17524 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
17525 -mtune=ultrasparc.
17526 (COMMON_LDFLAGS): Add -melf64_sparc.
17527 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
17528 (grubof_SOURCES): Use cache.S instead of cache.c.
17529 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
17530 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
17531 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
17532 commented though.
17533 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
17534 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
17535 (linux_mod_CFLAGS): Commented out.
17536 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
17537 out because module isn't built.
17538 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
17539 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
17540 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
17541 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
17542 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
17543 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17544 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17545 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
17546 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
17547 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
17548 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17549 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17550 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
17551 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
17552
34eeec8a 175532005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
17554
17555 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
17556 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
17557 longer, because HFS should not be used on PC.
17558
708367a3 175592005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17560
17561 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
17562 consistently within the loop.
17563
6fa1251a 175642005-10-15 Marco Gerards <mgerards@xs4all.nl>
17565
17566 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
17567 directory can not be read.
17568
4801580b 175692005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17570
17571 * configure.ac (AC_INIT): Increase the version number to 1.91.
17572
17573 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
17574 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
17575 term/i386/pc/serial.c.
17576
219ad426 175772005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17578
17579 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
17580 file size must be permitted.
17581
17582 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
17583 between %ah and %al.
17584
688e5699 175852005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17586
17587 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
17588 grub_uint64_t.
17589 Call the hook with a NUL-terminated filename.
17590 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
17591 grub_cpu_to_be32.
17592
17593 * kern/term.c (cursor_state): New variable.
17594 (grub_term_set_current): Reset the cursor state on a new
17595 terminal.
17596 (grub_setcursor): Rewritten to use CURSOR_STATE.
17597 (grub_getcursor): New function.
17598
17599 * include/grub/term.h (grub_getcursor): New prototype.
17600
17601 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
17602 integers on ARM. Reported by Timothy Baldwin
17603 <T.E.Baldwin99@members.leeds.ac.uk>.
17604
bb34586c 176052005-10-11 Marco Gerards <mgerards@xs4all.nl>
17606
17607 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
17608 allocated.
17609 (grub_sfs_dir): Likewise.
17610
9a909877 176112005-10-09 Marco Gerards <mgerards@xs4all.nl>
17612
17613 Add support for the SFS filesystem.
17614
17615 * fs/sfs.c: New file.
17616
17617 * DISTLIST: Added `fs/sfs.c'.
17618
17619 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
17620 (grub_probefs_SOURCES): Likewise.
17621 (grub_emu_SOURCES): Likewise.
17622 (pkgdata_MODULES): Add `sfs.mod'.
17623 (sfs_mod_SOURCES): New variable.
17624 (sfs_mod_CFLAGS): Likewise.
17625 (sfs_mod_LDFLAGS): Likewise.
17626
17627 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
17628 (pkgdata_MODULES): Add `sfs.mod'.
17629 (sfs_mod_SOURCES): New variable.
17630 (sfs_mod_CFLAGS): Likewise.
17631
17632 * util/grub-emu.c (main): Call `grub_sfs_init' and
17633 `grub_sfs_fini'.
17634
17635 * include/grub/fs.h (grub_sfs_init): New prototype.
17636 (grub_sfs_fini): Likewise.
17637
57bdbde3 176382005-10-07 Marco Gerards <mgerards@xs4all.nl>
17639
17640 Add support for the AFFS filesystem.
17641
17642 * fs/affs.c: New file.
17643
17644 * DISTLIST: Added `fs/affs.c'.
17645
17646 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
17647 (grub_probefs_SOURCES): Likewise.
17648 (grub_emu_SOURCES): Likewise.
17649 (pkgdata_MODULES): Add `affs.mod'.
17650 (affs_mod_SOURCES): New variable.
17651 (affs_mod_CFLAGS): Likewise.
17652 (affs_mod_LDFLAGS): Likewise.
17653
17654 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
17655 (pkgdata_MODULES): Add `affs.mod'.
17656 (affs_mod_SOURCES): New variable.
17657 (affs_mod_CFLAGS): Likewise.
17658
17659 * util/grub-emu.c (main): Call `grub_affs_init' and
17660 `grub_affs_fini'.
17661
17662 * include/grub/fs.h (grub_affs_init): New prototype.
17663 (grub_affs_fini): Likewise.
17664
047b67e0 176652005-10-01 Marco Gerards <mgerards@xs4all.nl>
17666
17667 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
17668
59b8208a 176692005-10-01 Marco Gerards <mgerards@xs4all.nl>
17670
17671 * configure.ac: Accept `x86_64' as host_cpu. In that case add
17672 `-m32' to CFLAGS.
17673
17674 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
17675 linking.
f19dbdb7 17676
59b8208a 17677 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
17678 (COMMON_LDFLAGS): New variable.
17679 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
17680 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
17681 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
17682 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
17683 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
17684 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
17685 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
17686 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
17687 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
17688 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
17689 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17690 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17691 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
17692 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
17693 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
17694 variables.
17695 (normal_mod_ASFLAGS): Add `-m32'.
17696
17697 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
17698 (grub_host_size_t, grub_host_ssize_t): New types.
17699 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
fe6b695a 17700 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
59b8208a 17701 `GRUB_HOST_SIZEOF_VOID_P'.
17702
17703 * include/grub/kernel.h (struct grub_module_header): Type of
17704 member offset changed to `grub_host_off_t'. Type of member size
17705 changed to `grub_host_size_t'.
17706 (struct grub_module_info): Type of member offset changed to
17707 `grub_host_off_t'. Type of member size changed to
17708 `grub_host_size_t'.
17709
b4093103 177102005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
17711
17712 Make GRUB's kernel compliant to Multiboot Specification.
f19dbdb7 17713
b4093103 17714 * kern/i386/pc/startup.S (multiboot_header): New label.
17715 (multiboot_entry): Likewise.
17716 (multiboot_trampoline): Likewise.
17717
17718 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
17719 Increased to 0x4A0.
17720
17721 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
17722 put parentheses after a question mark.
17723 [!GRUB_UTIL] (my_mod): New variable.
17724
17725 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
17726
b2499b29 177272005-09-28 Marco Gerards <mgerards@xs4all.nl>
17728
17729 Adds support for the XFS filesystem. Btrees are not supported
17730 yet.
17731
17732 * fs/xfs.c: New file.
17733
17734 * DISTLIST: Added `fs/xfs.c'.
17735
17736 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
17737 (grub_probefs_SOURCES): Likewise.
17738 (grub_emu_SOURCES): Likewise.
17739 (pkgdata_MODULES): Add `xfs.mod'.
17740 (xfs_mod_SOURCES): New variable.
17741 (xfs_mod_CFLAGS): Likewise.
17742
17743 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
17744 (pkgdata_MODULES): Add `xfs.mod'.
17745 (xfs_mod_SOURCES): New variable.
17746 (xfs_mod_CFLAGS): Likewise.
17747
17748 * util/grub-emu.c (main): Call `grub_xfs_init' and
17749 `grub_xfs_fini'.
17750
17751 * include/grub/fs.h (grub_xfs_init): New prototype.
17752 (grub_xfs_fini): Likewise.
17753
f19dbdb7 17754
83d37a62 177552005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
17756
17757 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
17758 color modes, allow greater than 16 colors to be configured as
17759 a default palette.
17760
47d2d65e 177612005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
17762
17763 * normal/completion.c (complete_arguments): Add the qualifier
17764 const into OPTIONS.
17765
17766 From Omniflux <omniflux+lists@omniflux.com>:
17767 * include/grub/terminfo.h: New file.
17768 * include/grub/tparm.h: Likewise.
17769 * include/grub/i386/pc/serial.h: Likewise.
17770 * term/terminfo.c: Likewise.
17771 * term/tparm.c: Likewise.
17772 * term/i386/pc/serial.c: Likewise.
17773 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
17774 serial.mod.
17775 (terminfo_mod_SOURCES): New variable.
17776 (terminfo_mod_CFLAGS): Likewise.
17777 (serial_mod_SOURCES): Likewise.
17778 (serial_mod_CFLAGS): Likewise.
17779
48b671ff 177802005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
17781
17782 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
17783 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
17784 and kern/powerpc/ieee1275/cmain.c, respectively.
17785
17786 * boot/powerpc/ieee1275/crt0.S: Moved to ...
17787 * kern/powerpc/ieee1275/crt0.S: ... here.
17788
17789 * boot/powerpc/ieee1275/cmain.c: Moved to ...
17790 * kern/powerpc/ieee1275/cmain.c: ... here.
f19dbdb7 17791
48b671ff 17792 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
17793 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
17794 instead of boot/powerpc/ieee1275/crt0.S and
17795 boot/powerpc/ieee1275/cmain.c, respectively.
17796
17797 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
17798 sectors. It was not used anyway.
17799
09fc77a7 178002005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17801
17802 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
17803 `unused parameter' warning.
17804
003789c7 178052005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17806
17807 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
17808 function.
17809 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
17810 getcharwidth.
17811
67f44c86 178122005-08-28 Marco Gerards <metgerards@student.han.nl>
17813
17814 * include/grub/normal.h (enum grub_completion_type): Added
17815 `GRUB_COMPLETION_TYPE_ARGUMENT'.
17816
17817 * normal/cmdline.c (print_completion): Handle
17818 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
17819 * normal/menu_entry.c (store_completion): Likewise.
17820
17821 * normal/completion.c (complete_arguments): New function.
17822 (grub_normal_do_completion): Call `complete_arguments' when the
17823 current words start with a dash.
17824
0b5abe02 178252005-08-27 Marco Gerards <metgerards@student.han.nl>
17826
17827 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
17828 `gzio.mod' instead of `io.mod').
17829
d9864ee1 178302005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
17831
17832 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
17833 (DISTDIRS): Added io and video.
17834 Rewrite the search routine to make an output consistently.
17835
17836 * DISTLIST: Added conf/sparc64-ieee1275.mk,
17837 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
17838 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
17839 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
17840 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
17841 util/powerpc/ieee1275/misc.c.
f19dbdb7 17842
d9864ee1 17843 * include/grub/gzio.h: New file.
17844 * io/gzio.c: Likewise.
f19dbdb7 17845
d9864ee1 17846 * kern/file.c (grub_file_close): Call grub_device_close only if
17847 FILE->DEVICE is not NULL.
17848
17849 * include/grub/mm.h [!NULL] (NULL): New macro.
17850
17851 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
17852
17853 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
17854 (pkgdata_MODULES): Added gzio.mod.
17855 (gzio_mod_SOURCES): New variable.
17856 (gzio_mod_CFLAGS): Likewise.
17857
17858 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
17859 (pkgdata_MODULES): Added gzio.mod.
17860 (gzio_mod_SOURCES): New variable.
17861 (gzio_mod_CFLAGS): Likewise.
17862
17863 * commands/cat.c: Include grub/gzio.h.
17864 (grub_cmd_cat): Use grub_gzfile_open instead of
17865 grub_file_open.
f19dbdb7 17866
d9864ee1 17867 * commands/cmp.c: Include grub/gzio.h.
17868 (grub_cmd_cmp): Use grub_gzfile_open instead of
17869 grub_file_open.
17870
17871 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
17872 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
17873 grub_file_open.
17874 (grub_rescue_cmd_module): Likewise.
17875
fa46f4b5 178762005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
17877
17878 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
17879 kern/sparc64/ieee1275/init.c because it contains _start.
17880 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
17881
e9211b5d 178822005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
17883
17884 * configure.ac: Add support for sparc64 host with ieee1275
17885 firmware.
17886 * configure: Generated from configure.ac.
17887 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
17888 instead of int.
17889 (grub_ofdisk_read): Likewise.
17890 (grub_ofdisk_open): Use %p to print pointer values, and cast the
17891 pointers as (void *) to remove a warning.
17892 (grub_ofdisk_close): Likewise.
17893 (grub_ofdisk_read): Likewise.
17894 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
17895 returns, so make it return void to remove a warning.
17896 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
17897 Corresponding prototype change.
17898 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
17899 values, and cast the pointers as (void *) to remove a warning.
17900 (grub_mm_dump): Likewise.
17901 * conf/sparc64-ieee1275.mk: New file.
17902 * conf/sparc64-ieee1275.rmk: Likewise.
17903 * include/grub/sparc64/setjmp.h: Likewise.
17904 * include/grub/sparc64/types.h: Likewise.
17905 * include/grub/sparc64/ieee1275/console.h: Likewise.
17906 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
17907 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
17908 * include/grub/sparc64/ieee1275/time.h: Likewise.
17909 * kern/sparc64/cache.c: Likewise.
17910 * kern/sparc64/dl.c: Likewise.
17911 * kern/sparc64/ieee1275/init.c: Likewise.
17912 * kern/sparc64/ieee1275/openfw.c: Likewise.
17913
385c6a92 179142005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
17915
17916 * util/console.c (grub_ncurses_putchar): If C is greater than
17917 0x7f, set C to a question mark.
17918 (grub_ncurses_getcharwidth): New function.
17919 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
17920 getcharwidth.
17921
17922 * normal/menu.c (print_entry): Made aware of Unicode. First,
17923 convert TITLE to UCS-4, and predict the cursor position by
17924 grub_getcharwidth.
17925
17926 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
17927 const to SRC.
17928 * kern/misc.c (grub_utf16_to_utf8): Likewise.
17929
16ccb8b1 179302005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17931
17932 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
17933 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
17934 grub_strcat.
17935
17936 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
17937 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
17938 grub_strcpy and grub_strlen. Take it into account that a space
17939 character is inserted as a delimiter.
17940
6a85ce79 179412005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17942
17943 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
fe6b695a 17944 invalid magic in the error.
6a85ce79 17945
17946 * commands/search.c: New file.
f19dbdb7 17947
6a85ce79 17948 * util/grub-emu.c (main): Call grub_search_init and
17949 grub_search_fini.
17950
17951 * kern/rescue.c (grub_rescue_print_disks): Removed.
17952 (grub_rescue_print_devices): New function.
17953 (grub_rescue_cmd_ls): Use grub_device_iterate with
17954 grub_rescue_print_devices instead of grub_disk_dev_iterate with
17955 grub_rescue_print_disks.
17956
17957 * kern/partition.c (grub_partition_iterate): Return the result of
17958 PARTMAP->ITERATE instead of GRUB_ERRNO.
17959
17960 * kern/device.c: Include grub/partition.h.
17961 (grub_device_iterate): New function.
17962
17963 * include/grub/partition.h (grub_partition_iterate): Return int
17964 instead of grub_err_t.
17965
17966 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
17967 prototype.
17968 [GRUB_UTIL] (grub_search_fini): Likewise.
17969
17970 * include/grub/device.h (grub_device_iterate): New prototype.
17971
17972 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
17973 commands/search.c.
17974 (pkgdata_MODULES): Added search.mod.
17975 (search_mod_SOURCES): New variable.
17976 (search_mod_CFLAGS): Likewise.
17977
17978 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
17979 (pkgdata_MODULES): Added search.mod.
17980 (search_mod_SOURCES): New variable.
17981 (search_mod_CFLAGS): Likewise.
17982
17983 * commands/ls.c (grub_ls_list_disks): Renamed to ...
17984 (grub_ls_list_devices): ... this, and use grub_device_iterate.
17985 All callers changed.
17986
17987 * DISTLIST: Added commands/search.c.
17988
ef095434 179892005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17990
17991 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
17992 conversion.
17993 (grub_getcharwidth): New function.
17994
17995 * kern/misc.c (grub_utf8_to_ucs4): New function.
17996
17997 * include/grub/term.h (struct grub_term): Added a new member
17998 "getcharwidth".
17999 (grub_getcharwidth): New prototype.
18000
18001 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
18002
18003 * term/i386/pc/console.c (map_char): New function. Segregated from
18004 grub_console_putchar.
18005 (grub_console_putchar): Use map_char.
18006 (grub_console_getcharwidth): New function.
18007 (grub_console_term): Specified grub_console_getcharwidth as
18008 getcharwidth.
18009
18010 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
18011 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
18012
18013 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
18014 GRUB_ERRNO.
18015 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
18016 on grub_strtoul completely.
18017 (write_char): Declare local variables in the beginning of the
18018 function.
18019 (grub_vesafb_getcharwidth): New function.
18020 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
18021 getcharwidth.
18022
1f0a95e4 180232005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
18024
18025 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
18026 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
18027 commands/i386/pc/vbetest.c.
18028
18029 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
18030 call grub_vbe_get_controller_info again, because the returned
18031 information is volatile.
18032 (grub_vbe_set_video_mode): Mostly rewritten.
18033 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
18034 grub_vbe_status_t correctly.
18035 (grub_vbe_get_video_mode_info): Likewise.
18036 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
18037 several if statements.
18038
18039 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
18040 * commands/i386/pc/vbeinfo.c: ... this.
18041
18042 * commands/i386/pc/vbe_test.c: Renamed to ...
18043 * commands/i386/pc/vbetest.c: ... this.
18044
18045 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
18046 ...
18047 (grub_cmd_vbeinfo): ... this. Save video modes before
18048 iterating. Skip a video mode, if it is not available, not enough
18049 information is given or it is monochrome. Show the memory
18050 model. Leave the interpretation of MODEVAR to grub_strtoul
18051 completely.
18052 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
18053 (GRUB_MOD_FINI): Likewise.
18054
18055 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
18056 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
18057 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
18058 duplicated grub_env_get. Leave the interpretation of MODEVAR to
18059 grub_strtoul completely.
18060 (real2pm): Removed.
18061 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
18062 (GRUB_MOD_FINI): Likewise.
18063
18064 * normal/misc.c: Include grub/mm.h.
18065
18066 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
18067 vbe_list_modes with vbetest.mod and vbeinfo.mod.
18068 (vbe_list_modes_mod_SOURCES): Removed.
18069 (vbe_list_modes_mod_CFLAGS): Likewise.
18070 (vbe_test_mod_SOURCES): Likewise.
18071 (vbe_test_mod_CFLAGS): Likewise.
18072 (vbeinfo_mod_SOURCES): New variable.
18073 (vbeinfo_mod_CFLAGS): Likewise.
18074 (vbetest_mod_SOURCES): Likewise.
18075 (vbetest_mod_CFLAGS): Likewise.
18076
992ffbbe 180772005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
18078
18079 * normal/misc.c: New file.
18080
18081 * DISTLIST: Added normal/misc.c.
f19dbdb7 18082
992ffbbe 18083 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
18084 DISK to HOOK. Call HOOK with DISK.
18085 * partmap/apple.c (apple_partition_map_iterate): Likewise.
18086 * partmap/pc.c (pc_partition_map_iterate): Likewise.
18087 * partmap/sun.c (sun_partition_map_iterate): Likewise.
18088
18089 * normal/menu_entry.c (struct screen): Added a new member
18090 "completion_shown".
18091 (completion_buffer): New global variable.
18092 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
18093 (store_completion): New function.
18094 (complete): Likewise.
18095 (clear_completions): Likewise.
18096 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
18097 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
18098 a tab, call complete.
18099
18100 * normal/completion.c (disk_dev): Removed.
18101 (print_simple_completion): Likewise.
18102 (print_partition_completion): Likewise.
18103 (print_func): New global variable.
18104 (add_completion): Do not take the arguments WHAT or PRINT any
18105 longer. Added a new argument TYPE. Instead of printing directly,
18106 call PRINT_FUNC if not NULL.
18107 All callers changed.
18108 (complete_device): Use a local variable DEV instead of
18109 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
18110 (grub_normal_do_completion): Take a new argument HOOK. Do not
18111 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
18112 empty string, return NULL instead.
18113 All callers changed.
18114
18115 * normal/cmdline.c (print_completion): New function.
18116
18117 * kern/partition.c (grub_partition_iterate): Add an argument DISK
18118 to HOOK.
18119 All callers changed.
18120
18121 * kern/disk.c (grub_print_partinfo): Removed.
18122
18123 * include/grub/partition.h (struct grub_partition_map): Add a new
18124 argument DISK into HOOK of ITERATE.
18125 (grub_partition_iterate): Add a new argument DISK to HOOK.
18126
18127 * include/grub/normal.h (enum grub_completion_type): New enum.
18128 (grub_completion_type_t): New type.
18129 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
18130 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
18131 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
18132 (GRUB_COMPLETION_TYPE_FILE): Likewise.
18133 (grub_normal_do_completion): Added a new argument HOOK.
18134 (grub_normal_print_device_info): New prototype.
18135
18136 * include/grub/disk.h (grub_print_partinfo): Removed.
18137
18138 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
18139 (normal_mod_SOURCES): Likewise.
18140 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
18141 (normal_mod_SOURCES): Likewise.
18142
18143 * commands/ls.c (grub_ls_list_disks): Use
18144 grub_normal_print_device_info instead of grub_print_partinfo. Free
18145 PNAME.
18146 (grub_ls_list_files): Use grub_normal_print_device_info instead of
18147 duplicating the code.
18148
0bd41162 181492005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18150
18151 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
f19dbdb7 18152 follow GCS more precisely.
18153 * commands/i386/pc/vbe_test.c: Likewise.
18154 * include/grub/i386/pc/vbe.h: Likewise.
18155 * term/i386/pc/vesafb.c: Likewise.
18156 * video/i386/pc/vbe.c: Likewise.
0bd41162 18157
6323696a 181582005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18159
18160 * DISTLIST: Added term/i386/pc/vesafb.c
18161 DISTLIST: Added video/i386/pc/vbe.c
18162 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
18163 DISTLIST: Added commands/i386/pc/vbe_test.c.
18164 * commands/i386/pc/vbe_list_modes.c: New file.
18165 * commands/i386/pc/vbe_test.c: Likewise.
18166 * term/i386/pc/vesafb.c: Likewise.
18167 * video/i386/pc/vbe.c: Likewise.
18168 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
18169 (grub_vbe_probe) Added prototype.
18170 (grub_vbe_set_video_mode) Likewise.
18171 (grub_vbe_get_video_mode) Likewise.
18172 (grub_vbe_get_video_mode_info) Likewise.
18173 (grub_vbe_set_pixel_rgb) Likewise.
18174 (grub_vbe_set_pixel_index) Likewise.
18175 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
18176 (pkgdata_MODULES): Added vesafb.mod.
18177 (pkgdata_MODULES): Added vbe_list_modes.mod.
18178 (pkgdata_MODULES): Added vbe_test.mod.
18179 (vbe_mod_SOURCES): Added.
18180 (vbe_mod_CFLAGS): Likewise.
18181 (vesafb_mod_SOURCES): Likewise.
18182 (vesafb_mod_CFLAGS): Likewise.
18183 (vbe_list_modes_mod_SOURCES): Likewise.
18184 (vbe_list_modes_mod_CFLAGS): Likewise.
18185 (vbe_test_mod_SOURCES): Likewise.
18186 (vbe_test_mod_CFLAGS): Likewise.
18187
0a74e62f 181882005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
18189
0a74e62f 18190 * normal/command.c (grub_command_execute): If INTERACTIVE is
18191 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
18192 CMDLINE. Disable the pager if INTERACTIVE is true.
18193 All callers are changed.
18194
18195 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
18196 before reading a config file.
18197 * normal/main.c (read_config_file): Even if a command is not
18198 found, register it if it is within an entry.
18199
18200 * util/grub-emu.c: Include sys/types.h and unistd.h.
18201 (options): Added --hold.
18202 (struct arguments): Added a new member "hold".
18203 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
18204 missing.
18205 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
18206 cleared by a debugger, if it is not zero.
18207
18208 * include/grub/normal.h (grub_command_execute): Add an argument
18209 INTERACTIVE.
18210
e51f85ae 182112005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
18212
18213 * DISTLIST: Added include/grub/i386/pc/vbe.h.
18214
e9c6f39b 182152005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
18216
18217 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
18218 program with another one, because the old one didn't detect a bug
18219 in gcc-3.4. Always use regparm 2, because the new test is still
18220 not enough for gcc-4.0. Someone must investigate a simple test
18221 case which detects a bug in gcc-4.0.
18222
8de3495c 182232005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
18224
18225 * DISTLIST: Added normal/completion.c.
18226
18227 * normal/completion.c: New file.
f19dbdb7 18228
8de3495c 18229 * term/i386/pc/console.c (grub_console_getwh): New function.
18230 (grub_console_term): Assign grub_console_getwh to getwh.
18231
18232 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
18233 function is defined in normal/completion.c as
18234 grub_normal_do_completion.
18235 (grub_cmdline_get): Use grub_normal_do_completion instead of
18236 grub_tab_complete.
18237
18238 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
18239 returns non-zero, otherwise return 0.
18240 (grub_partition_iterate): First, probe the partition map. Then,
18241 call ITERATE only for this partition map.
18242
18243 * kern/misc.c (grub_strncmp): Rewritten.
18244
18245 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
18246 returns non-zero. Otherwise return 0.
18247
18248 * include/grub/partition.h (grub_partition_map_iterate): Return
18249 int instead of void.
18250
18251 * include/grub/normal.h (grub_normal_do_completion): New prototype.
18252
18253 * include/grub/misc.h (grub_strncmp): Change the type of N to
18254 grub_size_t.
18255
18256 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
18257 of void.
18258
18259 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
fe6b695a 18260 unsigned explicitly before comparing it with I.
8de3495c 18261
18262 * kern/main.c (grub_env_write_root): Add the attribute unused into
18263 VAR.
18264
18265 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18266 normal/completion.c.
18267 (normal_mod_SOURCES): Likewise.
18268 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
18269 (normal_mod_SOURCES): Likewise.
18270
18271 * normal/command.c (grub_iterate_commands): If ITERATE returns
18272 non-zero, return one immediately.
18273
e85e144b 182742005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
18275
18276 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
18277 * kern/i386/pc/startup.S: Updated Global Descriptor table's
18278 descriptions.
18279 (grub_vbe_get_controller_info): New function.
18280 (grub_vbe_get_mode_info): Likewise.
18281 (grub_vbe_set_mode): Likewise.
18282 (grub_vbe_get_mode): Likewise.
18283 (grub_vbe_set_memory_window): Likewise.
18284 (grub_vbe_get_memory_window): Likewise.
18285 (grub_vbe_set_scanline_length): Likewise.
18286 (grub_vbe_get_scanline_length): Likewise.
18287 (grub_vbe_set_display_start): Likewise.
18288 (grub_vbe_get_display_start): Likewise.
18289 (grub_vbe_set_palette_data): Likewise.
18290 * include/grub/i386/pc/vbe.h: New file.
18291
c46153d2 182922005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18293
18294 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18295 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
18296 * DISTLIST: Likewise.
18297 * kern/ieee1275/of.c: Moved to ...
18298 * kern/ieee1275/ieee1275.c: ... here.
18299
0cb90c45 183002005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18301
18302 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
18303 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
18304 Pass 0 as `end' parameter to grub_strtoul().
18305
a19fb360 183062005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18307
18308 * include/grub/powerpc/ieee1275/console.h: Do not include
18309 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
18310 ifdef.
18311 (grub_console_cur_color): Remove i386-specific prototype.
18312 (grub_console_real_putchar): Likewise.
18313 (grub_console_checkkey): Likewise.
18314 (grub_console_getkey): Likewise.
18315 (grub_console_getxy): Likewise.
18316 (grub_console_gotoxy): Likewise.
18317 (grub_console_cls): Likewise.
18318 (grub_console_setcursor): Likewise.
18319 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
18320 Include <grub/machine/console.h>.
18321 * term/ieee1275/ofconsole.c: Likewise.
18322
4ac9bd04 183232005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
18324
18325 * Makefile.in (LIBLZO): New variable.
18326
18327 * configure.ac: Check for LZO version 2.
18328
18329 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
18330 lzo/lzo1x.h instead of lzo1x.h.
18331
18332 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
18333 of -llzo.
18334
18335 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
18336 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
18337
18338 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
18339 copying the data from PARTITION to P.
18340
f4917dfd 183412005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18342
18343 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
18344 negative, unload the module.
18345
18346 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
18347 map is "pc_partition_map" but not "pc".
18348 (usage): Fix the description. The options are --boot-image and
18349 --core-image but not --boot-file or --core-file.
18350 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
18351 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
18352 DEFAULT_DIRECTORY.
18353
18354 * util/i386/pc/grub-install.in: Do not specify --boot-file or
18355 --core-file. Specify INSTALL_DEVICE as an argument.
18356
18357 * util/console.c: Include config.h.
18358 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
18359 [HAVE_NCURSES_H]: Include ncurses.h.
18360 [HAVE_CURSES_H]: Include curses.h.
18361 [!A_NORMAL] (A_NORMAL): Defined as zero.
18362 [!A_STANDOUT] (A_STANDOUT): Likewise.
18363
18364 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
18365 -lncurses.
18366 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
18367
18368 * configure.ac: Check for curses libraries and headers.
18369
18370 * Makefile.in (LIBCURSES): New variable.
18371
18372 * genmk.rb (Script::rule): Set the executable bits.
18373
18374 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
18375 name of the PC partition map is "pc_partition_map" but not "pc".
18376
0e143073 183772005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18378
18379 * util/i386/pc/grub-install.in (grub_probefs): New variable.
18380 (modules): Likewise.
18381 (usage): Added descriptions for --modules and --grub-probefs.
18382 Handle --modules and --grub-probefs. Save the arguments in MODULES
18383 and GRUB_PROBEFS, respectively.
18384 Auto-detect a filesystem module against GRUBDIR. If the result is
18385 empty and modules are not specified explicitly, abort the
18386 installation. Add the result to MODULES.
18387
18388 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
18389 disk/powerpc/ieee1275/ofdisk.c,
18390 include/grub/powerpc/ieee1275/init.h and
18391 term/powerpc/ieee1275/ofconsole.c.
18392 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
18393 term/ieee1275/ofconsole.c.
18394
18395 * include/grub/powerpc/ieee1275/console.h: Resurrected.
18396
18397 * COPYING: Upgraded to the latest version. Only the address of the
18398 FSF office has changed.
f19dbdb7 18399
efd6e6d5 184002005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18401
18402 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18403 kern/ieee1275.c with kern/ieee1275/of.c.
18404
18405 * kern/ieee1275.c: Moved to ...
18406 * kern/ieee1275/of.c: ... here.
18407
8ceafda2 184082005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
18409
18410 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
fe6b695a 18411 readability.
8ceafda2 18412
18413 * config.guess: Updated to the latest version from gnulib.
18414 * config.sub: Likewise.
18415 * install.sh: Likewise.
18416 * mkinstalldirs: Likewise.
18417
18418 * include/grub/console.h: Removed. This file is arch-specific. Do
18419 not put this in include/grub.
18420
18421 * include/grub/i386/pc/console.h: Resurrected.
18422
18423 * util/console.c: Include grub/machine/console.h instead of
18424 grub/console.h.
18425 * util/grub-emu.c: Likewise.
18426
267f6cd9 184272005-08-04 Marco Gerards <metgerards@student.han.nl>
18428
18429 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
18430 hardcoded value.
f19dbdb7 18431
267f6cd9 18432 From Vincent Pelletier <subdino2004@yahoo.fr>
18433 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
18434 Redefined to use grub_getwh.
18435 (grub_term): New member named getwh.
18436 (grub_getwh): New prototype.
18437 * kern/term.c (grub_getwh): New function.
18438 * term/i386/pc/console.c (grub_console_getwh): New function.
18439 (grub_console_term): New member `getwh'.
18440 * term/i386/pc/vga.c (grub_vga_getwh): New function.
18441 (grub_vga_term): New member `getwh'.
0b5abe02 18442 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
267f6cd9 18443 grub_ssize_t.
18444 (grub_ofconsole_getw): New function.
18445 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
18446 (grub_ofconsole_term): New field named getwh and new initial
18447 value.
18448
3be7266d 184492005-08-03 Hollis Blanchard <hollis@penguinppc.org>
18450
18451 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
18452 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
18453 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
18454 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
18455 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
18456 of <grub/machine/ieee1275.h>.
18457 * commands/ieee1275/reboot.c: Likewise.
18458 * boot/powerpc/ieee1275/ieee1275.c: Move ...
18459 * kern/ieee1275.c: ... to here. All users updated. Change all
18460 parameter structs to use new type `grub_ieee1275_cell_t'.
18461 * term/powerpc/ieee1275/ofconsole.c: Move ...
18462 * term/ieee1275/ofconsole.c: ... to here. All users updated.
18463 * disk/powerpc/ieee1275/ofdisk.c: Move ...
18464 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
18465 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
18466 to return int.
18467 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
18468 Remove unused prototypes. All users updated.
18469 * include/grub/powerpc/ieee1275/console.h: Removed.
18470 * include/grub/powerpc/ieee1275/ieee1275.h: Define
18471 `grub_ieee1275_cell_t'.
18472 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
18473 Cast comparisons with -1 to the correct type.
18474 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
18475 type to match `grub_ieee1275_entry_fn'.
18476
8b5f3938 184772005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
18478
18479 * DISTLIST: Added util/i386/pc/grub-probefs.c.
18480
18481 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
18482 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
18483 partmap/sun.c.
18484 (grub_probefs_SOURCES): New variable.
18485
18486 * util/i386/pc/grub-probefs.c: New file.
18487
18488 * util/i386/pc/grub-setup.c (main): Call
18489 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
18490 grub_hfs_init and grub_jfs_init to initialize the system. Call
18491 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
18492 grub_pc_partition_map_fini to finish the system.
18493
ea409713 184942005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
18495
18496 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
18497 function.
18498 (grub_multiboot_load_elf32): Likewise.
18499 (grub_multiboot_is_elf64): Likewise.
18500 (grub_multiboot_load_elf64): Likewise.
18501 (grub_multiboot_load_elf): Likewise.
18502 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
18503 an ELF32 or ELF64 file.
18504 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
18505
18506 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
18507 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
18508 NULL before calling FS->LABEL.
18509 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
18510 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
18511 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
18512 before calling FS->LABEL.
18513
141a288b 185142005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
18515
18516 * util/i386/pc/grub-install.in (datadir): New variable.
18517 (libdir): Removed.
18518 (pkgdatadir): New variable.
18519 (pkglibdir): Removed.
18520
0d5f8a54 185212005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
18522
18523 * DISTLIST: Added util/i386/pc/grub-install.in.
18524
18525 * util/i386/pc/grub-install.in: New file.
18526
18527 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
18528 (grub_install_SOURCES): Likewise.
18529
18530 * genmk.rb: Added support for scripts.
18531 (Script): New class.
18532 (scripts): New variable.
18533
18534 * Makefile.in (install-local): Install sbin_SCRIPTS by
18535 INSTALL_SCRIPT.
18536 (uninstall): Remove sbin_SCRIPTS.
18537
18538 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
18539 device, try to get a GRUB device by
18540 grub_util_biosdisk_get_grub_dev.
18541 Free DEST_DEV.
18542
18543 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
18544 description for --device-map.
18545
5f968e1e 185462005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18547
18548 Change the semantics of variable hooks. They now return strings
18549 instead of error values.
f19dbdb7 18550
5f968e1e 18551 * util/i386/pc/grub-setup.c: Include grub/env.h.
18552 (setup): Use grub_device_set_root instead of grub_env_set.
18553
18554 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
18555 grub_env_get instead of grub_device_set_root and
18556 grub_device_get_root, respectively.
18557
18558 * kern/main.c (grub_env_write_root): New function.
18559 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
18560 grub_env_set instead of grub_device_set_root.
18561
18562 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
18563 many variables.
18564 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
18565 rather than calling ENV->WRITE_HOOK afterwards.
18566 (grub_env_get): Return the result of ENV->READ_HOOK rather than
18567 passing a pointer of a pointer.
18568 (grub_register_variable_hook): Change the types of "read_hook" and
18569 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
18570 respectively.
18571 Allocate the default empty string on the heap, because this string
18572 may be freed later.
18573
18574 * kern/device.c: Include grub/env.h.
18575 (grub_device_set_root): Removed.
18576 (grub_device_get_root): Likewise.
18577 (grub_device_open): Use grub_env_get instead of
18578 grub_device_get_root.
18579
18580 * include/grub/env.h (grub_env_read_hook_t): New type.
18581 (grub_env_write_hook_t): Likewise.
18582 (grub_env_var): Change the types of "read_hook" and "write_hook"
18583 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
18584 (grub_register_variable_hook): Likewise.
18585
18586 * include/grub/device.h (grub_device_set_root): Removed.
18587 (grub_device_set_root): Likewise.
18588
18589 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
18590 make sure that DIRNAME terminates with '/', so that
18591 grub_fat_find_dir will fail if PATH is not a directory.
18592
18593 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
18594 from DIRNAME.
18595 Use the qualifier auto for print_files and print_files_long.
18596 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
18597 as a regular file.
18598 Put a newline only if there is no error.
18599 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
18600 used.
18601
896f0afd 186022005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18603
18604 * kern/partition.c (grub_partition_probe): Initialize PART to
18605 NULL. Otherwise, when no partition map is registered, this returns
18606 a garbage.
18607
b28b81b2 186082005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
18609
18610 * partmap/apple.c (apple_partition_map_iterate): Check if POS
18611 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
18612 valid.
18613
5f3607e0 186142005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
18615
18616 * commands/ls.c (grub_ls_list_disks): Print the filesystem
18617 information on each device, if it does not have partitions. Print
18618 "Device" instead of "Disk", because this function is not specific
18619 to disk devices.
18620
18621 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
18622 static to ensure that it is put on the memory rather than a
18623 register.
18624
502c87e8 186252005-07-17 Yoshinori Okuji <okuji@enbug.org>
18626
18627 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
18628 (grub_cat_init): Likewise.
18629 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
18630 (options): Likewise.
18631 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
18632 (grub_configfile_init): Likewise.
18633 * font/manager.c (GRUB_MOD_INIT): Likewise.
18634 * commands/help.c (GRUB_MOD_INIT): Likewise.
18635 (grub_help_init): Likewise.
18636 * normal/command.c (grub_command_init): Likewise.
18637 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
18638 * disk/loopback.c (grub_loop_init): Likewise.
18639 (GRUB_MOD_INIT): Likewise.
18640 * commands/ls.c (grub_ls_init): Likewise.
18641 (GRUB_MOD_INIT): Likewise.
18642 (options): Likewise.
18643 * commands/boot.c (grub_boot_init): Likewise.
18644 (GRUB_MOD_INIT): Likewise.
18645 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
18646 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
18647 (GRUB_MOD_INIT): Likewise.
18648 * commands/cmp.c (grub_cmp_init): Likewise.
18649 (GRUB_MOD_INIT): Likewise.
18650
18651 * normal/arg.c: Use <> instead of "" to include header files.
18652 (SHORT_ARG_HELP): New macro.
18653 (SHORT_ARG_USAGE): Likewise.
18654 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
18655 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
18656 descriptions.
18657 (find_short): Check if C is 'h' or 'u' explicitly.
18658 (grub_arg_show_help): Use space characters instead of tabs. Treat
18659 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
18660 are shown with --help and --usage only if they are not used for
18661 the command itself.
18662 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
18663 'h' and 'u'.
18664
18665 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
18666 const into "longarg". Change the type of "shortarg" to int.
18667
f806d18e 186682005-07-17 Yoshinori Okuji <okuji@enbug.org>
18669
18670 * boot/i386/pc/boot.S (boot_drive_check): New label.
18671
18672 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
18673 macro.
18674
18675 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
18676 which do not pass a boot drive correctly. Copied from GRUB Legacy.
18677
e293232b 186782005-07-17 Yoshinori Okuji <okuji@enbug.org>
18679
18680 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
18681 When turning off Gate A20, skip the check and return immediately,
18682 because this is not fatal usually.
18683
ebedfd00 186842005-07-17 Yoshinori Okuji <okuji@enbug.org>
18685
18686 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
18687 be 0x7C00 instead of 0x8000.
18688
18689 * boot/i386/pc/pxeboot.S: Rewritten.
18690
18691 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
18692 EXT_C.
18693 (gate_a20_check_state): Read a byte from 0x108000. Invert the
18694 result.
18695
654fc59f 186962005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
18697
18698 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
18699 robustness. This routine now supports a BIOS call and System
18700 Control Port A to modify the gate A20.
18701
18702 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
18703 Increased to 0x440.
18704
09f9923f 187052005-07-12 Hollis Blanchard <hollis@penguinppc.org>
18706
18707 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
18708 device path and resulting ihandle.
18709 (grub_ofdisk_close): dprintf the ihandle being closed.
18710 (grub_ofdisk_read): dprintf function parameters.
18711 * kern/mm.c (grub_mm_init_region): Likewise.
18712 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
18713 (grub_linux_boot): dprintf the Linux entry point, initrd address and
18714 size, and boot arguments.
18715 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
18716 before loading into memory.
18717 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
18718 before loading into memory.
18719
7ef504d8 187202005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
18721
18722 * kern/mm.c: Added much documentation.
18723 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
18724 8, set to 5 instead of 8.
18725
e0f050c2 187262005-07-10 Yoshinori Okuji <okuji@enbug.org>
18727
18728 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
18729
18730 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
18731 (grub_mkdevicemap_SOURCES): New variable.
18732
18733 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
18734 lib/device.c of GRUB Legacy.
18735
7224189a 187362005-07-10 Yoshinori Okuji <okuji@enbug.org>
18737
18738 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
18739 instead of PATH is NULL.
18740
68c864eb 187412005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
18742
18743 * commands/cmp.c (BUFFER_SIZE): New macro.
18744 (grub_cmd_cmp): Close the right file at the right time. Compare
18745 only data just read. Don't report files of different size as
18746 identical. Dynamically allocate buffers. Move variable
18747 declarations at the beginning of function.
18748
e6f3e614 187492005-07-09 Yoshinori Okuji <okuji@enbug.org>
18750
18751 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
18752 reverse.
18753
f8f1559a 187542004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
18755
18756 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
18757 when backspace is pressed at beginning of line.
18758
39c9d41d 187592005-07-03 Yoshinori Okuji <okuji@enbug.org>
18760
18761 * DISTLIST: Added genfslist.sh.
18762
18763 * normal/main.c (fs_module_list): New variable.
18764 (autoload_fs_module): New function.
18765 (read_fs_list): Likewise.
18766 (grub_normal_execute): Call read_fs_list.
18767
18768 * kern/fs.c (grub_fs_autoload_hook): New variable.
18769 (grub_fs_probe): Added support for auto-loading.
18770
18771 * include/grub/normal.h (struct grub_fs_module_list): New struct.
18772 (grub_fs_module_list_t): New type.
18773
18774 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
18775 (grub_fs_autoload_hook): New prototype.
18776
18777 * genfslist.sh: New file.
f19dbdb7 18778
39c9d41d 18779 * genmk.rb: Added a rule to generate a filesystem list.
18780
121c1d83 187812005-06-30 Marco Gerards <metgerards@student.han.nl>
18782
18783 * configure.ac: Fix the test for cross-compiling.
18784
18785 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
18786 define GRUB_UTIL anymore.
18787
18788 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
18789 so this function works on other systems than just big endian.
18790 (load_modules): Likewise.
18791 (add_segments): Likewise.
18792
e75d76e1 187932005-06-23 Hollis Blanchard <hollis@penguinppc.org>
18794
18795 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
18796 contains `l' modifier, get a long from va_arg().
18797
50b5a0a7 187982005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
18799
18800 * kern/mm.c (grub_free): If the next free block which is being
18801 merged is the first free block, set the first block to the block
18802 being freed.
18803 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
18804
89371b20 188052005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18806
18807 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
18808 `grub_ieee1275_chosen'.
18809
168d6e58 188102005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18811
18812 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
18813 (grub_ieee1275_chosen): New variable.
18814 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
18815 `chosen'.
18816 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
18817 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
18818 Rename first argument to `phandle' for consistency.
18819 (grub_ieee1275_get_property_length): Likewise.
18820 (grub_ieee1275_next_property): Likewise. Change type of first argument
18821 to grub_ieee1275_phandle_t.
18822 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
18823 Move export next to declaration.
18824 (grub_ieee1275_chosen): New variable.
18825 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
18826 Correct cosmetic typo.
18827 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
18828 `grub_ieee1275_chosen'.
18829 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
18830 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
18831 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
18832 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
18833 `grub_ieee1275_chosen'.
18834
ca5baa3f 188352005-05-10 Hollis Blanchard <hollis@penguinppc.org>
18836
18837 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
18838 /chosen/bootargs.
18839 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
18840 /chosen/bootargs as "variable=value" pairs.
18841
708b345f 188422005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
18843
18844 * include/grub/misc.h (grub_dprintf): New macro.
18845 (grub_real_dprintf): New prototype.
18846 (grub_strword): Likewise.
18847 (grub_iswordseparator): Likewise.
18848 * kern/misc.c (grub_real_dprintf): New function.
18849 (grub_strword): Likewise.
18850 (grub_iswordseparator): Likewise.
18851
f4c5e67c 188522005-04-30 Hollis Blanchard <hollis@penguinppc.org>
18853
18854 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
18855 (roundup): Remove macro.
18856 (grub_ieee1275_flags): Make static.
18857 (grub_ieee1275_realmode): Remove.
18858 (grub_ieee1275_test_flag): New function.
18859 (grub_ieee1275_set_flag): Likewise.
18860 (find_options): Rename to `grub_ieee1275_find_options'; update
18861 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
18862 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
18863 (cmain): New prototype.
18864 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
18865 `grub_ieee1275_flags' directly.
18866 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
18867 machine/biosdisk.h.
18868 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
18869 Don't include grub/machine/init.h.
18870 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
18871 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
18872 Remove prototype.
18873 (grub_ieee1275_realmode): Likewise.
18874 (grub_ieee1275_flag): New enum.
18875 (grub_ieee1275_test_flag): New prototype.
18876 (grub_ieee1275_set_flag): New prototype.
18877 * include/grub/powerpc/ieee1275/init.h: Remove file.
18878 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
18879 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
18880 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
18881 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
18882 comment.
18883 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
18884 `grub_ieee1275_test_flag'.
18885 (grub_ieee1275_encode_devname): Likewise.
18886
ed16607e 188872005-04-21 Hollis Blanchard <hollis@penguinppc.org>
18888
18889 * include/grub/powerpc/ieee1275/ieee1275.h
18890 (grub_ieee1275_encode_devname): New prototype.
18891 (grub_ieee1275_get_filename): Likewise.
18892 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
18893 function.
18894 (grub_set_prefix): Likewise.
18895 (grub_machine_init): Call grub_set_prefix.
18896 * kern/powerpc/ieee1275/openfw.c: Fix typos.
18897 (grub_parse_type): New enum.
18898 (grub_ieee1275_get_devargs): New function.
18899 (grub_ieee1275_get_devname): Likewise.
18900 (grub_ieee1275_parse_args): Likewise.
18901 (grub_ieee1275_get_filename): Likewise.
18902 (grub_ieee1275_encode_devname): Likewise.
18903
be369920 189042005-03-30 Marco Gerards <metgerards@student.han.nl>
18905
18906 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
18907 `grub_loader_unset'.
18908
a5ce3a4a 189092005-03-26 Hollis Blanchard <hollis@penguinppc.org>
18910
18911 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
18912 instead of grub_ieee1275_interpret.
18913 (grub_halt_init): New function.
18914 (grub_halt_fini): Likewise.
18915 (GRUB_MOD_INIT): Correct message grammar.
18916 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
18917 instead of grub_ieee1275_interpret.
18918 (grub_reboot_init): New function.
18919 (grub_reboot_fini): Likewise.
18920 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
18921 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
18922 util/i386/pc/misc.c with commands/ieee1275/halt.c,
18923 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
18924 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
18925 function.
18926 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
18927 Add prototype.
18928 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
18929 prototype.
18930 (grub_halt): Likewise.
18931 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
18932 (cmain): Remove __attribute__((unused)).
18933 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
18934 (grub_heap_len): Likewise.
18935 (grub_machine_fini): New function.
18936 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
18937 (grub_halt): Likewise.
18938 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
18939 function.
18940 * util/powerpc/ieee1275/misc.c: New file.
18941
0058f771 189422005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
18943
18944 * DISTLIST: New file.
18945 * gendistlist.sh: Likewise.
f19dbdb7 18946
0058f771 18947 * Makefile.in (COMMON_DISTFILES): Removed.
18948 (BOOT_DISTFILES): Likewise.
18949 (CONF_DISTFILES): Likewise.
18950 (DISK_DISTFILES): Likewise.
18951 (FS_DISTFILES): Likewise.
18952 (INCLUDE_DISTFILES): Likewise.
18953 (KERN_DISTFILES): Likewise.
18954 (LOADER_DISTFILES): Likewise.
18955 (TERM_DISTFILES): Likewise.
18956 (UTIL_DISTFILES): Likewise.
18957 (DISTFILES): Likewise.
18958 (uninstall): Uninstall files in $(pkgdata_DATA).
18959 (DISTLIST): New target.
18960 (distdir): Use the contents of the file DISTLIST to get a list of
18961 distributed files.
18962
46b3b8a5 189632005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
18964
18965 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
18966 descriptor. This is ported from GRUB Legacy.
18967
18968 * gencmdlist.sh: Added an extra semicolon to make it work with
18969 old sed versions. Reported by Robert Bihlmeyer
18970 <robbe@orcus.priv.at>.
18971
5822ff87 189722005-03-08 Yoshinori Okuji <okuji@enbug.org>
18973
18974 Automatic loading of commands is supported.
f19dbdb7 18975
5822ff87 18976 * normal/main.c (read_command_list): New function.
18977 (grub_normal_execute): Call read_command_list.
18978
18979 * normal/command.c (grub_register_command): Return zero or CMD.
18980 Allocate CMD->NAME from the heap.
18981 Initialize CMD->MODULE_NAME to zero.
18982 Find the same name as well. If the same command is found and it is
18983 a dummy command, overwrite members. If it is not a dummy command,
18984 return zero.
18985 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
18986 (grub_command_find): If a dummy command is found, load a module
18987 and retry to find a command only once.
18988
18989 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
18990 make sure that each command is loaded.
18991
18992 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
18993 macro.
18994 (struct grub_command): Remove const from the member `name'.
18995 Add a new member `module_name'.
18996 (grub_register_command): Return grub_command_t.
18997
18998 * commands/help.c (grub_cmd_help): Call grub_command_find to make
18999 sure that each command is loaded.
19000
19001 * genmk.rb (PModule::rule): Specify a module name without the
19002 suffix ".mod" to gencmdlist.sh.
19003
7b1f4b57 190042005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19005
19006 * gencmdlist.sh: New file.
f19dbdb7 19007
7b1f4b57 19008 * genmk.rb (PModule::rule): Generate a rule for a command list.
19009 Clean command.lst.
19010 Generate command.lst from $(COMMANDFILES).
19011
19012 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
19013 (DATA): Added $(pkgdata_DATA).
19014 (install-local): Install files in $(pkgdata_DATA).
19015
062aaf39 190162005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19017
19018 * term/i386/pc/vga.c (debug_command): Removed.
19019 (GRUB_MOD_INIT): Do not register the command "debug".
19020
19021 From Hollis Blanchard:
19022 * commands/configfile.c: New file.
19023 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19024 commands/configfile.c.
19025 (pkgdata_MODULES): Added configfile.mod.
19026 (configfile_mod_SOURCES): New variable.
19027 (configfile_mod_CFLAGS): Likewise.
19028 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
19029 commands/configfile.c.
19030 (pkgdata_MODULES): Added configfile.mod.
19031 (configfile_mod_SOURCES): New variable.
19032 (configfile_mod_CFLAGS): Likewise.
19033 * util/grub-emu.c (main): Call grub_configfile_init and
19034 grub_configfile_fini.
19035 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
19036 prototype.
19037 [GRUB_UTIL] (grub_configfile_fini): Likewise.
f19dbdb7 19038
cee01aa6 190392005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19040
19041 * normal/arg.c (grub_arg_show_help): Do not show the bug report
19042 address.
19043
19044 * commands/help.c (grub_cmd_help): Do not print newlines after
19045 the last command in print_command_help.
19046
93f3a1d8 190472005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19048
19049 * commands/default.h: New file.
19050 * commands/timeout.h: Likewise.
19051 * normal/context.c: Likewise.
f19dbdb7 19052
93f3a1d8 19053 * util/misc.c: Do not include sys/times.h.
19054 Include sys/time.h and grub/machine/time.h.
19055 (grub_get_rtc): Rewritten with gettimeofday.
19056
19057 * util/grub-emu.c (main): Call grub_default_init and
19058 grub_timeout_init before grub_normal_init, and call
19059 grub_timeout_fini and grub_default_fini after grub_main.
19060
19061 * util/console.c (grub_ncurses_checkkey): Return the read
19062 character or -1.
19063
19064 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
19065 timeouts.
19066
19067 * normal/main.c (read_config_file): Push MENU. If this fails,
19068 print an error and wait for a user input.
19069 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
19070 If a menu is empty or an error occurs, pop MENU.
19071 (grub_normal_execute): Pop and free MENU after grub_menu_run
19072 returns.
19073
19074 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
19075
19076 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
19077 include time.h.
19078 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19079 without GRUB_UTIL.
19080 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
19081 time.h.
19082 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19083 without GRUB_UTIL.
19084
19085 * include/grub/normal.h (struct grub_menu_list): New struct.
19086 (grub_menu_list_t): New type.
19087 (struct grub_context): New struct.
19088 (grub_context_t): New type.
19089 (grub_register_command): Got rid of EXPORT_FUNC.
19090 (grub_unregister_command): Likewise.
19091 (grub_context_get): New prototype.
19092 (grub_context_get_current_menu): Likewise.
19093 (grub_context_push_menu): Likewise.
19094 (grub_context_pop_menu): Likewise.
19095 [GRUB_UTIL] (grub_default_init): Likewise.
19096 [GRUB_UTIL] (grub_default_fini): Likewise.
19097 [GRUB_UTIL] (grub_timeout_init): Likewise.
19098 [GRUB_UTIL] (grub_timeout_fini): Likewise.
19099
19100 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
19101 commands/timeout.c and normal/context.c.
19102 (pkgdata_MODULES): Added default.mod and timeout.mod.
19103 (normal_mod_SOURCES): Added normal/context.c.
19104 (default_mod_SOURCES): New variable.
19105 (default_mod_CFLAGS): Likewise.
19106 (timeout_mod_SOURCES): Likewise.
19107 (timeout_mod_CFLAGS): Likewise.
19108 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
19109 conf/i386-pc.rmk.
19110 (pkgdata_MODULES): Added default.mod and timeout.mod.
19111 (normal_mod_SOURCES): Added normal/context.c.
19112 (default_mod_SOURCES): New variable.
19113 (default_mod_CFLAGS): Likewise.
19114 (timeout_mod_SOURCES): Likewise.
19115 (timeout_mod_CFLAGS): Likewise.
19116
19117 * Makefile.in (all-local): Added $(MKFILES).
19118
4ed2e1dd 191192005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
19120
19121 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
19122 (grub_emu_SOURCES): Likewise.
19123 (pkgdata_MODULES): Add `sun.mod'.
19124 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19125 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19126 `partmap/sun.c'.
19127 (pkgdata_MODULES): Add `sun.mod'.
19128 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19129 * include/grub/partition.h (grub_sun_partition_map_init): New
19130 prototype.
19131 (grub_sun_partition_map_fini): Likewise.
19132 * partmap/sun.c: New file.
19133 * util/grub-emu.c (main): Initialize and de-initialize the sun
19134 partitionmap support.
19135
4d4e372e 191362005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
19137
19138 This implements an Emacs-like menu entry editor.
f19dbdb7 19139
4d4e372e 19140 * normal/menu_entry.c: New file.
f19dbdb7 19141
4d4e372e 19142 * util/console.c (grub_ncurses_putchar): Translate some Unicode
19143 characters to ASCII.
19144 (saved_char): New variable.
19145 (grub_ncurses_checkkey): Rewritten completely.
19146 (grub_ncurses_getkey): Likewise.
19147 (grub_ncurses_init): Call raw instead of cbreak.
19148
19149 * normal/menu.c (print_entry): Do not put a space.
19150 (init_page): Renamed to ...
19151 (grub_menu_init_page): ... this. All callers changed.
19152 (edit_menu_entry): Removed.
19153 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
19154
19155 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
19156
19157 * kern/misc.c (grub_vprintf): Call grub_refresh.
19158
19159 * normal/menu.c (DISP_LEFT): Renamed to ...
19160 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
19161 * normal/menu.c (DISP_UP): Renamed to ...
19162 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
19163 * normal/menu.c (DISP_RIGHT): Renamed to ...
19164 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
19165 * normal/menu.c (DISP_DOWN): Renamed to ...
19166 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
19167 * normal/menu.c (DISP_HLINE): Renamed to ...
19168 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
19169 * normal/menu.c (DISP_VLINE): Renamed to ...
19170 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
19171 * normal/menu.c (DISP_UL): Renamed to ...
19172 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
19173 * normal/menu.c (DISP_UR): Renamed to ...
19174 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
19175 * normal/menu.c (DISP_LL): Renamed to ...
19176 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
19177 * normal/menu.c (DISP_LR): Renamed to ...
19178 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
19179 * normal/menu.c (TERM_WIDTH): Renamed to ...
19180 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
19181 * normal/menu.c (TERM_HEIGHT): Renamed to ...
19182 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
19183 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
19184 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
19185 * normal/menu.c (TERM_MARGIN): Renamed to ...
19186 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
19187 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
19188 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
19189 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
19190 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
19191 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
19192 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
19193 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
19194 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
19195 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
19196 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
19197 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
19198 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
19199 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
19200 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
19201 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
19202 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
19203 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
19204 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
19205 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
19206 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
19207 All callers changed.
19208
19209 * include/grub/normal.h: New prototype.
19210
19211 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19212 normal/menu_entry.c.
19213 (normal_mod_SOURCES): Likewise.
19214 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
19215 (normal_mod_SOURCES): Likewise.
19216
e6b92c8a 192172005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
19218
19219 * include/grub/normal.h (grub_halt_init): New prototype.
19220 (grub_halt_fini): Likewise.
19221 (grub_reboot_init): Likewise.
19222 (grub_reboot_fini): Likewise.
19223
19224 * util/grub-emu.c: Include signal.h.
19225 (main_env): New global variable.
19226 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
19227 catch C-c.
19228 (grub_machine_fini): New function.
19229 (main): Call grub_halt_init and grub_reboot_init before
19230 grub_main, and grub_reboot_fini and grub_halt_fini after it.
19231 Call setjmp with MAIN_ENV to go back afterwards.
19232 Call grub_machine_fini right before return.
19233
19234 * include/grub/util/misc.h: Include setjmp.h.
19235 (main_env): New prototype.
19236
19237 * include/grub/kernel.h (grub_machine_fini): New prototype.
19238 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
19239 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
19240
19241 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
19242 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
19243 * term/i386/pc/console.c (grub_console_fini): Likewise.
f19dbdb7 19244
e6b92c8a 19245 * util/i386/pc/misc.c: New file.
f19dbdb7 19246
e6b92c8a 19247 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19248 util/i386/pc/misc.c, commands/i386/pc/halt.c and
19249 commands/i386/pc/reboot.c.
19250
c642636f 192512005-02-14 Guillem Jover <guillem@hadrons.org>
19252
19253 * include/grub/dl.h (grub_dl_check_header): New prototype.
19254 (grub_arch_dl_check_header): Change return type to grub_err_t,
19255 remove size parameter and export function. Update all callers.
19256 * kern/dl.c (grub_dl_check_header): New function.
19257 (grub_dl_load_core): Use `grub_dl_check_header' instead of
19258 `grub_arch_dl_check_header'. Check ELF type. Check if sections
19259 are inside the core.
19260 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
19261 independent ELF header checks.
19262 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19263 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
19264 `grub_dl_check_header' instead of explicit checks. Check for the
19265 ELF type.
19266 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
19267 `grub_dl_check_header' instead of explicit checks. Remove arch
19268 specific ELF header checks.
19269
e6b92c8a 19270 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
19271 argument SIZE.
19272
5eabe94b 192732005-02-13 Hollis Blanchard <hollis@penguinppc.org>
19274
19275 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
19276 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
19277
1b14a681 192782005-02-12 Hollis Blanchard <hollis@penguinppc.org>
19279
19280 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
f19dbdb7 19281 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
1b14a681 19282 (part_map_iterate): Clear `grub_errno' and return 0 if
f19dbdb7 19283 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
1b14a681 19284 * partmap/amiga.c (amiga_partition_map_iterate): Return
19285 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
19286 * partmap/apple.c (apple_partition_map_iterate): Likewise.
19287
aca108aa 192882005-02-01 Guillem Jover <guillem@hadrons.org>
19289
19290 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
19291 help info.
19292
c9f9c556 192932005-01-31 Marco Gerards <metgerards@student.han.nl>
19294
19295 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
19296 Removed prototype.
19297 (grub_rescue_cmd_linux): New prototype.
19298 (grub_rescue_cmd_initrd): Likewise.
19299 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
19300 `bi_rec'.
19301 (grub_linux_release_mem): Release the memory for the initrd.
19302 (grub_load_linux): Renamed from this...
19303 (grub_rescue_cmd_linux): ...To this. Changed all callers.
19304 Changed `entry' not to be static. Loop over memory regions to
19305 find another one when the default fails.
19306 (grub_rescue_cmd_initrd): New function.
19307 (grub_linux_init): Remove function.
19308 (grub_linux_fini): Likewise.
19309 (GRUB_MOD_INIT): Register `initrd'.
19310 (GRUB_MOD_FINI): Unregister `initrd'.
19311 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
19312 Function removed.
19313 (grub_linux_normal_fini): Likewise.
19314 (GRUB_MOD_INIT): Register `initrd'.
19315 (GRUB_MOD_FINI): Unregister `initrd'.
19316
990cf3aa 193172005-01-31 Marco Gerards <metgerards@student.han.nl>
19318
19319 * commands/help.c: New file.
19320 * normal/arg.c (show_help): Renamed to...
19321 (grub_arg_show_help): ... this.
19322 * commands/i386/pc/halt.c: New file.
19323 * commands/i386/pc/reboot.c: Likewise.
19324 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
19325 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
19326 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
19327 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
19328 variables.
19329 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19330 `commands/help.c'.
19331 (pkgdata_MODULES): Add `help.mod'.
19332 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
19333 * grub/i386/pc/init.h (grub_reboot): New prototype.
19334 (grub_halt): Likewise.
19335 * include/grub/normal.h (grub_arg_show_help): New prototype.
19336 (grub_help_init): Likewise.
19337 (grub_help_fini): Likewise.
19338 * util/grub-emu.c (main): Initialize and deinitialize the help
19339 command.
19340
19341 * normal/cmdline.c (grub_cmdline_get): Doc fix.
19342
19343 * normal/command.c (grub_command_init): Fixed the description of
19344 the `set' and `unset' commands.
19345
193462005-01-31 Marco Gerards <metgerards@student.han.nl>
0f79cdc1 19347
19348 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
19349 function.
19350 * commands/ieee1275/halt.c: New file.
19351 * commands/ieee1275/reboot.c: Likewise.
19352 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
19353 `__attribute__ ((unused))'. Some GCS related fixed.
19354 (grub_suspend_init) [GRUB_UTIL]: Function removed.
19355 (grub_suspend_fini): Likewise.
19356 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
19357 and `halt.mod'.
19358 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
19359 (halt_mod_CFLAGS): New variables.
19360 * include/grub/powerpc/ieee1275/ieee1275.h
19361 (grub_ieee1275_interpret): New prototype.
19362
1ab09cc7 193632005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
19364
19365 * include/grub/misc.h (memmove): New prototype.
19366 (memcpy): Likewise.
19367
8b8cbdb2 193682005-01-22 Hollis Blanchard <hollis@penguinppc.org>
19369
19370 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
19371 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
19372
e3741a27 193732005-01-22 Marco Gerards <metgerards@student.han.nl>
19374
19375 * kern/misc.c (grub_strndup): Function rewritten.
19376
776bd780 193772005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
19378
19379 * normal/menu.c (TERM_WIDTH): Macro redefined.
19380 (TERM_TOP_BORDER_Y): Likewise.
19381 (draw_border): Replaced while-loop by a for-loop. Make the number
19382 of lines consistent with the number of lines displayed in
19383 print_entries. Added a margin below the rectangle.
19384 (print_entry): Make the entry fit in the rectangle.
19385 (print_entries): Display the scroll arrows next to the right
19386 border.
19387
78026bce 193882005-01-21 Marco Gerards <metgerards@student.han.nl>
19389
19390 * fs/minix.c (grub_minix_find_file): Reserve more space for
19391 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
19392 `grub_strncpy' to copy `path' into it.
19393
67bbaf0f 193942005-01-21 Marco Gerards <metgerards@student.han.nl>
19395
19396 Add the loopback device, a device via which files can be accessed
19397 as devices.
f19dbdb7 19398
67bbaf0f 19399 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
19400 (pkgdata_MODULES): Add loopback.mod.
19401 (loopback_mod_SOURCES): New variable.
19402 (loopback_mod_CFLAGS): Likewise.
19403 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19404 `disk/loopback.c'.
19405 (pkgdata_MODULES): Add loopback.mod.
19406 (loopback_mod_SOURCES): New variable.
19407 (loopback_mod_CFLAGS): Likewise.
19408 * disk/loopback.c: new file.
19409 * include/grub/normal.h (grub_loop_init): New prototype.
19410 (grub_loop_fini): New prototype.
19411 * util/grub-emu.c (main): Initialize and de-initialize loopback
19412 support.
19413 * include/grub/disk.h (grub_disk_dev_id): Add
19414 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
19415
6f1c18bd 194162005-01-20 Hollis Blanchard <hollis@penguinppc.org>
19417
19418 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
19419 function.
19420 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
19421 (suspend_mod_SOURCES): New variable.
19422 (suspend_mod_CFLAGS): Likewise.
19423 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
19424 New prototype.
19425 * commands/ieee1275/suspend.c: New file.
19426
b38551da 194272005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
19428
19429 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
f19dbdb7 19430 ((unused))' to `__attribute__ ((used))'.
b38551da 19431 (GRUB_MOD_FINI): Likewise.
19432 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
19433 * genmk.rb (PModule): Assign space to common symbols when linking
19434 modules.
19435
777aff39 194362005-01-20 Marco Gerards <metgerards@student.han.nl>
19437
19438 * include/grub/mm.h (grub_mm_init_region): Change the type of the
19439 `unsigned' arguments to `grub_size_t'.
19440 (grub_malloc): Likewise.
19441 (grub_realloc): Likewise.
19442 (grub_memalign): Likewise.
19443 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
19444 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19445 * util/misc.c (grub_malloc): Likewise.
19446 (grub_realloc): Likewise.
19447 * kern/mm.c (get_header_from_pointer): Change the casts to
19448 `unsigned' into a cast to `grub_size_t'.
19449
19450 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
19451 point to `currnode' when `currnode' is changed.
19452
19453 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
19454 Schottelius <nico-linux@schottelius.org>.
19455
d0ff18e1 194562005-01-09 Hollis Blanchard <hollis@penguinppc.org>
19457
19458 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
19459 (note_path): Remove variable.
19460 (GRUB_IEEE1275_NOTE_NAME): New macro.
19461 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
19462 (grub_ieee1275_note_hdr): New structure.
19463 (grub_ieee1275_note_desc): Likewise.
19464 (grub_ieee1275_note): Likewise.
19465 (load_note): Remove `dir' argument. All callers updated. Remove
19466 `note_img' and `path'. Do not load a file from `note_path'.
19467 Initialize a struct grub_ieee1275_note and write that to `out'.
19468 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
19469
4ca7004c 194702005-01-05 Marco Gerards <metgerards@student.han.nl>
19471
19472 * util/misc.c (grub_util_read_image): Revert last change. It
19473 called `grub_util_read_at', which seeks from the beginning of the
19474 file.
19475
0b412211 194762005-01-04 Hollis Blanchard <hollis@penguinppc.org>
19477
19478 * TODO: Add note about endianness in grub-mkimage.
19479 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
19480 section.
19481 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
19482 (grub_mkimage_SOURCES): New target.
19483 * include/grub/kernel.h (grub_start_addr): Remove variable.
19484 (grub_end_addr): Likewise.
19485 (grub_total_module_size): Likewise.
19486 (grub_kernel_image_size): Likewise.
19487 (GRUB_MODULE_MAGIC): New constant.
19488 (grub_module_info): New structure.
19489 (grub_arch_modules_addr): New prototype.
19490 (grub_get_end_addr): Remove prototype.
19491 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
19492 * include/grub/powerpc/ieee1275/kernel.h: New file.
19493 * include/grub/util/misc.h (grub_util_get_fp_size): New
19494 prototype.
19495 (grub_util_read_at): Likewise.
19496 (grub_util_write_image_at): Likewise.
19497 * kern/main.c (grub_get_end_addr): Remove function.
19498 (grub_load_modules): Call grub_arch_modules_addr instead of using
19499 grub_end_addr. Look for a grub_module_info struct in memory. Use
19500 the grub_module_info fields instead of calling grub_get_end_addr
19501 as loop conditions. Move grub_add_unused_region code here.
19502 (grub_add_unused_region): Remove function.
19503 * kern/i386/pc/init.c: Include grub/cache.h.
19504 (grub_machine_init): Remove call to grub_get_end_addr. Remove
19505 one call to add_mem_region.
19506 (grub_arch_modules_addr): New function.
19507 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
19508 (grub_total_module_size): Likewise.
19509 Include grub/machine/kernel.h.
19510 (grub_arch_modules_addr): New function.
19511 * util/grub-emu.c (grub_end_addr): Remove variable.
19512 (grub_total_module_size): Likewise.
19513 (grub_arch_modules_addr): New function.
19514 * util/misc.c: Include unistd.h.
19515 (grub_util_get_fp_size): New function.
19516 (grub_util_read_at): Likewise.
19517 (grub_util_write_image_at): Likewise.
19518 (grub_util_read_image): Call grub_util_read_at.
19519 (grub_util_write_image): Call grub_util_write_image_at.
19520 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
19521 additional memory in kernel_img for a struct grub_module_info.
19522 Fill in that grub_module_info.
19523 * util/powerpc/ieee1275/grub-mkimage.c: New file.
19524
458786f8 195252005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19526
19527 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
19528 New function.
19529 * include/grub/powerpc/ieee1275/ieee1275.h
19530 (grub_ieee1275_milliseconds): New prototype.
19531 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
19532 Change to 1000.
19533 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
19534 grub_ieee1275_milliseconds.
19535
ac507d1b 195362005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19537
19538 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
19539 variable.
19540 (find_options): New function.
19541 (cmain): Call find_options.
19542 * include/grub/powerpc/ieee1275/ieee1275.h
19543 (grub_ieee1275_realmode): New extern variable.
19544 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
19545 grub_map if grub_ieee1275_realmode is false.
19546
6b8fd1c4 195472004-12-29 Marco Gerards <metgerards@student.han.nl>
19548
19549 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
19550 lines are inserted and make it work like readline. Reported by
19551 Vincent Pelletier <subdino2004@yahoo.fr>.
19552
8514a1e0 195532004-12-28 Marco Gerards <metgerards@student.han.nl>
19554
19555 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
19556
19557 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
19558 `kern/powerpc/cache.S'.
19559
924b6140 195602004-12-27 Marco Gerards <metgerards@student.han.nl>
19561
19562 * genmk.rb: Handle the `Program' class in the main loop. Written
19563 by Johan Rydberg <jrydberg@gnu.org>.
19564 (Program): New class.
19565 (programs): New variable.
19566 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
19567 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
19568 instead of "grub/kernel.h". Include <grub/machine/init.h>.
19569 (help_arch): Function removed.
19570 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
19571 `powerpc/libgcc.h' and `loader.h'.
19572 (pkgdata_PROGRAMS): New variable.
19573 (sbin_UTILITIES): Variable removed.
19574 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
19575 (grubof_SOURCES): Variable re-defined so it only includes the
19576 core functionality.
19577 (grubof_CFLAGS): Remove `-DGRUBOF'.
19578 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
19579 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
19580 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
19581 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
19582 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
19583 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
19584 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
19585 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
19586 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
19587 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
19588 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
19589 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
19590 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
19591 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
19592 (pc_mod_CFLAGS): New variables.
19593 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
19594 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
19595 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
19596 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
19597 Moved from here...
19598 * include/grub/i386/pc/init.h (grub_os_area_addr)
19599 (rub_os_area_size): ... to here.
19600 * include/grub/powerpc/ieee1275/ieee1275.h
19601 (grub_ieee1275_entry_fn): Export symbol.
19602 * include/grub/powerpc/ieee1275/init.h: New file.
19603 * include/grub/powerpc/libgcc.h: Likewise.
19604 * include/grub/cache.h: Likewise.
19605 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
19606 <hollis@penguinppc.org>.
19607 * kern/dl.c: Include <grub/cache.h>.
19608 (grub_dl_flush_cache): New function.
19609 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
19610 for this module.
19611 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
19612 (grub_console_init): Removed prototypes.
19613 (grub_machine_init): Don't initialize the modules anymore.
19614 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
19615 static.
19616 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
19617 Macro undef removed.
19618 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
19619 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
19620 relocation `R_PPC_REL32'. Return an error when the relocation is
19621 unknown.
19622 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
19623 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
19624 * util/misc.c (grub_arch_sync_caches): Likewise.
19625
e4b47e0c 196262004-12-19 Marco Gerards <metgerards@student.han.nl>
19627
19628 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
19629 `symlist.c', add `grubof_symlist.c'.
19630 (symlist.c): Variable removed.
19631 (grubof_HEADERS): Variable added.
19632 (grubof_symlist.c): New target.
19633 (kernel_syms.lst): Use `grubof_HEADERS' instead of
19634 `kernel_img_HEADERS'.
19635 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
19636 * kern/powerpc/dl.c: New file.
19637 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
19638 Function removed.
19639 (grub_arch_dl_relocate_symbols): Likewise.
19640 (grub_register_exported_symbols): Likewise.
19641
4ceb3636 196422004-12-13 Marco Gerards <metgerards@student.han.nl>
19643
19644 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
19645 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
19646 to fail instead. Reported by Vincent Pelletier
19647 <subdino2004@yahoo.fr>.
19648
19649 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
19650 it is not allocated. Reported by Vincent Pelletier
19651 <subdino2004@yahoo.fr>.
19652
19653 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
19654 output so the output looks better.
f19dbdb7 19655
3f1578fe 196562004-12-04 Marco Gerards <metgerards@student.han.nl>
19657
19658 Modulize the partition map support and add support for the amiga
19659 partition map.
f19dbdb7 19660
3f1578fe 19661 * commands/ls.c: Include <grub/partition.h> instead of
19662 <grub/machine/partition.h>.
19663 * kern/disk.c: Likewise.
19664 * kern/rescue.c: Likewise.
19665 * loader/i386/pc/chainloader.c: Likewise.
19666 * normal/cmdline.c: Likewise.
19667 * kern/powerpc/ieee1275/init.c: Likewise.
19668 (grub_machine_init): Call `grub_pc_partition_map_init',
19669 `grub_amiga_partition_map_init' and
19670 `grub_apple_partition_map_init'.
19671 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
19672 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
19673 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
19674 `partition.h' and `pc_partition.h'.
19675 (grub_setup_SOURCES): Remove
19676 `disk/i386/pc/partition.c'. Add `kern/partition.c',
19677 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19678 (grub_emu_SOURCES): Likewise.
19679 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
19680 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
19681 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
19682 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19683 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
19684 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19685 (grubof_SOURCES): Likewise.
19686 * disk/i386/pc/partition.c: File removed.
19687 * disk/powerpc/ieee1275/partition.c: Likewise.
19688 * include/grub/powerpc/ieee1275/partition.h: Likewise.
19689 * include/grub/i386/pc/partition.h: Likewise.
19690 * kern/partition.c: New file.
19691 * partmap/amiga.c: Likewise.
19692 * partmap/apple.c: Likewise.
19693 * partmap/pc.c: Likewise.
19694 * include/grub/partition.h: Likewise..
19695 * include/grub/pc_partition.h: Likewise.
19696 * util/grub-emu.c: Include <grub/partition.h> instead of
19697 <grub/machine/partition.h>.
19698 (main): Call `grub_pc_partition_map_init',
19699 `grub_amiga_partition_map_init' and
19700 `grub_apple_partition_map_init' and deinitialize afterwards.
19701 * util/i386/pc/biosdisk.c: Include `#include
19702 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19703 `<grub/machine/partition.h>'.
19704 * util/i386/pc/grub-setup.c: Likewise.
19705 * util/i386/pc/biosdisk.c: Likewise.
19706 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
19707 partition information in case of a PC partition.
19708 * util/i386/pc/grub-setup.c: Include `#include
19709 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19710 `<grub/machine/partition.h>'.
19711 (setup): Only access the PC specific partition information in case
19712 of a PC partition.
19713
0ef4ced9 197142004-11-17 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 19715
0ef4ced9 19716 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
19717 (grub_longjmp): Likewise.
19718 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
19719 20.
19720 * normal/powerpc/setjmp.S: New file.
19721 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
19722 `normal/powerpc/setjmp.S'.
19723 (grubof_CFLAGS): Add `-DGRUBOF'.
19724 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
19725 [GRUB_UTIL && !GRUBOF].
f19dbdb7 19726
19950e29 197272004-11-16 Marco Gerards <metgerards@student.han.nl>
19728
19729 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
19730 property named `name'. Correctly handle the error returned by
19731 `grub_ieee1275_finddevice' if a device can not be opened.
19732
a2fea427 197332004-11-02 Hollis Blanchard <hollis@penguinppc.org>
19734
19735 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
19736 `actual' for negativity.
19737 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19738 kern/fshelp.c.
19739
41ea0ea3 197402004-11-01 Marco Gerards <metgerards@student.han.nl>
19741
19742 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
19743 (PAGE_OFFSET): New macro.
19744 (CRTC_ADDR_PORT): Likewise.
19745 (CRTC_DATA_PORT): Likewise.
19746 (START_ADDR_HIGH_REGISTER): Likewise.
19747 (START_ADDR_LOW_REGISTER): Likewise.
19748 (GRAPHICS_ADDR_PORT): Likewise.
19749 (GRAPHICS_DATA_PORT): Likewise.
19750 (READ_MAP_REGISTER): Likewise.
19751 (INPUT_STATUS1_REGISTER): Likewise.
19752 (INPUT_STATUS1_VERTR_BIT): Likewise.
19753 (page): New variable.
19754 (wait_vretrace): New function.
19755 (set_read_map): Likewise.
19756 (set_start_address): Likewise.
19757 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
19758 the right page.
19759 (check_vga_mem): Take the page into account.
19760 (write_char): Likewise.
19761 (write_cursor): Likewise.
19762 (scroll_up): Likewise. Copy the page to the page that is not
19763 shown and switch between both pages.
19764 (grub_vga_putchar): Fix off by one error.
19765 (grub_vga_cls): Wait for the vertical retrace. Take the page into
19766 account.
19767
ad0bd20b 197682004-11-01 Marco Gerards <metgerards@student.han.nl>
19769
19770 Add support for iso9660 (including rockridge).
f19dbdb7 19771
ad0bd20b 19772 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19773 (iso9660_mod_SOURCES): New variable.
19774 (iso9660_mod_CFLAGS): Likewise.
19775 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19776 * include/grub/fs.h (grub_iso9660_init): New prototype.
19777 * util/grub-emu.c (main): Call `grub_iso9660_init'.
19778 * fs/iso9660.c: New file.
19779
19780 * include/grub/misc.h (grub_strncat): New prototype.
19781 * kern/misc.c (grub_strncat): New function.
f19dbdb7 19782
ad0bd20b 19783 * fs/hfs.c (grub_hfs_mount): Translate the error
19784 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
19785 * fs/jfs.c (grub_jfs_mount): Likewise.
19786 * fs/ufs.c (grub_ufs_mount): Likewise.
19787
a5477a59 197882004-10-28 Hollis Blanchard <hollis@penguinppc.org>
19789
19790 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
19791 which initialized BAT registers.
19792 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
19793 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19794 Move from here...
19795 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
19796 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19797 ... to here.
19798 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
19799 (grub_mapclaim): Likewise.
19800 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
19801 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
19802 hand.
19803
9304c1f8 198042004-10-19 Hollis Blanchard <hollis@penguinppc.org>
19805
19806 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
19807 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
19808 -ffreestanding and -msoft-float.
19809
86f4ae25 198102004-10-15 Hollis Blanchard <hollis@penguinppc.org>
19811
19812 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
19813 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
19814 set in grub_ieee1275_flags.
19815
38912228 198162004-10-14 Hollis Blanchard <hollis@penguinppc.org>
19817
19818 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
19819 prototype.
19820 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
19821 grub_console_init first.
19822 Change the memory range used for grub_ieee1275_claim and
19823 grub_mm_init_region.
19824 Print an error message if the claim fails.
19825 Include <grub/misc.h>.
19826
d1923dc8 198272004-10-13 Hollis Blanchard <hollis@penguinppc.org>
19828
19829 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
19830 Call grub_children_iterate for device nodes of type `scsi',
19831 `ide', or `ata'.
19832 (grub_ofdisk_open): Remove manual device alias resolution.
19833 Fix memory leak when device cannot be opened.
f19dbdb7 19834 * include/grub/powerpc/ieee1275/ieee1275.h
d1923dc8 19835 (grub_children_iterate): New prototype.
19836 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
19837 New function.
19838 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
19839 Return -1 if args.size was -1.
19840
4512e4f3 198412004-10-11 Hollis Blanchard <hollis@penguinppc.org>
19842
19843 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
19844 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
19845 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
19846 Open Firmware's memory for it; claim memory from _start to _end.
19847 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
19848 (_end): New extern.
19849 (_start): Zero BSS from __bss_start to _end.
19850 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
19851 New extern.
19852 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
19853
4d61feb0 198542004-10-11 Hollis Blanchard <hollis@penguinppc.org>
19855
ad0bd20b 19856 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
19857 -1 if args.base was -1.
4d61feb0 19858
026fa2f9 198592004-10-08 Hollis Blanchard <hollis@penguinppc.org>
19860
19861 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
19862 escape sequence instead of a literal ^L. Also call
19863 grub_ofconsole_gotoxy.
19864
9f2220ef 198652004-10-03 Hollis Blanchard <hollis@penguinppc.org>
19866
19867 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
19868 void * arguments to grub_addr_t. All callers updated. Also make
19869 the `result' argument optional.
19870 (grub_ieee1275_release): change void * arguments to grub_addr_t.
19871 All callers updated.
19872
8a572cd7 198732004-09-22 Hollis Blanchard <hollis@penguinppc.org>
19874
19875 * commands/ls.c (grub_ls_list_files): Use the string following the
19876 initial ')', if present, as the filesystem path.
19877 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
19878
19879 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
19880
18aa81f2 198812004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
19882
19883 Make the source code of the menu interface more readable.
f19dbdb7 19884
18aa81f2 19885 * normal/menu.c: Include grub/mm.h.
19886 (TERM_WIDTH): New macro.
19887 (TERM_HEIGHT): Likewise.
19888 (TERM_INFO_HEIGHT): Likewise.
19889 (TERM_MARGIN): Likewise.
19890 (TERM_SCROLL_WIDTH): Likewise.
19891 (TERM_TOP_BORDER_Y): Likewise.
19892 (TERM_LEFT_BORDER_X): Likewise.
19893 (TERM_BORDER_WIDTH): Likewise.
19894 (TERM_MESSAGE_HEIGHT): Likewise.
19895 (TERM_BORDER_HEIGHT): Likewise.
19896 (TERM_NUM_ENTRIES): Likewise.
19897 (TERM_FIRST_ENTRY_Y): Likewise.
19898 (TERM_ENTRY_WIDTH): Likewise.
19899 (TERM_CURSOR_X): Likewise.
19900 (draw_border): Use macros instead of magic numbers.
19901 (print_entry): Likewise.
19902 (print_entries): Likewise.
19903 (run_menu): Likewise. Also, handle the key 'e'.
19904 (run_menu_entry): Ignore empty command lines.
19905 (print_message): Added a new argument EDIT. If EDIT is true,
19906 print a different message.
19907 (init_page): Likewise.
19908 (edit_menu_entry): New function. Not implemented yet.
19909
b47efe30 199102004-09-17 Marco Gerards <metgerards@student.han.nl>
19911
19912 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
19913 can be loaded from normal mode.
f19dbdb7 19914
b47efe30 19915 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
19916 `multiboot.mod'.
19917 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
19918 (multiboot_mod_CFLAGS): New variables.
19919 * loader/i386/pc/linux_normal.c: New file.
f19dbdb7 19920 * loader/i386/pc/multiboot_normal.c: Likewise.
19921
b47efe30 19922 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
19923 attribute `unused'.
f19dbdb7 19924
b47efe30 19925 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
19926 `fdiro' to read the mode information from instead of `diro'.
19927
19928 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
19929 looking up a symlink.
19930
19931 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
19932 macro.
19933 * normal/command.c (grub_command_execute): Don't parse the
19934 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
19935 flags of the command.
19936
19937 * normal/menu.c (grub_menu_run): Fix typo.
19938
da75ac71 199392004-09-14 Hollis Blanchard <hollis@penguinppc.org>
19940
19941 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
19942
19943 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
19944 `y + 1' instead of `y - 1'.
19945
19946 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
f19dbdb7 19947
062b24c2 199482004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
19949
19950 From Hollis Blanchard <hollis@penguinppc.org>:
19951 * kern/misc.c (memmove): New alias for grub_memmove.
19952 (memcmp): New alias for grub_memcmp.
19953 (memset): New alias for grub_memset.
f19dbdb7 19954 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
062b24c2 19955 Change "int handle" to "grub_ieee1275_phandle_t handle".
f19dbdb7 19956 * include/grub/powerpc/ieee1275/ieee1275.h
062b24c2 19957 (grub_ieee1275_get_property): Likewise.
f19dbdb7 19958
8ddad845 199592004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
19960
19961 Added normal mode command `chainloader' as module chain.mod, which
19962 depends on normal.mod and _chain.mod.
f19dbdb7 19963
8ddad845 19964 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
19965 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
19966 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
19967 Deleted prototype.
19968 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
19969 but arguments parsing moved to ...
19970 (grub_chainloader_cmd): ... here. New function.
19971 * include/grub/i386/pc/chainloader.h: New file.
19972 * loader/i386/pc/chainloader_normal.c: Likewise.
19973
2c1f4ce3 199742004-09-11 Marco Gerards <metgerards@student.han.nl>
19975
19976 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
19977 (grub_mkimage_LDFLAGS): Likewise.
19978 (grub_emu_SOURCES): Likewise.
19979 (kernel_img_HEADERS): Added fshelp.h.
19980 * fs/ext2.c: Include <grub/fshelp.h>.
19981 (FILETYPE_REG): New macro.
19982 (FILETYPE_INO_REG): Likewise.
19983 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
19984 Changed all users.
19985 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
19986 all users.
19987 (grub_fshelp_node): New struct.
19988 (grub_ext2_data): Added member `diropen'. Changed member `inode'
19989 to a pointer.
19990 (grub_ext2_get_file_block): Removed function.
19991 (grub_ext2_read_block): New function.
19992 (grub_ext2_read_file): Replaced parameter `data' by `node'.
19993 This function was written.
19994 (grub_ext2_mount): Read the root inode. Create a diropen struct.
19995 (grub_ext2_find_file): Removed function.
19996 (grub_ext2_read_symlink): New function.
19997 (grub_ext2_iterate_dir): Likewise.
19998 (grub_ext2_open): Rewritten.
19999 (grub_ext2_dir): Rewritten.
20000 * include/grub/fshelp.h: New file.
20001 * fs/fshelp.c: Likewise.
20002
3c52136a 200032004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
20004
20005 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
20006 (print_message): Add a missing newline.
20007 (run_menu): Added timeout support.
20008 (run_menu_entry): New local function.
20009 (grub_menu_run): Added support for booting.
20010
20011 * kern/loader.c (grub_loader_is_loaded): New function.
20012
20013 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
20014 (grub_get_rtc): Exported.
20015
20016 * include/grub/i386/pc/time.h: Include grub/symbol.h.
20017 (grub_get_rtc): Exported.
20018
20019 * include/grub/normal.h (struct grub_command_list): Remove
20020 constant from the member `command'.
20021
20022 * include/grub/loader.h (grub_loader_is_loaded): Declared.
20023
20024 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
20025
20026 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
20027
aa033560 200282004-08-28 Marco Gerards <metgerards@student.han.nl>
20029
20030 Add support for the JFS filesystem.
20031
20032 * fs/jfs.c: New file.
20033 * include/grub/fs.h (grub_jfs_init): New prototype.
20034 (grub_jfs_fini): New prototype.
20035 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
20036 (grub_emu_SOURCES): Likewise.
20037 (pkgdata_MODULES): Add jfs.mod.
20038 (jfs_mod_SOURCES): New variable.
20039 (jfs_mod_CFLAGS): Likewise.
20040 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
20041 (grubof_SOURCES): Likewise.
20042 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
20043
20044 * fs/fat.c (grub_fat_find_dir): Convert the filename little
20045 endian to the host endian.
20046 (grub_fat_utf16_to_utf8): Move function from there...
20047 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
fe987087 20048 the endianness of the source string anymore.
aa033560 20049 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
20050
94bc45af 200512004-08-24 Marco Gerards <metgerards@student.han.nl>
20052
20053 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
20054 (grub_boot_fini) [GRUB_UTIL]: Likewise.
20055 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
20056 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
f19dbdb7 20057
94bc45af 20058 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
20059 (grub_hfs_iterate_dir): Make the function static. Add prototypes
20060 for `node_found' and `it_dir'.
20061 (grub_hfs_dir): Add prototype for `dir_hook'.
20062
20063 * fs/minix.c (grub_minix_get_file_block): Add prototype for
20064 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
20065 and `indir32' to silence a gcc warning.
20066
20067 * include/grub/fs.h (grub_hfs_init): New prototype.
20068 (grub_hfs_fini): Likewise.
f19dbdb7 20069
20070
97543f08 200712004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
20072
20073 Each disk device has its own id now. This is useful to make use
20074 of multiple disk devices.
f19dbdb7 20075
97543f08 20076 * include/grub/disk.h (grub_disk_dev_id): New enum.
20077 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
20078 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
20079
20080 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
20081 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20082
20083 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
20084 GRUB_DISK_DEVICE_OFDISK_ID as an id.
20085
20086 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
20087 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20088
20089 * include/grub/disk.h (struct grub_disk_dev): Added a new member
20090 "id" which is used by the cache manager.
20091
20092 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
20093 of just "GRUB".
20094
64372eb4 200952004-08-18 Marco Gerards <metgerards@student.han.nl>
20096
20097 * fs/hfs.c: New file.
20098 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
20099 (grub_emu_SOURCES): Likewise.
20100 (pkgdata_MODULES): Add hfs.mod.
20101 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
20102 (grubof_SOURCES): Likewise.
20103 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
20104
20105 * include/grub/misc.h (grub_strncasecmp): Add prototype.
20106 * kern/misc.c (grub_strncasecmp): Add function.
20107
cc61b58f 201082004-08-14 Marco Gerards <metgerards@student.han.nl>
20109
20110 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
20111 with parentheses.
20112
20113 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
20114 (grub_ext2_dir): In case the directory entry type is unknown, read
20115 it from the inode.
20116
0ef123f6 201172004-08-02 Peter Bruin <pjbruin@dds.nl>
20118
20119 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
20120 grub_load_linux instead of grub_rescue_cmd_linux as second
20121 argument of grub_rescue_register_command.
20122
20123 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
20124
a447c5df 201252004-07-27 Marco Gerards <metgerards@student.han.nl>
20126
20127 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
20128 function.
20129 * commands/boot.c: Remove the check for `GRUB_UTIL'.
20130 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
20131 `loader/powerpc/ieee1275/linux.c',
20132 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
20133 * include/grub/powerpc/ieee1275/ieee1275.h
20134 (grub_ieee1275_release): New prototype.
20135 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
20136 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
20137 normal, boot, linux and linux_normal.
20138 * loader/powerpc/ieee1275/linux.c: New file.
20139 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
20140
5a9e3546 201412004-07-12 Marco Gerards <metgerards@student.han.nl>
20142
20143 * normal/arg.c (grub_arg_parse): Correct error handling after
20144 reallocating the argumentlist (check if `argl' is not null instead
20145 of checking if `args' is not null).
20146 * kern/mm.c (grub_realloc): Return the same pointer when using the
20147 same region, instead of returning the header address.
20148
e15199cb 201492004-07-11 Marco Gerards <metgerards@student.han.nl>
20150
20151 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
20152 one block instead of two when looking for the initial partition.
20153 (grub_partition_probe): Initialize the local variable `p' with 0.
20154 Use base 10 for the grub_strtoul call.
20155 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
20156 need for one local variable.
20157 (grub_strtoul): Don't add the new value to `num', instead of that
20158 just assign it.
20159
020616c2 201602004-07-11 Marco Gerards <metgerards@student.han.nl>
20161
20162 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
20163 (pxeboot_img_SOURCES): New variable.
20164 (pxeboot_img_ASFLAGS): Likewise.
20165 (pxeboot_img_LDFLAGS): Likewise.
20166 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
20167 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
20168 <lode_leroy@hotmail.com>.
20169
6c51eb64 201702004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20171
20172 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
20173 there was no input.
20174
cfb12aff 201752004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20176
20177 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
20178 the history buffer logic.
20179
6eabba74 201802004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20181
20182 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
20183 (FILETYPE_INO_SYMLINK): New macros.
20184 (grub_ext2_find_file): Check if the node is a directory using the
20185 inode stat information instead of using the filetype in the
20186 dirent. Exclude the first character of an absolute symlink.
20187 (grub_ext2_dir): Mask out the filetype part of the mode member of
20188 the inode.
20189
66e19ef8 201902004-05-24 Marco Gerards <metgerards@student.han.nl>
20191
20192 Add support for UFS version 1 and 2. Add support for the minix
20193 filesystem version 1 and 2, both the variants with 14 and 30 long
20194 filenames.
f19dbdb7 20195
66e19ef8 20196 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
20197 fs/minix.c.
20198 (grub_emu_SOURCES): Likewise.
20199 (pkgdata_MODULES): Add ufs.mod and minix.mod.
20200 (ufs_mod_SOURCES): New variable.
20201 (ufs_mod_CFLAGS): Likewise.
20202 (minix_mod_SOURCES): Likewise.
20203 (minix_mod_CFLAGS): Likewise.
20204 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
20205 fs/minix.c.
20206 (grubof_SOURCES): Likewise.
20207 * fs/ufs.c: New file.
20208 * fs/minix.c: New file.
20209 * include/grub/fs.h (grub_ufs_init): New prototype.
20210 (grub_ufs_fini): Likewise.
20211 (grub_minix_init): Likewise.
20212 (grub_minix_fini): Likewise.
20213 * util/grub-emu.c (main): Initialize and deinitialize UFS and
20214 minix fs.
20215
cc2e748a 202162004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
20217
20218 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
20219 commands/ls.c, commands/terminal.c, commands/boot.c,
20220 commands/cmp.c and commands/cat.c.
20221 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
20222
20223 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
20224 "env.h"
20225
4b13b216 202262004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20227
20228 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
20229 and grub_, respectively. Because the conversion is trivial and
20230 mechanical, I omit the details here. Please refer to the CVS
20231 if you need more information.
20232
6a142551 202332004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20234
20235 * include/pupa: Renamed to ...
20236 * include/grub: ... this.
20237 * util/i386/pc/pupa-mkimage.c: Renamed to ...
20238 * util/i386/pc/grub-mkimage.c: ... this.
20239 * util/i386/pc/pupa-setup.c: Renamed to ...
20240 * util/i386/pc/grub-setup.c: ... this.
20241 * util/pupa-emu.c: Renamed to ...
20242 * util/grub-emu.c: ... this.
20243
e56cdf21 202442004-03-29 Marco Gerards <metgerards@student.han.nl>
20245
20246 Add support for the newworld apple macintosh (PPC). This has been
20247 tested on the powerbook 2000 only. It only adds support for
20248 generic ieee1275 functions, console and disk support. This should
20249 be easy to port to other architectures with support for Open
20250 Firmware.
f19dbdb7 20251
e56cdf21 20252 * configure.ac: Accept the powerpc as host_cpu. In the case of
20253 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
20254 specific tests are only executed while building for the i386.
20255 Inverse test for crosscompile.
20256 * genmk.rb (Utility): Allow assembler files.
20257 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
20258 * conf/powerpc-ieee1275.rmk: New file.
20259 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
20260 * disk/powerpc/ieee1275/partition.c: Likewise.
20261 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
20262 * include/pupa/powerpc/ieee1275/console.h: Likewise.
20263 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
20264 * include/pupa/powerpc/ieee1275/time.h: Likewise.
20265 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
20266 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
20267 * include/pupa/powerpc/ieee1275/loader.h
20268 * include/pupa/powerpc/setjmp.h: Likewise.
20269 * include/pupa/powerpc/types.h: Likewise.
20270 * kern/powerpc/ieee1275/init.c: Likewise.
20271 * kern/powerpc/ieee1275/openfw.c: Likewise.
20272 * term/powerpc/ieee1275/ofconsole.c: Likewise.
20273
20274 These files were written by Johan Rydberg
20275 (jrydberg@night.trouble.net) and I only modified them slightly.
f19dbdb7 20276
e56cdf21 20277 * boot/powerpc/ieee1275/cmain.c: New file.
20278 * boot/powerpc/ieee1275/crt0.S: Likewise.
20279 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
20280 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
20281
8c8cc205 202822004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
20283
20284 * Makefile.in: Update copyright.
20285 * genmodsrc.sh: Likewise.
20286 * gensymlist.sh: Likewise.
20287 * term/i386/pc/vga.c: Indent correctly.
20288
20289 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
20290 bugreporting address.
20291 * util/i386/pc/pupa-setup.c (usage): Likewise,
20292 (main): Call pupa_ext2_init and pupa_ext2_fini.
20293
f19dbdb7 20294 * fs/fat.c (log2): Renamed to ...
8c8cc205 20295 (fat_log2): ... this.
20296 All callers changed.
20297 * kern/misc.c (memcpy): Alias to pupa_memmove.
20298 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
20299 lvalue cast.
20300 * util/console.c (pupa_ncurses_fini): Return 0.
20301
20302 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
20303 Move fail label here.
20304 [__GNU__]: Don't warn when using stat.
20305 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
20306 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
20307 long int. Use strtol instead of strtoul.
f19dbdb7 20308
db1771cf 203092004-03-14 Marco Gerards <metgerards@student.han.nl>
20310
20311 * commands/boot.c: New file.
20312 * commands/cat.c: Likewise.
20313 * commands/cmp.c: Likewise.
20314 * commands/ls.c: Likewise.
20315 * commands/terminal.c: Likewise.
20316 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
20317 (pupa_register_command): Changed interface to match the new
20318 argument parser.
20319 (pupa_command_execute): Changed (almost rewritten) so it uses
20320 pupa_split_command. Added support for setting variables using the
20321 syntax `foo=bar'.
20322 (rescue_command): Changed to work with the new argument parser.
20323 (terminal_command): Moved from here to commands/terminal.c.
20324 (set_command): New function.
20325 (unset_command): New function.
20326 (insmod_command): New function.
20327 (rmmod_command): New function.
20328 (lsmod_command): New function.
20329 (pupa_command_init): Don't initialize the command terminal
20330 anymore. Initialize the commands set, unset, insmod, rmmod and
20331 lsmod.
20332 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
20333 (kernel_img_HEADERS): Add arg.h and env.h.
20334 (pupa_mkimage_LDFLAGS): Add kern/env.c.
20335 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
20336 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
20337 normal/arg.c.
20338 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
20339 terminal.mod.
20340 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
20341 (boot_mod_SOURCES): New variable.
20342 (terminal_mod_SOURCES): Likewise.
20343 (ls_mod_SOURCES): Likewise.
20344 (cmp_mod_SOURCES): Likewise.
20345 (cat_mod_SOURCES): Likewise.
20346
20347 * normal/arg.c: New file.
20348 * kern/env.c: Likewise.
20349 * include/pupa/arg.h: Likewise.
20350 * include/pupa/env.h: Likewise.
20351 * font/manager.c (font_command): Changed to match argument parsing
20352 interface changes.
20353 (PUPA_MOD_INIT): Likewise.
20354 * hello/hello.c (pupa_cmd_hello): Likewise.
20355 (PUPA_MOD_INIT): Likewise.
20356 * include/pupa/disk.h: Include <pupa/device.h>.
20357 (pupa_print_partinfo): New prototype.
20358 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
20359 (pupa_dl_get_prefix): Likewise.
20360 * include/pupa/misc.h: Include <pupa/err.h>.
20361 (pupa_isgraph): New prototype.
20362 (pupa_isdigit): Likewise.
20363 (pupa_split_cmdline): Likewise.
20364 * include/pupa/normal.h: Include <pupa/arg.h>.
20365 (pupa_command): Changed the prototype of the member `func' to
20366 match the argument parsing interface. Added member `options'.
20367 (pupa_register_command): Updated to match function.
20368 (pupa_arg_parse): New prototype.
20369 (pupa_hello_init) [PUPA_UTIL]: New prototype.
20370 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
20371 (pupa_ls_init) [PUPA_UTIL]: Likewise.
20372 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
20373 (pupa_cat_init) [PUPA_UTIL]: Likewise.
20374 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
20375 (pupa_boot_init) [PUPA_UTIL]: Likewise.
20376 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
20377 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
20378 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
20379 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
20380 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
20381 * kern/disk.c: Include <pupa/file.h>.
20382 (pupa_print_partinfo): New function.
20383 * kern/dl.c: Include <pupa/env.h>.
20384 (pupa_dl_dir): Variable removed.
20385 (pupa_dl_load): Use the environment variable `prefix' instead of
20386 the variable pupa_dl_dir.
20387 (pupa_dl_set_prefix): Function removed.
20388 (pupa_dl_get_prefix): Likewise.
20389 * kern/i386/pc/init.c: Include <pupa/env.h>.
20390 (pupa_machine_init): Use the environment variable `prefix' instead of
20391 using pupa_dl_set_prefix to set the prefix.
20392 * kern/main.c: Include <pupa/env.h>.
20393 (pupa_set_root_dev): Use the environment variable `prefix' instead of
20394 using pupa_dl_get_prefix to get the prefix.
20395 * kern/misc.c: Include <pupa/env.h>.
20396 (pupa_isdigit): New function.
20397 (pupa_isgraph): Likewise.
20398 (pupa_ftoa): Likewise.
20399 (pupa_vsprintf): Added support for printing values of the type
20400 `double'. Make it possible to format variable output when using
20401 formatting like `%1.2%f'.
20402 (pupa_split_cmdline): New function.
20403 * kern/rescue.c: Include <pupa/env.h>.
20404 (next_word): Removed function.
20405 (pupa_rescue_cmd_prefix): Likewise.
20406 (pupa_rescue_cmd_set): New function.
20407 (pupa_rescue_cmd_unset): New function.
20408 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
20409 split the command line instead of splitting it here. Added
20410 support for setting variables using the syntax `foo=bar'. Don't
20411 initialize the prefix command anymore. Initialized the set and
20412 unset commands.
20413 * normal/cmdline.c: Include <pupa/env.h>.
20414 (pupa_tab_complete): Added prototypes for print_simple_completion,
20415 print_partition_completion, add_completion, iterate_commands,
20416 iterate_dev, iterate_part and iterate_dir. Moved code to print
20417 partition information from here to kern/disk.c.
fe6b695a 20418 (pupa_cmdline_run): Don't check if the function exists anymore.
db1771cf 20419 * normal/main.c: Include <pupa/env.h>.
20420 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
20421 instead of using pupa_dl_get_prefix to get the prefix.
20422 * term/i386/pc/vga.c: Include <pupa/arg.h>.
20423 (check_vga_mem): Cast pointers to `void *' to silence a gcc
20424 warning.
20425 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
20426 (pupa_vga_setcolor): Declare unused variables with `__attribute__
20427 ((unused))' to silence a gcc warning.
20428 (pupa_vga_setcolor): Likewise.
20429 (debug_command): Changed to match argument parsing
20430 interface changes.
20431 * util/pupa-emu.c: Include <pupa/env.h>.
20432 (options): Added 0's for unused fields to silence a gcc warning.
20433 (argp): Likewise.
20434 (main): Use the environment variable `prefix' instead of using
20435 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
20436 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
20437 and terminal.
20438
20439 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
20440 * util/misc.c: Include <malloc.h>.
20441 (pupa_malloc): Rewritten so errors are correctly reported.
20442 (pupa_realloc): Likewise.
20443 (pupa_memalign): Likewise.
20444 (pupa_mm_init_region): Declare unused variables with
20445 `__attribute__ ((unused))' to silence a gcc warning.
20446 * normal/i386/setjmp.S: Remove tab at the end of the file to
20447 silence a gcc warning.
20448 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
20449 variables with `__attribute__ ((unused))' to silence a gcc
20450 warning.
20451 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
20452 local variable i unsigned to silence a gcc warning.
20453
20454 * kern/term.c: Include <pupa/misc.h>.
20455 (pupa_more_lines): New variable.
20456 (pupa_more): Likewise.
20457 (pupa_putcode): When the pager is active pause at the end of every
20458 screen.
20459 (pupa_set_more): New function.
20460 * include/pupa/term.h (pupa_set_more): New prototype.
20461
20462
3b1139cb 204632004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
20464
20465 Now this project is GRUB 2 rather than PUPA. The location of
20466 the CVS repository was moved to GRUB's.
f19dbdb7 20467
3b1139cb 20468 * configure.ac: Use bug-grub as the reporting address.
20469 Use GRUB instead of PUPA.
20470 Change the version number to 1.90.
20471
8367695c 204722004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
20473
20474 * genkernsyms.sh: Updated copyright information.
20475 * genmk.rb: Likewise.
20476 * genmodsrc.sh: Likewise.
20477 * gensymlist.sh: Likewise.
20478 * boot/i386/pc/boot.S: Likewise.
20479 * boot/i386/pc/diskboot.S: Likewise.
20480 * disk/i386/pc/biosdisk.c: Likewise.
20481 * disk/i386/pc/partition.c: Likewise.
20482 * font/manager.c: Likewise.
20483 * fs/ext2.c: Likewise.
20484 * fs/fat.c: Likewise.
20485 * include/pupa/boot.h: Likewise.
20486 * include/pupa/device.h: Likewise.
20487 * include/pupa/disk.h: Likewise.
20488 * include/pupa/dl.h: Likewise.
20489 * include/pupa/elf.h: Likewise.
20490 * include/pupa/err.h: Likewise.
20491 * include/pupa/file.h: Likewise.
20492 * include/pupa/font.h: Likewise.
20493 * include/pupa/fs.h: Likewise.
20494 * include/pupa/kernel.h: Likewise.
20495 * include/pupa/loader.h: Likewise.
20496 * include/pupa/misc.h: Likewise.
20497 * include/pupa/mm.h: Likewise.
20498 * include/pupa/net.h: Likewise.
20499 * include/pupa/normal.h: Likewise.
20500 * include/pupa/rescue.h: Likewise.
20501 * include/pupa/setjmp.h: Likewise.
20502 * include/pupa/symbol.h: Likewise.
20503 * include/pupa/term.h: Likewise.
20504 * include/pupa/types.h: Likewise.
20505 * include/pupa/i386/setjmp.h: Likewise.
20506 * include/pupa/i386/types.h: Likewise.
20507 * include/pupa/i386/pc/biosdisk.h: Likewise.
20508 * include/pupa/i386/pc/boot.h: Likewise.
20509 * include/pupa/i386/pc/console.h: Likewise.
20510 * include/pupa/i386/pc/init.h: Likewise.
20511 * include/pupa/i386/pc/kernel.h: Likewise.
20512 * include/pupa/i386/pc/linux.h: Likewise.
20513 * include/pupa/i386/pc/loader.h: Likewise.
20514 * include/pupa/i386/pc/memory.h: Likewise.
20515 * include/pupa/i386/pc/multiboot.h: Likewise.
20516 * include/pupa/i386/pc/partition.h: Likewise.
20517 * include/pupa/i386/pc/time.h: Likewise.
20518 * include/pupa/i386/pc/vga.h: Likewise.
20519 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
20520 * include/pupa/util/getroot.h: Likewise.
20521 * include/pupa/util/misc.h: Likewise.
20522 * include/pupa/util/resolve.h: Likewise.
20523 * kern/device.c: Likewise.
20524 * kern/disk.c: Likewise.
20525 * kern/dl.c: Likewise.
20526 * kern/err.c: Likewise.
20527 * kern/file.c: Likewise.
20528 * kern/fs.c: Likewise.
20529 * kern/loader.c: Likewise.
20530 * kern/main.c: Likewise.
20531 * kern/misc.c: Likewise.
20532 * kern/mm.c: Likewise.
20533 * kern/rescue.c: Likewise.
20534 * kern/term.c: Likewise.
20535 * kern/i386/dl.c: Likewise.
20536 * kern/i386/pc/init.c: Likewise.
20537 * kern/i386/pc/lzo1x.S: Likewise.
20538 * kern/i386/pc/startup.S: Likewise.
20539 * loader/i386/pc/chainloader.c: Likewise.
20540 * loader/i386/pc/linux.c: Likewise.
20541 * loader/i386/pc/multiboot.c: Likewise.
20542 * normal/cmdline.c: Likewise.
20543 * normal/command.c: Likewise.
20544 * normal/main.c: Likewise.
20545 * normal/menu.c: Likewise.
20546 * normal/i386/setjmp.S: Likewise.
20547 * term/i386/pc/console.c: Likewise.
20548 * term/i386/pc/vga.c: Likewise.
20549 * util/console.c: Likewise.
20550 * util/genmoddep.c: Likewise.
20551 * util/misc.c: Likewise.
20552 * util/pupa-emu.c: Likewise.
20553 * util/resolve.c: Likewise.
20554 * util/unifont2pff.rb: Likewise.
20555 * util/i386/pc/biosdisk.c: Likewise.
20556 * util/i386/pc/getroot.c: Likewise.
20557 * util/i386/pc/pupa-mkimage.c: Likewise.
20558 * util/i386/pc/pupa-setup.c: Likewise.
20559
e6eced71 205602004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
20561
20562 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
20563 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
20564 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
20565 reading and reset it after reading.
20566 (pupa_ext2_close): Return PUPA_ERR_NONE.
20567
20568 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
20569 Correct value.
20570 (struct linux_kernel_header): Add kernel_version and
20571 initrd_addr_max.
20572 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
20573 pupa_file_read succeeds.
20574 (pupa_rescue_cmd_initrd): Implement.
20575
5aded270 205762003-12-03 Marco Gerards <metgerards@student.han.nl>
20577
20578 * fs/ext2.c (pupa_ext2_label): New function.
20579 (pupa_ext2_fs): Added label.
20580 * fs/fat.c (pupa_fat_label): New function.
20581 (pupa_fat_fs): Added label.
20582 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
20583
20584 * kern/misc.c (pupa_strndup): New function.
20585 * include/pupa/misc.h (pupa_strndup): New prototype.
20586
20587 * include/pupa/normal.h: Include <pupa/err.h>.
20588 (pupa_set_history): New prototype.
20589 (pupa_iterate_commands): New prototype.
20590 * normal/cmdline.c: Include <pupa/machine/partition.h>,
20591 <pupa/disk.h>, <pupa/file.h>.
20592 (hist_size): New variable.
20593 (hist_lines): Likewise.
20594 (hist_end): Likewise.
20595 (hist_used): Likewise.
20596 (pupa_set_history): New function.
20597 (pupa_history_get): Likewise.
20598 (pupa_history_add): Likewise.
20599 (pupa_history_replace): Likewise.
20600 (pupa_tab_complete): Likewise.
20601 (pupa_cmdline_run): Added tab completion and history buffer. Tab
20602 completion shows partitionnames while completing partitions, this
20603 feature was suggested by Jeff Bailey.
20604 * normal/command.c (pupa_iterate_commands): New function.
20605 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
20606 (pupa_normal_init): Initialize history buffer.
20607 (PUPA_MOD_INIT): Likewise.
20608 (pupa_normal_fini): Free the history buffer.
20609 (PUPA_MOD_FINI): Likewise.
20610
20611 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
20612 key.
20613
20614 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
20615 * configure.ac [i386]: Check for regparam bug.
20616 (NESTED_FUNC_ATTR) [! i386]: Defined.
20617
1f7315a3 206182003-11-17 Marco Gerards <metgerards@student.han.nl>
20619
20620 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
20621 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
20622 (pupa_emu_SOURCES): New variable.
20623 (pupa_emu_LDFLAGS): Likewise.
20624 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
20625 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
20626 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
20627 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20628 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
20629 (pupa_jmp_buf): New typedef.
20630 (pupa_setjmp) [PUPA_UTIL]: New macro.
20631 (pupa_longjmp) [PUPA_UTIL]: Likewise.
20632 * include/pupa/term.h (struct pupa_term): New member `refresh'.
20633 (pupa_refresh): New prototype.
20634 * include/pupa/util/getroot.h: New file.
20635 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
20636 it.
20637 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
20638 (pupa_rescue_cmd_cat): Likewise.
20639 (pupa_rescue_cmd_ls): Likewise.
20640 (pupa_rescue_cmd_testload): Likewise.
20641 (pupa_rescue_cmd_lsmod): Likewise.
20642 * normal/cmdline.c (pupa_cmdline_get): Likewise.
20643 * normal/menu.c (run_menu): Likewise.
20644 * kern/term.c (pupa_cls): Likewise.
20645 (pupa_refresh): New function.
20646 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
20647 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20648 * util/console.c: New file.
f19dbdb7 20649
1f7315a3 20650 * util/i386/pc/getroot.c: New file.
20651 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
20652 (pupa_putchar): New function.
20653 (pupa_refresh): Likewise.
20654 (xgetcwd): Function moved to ...
20655 (strip_extra_slashes): Likewise.
20656 (get_prefix): Likewise.
f19dbdb7 20657 * util/i386/pc/getroot.c: ... here.
1f7315a3 20658 (find_root_device): Function moved and renamed to...
20659 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
20660 Changed all callers.
20661 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
20662 and renamed to...
20663 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
20664 Changed all callers.
20665 * util/misc.c (pupa_memalign): New function.
20666 (pupa_mm_init_region): Likewise.
20667 (pupa_register_exported_symbols): Likewise.
20668 (pupa_putchar): Function removed.
20669 * util/pupa-emu.c: New file.
20670
9a5c1ade 206712003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
20672
20673 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
20674 (_multiboot_mod_SOURCES): New variable.
20675 (_multiboot_mod_CFLAGS): Likewise.
20676 * loader/i386/pc/multiboot.c: New file.
20677 * include/pupa/i386/pc/multiboot.h: Likewise.
20678 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
20679 (pupa_multiboot_real_boot): New function.
20680 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
20681 (pupa_multiboot_real_boot): New prototype.
20682 (pupa_rescue_cmd_multiboot): Likewise
20683 (pupa_rescue_cmd_module): Likewise.
20684
20685 * kern/loader.c (pupa_loader_set): Continue when
20686 pupa_loader_unload_func() fails.
20687 (pupa_loader_unset): New function.
20688 * include/pupa/loader.h (pupa_loader_unset): New prototype.
20689
20690 * kern/misc.c (pupa_stpcpy): New function.
20691 * include/pupa/misc.h (pupa_stpcpy): New prototype.
20692
8e72a9c0 206932003-11-12 Marco Gerards <metgerards@student.han.nl>
20694
20695 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
20696 for available extensions.
20697
20698 * include/pupa/i386/pc/time.h: New file.
20699 * kern/disk.c: Include <pupa/machine/time.h>.
20700 (PUPA_CACHE_TIMEOUT): New macro.
20701 (pupa_last_time): New variable.
20702 (pupa_disk_open): Flush the cache when there was a timeout.
20703 (pupa_disk_close): Reset the timer.
20704 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
20705 pupa_currticks.
20706 * util/misc.c: Include <sys/times.h>
20707 (pupa_get_rtc): New function.
20708
c4adbd32 207092003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
20710
20711 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
20712 as blocks.
20713 (pupa_ext2_get_file_block): Use blocks member.
20714
20715 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
20716 first block. Return -1 instead of pupa_errno on error.
20717
bfd30f06 207182003-10-27 Marco Gerards <metgerards@student.han.nl>
20719
20720 * README: In the pupa-mkimage example use _chain instead of chain
20721 and ext2 instead of fat.
20722 * TODO: Replace ext2fs with jfs as an example. Add an item for
20723 adding journal playback for ext2fs.
20724 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
20725 (pkgdata_MODULES): Added ext2.mod.
20726 (ext2_mod_SOURCES): New variable.
20727 (ext2_mod_CFLAGS): Likewise.
20728 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
20729 * include/pupa/misc.h (pupa_strncpy): New prototype.
20730 (pupa_strcat): Likewise.
20731 (pupa_strncmp): Likewise.
20732 * kern/misc.c (pupa_strcat): Enable function.
20733 (pupa_strncpy): New function.
20734 (pupa_strncmp): Likewise.
20735 * fs/ext2.c: New file.
f19dbdb7 20736
bfd30f06 20737 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
20738 when the read failed before retrying.
20739 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
20740 (_FILE_OFFSET_BITS): Likewise.
20741 * configure.ac: Added AC_SYS_LARGEFILE.
20742
98d15063 207432003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20744
20745 * genmk.rb (PModule#rule): Make sure to get only symbol names
20746 from the output of nm.
20747 Reported by Robert Millan <zeratul2@wanadoo.es>.
20748
18d9c7cd 207492003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20750
20751 I forgot to check in these changes for a long time. This adds
20752 incomplete support for VGA console, and this is still very
20753 buggy. Also, a lot of consideration is required for I18N,
20754 UNICODE, and VGA font issues. Therefore, assume that this is
20755 such that "better than nothing".
f19dbdb7 20756
18d9c7cd 20757 * font/manager.c: New file.
20758 * include/pupa/font.h: Likewise.
20759 * include/pupa/i386/pc/vga.h: Likewise.
20760 * term/i386/pc/vga.c: Likewise.
20761 * util/unifont2pff.rb: Likewise.
20762
20763 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
20764 (pkgdata_MODULES): Added vga.mod and font.mod.
20765 (vga_mod_SOURCES): New variables.
20766 (vga_mod_CFLAGS): Likewise.
20767 (font_mod_SOURCES): Likewise.
20768 (font_mod_CFLAGS): Likewise.
20769
20770 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
20771
20772 * include/pupa/term.h: Include pupa/err.h.
f19dbdb7 20773 (struct pupa_term): Added init and fini.
18d9c7cd 20774 Changed the argument of putchar to pupa_uint32_t.
20775
20776 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
20777 (pupa_console_real_putchar): New prototype.
20778 (pupa_console_putchar): Removed.
20779 (pupa_console_checkkey): Exported.
20780 (pupa_console_getkey): Likewise.
20781
20782 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
20783 characters.
20784
20785 * kern/term.c (pupa_term_set_current): Rewritten.
20786 (pupa_putchar): Likewise.
20787 (pupa_putcode): New function.
20788
20789 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
20790 (pupa_console_real_putchar): ... this.
20791 (pupa_vga_set_mode): New function.
20792 (pupa_vga_get_font): Likewise.
20793
20794 * normal/command.c: Include pupa/term.h.
20795 (terminal_command): New function.
20796 (pupa_command_init): Register the command "terminal".
20797
20798 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
20799 (DISP_UP): Likewise.
20800 (DISP_RIGHT): Likewise.
20801 (DISP_DOWN): Likewise.
20802 (DISP_HLINE): Likewise.
20803 (DISP_VLINE): Likewise.
20804 (DISP_UL): Likewise.
20805 (DISP_UR): Likewise.
20806 (DISP_LL): Likewise.
20807 (DISP_LR): Likewise.
20808
20809 * term/i386/pc/console.c (pupa_console_putchar): New function.
f19dbdb7 20810
977329f5 208112003-02-08 NIIBE Yutaka <gniibe@m17n.org>
20812
20813 * util/resolve.c (pupa_util_resolve_dependencies): BUG
20814 FIX. Reverse the path_list.
20815
20816 * include/pupa/normal.h: Export pupa_register_command and
20817 pupa_unregister_command.
20818
20819 * hello/hello.c (pupa_cmd_hello): New module.
20820 * conf/i386-pc.rmk: Added hello.mod.
20821
1f5ab428 208222003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
20823
20824 * kern/i386/pc/lzo1x.S: New file.
f19dbdb7 20825
1f5ab428 20826 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
20827 (compress_kernel): New variable.
20828 (generate_image): Heavily modified to support compressing a
20829 large part of the core image.
20830
20831 * util/misc.c (pupa_util_read_image): Fix a file descriptor
20832 leak.
20833 (pupa_util_load_image): New function.
20834
20835 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
20836 (pupa_compressed_size): New variable.
20837 (codestart): Enable Gate A20 here.
20838 Decompress the compressed part of the core image.
20839 Rearrange the code to put functions and variables which are
20840 required for initialization in the non-compressed part.
20841 Include lzo1x.S.
20842
20843 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
20844 here.
20845
20846 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
20847
f19dbdb7 20848 * include/pupa/i386/pc/kernel.h
1f5ab428 20849 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
20850 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
20851 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
20852 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
20853 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
20854
20855 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
20856
20857 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
20858 (Utility#rule): Likewise.
20859
20860 * configure.ac: Check if LZO is available.
20861
ce5bf700 208622003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
20863
20864 * include/pupa/normal.h: New file.
20865 * include/pupa/setjmp.h: Likewise.
20866 * include/pupa/i386/setjmp.h: Likewise.
20867 * normal/cmdline.c: Likewise.
20868 * normal/command.c: Likewise.
20869 * normal/main.c: Likewise.
20870 * normal/menu.c: Likewise.
20871 * normal/i386/setjmp.S: Likewise.
f19dbdb7 20872
ce5bf700 20873 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
20874 (pupa_rescue_cmd_initrd): Likewise.
20875
20876 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
20877 Likewise.
20878
20879 * kern/i386/pc/startup.S (translation_table): New variable.
20880 (translate_keycode): New function.
20881 (pupa_console_getkey): Call translate_keycode.
20882
20883 * kern/rescue.c (attempt_normal_mode): New function.
20884 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
20885 it failed, print a message.
20886
20887 * kern/mm.c (pupa_real_malloc): Print more information when a
20888 free magic is broken.
20889 (pupa_free): If the first free header is not free actually, set
20890 it to P.
20891
20892 * kern/main.c (pupa_load_normal_mode): Just load the module
20893 "normal".
20894 (pupa_main): Don't print the message
20895 "Entering into rescue mode..." here.
20896
20897 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
20898 Declared.
20899 (pupa_rescue_cmd_initrd): Likewise.
20900 (pupa_rescue_cmd_initrd): Likewise.
20901
20902 * include/pupa/symbol.h (FUNCTION): Specify the type.
20903 (VARIABLE): Likewise.
20904
20905 * include/pupa/err.h (pupa_err_t): Added
20906 PUPA_ERR_UNKNOWN_COMMAND.
20907
20908 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
20909 (pupa_dl_get_prefix): Likewise.
20910
20911 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
20912 Added _chain.mod and _linux.mod instead of chain.mod and
20913 linux.mod.
20914 (chain_mod_SOURCES): Renamed to ...
20915 (_chain_mod_SOURCES): ... this.
20916 (chain_mod_CFLAGS): Renamed to ...
20917 (_chain_mod_CFLAGS): ... this.
20918 (linux_mod_SOURCES): Renamed to ...
20919 (_linux_mod_SOURCES): ... this.
20920 (linux_mod_CFLAGS): Renamed to ...
20921 (_linux_mod_CFLAGS): ... this.
20922 (normal_mod_SOURCES): New variable.
20923 (normal_mod_CFLAGS): Likewise.
20924 (normal_mod_ASFLAGS): Likewise.
20925
209262003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
20927
20928 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
20929 possible.
20930
fe6b695a 20931 * kern/dl.c (pupa_dl_ref): Refer depending modules
ce5bf700 20932 recursively.
20933 (pupa_dl_unref): Unrefer depending modules recursively.
20934 Don't call pupa_dl_unload implicitly, because PUPA can crash if
20935 a module is unloaded before one depending on that module is
20936 unloaded.
20937 (pupa_dl_unload): Unload depending modules explicitly,
20938 if possible.
20939
c04da074 209402003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
20941
20942 * include/pupa/i386/pc/linux.h: New file.
20943 * loader/i386/pc/linux.c: Likewise.
f19dbdb7 20944
c04da074 20945 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
20946 Removed.
20947 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
20948 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
20949 of PUPA_CHAINLOADER_BOOT_SECTOR.
20950
20951 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
20952 (pupa_linux_prot_size): New variable.
20953 (pupa_linux_tmp_addr): Likewise.
20954 (pupa_linux_real_addr): Likewise.
20955 (pupa_linux_boot_zimage): New function.
20956 (pupa_linux_boot_bzimage): Likewise.
20957
20958 * kern/i386/pc/init.c (struct mem_region): New structure.
20959 (MAX_REGIONS): New macro.
20960 (mem_regions): New variable.
20961 (num_regions): Likewise.
20962 (pupa_os_area_addr): Likewise.
20963 (pupa_os_area_size): Likewise.
20964 (pupa_lower_mem): Likewise.
20965 (pupa_upper_mem): Likewise.
20966 (add_mem_region): New function.
20967 (compact_mem_regions): Likewise.
20968 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
20969 the size of the conventional memory and that of so-called upper
20970 memory (before the first memory hole).
20971 Instead of adding each found region to free memory, use
20972 add_mem_region and add them after removing overlaps.
20973 Also, add only 1/4 of the upper memory to free memory. The rest
20974 is used for loading OS images. Maybe this is ad hoc, but this
20975 makes it much easier to relocate OS images when booting.
20976
20977 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
20978 (pupa_enter_rescue_mode): Don't register initrd and module.
20979
20980 * kern/mm.c: Include pupa/dl.h.
20981
20982 * kern/main.c: Include pupa/file.h and pupa/device.h.
20983
20984 * kern/loader.c (pupa_loader_load_module_func): Removed.
20985 (pupa_loader_load_module): Likewise.
20986
20987 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
20988 ``.o''.
20989
20990 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
20991 (pupa_linux_tmp_addr): Likewise.
20992 (pupa_linux_real_addr): Likewise.
20993 (pupa_linux_boot_zimage): Likewise.
20994 (pupa_linux_boot_bzimage): Likewise.
20995
20996 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
20997 (pupa_upper_mem): Likewise.
20998 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
20999 module is too dangerous.
21000
21001 * include/pupa/loader.h (pupa_os_area_addr): Declared.
21002 (pupa_os_area_size): Likewise.
21003 (pupa_loader_set): Remove the first argument. Loader doesn't
21004 manage modules or initrd any longer.
21005 (pupa_loader_load_module): Removed.
21006
21007 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
21008 (linux_mod_SOURCES): New variable.
21009 (linux_mod_CFLAGS): Likewise.
21010
a13f9237 210112003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
21012
21013 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
21014 the length of a blocklist correctly.
21015
21016 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
21017 Use ioctl only if the OS file is a block device.
21018 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
21019 not very useful for normal files.
21020
21021 * kern/main.c (pupa_set_root_dev): New function.
21022 (pupa_load_normal_mode): Likewise.
21023 (pupa_main): Call those above.
21024
21025 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
21026 pupa_uint16_t.
21027
21028 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
21029
a5ffe966 210302003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
21031
21032 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
21033 (setup): Configure the installed partition information and the
21034 dl prefix.
21035
21036 * loader/i386/pc/chainloader.c (my_mod): New variable.
21037 (pupa_chainloader_unload): New function.
21038 (pupa_rescue_cmd_chainloader): Refer itself.
21039 (PUPA_MOD_INIT): Save its own module in MY_MOD.
21040
21041 * kern/i386/pc/startup.S (install_partition): Removed.
21042 (version_string): Likewise.
21043 (config_file): Likewise.
21044 (pupa_install_dos_part): New variable.
21045 (pupa_install_bsd_part): Likewise.
21046 (pupa_prefix): Likewise.
21047 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
21048
21049 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
21050 and pupa/misc.h.
21051 (make_install_device): New function.
21052 (pupa_machine_init): Set the dl prefix.
21053
21054 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
21055 (buf): Renamed to ...
21056 (linebuf): ... this.
21057 (pupa_rescue_cmd_prefix): New function.
21058 (pupa_rescue_cmd_insmod): Likewise.
21059 (pupa_rescue_cmd_rmmod): Likewise.
21060 (pupa_rescue_cmd_lsmod): Likewise.
21061 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
21062 rmmod and lsmod.
21063
21064 * kern/mm.c (pupa_memalign): If failed even after invalidating
21065 disk caches, unload unneeded modules and retry.
21066
21067 * kern/misc.c (pupa_memmove): New function.
21068 (pupa_memcpy): Removed.
21069 (pupa_strcpy): New function.
21070 (pupa_itoa): Made static.
21071
21072 * kern/dl.c (pupa_dl_iterate): New function.
21073 (pupa_dl_ref): Likewise.
21074 (pupa_dl_unref): Likewise.
21075 (pupa_dl_unload): Return if succeeded or not.
21076 (pupa_dl_unload_unneeded): New function.
21077 (pupa_dl_unload_all): Likewise.
21078 (pupa_dl_init): Renamed to ...
21079 (pupa_dl_set_prefix): ... this.
21080 (pupa_dl_get_prefix): New function.
21081
21082 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
21083 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
21084 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
21085 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
21086 (pupa_install_dos_part): Declared.
21087 (pupa_install_bsd_part): Likewise.
21088 (pupa_prefix): Likewise.
21089 (pupa_boot_drive): Likewise.
21090
21091 * include/pupa/types.h: Fix a typo.
21092
21093 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
21094 pupa_memmove.
21095 (pupa_memmove): Declared.
21096 (pupa_strcpy): Likewise.
21097
21098 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
21099 pupa_mod_init takes one argument, its own module.
21100 (pupa_dl_unload_unneeded): Declared.
21101 (pupa_dl_unload_all): Likewise.
21102 (pupa_dl_ref): Likewise.
21103 (pupa_dl_unref): Likewise.
21104 (pupa_dl_iterate): Likewise.
21105 (pupa_dl_init): Renamed to ...
21106 (pupa_dl_set_prefix): ... this.
21107 (pupa_dl_get_prefix): Declared.
21108
21109 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
f19dbdb7 21110 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
a5ffe966 21111 unloaded.
21112 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
21113 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
21114
21115 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
21116 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
21117
012d7999 211182003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21119
21120 * util/i386/pc/pupa-setup.c (setup): Define the internal
21121 function find_first_partition_start at the top level, because GCC
21122 3.0.x cannot compile internal functions in deeper scopes
21123 correctly.
21124 (find_root_device): Use lstat instead of stat.
21125 Don't follow symbolic links.
21126 Fix the path-constructing code.
21127
21128 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
21129 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
21130 by a BLKGETSIZE ioctl first, because block devices don't fill
21131 the member st_mode of the structure stat on Linux.
21132 [__linux__] (linux_find_partition): Use a temporary buffer
21133 REAL_DEV for the working space. Copy it to DEV before returning.
21134 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
21135 buffer cache consistent.
21136 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
21137 strncmp. The previous value was merely wrong.
21138 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
21139
21140 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
21141 FAT size is 12. The previous value was merely wrong.
21142
21143 * kern/main.c (pupa_main): Don't split the starting message from
21144 newlines.
21145
21146 * kern/term.c (pupa_putchar): Put CR after LF instead of before
21147 LF, because BIOS goes crazy about character attributes in this
21148 case.
21149
1cc73a62 211502003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21151
21152 * include/i386/pc/util/biosdisk.h: New file.
21153 * util/i386/pc/biosdisk.c: Likewise.
21154 * util/i386/pc/pupa-setup.c: Likewise.
f19dbdb7 21155
1cc73a62 21156 * Makefile.in (INCLUDE_DISTFILES): Added
21157 include/pupa/i386/pc/util/biosdisk.h.
21158 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
21159 directory util/i386/pc.
21160 (install-local): Added a rule for sbin_UTILITIES.
21161 (uninstall): Likewise.
21162
21163 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
21164
21165 * util/misc.c (xrealloc): New function.
21166 (pupa_malloc): Likewise.
21167 (pupa_free): Likewise.
21168 (pupa_realloc): Likewise.
21169 (pupa_stop): Likewise.
21170 (pupa_putchar): Likewise.
21171
21172 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
21173
21174 * include/pupa/util/misc.h (xrealloc): Declared.
21175
21176 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
21177 macro.
21178 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
21179 (PUPA_BOOT_MACHINE_BPB_END): ... this.
21180
21181 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
21182 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21183
21184 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
21185 way should be implemented.
21186 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21187
21188 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
21189 the size of NAME for safety.
21190 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
21191 0x88.
21192
21193 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
21194 (pupa_setup_SOURCES): Likewise.
21195
21196 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
21197
08b70fe8 211982002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21199
21200 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
21201 bunch of pushl's from pusha, because this destroys the return
21202 value.
21203
62ddcc8f 212042002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21205
21206 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
21207 This means that any missing prototypes could be fatal. Also, you
21208 must take care when writing assembly code. See the comments at
21209 the beginning of startup.S, for more details.
f19dbdb7 21210
62ddcc8f 21211 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
21212 compilation mechanism.
21213 (pupa_chainloader_real_boot): Likewise.
21214 (pupa_biosdisk_rw_int13_extensions): Likewise.
21215 (pupa_biosdisk_rw_standard): Likewise.
21216 (pupa_biosdisk_check_int13_extensions): Likewise.
21217 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
21218 (pupa_biosdisk_get_diskinfo_standard): Likewise.
21219 (pupa_get_memsize): Likewise.
21220 (pupa_get_mmap_entry): Likewise.
21221 (pupa_console_putchar): Likewise.
21222 (pupa_console_setcursor): Likewise.
21223 (pupa_getrtsecs): Use pushl instead of push.
21224
21225 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
21226 memory instead of the stack for a mmap entry, because some
21227 BIOSes may ignore the maximum size and overflow.
21228
21229 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
21230
21231 * genmk.rb (PModule#rule): Compile automatically generated
21232 sources with module-specific CFLAGS as well as other sources.
21233
9962ed99 212342002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21235
21236 * configure.ac: Check ld.
21237 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
21238 respectively, before checking endianness and sizes.
21239
21240 * Makefile.in (LD): New variable.
f19dbdb7 21241
abdfc3c5 212422002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21243
21244 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
21245
6a161fa9 212462002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21247
21248 * Changelog: New file.
21249