]> git.proxmox.com Git - grub2.git/blame - ChangeLog
2009-11-22 Robert Millan <rmh.grub@aybabtu.com>
[grub2.git] / ChangeLog
CommitLineData
87d58298
RM
12009-11-22 Robert Millan <rmh.grub@aybabtu.com>
2
3 * util/i386/pc/grub-mkimage.c: Ungettextize grub_util_info() strings.
4 * util/i386/pc/grub-setup.c: Likewise.
5
994cc3a3
ST
62009-11-21 Samuel Thibault <samuel.thibault@ens-lyon.org>
7
8 * util/getroot.c [__GNU__]: Include <hurd.h>, <hurd/lookup.h>, and
9 <hurd/fs.h>
10 [__GNU__] (grub_guess_root_device): Call file_name_lookup and
11 file_get_storage_info to implement grub_guess_root_device.
12
26a61d6a
FZ
132009-11-21 Felix Zielcke <fzielcke@z-51.de>
14
15 * Makefile.in (target): Use make's builtin $(shell) function
16 instead of calling directly $(SHELL) to create the locale directories,
17 inside the $(foreach) function.
18
74ff1dd5
FZ
192009-11-21 Felix Zielcke <fzielcke@z-51.de>
20
21 * util/grub-mkrescue.in: Print an error and usage if output option
22 has not been given.
23
0b787d0e
FZ
242009-11-21 Felix Zielcke <fzielcke@z-51.de>
25
26 Patch from Loïc Minier <loic.minier@ubuntu.com>.
27 * util/grub.d/30_os-prober.in: Cope with Linux entries where
28 root and /boot are on different devices.
29
1164b270
RM
302009-11-21 Robert Millan <rmh.grub@aybabtu.com>
31
32 Fix build for srcdir != objdir.
33
34 * Makefile.in (po/$(PACKAGE).pot): Rename to ...
35 ($(srcdir)/po/$(PACKAGE).pot): ... this. Run $(XGETTEXT) from
36 $(srcdir).
37 ($(foreach lang, $(LINGUAS), po/$(lang).po)): Rename to ...
38 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po): ... this. Use $^
39 reference for input.
40
13774a2f
RM
412009-11-21 Robert Millan <rmh.grub@aybabtu.com>
42
43 * util/grub-mkrescue.in: Use source directory direcly (without copiing
44 or hardlinking it). Remove -J option, Joliet is not compatible with
45 multiple source directories.
46
efda854e
RM
472009-11-21 Carles Pina i Estany <carles@pina.cat>
482009-11-21 Robert Millan <rmh.grub@aybabtu.com>
49
50 * util/grub-mkrescue.in: Recognize `--override-directory' option.
51 (process_input_dir): New function. Process an arbitrary input
52 directory.
53 Misc adjustments to support both "override mode" and system-wide mode.
54
6c09890c
FZ
552009-11-20 Felix Zielcke <fzielcke@z-51.de>
56
57 * configure.ac (UNIFONT_BDF): Rename to ...
58 (FONT_SOURCE): ... this. Update all users.
59
a797824f
FZ
602009-11-20 Felix Zielcke <fzielcke@z-51.de>
61
62 * configure.ac: Add `/usr/share/fonts/X11/misc/unifont.pcf.gz'
63 to the list of unifont files to look for.
64
cd4f42b0
RM
652009-11-19 Robert Millan <rmh.grub@aybabtu.com>
66
67 Patch from Joe Auricchio <jauricchio@gmail.com>
68 * commands/minicmd.c (grub_mini_cmd_clear): New function.
69 (GRUB_MOD_INIT(minicmd)): Register grub_mini_cmd_clear().
70 (GRUB_MOD_FINI(minicmd)): Unregister grub_mini_cmd_clear().
71
393c783d
FZ
722009-11-19 Felix Zielcke <fzielcke@z-51.de>
73
74 * Makefile.in (install-local): Add a missing backslash.
75
b2f1e327
FZ
762009-11-19 Felix Zielcke <fzielcke@z-51.de>
77
78 * include/grub/x86_64/io.h: New file.
79
f577f7a0
RM
802009-11-19 Robert Millan <rmh.grub@aybabtu.com>
81
82 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `gnulib/progname.c'.
83 * util/i386/pc/grub-setup.c: Include `<grub/i18n.h>'.
84 Include `"progname.h"'.
85 (main): Initialize gettext.
86 * util/i386/pc/grub-setup.c: Gettexttize.
87 * util/i386/pc/grub-mkimage.c: Likewise.
88
89 * Makefile.in (po/*.po): Redefine as ...
90 ($(foreach lang, $(LINGUAS), po/$(lang).po)): ... this.
91
92 * po/POTFILES: Add `util/i386/pc/grub-setup.c'.
93
c37943b6
RM
942009-11-19 Robert Millan <rmh.grub@aybabtu.com>
95
96 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/progname.c'.
97 * util/mkisofs/mkisofs.c: Include `"progname.h"'.
98 (program_name): Remove.
99 (main): Initialize gettext support.
6323f705
RM
100 * util/mkisofs/mkisofs.h: Include `<locale.h>'.
101 Include `<libintl.h>'.
102 (_): New macro.
c37943b6
RM
103
104 * util/mkisofs/eltorito.c: Gettexttize.
105 * util/mkisofs/joliet.c: Likewise.
106 * util/mkisofs/mkisofs.c: Likewise.
c37943b6
RM
107 * util/mkisofs/multi.c: Likewise.
108 * util/mkisofs/rock.c: Likewise.
109 * util/mkisofs/tree.c: Likewise.
110 * util/mkisofs/write.c: Likewise.
111
112 * po/POTFILES: Update with new files.
113
5ce77c6e
RM
1142009-11-18 Robert Millan <rmh.grub@aybabtu.com>
115
116 * util/mkisofs/eltorito.c: Fix minor mistake in license text.
117 * util/mkisofs/iso9660.h: Likewise.
118 * util/mkisofs/joliet.c: Likewise.
119 * util/mkisofs/mkisofs.c: Likewise.
120 * util/mkisofs/mkisofs.h: Likewise.
121 * util/mkisofs/rock.c: Likewise.
122 * util/mkisofs/tree.c: Likewise.
123 * util/mkisofs/write.c: Likewise.
124
125 * util/mkisofs/eltorito.c (rcsid): Remove.
126 * util/mkisofs/hash.c: Likewise.
127 * util/mkisofs/joliet.c: Likewise.
128 * util/mkisofs/name.c: Likewise.
129 * util/mkisofs/rock.c: Likewise.
130 * util/mkisofs/tree.c: Likewise.
131 * util/mkisofs/write.c: Likewise.
132
1dabbc77
RM
1332009-11-18 Robert Millan <rmh.grub@aybabtu.com>
134
135 * util/mkisofs/match.c: Rewrite from scratch, using a linked list
136 instead of static allocation.
137 * util/mkisofs/match.h: Likewise.
138
633877cb
RM
1392009-11-18 Robert Millan <rmh.grub@aybabtu.com>
140
141 * po/POTFILES-shell: New file. List `util/grub.d/10_kfreebsd.in'
142 and `util/grub.d/10_linux.in'.
143 * Makefile.in (po/$(PACKAGE).pot): Process `po/POTFILES-shell' for
144 translatable Shell files.
145
af1c0c85
RM
1462009-11-18 Robert Millan <rmh.grub@aybabtu.com>
147
148 * Makefile.in ($(srcdir)/aclocal.m4): New target.
149
769ae37b
RM
1502009-11-17 Robert Millan <rmh.grub@aybabtu.com>
151
152 * INSTALL: Document Automake is needed for bootstrap.
153 * po/ca.po: Fix PO-Revision-Date and Language-Team fields.
154 * util/grub.d/10_kfreebsd.in (bindir): New variable.
155 Add gettext initialization.
156 (kfreebsd_entry): Make menuentry output translatable.
157
1582009-11-17 Robert Millan <rmh.grub@aybabtu.com>
159
160 * Makefile.in (XGETTEXT, MSGMERGE, MSGFMT): New variables.
161 (po/$(PACKAGE).pot): Replace `xgettext' with `$(XGETTEXT)'.
162 (po/*.po): Replace `msgmerge' with `$(MSGMERGE)'.
163 (po/%.mo): Replace `msgfmt' with `$(MSGFMT)'.
164 (LINGUAS): Auto-generate using `po/LINGUAS'.
165 * po/LINGUAS: New file.
166
1672009-11-17 Robert Millan <rmh.grub@aybabtu.com>
168
169 * configure.ac: Call AM_GNU_GETTEXT() (defines localedir, among
170 other things).
171 * Makefile.in (CPPFLAGS): Add `-DLOCALEDIR=\"$(localedir)\"'.
172 * util/i386/pc/grub-mkimage.c (main): Issue setlocale() and
173 bindtextdomain() calls for gettext initialization.
174
1752009-11-17 Robert Millan <rmh.grub@aybabtu.com>
176
177 * gnulib/progname.c: New file (imported from Gnulib).
178 * gnulib/progname.h: Likewise.
179 * conf/i386-pc.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
180 * util/i386/pc/grub-mkimage.c: Include `"progname.h"'.
181 (usage): Replace `progname' with `program_name'.
182 (main): Use set_program_name() for program name initialization.
183
1842009-11-17 Robert Millan <rmh.grub@aybabtu.com>
185
186 * conf/common.rmk (grub_mkisofs_CFLAGS): Move `-I$(srcdir)/gnulib'
187 from here ...
188 * Makefile.in (CPPFLAGS): ... to here.
189
1902009-11-16 Robert Millan <rmh.grub@aybabtu.com>
191
192 * aclocal.m4: Move from here ...
193 * acinclude.m4: ... to here.
194 * autogen.sh: Add call to `aclocal'.
195 * configure.ac: Add AM_INIT_AUTOMAKE() after AC_INIT() call.
196
1972009-11-16 Robert Millan <rmh.grub@aybabtu.com>
198
199 * Makefile.in (CLEANFILES): Add `po/*.mo'.
200 (LINGUAS): New variable.
201 (all-local): Add `$(foreach lang, $(LINGUAS), po/$(lang).mo)'.
202 (install-local): Install MO files.
203 (po/$(PACKAGE).pot, po/*.po, po/%.mo): New rules.
204 * include/grub/i18n.h: New file.
205 * po/POTFILES: New file.
206 * po/ca.po: New file.
207 * util/grub.d/10_linux.in (bindir): New variable.
208 Add gettext initialization.
209 (linux_entry): Make menuentry output translatable.
210 * util/i386/pc/grub-mkimage.c: Include `<grub/i18n.h>'.
211 (usage): Make --help output translatable.
212 (main): Initialize gettext.
213
02c0a6ad
RM
2142009-11-17 Robert Millan <rmh.grub@aybabtu.com>
215
216 * import_gcry.py: New file (written by Vladimir with minor
217 adjustments).
218 * autogen.sh: Use import_gcry.py to auto-generate GRUB-ified
219 ciphers.
220 * INSTALL: Document that Python is required for bootstrap.
221
2222009-11-17 Robert Millan <rmh.grub@aybabtu.com>
223
224 Import ciphers from libgcrypt 1.4.4.
225
226 * lib/libgcrypt/cipher/ChangeLog
227 * lib/libgcrypt/cipher/ac.c
228 * lib/libgcrypt/cipher/arcfour.c
229 * lib/libgcrypt/cipher/bithelp.h
230 * lib/libgcrypt/cipher/blowfish.c
231 * lib/libgcrypt/cipher/camellia-glue.c
232 * lib/libgcrypt/cipher/camellia.c
233 * lib/libgcrypt/cipher/camellia.h
234 * lib/libgcrypt/cipher/cast5.c
235 * lib/libgcrypt/cipher/cipher.c
236 * lib/libgcrypt/cipher/crc.c
237 * lib/libgcrypt/cipher/des.c
238 * lib/libgcrypt/cipher/dsa.c
239 * lib/libgcrypt/cipher/ecc.c
240 * lib/libgcrypt/cipher/elgamal.c
241 * lib/libgcrypt/cipher/hash-common.c
242 * lib/libgcrypt/cipher/hash-common.h
243 * lib/libgcrypt/cipher/hmac-tests.c
244 * lib/libgcrypt/cipher/md.c
245 * lib/libgcrypt/cipher/md4.c
246 * lib/libgcrypt/cipher/md5.c
247 * lib/libgcrypt/cipher/primegen.c
248 * lib/libgcrypt/cipher/pubkey.c
249 * lib/libgcrypt/cipher/rfc2268.c
250 * lib/libgcrypt/cipher/rijndael-tables.h
251 * lib/libgcrypt/cipher/rijndael.c
252 * lib/libgcrypt/cipher/rmd.h
253 * lib/libgcrypt/cipher/rmd160.c
254 * lib/libgcrypt/cipher/rsa.c
255 * lib/libgcrypt/cipher/seed.c
256 * lib/libgcrypt/cipher/serpent.c
257 * lib/libgcrypt/cipher/sha1.c
258 * lib/libgcrypt/cipher/sha256.c
259 * lib/libgcrypt/cipher/sha512.c
260 * lib/libgcrypt/cipher/tiger.c
261 * lib/libgcrypt/cipher/twofish.c
262 * lib/libgcrypt/cipher/whirlpool.c
263
af2f93ac
RM
2642009-11-16 Robert Millan <rmh.grub@aybabtu.com>
265
266 Fix build for systems without error().
267
268 * gnulib/error.c: New file (imported from Gnulib).
269 * gnulib/error.h: Likewise.
270 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/error.c'.
271 * util/mkisofs/mkisofs.c (program_name): Remove `static' qualifier
272 (this variable is now used by error()).
273
73fb3dd5
FZ
2742009-11-16 Felix Zielcke <fzielcke@z-51.de>
275
814f5e96
FZ
276 * util/mkisofs/name.c (iso9660_file_length): Use isascii macro
277 instead of relying that char is signed.
73fb3dd5 278
a691ca33
VS
2792009-11-16 Vladimir Serbinenko <phcoder@gmail.com>
280
281 * fs/i386/pc/pxe.c (grub_pxefs_open): Correctly handle PXE choosing
282 blocksize different from specified.
283 (grub_pxefs_read): Likewise.
284
2af8f0f4
FZ
2852009-11-16 Felix Zielcke <fzielcke@z-51.de>
286
287 Enable ata.mod on x86_64-efi, i386-efi and i386-ieee1275.
288
289 * disk/ata.c (grub_ata_dumpinfo): Add a cast.
290 (grub_ata_readwrite): Likewise. Update 2 format strings.
291 (grub_atapi_read): Likewise.
292
293 * conf/i386-coreboot.rmk (pkglib_MODULES): Move `ata.mod' from here ...
294 * conf/i386.rmk (pkglib_MODULES): ... to here ...
295 * conf/x86_64-efi.rmk (pkglib_MODULES): ... and here.
296 * conf/i386-coreboot.rmk (ata_mod_SOURCES, ata_mod_CFLAGS)
297 (ata_mod_LDFLAGS): Move from here ...
298 * conf/i386.rmk: ... to here ...
299 * conf/x86_64-efi.rmk: ... and here.
300 * conf/i386-pc.rmk (pkglib_MODULES): Remove `ata.mod'
301 (ata_mod_SOURCES, ata_mod_CFLAGS, ata_mod_LDFLAGS): Remove.
302
83bdecaf
RM
3032009-11-16 Robert Millan <rmh.grub@aybabtu.com>
304
305 Relicense multiboot.h, with RMS' blessing.
306
307 * include/multiboot.h: Change to X11 license.
308
fd6fd3d7
RM
3092009-11-15 Robert Millan <rmh.grub@aybabtu.com>
310
311 Support --version in grub-mkisofs.
312
313 * util/mkisofs/mkisofs.c (rcsid): Remove variable.
314 (OPTION_VERSION): New macro.
315 (ld_options): Recognize --version.
316 (usage): Move `program_name' from here ...
317 (program_name): ... to here. Add `static' qualifier.
318 (main): Recognize `OPTION_VERSION'.
319
16a88c49
FZ
3202009-11-15 Felix Zielcke <fzielcke@z-51.de>
321
322 * Makefile.in (TARGET_CPPFLAGS): Replace `-isystem=$(srcdir)/include'
323 with `-nostdinc -isystem $(shell $(TARGET_CC) -print-file-name=include)'.
324
a4158476
RM
3252009-11-14 Robert Millan <rmh.grub@aybabtu.com>
326
327 Fix help2man generation for mkisofs.
328
329 * util/mkisofs/mkisofs.c (ld_options): Recognize --help.
330 (usage): Send output to stdout (rather than stderr).
331
fc2208b0
RM
3322009-11-14 Robert Millan <rmh.grub@aybabtu.com>
333
334 * conf/i386-coreboot.rmk (grub_mkrescue_SOURCES): Replace
335 `util/i386/coreboot/grub-mkrescue.in' with `util/grub-mkrescue.in'.
336 * conf/i386-pc.rmk (grub_mkrescue_SOURCES): Replace
337 `util/i386/pc/grub-mkrescue.in' with `util/grub-mkrescue.in'.
338 (bin_SCRIPTS): Add `grub-mkfloppy'.
339 (grub_mkfloppy_SOURCES): New variable.
340
341 * util/grub-mkrescue.in: New file.
342 * util/i386/pc/grub-mkfloppy.in: New file.
343
344 * util/i386/coreboot/grub-mkrescue.in: Remove.
345 * util/i386/pc/grub-mkrescue.in: Remove.
346
8d0edf4a
RM
3472009-11-13 Robert Millan <rmh.grub@aybabtu.com>
348
349 * include/grub/multiboot.h (struct grub_multiboot_header): Move
350 from here ...
351 * include/multiboot.h (struct multiboot_header): ... to here. Update
352 all users.
353 * include/grub/multiboot.h (struct grub_multiboot_info): Move
354 from here ...
355 * include/multiboot.h (struct multiboot_info): ... to here. Update
356 all users.
357 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): Move
358 from here ...
359 * include/multiboot.h (struct multiboot_mmap_entry): ... to here.
360 Update all users.
361 * include/grub/multiboot.h (struct grub_mod_list): Move
362 from here ...
363 * include/multiboot.h (struct multiboot_mod_list): ... to here.
364 Update all users.
365
a73f5969
RM
3662009-11-13 Robert Millan <rmh.grub@aybabtu.com>
367
368 * include/multiboot2.h (multiboot_word): Rename from this ...
369 (multiboot2_word): ... to this. Update all users.
370 (multiboot_header): Rename from this ...
371 (multiboot2_header): ... to this. Update all users.
372 (multiboot_tag_header): Rename from this ...
373 (multiboot2_tag_header): ... to this. Update all users.
374 (multiboot_tag_start): Rename from this ...
375 (multiboot2_tag_start): ... to this. Update all users.
376 (multiboot_tag_name): Rename from this ...
377 (multiboot2_tag_name): ... to this. Update all users.
378 (multiboot_tag_module): Rename from this ...
379 (multiboot2_tag_module): ... to this. Update all users.
380 (multiboot_tag_memory): Rename from this ...
381 (multiboot2_tag_memory): ... to this. Update all users.
382 (multiboot_tag_unused): Rename from this ...
383 (multiboot2_tag_unused): ... to this. Update all users.
384 (multiboot_tag_end): Rename from this ...
385 (multiboot2_tag_end): ... to this. Update all users.
386
1c8927f0
RM
3872009-11-13 Robert Millan <rmh.grub@aybabtu.com>
388
389 Disable Multiboot2 in i386-ieee1275. It didn't actually work, and on
390 this platform we should support Multiboot1 first.
391
392 * conf/i386-ieee1275.rmk (pkglib_MODULES): Remove `multiboot.mod'.
393 (multiboot_mod_SOURCES, multiboot_mod_CFLAGS)
394 (multiboot_mod_LDFLAGS, multiboot_mod_ASFLAGS): Remove.
395
6e1e0d89
RM
3962009-11-12 Robert Millan <rmh.grub@aybabtu.com>
397
398 * util/mkisofs/eltorito.c (init_boot_catalog): Handle return code
399 of write calls (converting them to fwrite() if they aren't already).
400 (get_torito_desc): Likewise.
401 * util/mkisofs/rock.c (generate_rock_ridge_attributes): Likewise.
402
7f2b34d8
RM
4032009-11-12 Robert Millan <rmh.grub@aybabtu.com>
404
405 * util/i386/pc/grub-install.in: Move from here ...
406 * util/grub-install.in: ... to here. Update all users.
407
c0ef3311
CW
4082009-11-11 Colin Watson <cjwatson@ubuntu.com>
409
410 * util/powerpc/ieee1275/grub-mkrescue.in: Fix --version output.
411
e1f240ff
RM
4122009-11-11 Robert Millan <rmh.grub@aybabtu.com>
413
414 Support for El Torito without floppy emulation.
415
416 * util/mkisofs/eltorito.c: Include `<errno.h>'.
417 (init_boot_catalog): Improve error handling.
418 (get_torito_desc): Don't use floppy emulation unless requested by
419 user. Patch boot information table when requested via
420 `-boot-info-table'.
421 * util/mkisofs/iso9660.h (struct eltorito_boot_info): New struct.
422 * util/mkisofs/mkisofs.c (use_eltorito_emul_floppy)
423 (use_boot_info_table): New variables.
424 (OPTION_BOOT_INFO_TABLE, OPTION_NO_EMUL_BOOT)
425 (OPTION_ELTORITO_EMUL_FLOPPY): New macros.
426 (ld_options): Handle `-boot-info-table', `-no-emul-boot' and
427 `--eltorito-emul-floppy'.
428 (main): Handle `OPTION_BOOT_INFO_TABLE', `OPTION_NO_EMUL_BOOT'
429 and `OPTION_ELTORITO_EMUL_FLOPPY'.
430 * util/mkisofs/mkisofs.h (use_eltorito_emul_floppy)
431 (use_boot_info_table, get_731): New prototypes.
432 * util/mkisofs/write.c (get_731): New function.
433
af7d4de5
FZ
4342009-11-11 Felix Zielcke <fzielcke@z-51.de>
435
436 Fix the generation of the man page.
437
438 * util/pc/i386/grub-install.in: Source
439 `${libdir}/grub/grub-mkconfig_lib' after options have been parsed.
440
2c55dbc0
RM
4412009-11-11 Robert Millan <rmh.grub@aybabtu.com>
442
443 Large file support for grub-mkisofs.
444
445 * conf/common.rmk (grub_mkisofs_CFLAGS): Add `-D_FILE_OFFSET_BITS=64'.
446 * util/mkisofs/mkisofs.c (next_extent, last_extent)
447 (session_start): Upgrade type to `uint64_t'. Update all users.
448 * util/mkisofs/mkisofs.h: Include `<stdint.h>'.
449 (struct directory_entry): Upgrade type of `starting_block' and
450 `size' to `uint64_t'. Update all users.
451 (struct deferred): Remove unused structure.
452 (xfwrite): Upgrade type of `count' and `size' to `uint64_t'.
453 Update all users.
454 * util/mkisofs/tree.c (stat_filter, lstat_filter): Return -1 when
455 file is larger than `UINT32_MAX'.
456 * util/mkisofs/write.c (xfwrite): Upgrade type of `count' and
457 `size' to `uint64_t'. Update all users. Fix handling of fwrite()
458 return value.
459 (struct deferred_write): Upgrade type of `extent' and `size' to
460 `uint64_t'. Update all users.
461 (last_extent_written): Upgrade type to `uint64_t'. Update all
462 users.
463 (write_one_file): Upgrade type of `count' and `size' to `uint64_t'.
464 Update all users. Upgrade type of `remain' to `int64_t' and
465 `use' to `size_t'. Use error() to handle fread() errors.
466 (write_files): Rely on write_one_file() rather than calling
467 xfwrite() directly.
468
6a9cead5
FZ
4692009-11-09 Felix Zielcke <fzielcke@z-51.de>
470
471 * util/mkisofs/mkisofs.c (ld_options): Fix a spelling mistake.
472
4825d790
RM
4732009-11-09 Robert Millan <rmh.grub@aybabtu.com>
474
475 * util/mkisofs/fnmatch.c: Remove.
476 * util/mkisofs/getopt1.c: Likewise.
477 * util/mkisofs/getopt.c: Likewise.
478 * conf/common.rmk (grub_mkisofs_SOURCES): Replace
479 `util/mkisofs/fnmatch.c', `util/mkisofs/getopt1.c' and
480 `util/mkisofs/getopt.c' with `gnulib/fnmatch.c',
481 `gnulib/getopt1.c' and `gnulib/getopt.c'.
482 (grub_mkisofs_CFLAGS): Add `-I$(srcdir)/gnulib'.
483
484 * configure.ac: Detect `mingw32msvc' host_os.
485 Check for lstat(), getuid() and getgid().
486
487 * util/mkisofs/joliet.c: Include `<stdint.h>'. Replace all
488 instances of `u_char' with `uint8_t'.
489
490 * util/mkisofs/mkisofs.h: Include `<sys/stat.h>'.
491 [!HAVE_GETUID] (getuid): New function (stub).
492 [!HAVE_GETGID] (getgid): Likewise.
493 [!HAVE_LSTAT] (lstat): Likewise.
494 [!S_IROTH] (S_IROTH): New macro (dummy).
495 [!S_IRGRP] (S_IRGRP): Likewise.
496
84b860d8
RM
4972009-11-09 Robert Millan <rmh.grub@aybabtu.com>
498
499 * gnulib/fnmatch_loop.c (EXT): Fix warning (signed and unsigned type in
500 conditional expression).
501
66e9b712
RM
5022009-11-09 Robert Millan <rmh.grub@aybabtu.com>
503
504 Import from Gnulib.
505
506 * gnulib/fnmatch.c: New file.
507 * gnulib/fnmatch.h: Likewise.
508 * gnulib/fnmatch_loop.c: Likewise.
509 * gnulib/getopt.c: Likewise.
510 * gnulib/getopt.h: Likewise.
511 * gnulib/getopt1.c: Likewise.
512 * gnulib/getopt_int.h: Likewise.
513 * gnulib/gettext.h: Likewise.
514
34f4a5b0
RM
5152009-11-09 Robert Millan <rmh.grub@aybabtu.com>
516
517 * normal/dyncmd.c (read_command_list): Replace `0' with `NULL'.
518 * normal/handler.c (read_handler_list): Likewise.
519
ac451143
RM
5202009-11-09 Robert Millan <rmh.grub@aybabtu.com>
521
522 Misc cleanup.
523
524 * kern/command.c (grub_register_command_prio): Use
525 grub_zalloc() instead of explicitly zeroing data.
526 * kern/list.c: Include `<grub/mm.h>'.
527 (grub_named_list_find): Replace `0' with `NULL'.
528 * normal/autofs.c (struct grub_fs_module_list): Remove ad-hoc type.
529 (fs_module_list): Change type to `grub_named_list_t'. Update all
530 users.
531 * normal/dyncmd.c (read_command_list): Add space between function
532 call and parenthesis.
533 * normal/handler.c (read_handler_list): Likewise.
534
4089b167
RM
5352009-11-09 Robert Millan <rmh.grub@aybabtu.com>
536
537 * normal/auth.c (punishment_delay): Moved from here ...
538 (grub_auth_strcmp): ... to here (inside function).
539
325f5037
RM
5402009-11-09 Robert Millan <rmh.grub@aybabtu.com>
541
542 * include/grub/list.h (struct grub_named_list): Remove `const'
543 qualifier from `name'.
544 (struct grub_prio_list): Likewise.
545
7aea29a3
RM
5462009-11-09 Robert Millan <rmh.grub@aybabtu.com>
547
548 * normal/auth.c: Include `<grub/time.h>'.
549 (grub_auth_strcmp): Replace `strcmp' with `grub_strcmp'.
550
3fd6f044
RM
5512009-11-09 Robert Millan <rmh.grub@aybabtu.com>
552
553 * normal/auth.c (punishment_delay): New variable.
554 (grub_auth_strcmp): Rewrite using grub_get_time_ms ().
555 (grub_auth_check_authentication): Punish failed login attempts with
556 an incremental (2^N) delay.
557
a4cd68e4
RM
5582009-11-09 Robert Millan <rmh.grub@aybabtu.com>
559
560 * conf/common.rmk (grub_mkisofs_CFLAGS): Prefix include
561 path with $(srcdir).
562
7ad12f43
VS
5632009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
564
565 * normal/auth.c (grub_auth_strcmp): Fixed incorrect variable usage.
566
c1129f03
RM
5672009-11-09 Robert Millan <rmh.grub@aybabtu.com>
568
569 * util/i386/coreboot/grub-mkrescue.in: New file.
570 * conf/i386-coreboot.rmk (bin_SCRIPTS, grub_mkrescue_SOURCES): New
571 variables.
572
573 * conf/common.rmk (bin_UTILITIES): Add `grub-mkisofs'.
574 (grub_mkisofs_SOURCES, grub_mkisofs_CFLAGS): New variables.
575 * configure.ac: Add header and function checks to satisfy grub-mkisofs
576 requirements.
577 * util/mkisofs/defaults.h: New file.
578 * util/mkisofs/eltorito.c: Likewise.
579 * util/mkisofs/exclude.h: Likewise.
580 * util/mkisofs/fnmatch.c: Likewise.
581 * util/mkisofs/getopt.c: Likewise.
582 * util/mkisofs/getopt1.c: Likewise.
583 * util/mkisofs/hash.c: Likewise.
584 * util/mkisofs/include/fctldefs.h: Likewise.
585 * util/mkisofs/include/mconfig.h: Likewise.
586 * util/mkisofs/include/prototyp.h: Likewise.
587 * util/mkisofs/include/statdefs.h: Likewise.
588 * util/mkisofs/iso9660.h: Likewise.
589 * util/mkisofs/joliet.c: Likewise.
590 * util/mkisofs/match.c: Likewise.
591 * util/mkisofs/match.h: Likewise.
592 * util/mkisofs/mkisofs.c: Likewise.
593 * util/mkisofs/mkisofs.h: Likewise.
594 * util/mkisofs/multi.c: Likewise.
595 * util/mkisofs/name.c: Likewise.
596 * util/mkisofs/rock.c: Likewise.
597 * util/mkisofs/tree.c: Likewise.
598 * util/mkisofs/write.c: Likewise.
599
ec8bb77d
VS
6002009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
601
602 * normal/auth.c (grub_auth_strcmp): Fix bug which resulted in function
603 being insecure.
604
3716b12c
RM
6052009-11-08 Robert Millan <rmh.grub@aybabtu.com>
606
607 * util/i386/pc/grub-mkrescue.in: Fix miss-identification as
608 `grub-mkimage' (and use $0 when possible).
609
b97b7b91
RM
6102009-11-08 Robert Millan <rmh.grub@aybabtu.com>
611
612 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve
613 error message for excessively large memory map.
614
04114812
RM
6152009-11-08 Robert Millan <rmh.grub@aybabtu.com>
616
617 * autogen.sh: Use `sh gendistlist.sh' to avoid reliing on
618 executable bit.
619
e4eb2373
RM
6202009-11-08 Robert Millan <rmh.grub@aybabtu.com>
621
622 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve error
623 message for coreboot users.
624
c926e1d5 6252009-11-07 Robert Millan <rmh.grub@aybabtu.com>
626
627 Fix build with GNU gold.
628
629 * conf/i386-pc.rmk (boot_img_LDFLAGS, pxeboot_img_LDFLAGS)
630 (diskboot_img_LDFLAGS, lnxboot_img_LDFLAGS)
631 (cdboot_img_LDFLAGS): Prepend `0x' qualifier to hexadecimal
632 link addresses.
633 * aclocal.m4: Likewise.
634
86e5b1db 6352009-11-04 Felix Zielcke <fzielcke@z-51.de>
636
637 * configure.ac (AC_PREREQ): Bump to 2.59d.
638 * INSTALL: Make it more clear when Autoconf and Ruby are
639 needed and when to run `./autogen.sh'.
640
246cd78f 6412009-11-03 Samuel Thibault <samuel.thibault@ens-lyon.org>
642
643 * util/grub.d/30_os-prober.in: Restore default behavior for unsupported
644 OSes.
645
4f9dfb37 6462009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
647
648 * util/grub.d/30_os-prober.in: Add GNU/Hurd support
649
b82bd5e1 6502009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
651
652 * util/grub.d/10_hurd.in: Drop /dev/ prefix from root device path before
653 giving it to GNU Mach.
654
ff1a9bca 6552009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
656
657 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Subtract 1 from
658 GNU partition number to get internal GRUB partition number.
659
61697d9c 6602009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
661
662 * util/grub.d/10_hurd.in: Call prepare_grub_to_access_device
663 ${GRUB_DEVICE_BOOT} before loading /boot kernel.
664
a50569e1 6652009-11-01 Robert Millan <rmh.grub@aybabtu.com>
666
667 Based on patch from BVK Chaitanya <bvk.groups@gmail.com>
668 * kern/misc.c (grub_strchr, grub_strrchr): Fix to handle c == '\0'
669 case.
670
5b153867 6712009-11-01 Felix Zielcke <fzielcke@z-51.de>
672
673 * Makefile.in (TARGET_CPPFLAGS): Add `-I$(srcdir)/include'.
674
d9e2cd70 6752009-10-30 Robert Millan <rmh.grub@aybabtu.com>
676
677 Fix build problem.
678
679 * Makefile.in (TARGET_CPPFLAGS): Replace `-nostdinc' with
680 `-isystem=$(srcdir)/include'.
681
805111a4 6822009-10-30 Robert Millan <rmh.grub@aybabtu.com>
683
684 * util/i386/pc/grub-install.in: Remove hint that device.map should be
685 checked (grub-install doesn't currently rely on it).
686
fa6e945f 6872009-10-29 Robert Millan <rmh.grub@aybabtu.com>
688
689 Revert SVN r2660.
690
691 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): Moved from here ...
692 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
693 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): ... and here.
694 * conf/i386-ieee1275.rmk: Likewise.
695 * conf/i386-pc.rmk: Likewise.
696 * conf/powerpc-ieee1275.rmk: Likewise.
697 * conf/sparc64-ieee1275.rmk: Likewise.
698 * conf/x86_64-efi.rmk: Likewise.
699
cee15086 7002009-10-28 Robert Millan <rmh.grub@aybabtu.com>
701
702 * Makefile.in (TARGET_CPPFLAGS): Add `-nostdinc'.
703
95b9239e 7042009-10-28 Robert Millan <rmh.grub@aybabtu.com>
705
706 * include/grub/misc.h: Stop checking for APPLE_CC.
707
2ed19dfd 7082009-10-28 Robert Millan <rmh.grub@aybabtu.com>
709
710 * kern/i386/coreboot/init.c (grub_exit): Reimplement in a way that
711 doesn't cause an infinite call loop.
712
fdcdde19 7132009-10-28 Felix Zielcke <fzielcke@z-51.de>
714
715 * commands/acpi.c (grub_cmd_acpi): Fix the out of memory error
716 strings.
717
cefabfe1 7182009-10-26 Robert Millan <rmh.grub@aybabtu.com>
719
720 * autogen.sh: Support addition of external modules via `GRUB_CONTRIB'
721 variable.
722 * Makefile.in: Likewise.
723
ed96ab6d 7242009-10-26 Robert Millan <rmh.grub@aybabtu.com>
725
726 * gendistlist.sh: Simplify .svn check. Skip .bzr as well.
727
0579b753 7282009-10-26 Robert Millan <rmh.grub@aybabtu.com>
729
730 * Makefile.in (RMKFILES): Rewrite using $(wildcard).
731
478df409 7322009-10-26 Robert Millan <rmh.grub@aybabtu.com>
733
734 * disk/scsi.c: Remove `<grub/machine/kernel.h>' (not needed).
735
083d1679 7362009-10-26 Robert Millan <rmh.grub@aybabtu.com>
737
738 * gensymlist.sh.in (COMPILE_TIME_ASSERT): Copy macro declaration
739 from here ...
740 * include/grub/misc.h (COMPILE_TIME_ASSERT): ... to here.
741
5947ae32 7422009-10-26 Robert Millan <rmh.grub@aybabtu.com>
743
744 * Makefile.in (docs/grub.info): Use make syntax to ignore errors
745 in $(MAKEINFO) invocation. This makes it clear in output that
746 errors are being ignored.
747
94180ff6 7482009-10-26 Robert Millan <rmh.grub@aybabtu.com>
749
750 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): Moved
751 from here ...
752 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
753 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): Remove.
754 * conf/i386-ieee1275.rmk: Likewise.
755 * conf/i386-pc.rmk: Likewise.
756 * conf/powerpc-ieee1275.rmk: Likewise.
757 * conf/sparc64-ieee1275.rmk: Likewise.
758 * conf/x86_64-efi.rmk: Likewise.
759
9031b03a 7602009-10-26 Colin Watson <cjwatson@ubuntu.com>
761
762 * util/grub-editenv.c (main): If only a command is given, use
763 DEFAULT_DIRECTORY "/" GRUB_ENVBLK_DEFCFG as a default file name.
764 (usage): FILENAME is now optional and has a default.
765
e4f6809b 7662009-10-26 Colin Watson <cjwatson@ubuntu.com>
767
768 Improve grub-mkconfig performance when there are several menu
769 entries on a single filesystem.
770
771 * util/grub.d/10_linux.in (linux_entry): Cache the output of
772 prepare_grub_to_access_device.
773 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
774 * util/grub.d/30_os-prober.in: Likewise.
775
67937d4d 7762009-10-26 Robert Millan <rmh.grub@aybabtu.com>
777
778 * util/grub.d/10_freebsd.in: Remove.
779 * util/grub.d/10_kfreebsd.in: New file (based on 10_linux.in).
780 * configure.ac: Set host_kernel=kfreebsd for FreeBSD and GNU/kFreeBSD.
781
ee3756cc 7822009-10-26 Robert Millan <rmh.grub@aybabtu.com>
783
5c35048e 784 * docs/grub.cfg: Fix example usage of *BSD loaders.
ee3756cc 785
4dea1c6f 7862009-10-25 Robert Millan <rmh.grub@aybabtu.com>
787
788 * util/i386/pc/grub-setup.c (setup): Add missing parameter to
789 grub_util_error() call.
790
042484d7 7912009-10-25 Robert Millan <rmh.grub@aybabtu.com>
792
793 * include/grub/fs.h [GRUB_UTIL] (struct grub_fs): Add
794 `reserved_first_sector' member.
795 * fs/ext2.c [GRUB_UTIL] (grub_ext2_fs): Initialize
796 `reserved_first_sector' to 1.
797 * fs/fat.c [GRUB_UTIL] (grub_fat_fs): Likewise.
798 * fs/ntfs.c [GRUB_UTIL] (grub_ntfs_fs): Likewise.
799 * fs/hfsplus.c [GRUB_UTIL] (grub_hfsplus_fs): Likewise.
800 * util/i386/pc/grub-setup.c (setup): Add safety check that probes for
801 filesystems which begin at first sector.
802 (options): New option --skip-fs-probe.
803 (main): Handle --skip-fs-probe and pass it to setup().
804
d64448a7 8052009-10-25 Robert Millan <rmh.grub@aybabtu.com>
806
807 * include/grub/misc.h: Fix wrong evaluation of APPLE_CC.
808 (memset): Fix function prototype.
809
508d42ec 8102009-10-25 Robert Millan <rmh.grub@aybabtu.com>
8112009-10-25 Vasily Averin <vvs@parallels.com>
812
813 * fs/ext2.c (grub_ext2_iterate_dir): Avoid infinite loop when
814 `dirent.direntlen == 0'.
815
b240e30c 8162009-10-25 Robert Millan <rmh.grub@aybabtu.com>
817
818 * fs/cpio.c [MODE_USTAR]: Initialize `tar' module instead of
819 `cpio'.
820 [! MODE_USTAR]: Initialize `cpio' module instead of `tar'.
821
346e7fbe 8222009-10-25 Robert Millan <rmh.grub@aybabtu.com>
823
824 * configure.ac: Check for `__ashldi3', `__ashrdi3', `__lshrdi3',
825 `__trampoline_setup' and `__ucmpdi2'.
826 * include/grub/powerpc/libgcc.h: Only export symbols for functions
827 that libgcc provides.
828
cdb308b0 8292009-10-25 Robert Millan <rmh.grub@aybabtu.com>
830
831 * include/grub/powerpc/libgcc.h (memset): Remove function prototype.
832 * include/grub/sparc64/libgcc.h (memset): Likewise.
833 * include/grub/misc.h (memset, memcmp): New function prototypes.
834
fb26abc2 8352009-10-25 Robert Millan <rmh.grub@aybabtu.com>
836
837 * fs/cpio.c [MODE_USTAR]: Finish `tar' module instead of
838 `cpio'.
839 [! MODE_USTAR]: Finish `cpio' module instead of `tar'.
840
f6693890 8412009-10-25 Robert Millan <rmh.grub@aybabtu.com>
842
843 Patch from Samuel Thibault <samuel.thibault@ens-lyon.org>
844 * docs/grub.cfg: Compensate for recent change in multiboot
845 loader (since 2009-08-14 it won't pass filename to payload).
846 * util/grub.d/10_hurd.in: Likewise.
847
0933cdc0 8482009-10-21 Felix Zielcke <fzielcke@z-51.de>
849
850 * config.guess: Update to latest version from config git
851 repository.
852 * config.sub: Likewise.
853
3b2fe8c2 8542009-10-20 Robert Millan <rmh.grub@aybabtu.com>
855
856 Fix build on sparc64.
857
858 * configure.ac: Perform checks for libgcc symbols before
859 adding `-nostdlib' to LDFLAGS.
860
46695a62 8612009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
862
863 Let user specify OpenBSD root device.
864
865 * loader/i386/bsd.c (openbsd_root): New variable.
866 (openbsd_opts): New option 'root'.
867 (OPENBSD_ROOT_ARG): New macro.
868 (grub_openbsd_boot): Use 'openbsd_root'.
869 (grub_cmd_openbsd): Fill 'openbsd_root'.
870
d2b6b7fc 8712009-10-16 Robert Millan <rmh.grub@aybabtu.com>
872
873 * NEWS: Misc adjustments.
874
421bd7ac 8752009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
876
877 * NEWS: Mentioned XNU, ACPI, gptsync, password and parttool.
878
f1d29d87 8792009-10-16 Robert Millan <rmh.grub@aybabtu.com>
880
881 * configure.ac: Bump version to 1.97.
882
6f3cd880 8832009-10-16 Colin Watson <cjwatson@ubuntu.com>
884
885 * configure.ac (TARGET_CFLAGS): Add -mno-mmx -mno-sse -mno-sse2
886 -mno-3dnow on x86 architectures. Some toolchains enable these
887 features by default, but they rely on registers that aren't enabled
888 in GRUB. Thanks to Vladimir Serbinenko for the suggestion.
889
035f7122 8902009-10-15 Robert Millan <rmh.grub@aybabtu.com>
891
892 Make entry text a bit more readable.
893
894 * util/grub.d/10_linux.in: Add `with' before `Linux'.
895
44998e58 8962009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
897
898 * loader/i386/pc/xnu.c (grub_xnu_set_video): Fix loading splash image.
899
cd2851b3 9002009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
901
902 * commands/xnu_uuid.c (grub_cmd_xnu_uuid): Remove duplicated bitwise
903 operations.
904
c6f3b249 9052009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
906
907 * configure.ac: Add missing dollar.
908
6b5886ba 9092009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
910
911 Revert 2009-06-10 Pavel Roskin <proski@gnu.org>
912
913 * configure.ac: Put checks for __bswapsi2 and __bswapdi2.
914 * include/grub/powerpc/libgcc.h: Don't use weak attribute for all
915 exports.
916 * include/grub/sparc64/libgcc.h: Likewise. Use
917 preprocessor conditionals.
918
e9d66f6d 9192009-10-14 Robert Millan <rmh.grub@aybabtu.com>
920
921 * conf/common.rmk (grub-dumpbios): Remove rule.
922 (sbin_SCRIPTS, CLEANFILES): Remove `grub-dumpbios'.
923 * util/grub-dumpbios.in: Remove file.
924
9155bc17 9252009-10-14 Robert Millan <rmh.grub@aybabtu.com>
926
927 Refer to kernel of FreeBSD "kFreeBSD" to avoid confusion between
928 the Operating System (FreeBSD) and its kernel (kernel of FreeBSD).
929
930 * loader/i386/bsd.c (grub_freebsd_boot): Read kernel environment
931 from "kFreeBSD" namespace (rather than "FreeBSD"). Update all
932 users.
933
934 (GRUB_MOD_INIT (bsd)): Rename "freebsd" command to "kfreebsd",
935 "openbsd" to "kopenbsd", "netbsd" to "knetbsd", "freebsd_loadenv"
936 to "kfreebsd_loadenv", "freebsd_module" to "kfreebsd_module",
937 and "freebsd_module_elf" to "kfreebsd_module_elf". Update all
938 users.
939
bf7f7a18 9402009-10-12 Robert Millan <rmh.grub@aybabtu.com>
941
942 * term/tparm.c: Switch to GPLv3.
943
86564c26 9442009-10-09 Robert Millan <rmh.grub@aybabtu.com>
945
946 * include/grub/i386/cpuid.h: Add header protection.
947
5c936493 9482009-10-09 Robert Millan <rmh.grub@aybabtu.com>
949
950 Fail gracefuly when attempting to load 64-bit kFreeBSD on IA32 CPU.
951
952 * include/grub/i386/cpuid.h: New file.
953 * commands/i386/cpuid.c: Include `<grub/i386/cpuid.h>'.
954 (has_longmode): Rename to ...
955 (grub_cpuid_has_longmode): ... this. Update all users. Remove
956 `static' attribute.
957 * loader/i386/bsd.c: Include `<grub/i386/cpuid.h>'.
958 (grub_bsd_load_elf): Fail if load of 64-bit kernel was requested
959 on a CPU that doesn't implement AMD64 instruction set.
960
186e7cf2 9612009-10-06 Colin Watson <cjwatson@ubuntu.com>
962
963 * Makefile.in (docs/stamp-vti): Depend on configure.ac as well, so
964 that version.texi is rebuilt on version number changes.
965
83b65c4a 9662009-10-06 Colin Watson <cjwatson@ubuntu.com>
967
968 * Makefile.in: Don't set info_INFOS unless makeinfo was found.
969 Fixes bug #27602.
970
d244281c 9712009-10-06 Colin Watson <cjwatson@ubuntu.com>
972
973 * util/i386/pc/grub-install.in: Source
974 ${libdir}/grub/grub-mkconfig_lib before option processing, in order
975 that the --grub-probe option will work.
976 * util/sparc64/ieee1275/grub-install.in: Likewise.
977
da25306d 9782009-10-05 Robert Millan <rmh.grub@aybabtu.com>
979
980 * configure.ac: Bump version to 1.97~beta4.
981
e8ee83c0 9822009-10-03 Robert Millan <rmh.grub@aybabtu.com>
983
984 Resync grub-mkdevicemap in x86_64-efi.
985
986 * conf/x86_64-efi.rmk (sbin_UTILITIES): Enable `grub-mkdevicemap'.
987 (grub_mkdevicemap_SOURCES): Add missing `util/deviceiter.c' and
988 `util/devicemap.c'.
989
50dcabcf 9902009-10-01 Colin Watson <cjwatson@ubuntu.com>
991
992 * util/grub-editenv.c (create_envblk_file): Write new block with a
993 .new suffix and then rename it into place, to ensure atomic
994 creation.
995
0e51c3a7 9962009-09-28 Robert Millan <rmh.grub@aybabtu.com>
997
998 Do not automatically install headers.
999
1000 * Makefile.in (include_DATA): Remove. Update all users.
1001
31299a95 10022009-09-26 Robert Millan <rmh.grub@aybabtu.com>
1003
1004 * conf/common.rmk (pkglib_MODULES): Remove `lua.mod'.
1005 (lua_mod_SOURCES, lua_mod_CFLAGS, lua_mod_LDFLAGS): Remove.
1006
1007 * util/osdetect.lua: Remove.
1008 * script/lua/lauxlib.c: Likewise.
1009 * script/lua/ldebug.c: Likewise.
1010 * script/lua/grub_main.c: Likewise.
1011 * script/lua/lauxlib.h: Likewise.
1012 * script/lua/ldebug.h: Likewise.
1013 * script/lua/ltablib.c: Likewise.
1014 * script/lua/liolib.c: Likewise.
1015 * script/lua/lstrlib.c: Likewise.
1016 * script/lua/lualib.h: Likewise.
1017 * script/lua/ldo.c: Likewise.
1018 * script/lua/ldump.c: Likewise.
1019 * script/lua/ldo.h: Likewise.
1020 * script/lua/loslib.c: Likewise.
1021 * script/lua/lundump.c: Likewise.
1022 * script/lua/grub_lib.c: Likewise.
1023 * script/lua/ldblib.c: Likewise.
1024 * script/lua/lundump.h: Likewise.
1025 * script/lua/lmem.c: Likewise.
1026 * script/lua/grub_lib.h: Likewise.
1027 * script/lua/lmathlib.c: Likewise.
1028 * script/lua/lstate.c: Likewise.
1029 * script/lua/ltm.c: Likewise.
1030 * script/lua/lvm.c: Likewise.
1031 * script/lua/lmem.h: Likewise.
1032 * script/lua/lstate.h: Likewise.
1033 * script/lua/ltm.h: Likewise.
1034 * script/lua/ltable.c: Likewise.
1035 * script/lua/lvm.h: Likewise.
1036 * script/lua/llex.c: Likewise.
1037 * script/lua/lgc.c: Likewise.
1038 * script/lua/grub_lua.h: Likewise.
1039 * script/lua/loadlib.c: Likewise.
1040 * script/lua/lfunc.c: Likewise.
1041 * script/lua/lopcodes.c: Likewise.
1042 * script/lua/lparser.c: Likewise.
1043 * script/lua/ltable.h: Likewise.
1044 * script/lua/llex.h: Likewise.
1045 * script/lua/lgc.h: Likewise.
1046 * script/lua/lfunc.h: Likewise.
1047 * script/lua/lbaselib.c: Likewise.
1048 * script/lua/lopcodes.h: Likewise.
1049 * script/lua/lparser.h: Likewise.
1050 * script/lua/lzio.c: Likewise.
1051 * script/lua/linit.c: Likewise.
1052 * script/lua/lobject.c: Likewise.
1053 * script/lua/llimits.h: Likewise.
1054 * script/lua/lstring.c: Likewise.
1055 * script/lua/lzio.h: Likewise.
1056 * script/lua/lapi.c: Likewise.
1057 * script/lua/lcode.c: Likewise.
1058 * script/lua/lua.h: Likewise.
1059 * script/lua/lobject.h: Likewise.
1060 * script/lua/lstring.h: Likewise.
1061 * script/lua/lapi.h: Likewise.
1062 * script/lua/lcode.h: Likewise.
1063 * script/lua/luaconf.h: Likewise.
1064
cb8a2c38 10652009-09-26 Colin Watson <cjwatson@ubuntu.com>
1066
1067 * docs/grub.texi (Command-line and menu entry commands): Document
1068 date and echo commands.
1069
6b9b6276 10702009-09-24 Pavel Roskin <proski@gnu.org>
1071
1072 * include/grub/kernel.h (struct grub_module_header): Remove
1073 `grub_module_header_types'. Make `type' unsigned. Make `size'
1074 32-bit on all platforms.
1075 * util/elf/grub-mkimage.c (load_modules): Treat `type' as an
1076 8-bit field. Use grub_host_to_target32() for `size'.
1077 * util/i386/efi/grub-mkimage.c (make_mods_section): Likewise.
1078 * util/i386/pc/grub-mkimage.c (generate_image): Likewise.
1079 * util/sparc64/ieee1275/grub-mkimage.c (generate_image): Likewise.
1080
4e5a02a7 10812009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1082
1083 Fix "lost keypress" bug in at_keyboard.
1084
1085 * term/i386/pc/at_keyboard.c (grub_at_keyboard_checkkey): New function.
1086 Checks for readyness of input buffer (without flushing it).
1087 (grub_at_keyboard_term): Use grub_at_keyboard_checkkey() rather
1088 than grub_at_keyboard_getkey_noblock() for `checkkey' struct member.
1089
c6dcedf6 10902009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1091
1092 * util/i386/pc/grub-mkimage.c (generate_image): Enclose BIOS-specific
1093 size check within GRUB_MACHINE_PCBIOS section.
1094
74c958b1 10952009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1096
1097 * include/grub/i386/at_keyboard.h (KEYBOARD_ISREADY): Negate
1098 return value.
1099 * term/i386/pc/at_keyboard.c (grub_keyboard_getkey): Negate
1100 KEYBOARD_ISREADY check.
1101 (grub_at_keyboard_checkkey): Rename to ...
1102 (grub_at_keyboard_getkey_noblock): ... this. Update all users.
1103 Remove gratuitous cast.
1104
ff420223 11052009-09-23 Colin Watson <cjwatson@ubuntu.com>
1106
1107 * configure.ac: Call AC_PROG_MKDIR_P.
1108 * Makefile.in (docs/stamp-vti): Create docs directory. Create
1109 version.texi in $(builddir) rather than $(srcdir).
1110 (docs/grub.info): Create docs directory. Prepend $(builddir)/docs
1111 to makeinfo's @include search path.
1112
d96875df 11132009-09-23 Felix Zielcke <fzielcke@z-51.de>
1114
1115 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Cope with `*.dpkg-*'
1116
9b3f8365 11172009-09-23 Felix Zielcke <fzielcke@z-51.de>
1118
1119 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Add support
1120 for `*.dpkg-new'.
1121
c44c90db 11222009-09-21 Colin Watson <cjwatson@ubuntu.com>
1123
1124 Build info documentation. Some code borrowed from Automake.
1125
1126 * configure.ac: Check for makeinfo.
1127 * Makefile.in (MAKEINFO, INFOS, info_INFOS): New variables.
1128 (MAINTAINER_CLEANFILES): Add $(INFOS), docs/stamp-vti, and
1129 docs/version.texi.
1130 (MOSTLYCLEANFILES): Add vti.tmp.
1131 (docs/version.texi, docs/stamp-vti): Update automatically.
1132 (docs/grub.info): Build info documentation. Use --force and ignore
1133 errors for now.
1134 (all-local): Add $(INFOS).
1135 (install-local): Install info files.
1136 (uninstall): Uninstall info files.
1137 * docs/version.texi: Remove from revision control. This file is
1138 automatically generated on build now.
1139 * gendistlist.sh: Add `*.info'.
1140
e0b37bb5 11412009-09-21 Felix Zielcke <fzielcke@z-51.de>
1142
1143 * kern/term.c: Fix indentation.
1144
5a78865b 11452009-09-21 Felix Zielcke <fzielcke@z-51.de>
1146
1147 * util/hostdisk.c: Fix a comment.
1148
dace7e8a 11492009-09-20 Robert Millan <rmh.grub@aybabtu.com>
1150
1151 Fix regression introduced in r2539.
1152
1153 * term/usb_keyboard.c (USB_HID_DEVICE_TO_HOST): Change from 0x61
1154 to 0xA1.
1155
a83d079b 11562009-09-19 Colin Watson <cjwatson@ubuntu.com>
1157
1158 * util/grub.d/30_os-prober.in: Don't throw away stderr from
4cbbccec 1159 os-prober. Under normal operation, it does not print anything to
1160 stderr; if it does, we need to debug it, and throwing away stderr
1161 makes that excessively difficult.
a83d079b 1162
be94a509 11632009-09-16 Vladimir Serbinenko <phcoder@gmail.com>
1164
1165 * mmap/mmap.c (grub_cmd_badram): Fix off-by-one error.
1166
63f745e8 11672009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1168
1169 * aclocal.m4 (AC_LANG_PROGRAM): New macro. Overrides stock
1170 AC_LANG_PROGRAM from autoconf.
1171 (grub_ASM_USCORE, grub_PROG_OBJCOPY_ABSOLUTE): Add missing
1172 prototypes (fixes warning).
1173
1174 * configure.ac: Add `-Werror' to TARGET_CFLAGS unless
1175 `--disable-werror' was used.
1176
bbb2a70f 11772009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1178
1179 * partmap/msdos.c (pc_partition_map_iterate): Fix possible use of
1180 uninitialized `lastaddr'.
1181
77c24f1d 11822009-09-15 Vladimir Serbinenko <phcoder@gmail.com>
1183
0f0b8c87 1184 * partmap/msdos.c (pc_partition_map_iterate): Detect and break loops.
77c24f1d 1185
07197f23 11862009-09-14 Colin Watson <cjwatson@ubuntu.com>
1187
1188 * commands/test.c (get_fileinfo): Return immediately if
1189 grub_fs_probe fails.
1190
dabf1798 11912009-09-14 José Martínez <xosemp@gmail.com>
1192
1193 * commands/acpi.c (grub_cmd_acpi): Fix loading ACPI tables from file.
1194
d52109a7 11952009-09-14 Colin Watson <cjwatson@ubuntu.com>
1196
1197 * util/grub.d/30_os-prober.in: Cope with Windows 7 in os-prober
1198 output.
1199
56532179 12002009-09-13 Robert Millan <rmh.grub@aybabtu.com>
1201
1202 * configure.ac: Remove --enable-grub-pe2elf. Only build
1203 grub-pe2elf when needed by the build system itself.
1204 * conf/common.rmk: Remove $(enable_grub_pe2elf) check.
1205
8ef070f5 12062009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1207
1208 * configure.ac: Bump version to 1.97~beta3.
1209 * docs/version.texi: Likewise.
1210
61229557 12112009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1212
1213 * video/i386/pc/vbe.c (grub_vbe_get_video_mode_info): Move packed
1214 mode special handling (grub_vbe_bios_set_dac_palette_width() call)
1215 from here ...
1216 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS]
1217 (grub_linux_setup_video): ... to here (with some adjustments).
1218
5c9f8d84 12192009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1220
1221 Fix memory corruption issue (spotted by Colin Watson).
1222
1223 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette): Fix bug
1224 causing returned size to be stored in an incorrect memory location.
1225 Fix use of uninitialized value when storing the returned size.
1226
e8f5d6e9 12272009-09-12 Yves Blusseau <blusseau@zetam.org>
1228
1229 Change clean rules to properly remove files
1230
1231 * genmk.rb: add new clean rules
1232 * Makefile.in (clean): add the new targets
1233 (mostlyclean): likewise
1234
cda2a409 12352009-09-11 Colin Watson <cjwatson@ubuntu.com>
1236
1237 * include/grub/ntfs.h (struct grub_fshelp_node): Change `size'
1238 to grub_uint64_t.
1239 * fs/ntfs.c (init_file): Understand 64-bit sizes for
1240 non-resident files.
1241
86695375 12422009-09-11 Colin Watson <cjwatson@ubuntu.com>
1243
1244 * configure.ac: Don't look for help2man when cross-compiling. Fixes
1245 part of bug #27349.
1246
8aa1541a 12472009-09-10 Felix Zielcke <fzielcke@z-51.de>
1248
1249 * util/grub-mkconfig.in: Make the created config mode 400 and
1250 print a warning if it fails.
1251
48d9bb0a 12522009-09-10 Robert Millan <rmh.grub@aybabtu.com>
1253
1254 * util/grub.d/40_custom.in: Ask user to type custom entries below
1255 comment, rather than below 'exec tail' line.
1256
3b0521be 12572009-09-10 Colin Watson <cjwatson@ubuntu.com>
1258
1259 * util/grub.d/40_custom.in: Make sure that the explanatory text is
1260 visible in grub.cfg.
1261
50051d55 12622009-09-10 Colin Watson <cjwatson@ubuntu.com>
1263
1264 * util/grub.d/40_custom.in: Make it a little clearer how to use this
1265 file.
1266
c0d34387 12672009-09-10 Felix Zielcke <fzielcke@z-51.de>
1268
1269 * docs/grub.cfg: Add an example menu entry for memtest86+.
1270
80a608f3 12712009-09-09 Felix Zielcke <fzielcke@z-51.de>
1272
a2094832 1273 * config.guess: Update to latest version from config git.
80a608f3 1274 * config.sub: Likewise.
1275
99423078 12762009-09-08 Colin Watson <cjwatson@ubuntu.com>
1277
1278 * script/sh/execute.c (grub_script_execute_cmdline): Set "?" in
1279 unknown-command case. Fixes bug #27320.
1280
44454e4c 12812009-09-08 Felix Zielcke <fzielcke@z-51.de>
1282
1283 * kern/rescue_parser.c (grub_rescue_parse_line): Only suggest to try
1284 `help' if the command exists.
1285
e30d87ad 12862009-09-06 Robert Millan <rmh.grub@aybabtu.com>
1287
1288 * INSTALL: Require GCC 4.1.3 or later.
1289
9a86f1ec 12902009-09-06 Yves Blusseau <blusseau@zetam.org>
1291
1292 * Makefile.in (RMKFILES): add i386-qemu.rmk
1293 (MAINTAINER_CLEANFILES): add $(srcdir)/DISTLIST $(srcdir)/config.h.in
1294 $(srcdir)/stamp-h.in
1295
7f26d466 12962009-09-05 Robert Millan <rmh.grub@aybabtu.com>
1297
1298 * util/grub-probe.c (probe): Comment out buggy codepath, which
1299 was unexpectedly enabled by Colin Watson's 2009-09-02 fix. This
1300 should be re-enabled after 1.97.
1301
3a613259 13022009-09-05 Felix Zielcke <fzielcke@z-51.de>
1303
1304 * gendistlist.sh: Add `grub-dumpdevtree' and `*.lua' to the list
1305 find searches for.
1306
197f76c7 13072009-09-04 Vladimir Serbinenko <phcoder@gmail.com>
1308
1309 * loader/i386/xnu.c (grub_cpu_xnu_fill_devicetree): Remove
1310 unnecessary calls to grub_error.
1311
70ba68ce 13122009-09-04 Colin Watson <cjwatson@ubuntu.com>
1313
1314 * NEWS: Mention `keystatus' and Unicode fonts.
1315
4ff0d7a4 13162009-09-04 Robert Millan <rmh.grub@aybabtu.com>
1317
1318 * configure.ac: Bump version to 1.97~beta2.
1319 * docs/version.texi: Likewise.
1320
77c55a87 13212009-09-03 Colin Watson <cjwatson@ubuntu.com>
1322
1323 * configure.ac: By default, GCC 4.4 generates .eh_frame sections
1324 containing unwind information in some cases where it previously did
1325 not. Use -fno-dwarf2-cfi-asm if available to restore the old
1326 behaviour. See http://patchwork.kernel.org/patch/8555/ for related
1327 discussion.
1328
f79572cd 13292009-09-02 Yves BLUSSEAU <blusseau@zetam.org>
1330
1331 Embedding loadenv module into grub-emu
1332
1333 * conf/i386-pc.rmk (grub_emu_SOURCES): add lib/envblk.c and
1334 commands/loadenv.c
1335 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise
1336 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise
1337 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise
1338 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise
1339 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise
1340 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise
1341
93a81088 13422009-09-03 Magnus Granberg <zorry@ume.nu>
1343
1344 * aclocal.m4: Add grub_CHECK_PIE. It check if the compiler
1345 include -fPIE in the default specs.
1346 * configure.ac: Check if pie_possible is yes and add -fno-PIE
1347 to TARGET_CFLAGS.
1348
160034b2 13492009-09-03 Felix Zielcke <fzielcke@z-51.de>
1350
1351 * INSTALL: Note that GNU Bison 2.3 or later is required.
1352
087c07c4 13532009-09-03 Colin Watson <cjwatson@ubuntu.com>
1354
1355 * kern/i386/pc/startup.S: Fix typo.
1356
cbf978c0 13572009-09-02 Vladimir Serbinenko <phcoder@gmail.com>
1358
1359 * efiemu/loadcore.c (SUFFIX (grub_efiemu_loadcore_load)): Fix style
1360 according to GCS.
1361
13622009-09-02 Colin Watson <cjwatson@ubuntu.com>
f0910644 1363
1364 * docs/grub.texi (Naming convention): Describe one-based partition
1365 numbering.
1366 (Device syntax): Likewise.
1367 (File name syntax): Likewise.
1368 (Block list syntax): Likewise.
1369 (Making a GRUB bootable CD-ROM): Talk about grub.cfg rather than
1370 menu.lst.
1371 (File name syntax): Likewise.
1372 (Command-line and menu entry commands): Document acpi, blocklist,
1373 crc, export, insmod, keystatus, ls, set, and unset commands.
1374
f3e8cdfd 13752009-09-02 Colin Watson <cjwatson@ubuntu.com>
1376
1377 * commands/keystatus.c (GRUB_MOD_INIT (keystatus)): Adjust summary
1378 to avoid implying that only one of --shift, --ctrl, or --alt may be
1379 used.
1380
c0bc232b 13812009-09-02 Colin Watson <cjwatson@ubuntu.com>
1382
1383 * util/grub-probe.c (probe): Test st.st_mode using S_ISREG macro
1384 rather than comparing against S_IFREG, which will almost never work.
1385
aa0f752d 13862009-09-01 Vladimir Serbinenko <phcoder@gmail.com>
1387
1388 * commands/loadenv.c (check_blocklists): Fix off-by-one error.
1389 (write_blocklists): Likewise.
1390
ecb3166a 13912009-09-01 Colin Watson <cjwatson@ubuntu.com>
1392
1393 * script/lua/grub_lua.h (fputs): Supply a format string as the first
1394 argument to grub_printf.
1395
c403a125 13962009-09-01 Felix Zielcke <fzielcke@z-51.de>
31aba781 1397
1398 * genmk.rb: Add quotes around $(TARGET_OBJ2ELF) to cope with
c403a125 1399 non GNU test.
31aba781 1400
b5e7312c 14012009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1402
1403 * kern/file.c (grub_file_read): Spelling fix
1404
fe00f472 14052009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1406
1407 * loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix
1408 loading of headers in some cases.
1409
cc55302e 14102009-08-30 Robert Millan <rmh.grub@aybabtu.com>
1411
1412 * configure.ac: Bump version to 1.97~beta1.
1413 * docs/version.texi: Likewise.
1414
5c90cdd2 14152009-08-29 Vladimir Serbinenko <phcoder@gmail.com>
64bf71d0 1416
1417 * include/grub/i386/xnu.h: Add license header.
1418 include grub/err.h explicitly.
1419
c90edae4 14202009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1421
1422 * util/grub.d/10_freebsd.in: Detect `ufs1' and `ufs2' and map them
1423 to `ufs' in the vfs.root.mountfrom kernel parameter.
1424
d8888b5c 14252009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1426
1427 * term/i386/pc/serial.c: Include `<grub/machine/memory.h>'.
1428
1429 [GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Macroify initialization
1430 value (0x0400 -> GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR).
1431
1432 [! GRUB_MACHINE_PCBIOS] (GRUB_SERIAL_PORT_NUM): Calculate using
1433 `ARRAY_SIZE' macro.
1434
6f07b921 14352009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1436
1437 * kern/file.c (grub_file_read): Check offset.
1438 * fs/hfs.c (grub_hfs_read_file): Remove unnecessary offset check.
1439 * fs/jfs.c (grub_jfs_read_file): Likewise.
1440 * fs/ntfs.c (grub_ntfs_read): Likewise.
1441 * fs/reiserfs.c (grub_reiserfs_read): Likewise.
1442 * fs/minix.c (grub_minix_read_file): Correct offset check.
1443 * fs/ufs.c (grub_ufs_read_file): Likewise.
1444
b4f34077 14452009-08-28 Colin Watson <cjwatson@ubuntu.com>
1446
1447 * term/i386/pc/console.c (bios_data_area): Cast
1448 GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR explicitly.
1449
e7c69859 14502009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1451
1452 1-bit optimised blitters.
1453
1454 * include/grub/fbblit.h (grub_video_fbblit_replace_32bit_1bit): New
1455 prototype.
1456 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1457 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1458 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1459 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1460 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1461 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1462 * video/fb/fbblit.c (grub_video_fbblit_replace_32bit_1bit): New
1463 function.
1464 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1465 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1466 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1467 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1468 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1469 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1470 * video/fb/video_fb.c (common_blitter): Use 1-bit optimised blitters
1471 when possible.
1472 * video/video.c (grub_video_get_blit_format): Return
1473 GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED if bpp = 1.
1474
a57da43f 14752009-08-28 Colin Watson <cjwatson@ubuntu.com>
1476
1477 * normal/cmdline.c (grub_cmdline_get): Supply a format string as
1478 the first argument to grub_printf.
1479
4cbe67e5 14802009-08-28 Colin Watson <cjwatson@ubuntu.com>
14812009-08-28 Robert Millan <rmh.grub@aybabtu.com>
1482
1483 Add `getkeystatus' terminal method. Add a new `keystatus' command
1484 to query it.
1485
1486 * include/grub/term.h (GRUB_TERM_STATUS_SHIFT,
1487 GRUB_TERM_STATUS_CTRL, GRUB_TERM_STATUS_ALT): Definitions for
1488 modifier key bitmasks.
1489 (struct grub_term_input): Add `getkeystatus' member.
1490 (grub_getkeystatus): Add prototype.
1491 * kern/term.c (grub_getkeystatus): New function.
1492
1493 * include/grub/i386/pc/memory.h
1494 (GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR): New macro.
1495 (struct grub_machine_bios_data_area): Define necessary parts of BIOS
1496 Data Area layout.
1497 * term/i386/pc/console.c (grub_console_getkeystatus): New function.
1498 (grub_console_term_input): Set `getkeystatus' member.
1499 * term/usb_keyboard.c (grub_usb_hid): Macroify HID protocol
1500 constants.
1501 (grub_usb_keyboard_getreport): Likewise.
1502 (grub_usb_keyboard_checkkey): Likewise.
1503 (grub_usb_keyboard_getkeystatus): New function.
1504 (grub_usb_keyboard_term): Set `getkeystatus' member.
1505
1506 * commands/keystatus.c: New file.
1507 * conf/common.rmk (pkglib_MODULES): Add keystatus.mod.
1508 (keystatus_mod_SOURCES): New variable.
1509 (keystatus_mod_CFLAGS): Likewise.
1510 (keystatus_mod_LDFLAGS): Likewise.
1511 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add
1512 commands/keystatus.c.
1513 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1514 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1515 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1516 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1517 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1518 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4cbe67e5 1519
6e2a9085 15202009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1521
1522 Split befs.mod and afs.mod into *_be.mod and *.mod
1523
1524 * conf/common.rmk (grub_probe_SOURCES): Add afs_be.c and befs_be.c.
1525 (grub_fstest_SOURCES): Likewise.
1526 (pkglib_MODULES): Add afs_be.mod and befs_be.mod.
1527 (afs_be_mod_SOURCES): New variable.
1528 (afs_be_mod_CFLAGS): Likewise.
1529 (afs_be_mod_LDFLAGS): Likewise.
1530 (befs_be_mod_SOURCES): Likewise.
1531 (befs_be_mod_CFLAGS): Likewise.
1532 (befs_be_mod_LDFLAGS): Likewise.
1533 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add afs_be.c and befs_be.c.
1534 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1535 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1536 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
1537 (grub_emu_SOURCES): Likewise.
1538 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1539 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1540 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1541 * fs/afs_be.c: New file.
1542 * fs/befs_be.c: New file.
1543 * fs/afs.c (GRUB_AFS_FSNAME_SUFFIX): New definition.
1544 (GRUB_AFS_FSNAME): Use GRUB_AFS_FSNAME_SUFFIX.
1545 (U16): Replaced with ...
1546 (grub_afs_to_cpu16): ...this. All users updated.
1547 (U32): Replaced with ...
1548 (grub_afs_to_cpu32): ...this. All users updated.
1549 (U64): Replaced with ...
1550 (grub_afs_to_cpu64): ...this. All users updated.
1551 (GRUB_AFS_BO_LITTLE_ENDIAN): Remove.
1552 (GRUB_AFS_BO_BIG_ENDIAN): Likewise.
ad8ea1f4 1553 (grub_afs_validate_sblock): Check only one endianness.
6e2a9085 1554 (GRUB_MOD_INIT (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1555 (GRUB_MOD_INIT (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1556 (GRUB_MOD_INIT (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1557 (GRUB_MOD_INIT (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1558 (GRUB_MOD_FINI (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1559 (GRUB_MOD_FINI (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1560 (GRUB_MOD_FINI (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1561 (GRUB_MOD_FINI (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1562
32a71655 15632009-08-26 Bean <bean123ch@gmail.com>
1564
1565 * fs/xfs.c (GRUB_XFS_INO_INOINAG): Replace 1L with 1LL to support
1566 64-bit number.
1567 (GRUB_XFS_FSB_TO_BLOCK): Likewise.
1568 (grub_xfs_inode_block): Change return type to grub_uint64_t.
1569 (grub_xfs_read_inode): Change type of block to grub_uint64_t.
1570
552bf6c5 15712009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1572
1573 NetBSD memory map support.
1574
1575 * include/grub/i386/bsd.h (NETBSD_BTINFO_MEMMAP): New definition.
1576 (grub_netbsd_btinfo_mmap_header): New structure.
1577 (grub_netbsd_btinfo_mmap_entry): Likewise.
1578 * loader/i386/bsd.c (grub_netbsd_boot): Pass memory map.
1579
1ae2078c 15802009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1581
1582 Enable bsd.mod on coreboot.
1583
1584 * conf/i386-coreboot.rmk (pkglib_MODULES): Add bsd.mod.
1585 (bsd_mod_SOURCES): New variable.
1586 (bsd_mod_CFLAGS): Likewise.
1587 (bsd_mod_LDFLAGS): Likewise.
1588 (bsd_mod_ASFLAGS): Likewise.
1589 * loader/i386/bsd.c [!GRUB_MACHINE_PCBIOS]: Fix includes.
1590 (grub_bsd_get_device) [!GRUB_MACHINE_PCBIOS]: Set *biosdev to 0xff.
1591
beefc598 15922009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1593
1594 Cleanup NetBSD root support.
1595
1596 * loader/i386/bsd.c (grub_netbsd_boot): Remove call to
1597 grub_bsd_get_device.
1598 Fix typo.
1599
3b76e68b 16002009-08-25 Felix Zielcke <fzielcke@z-51.de>
1601
1602 * util/grub.d/00_header.in: Move check for the video backend of
1603 gfxterm from here ...
1604 * util/grub-mkconfig.in: ... to here. Enable gfxterm if there's
1605 a suitable video backend.
1606
aea664ea 16072009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1608
1609 Fix breakage in grub-setup.
1610
1611 * util/i386/pc/grub-setup.c (setup): Use "part_msdos" instead of
1612 "msdos_partition_map".
1613
ff747d50 16142009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1615
1616 Fix breakage in normal/auth.c.
1617
1618 * normal/auth.c (grub_iswordseparator): New function.
1619
e7e1f93f 16202009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1621
1622 Authentication support.
1623
1624 * commands/password.c: New file.
1625 * conf/common.rmk (pkglib_MODULES): Add password.mod.
1626 (password_mod_SOURCES): New variable.
1627 (password_mod_CFLAGS): Likewise.
1628 (password_mod_LDFLAGS): Likewise.
1629 (normal_mod_SOURCES): Add normal/auth.c.
1630 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add commands/password.c and
1631 normal/auth.c.
1632 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1633 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1634 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1635 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1636 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1637 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1638 * include/grub/auth.h: New file.
1639 * include/grub/err.h (grub_err_t): New enum value
1640 GRUB_ERR_ACCESS_DENIED.
1641 * include/grub/menu.h (grub_menu_entry): New fields 'restricted' and
1642 'users'.
1643 * include/grub/normal.h (grub_cmdline_get): New argument 'history'.
1644 * normal/cmdline.c (grub_cmdline_get): New argument 'history'. All
1645 users updated.
1646 * normal/auth.c: New file.
1647 * normal/main.c (grub_normal_add_menu_entry): Handle --users option.
1648 (grub_cmdline_run): Don't allow to go to command line without
1649 authentication.
1650 * normal/menu.c (grub_menu_execute_entry): Handle restricted entries.
1651 * normal/menu_entry.c (grub_menu_entry_run): Don't allow editing
1652 menuentry without superuser rights.
1653 * normal/menu_viewer.c (grub_menu_viewer_show_menu): Don't exit if
1654 user isn't a superuser.
1655
70f1161d 16562009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1657
1658 Save space by inlining misc.c functions.
1659
1660 * kern/misc.c (grub_iswordseparator): Made static.
1661 * kern/misc.c (grub_strcat): Moved from here ...
1662 * include/grub/misc.h (grub_strcat): ... here. Inlined.
1663 * kern/misc.c (grub_strncat): Moved from here ...
1664 * include/grub/misc.h (grub_strncat): ... here. Inlined.
1665 * kern/misc.c (grub_strcasecmp): Moved from here ...
1666 * include/grub/misc.h (grub_strcasecmp): ... here. Inlined.
1667 * kern/misc.c (grub_strncasecmp): Moved from here ...
1668 * include/grub/misc.h (grub_strncasecmp): ... here. Inlined.
1669 * kern/misc.c (grub_isalpha): Moved from here ...
1670 * include/grub/misc.h (grub_isalpha): ... here. Inlined.
1671 * kern/misc.c (grub_isdigit): Moved from here ...
1672 * include/grub/misc.h (grub_isdigit): ... here. Inlined.
1673 * kern/misc.c (grub_isgraph): Moved from here ...
1674 * include/grub/misc.h (grub_isgraph): ... here. Inlined.
1675 * kern/misc.c (grub_tolower): Moved from here ...
1676 * include/grub/misc.h (grub_tolower): ... here. Inlined.
1677
48e40bff 16782009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1679
1680 * script/sh/function.c (grub_script_function_find): Cut error message
1681 not to flood terminal.
1682 * script/sh/lexer.c (grub_script_yylex): Remove command line length
1683 limit.
1684 * script/sh/script.c (grub_script_arg_add): Duplicate string.
1685
c385bfc3 16862009-08-24 Colin Watson <cjwatson@ubuntu.com>
1687
1688 * term/usb_keyboard.c (grub_usb_keyboard_getreport): Make
1689 `report' grub_uint8_t *.
1690 (grub_usb_keyboard_checkkey): Make `data' elements grub_uint8_t.
1691 Use a 50-millisecond timeout rather than just repeating
1692 grub_usb_keyboard_getreport 50 times.
1693 (grub_usb_keyboard_getkey): Make `data' elements grub_uint8_t.
1694
2d21e3e8 16952009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1696
1697 Rename *_partition_map to part_*
1698
1699 * partmap/acorn.c (grub_acorn_partition_map): Set name to 'part_acorn'.
1700 * partmap/amiga.c (grub_amiga_partition_map): Set name to 'part_amiga'.
1701 * partmap/apple.c (grub_apple_partition_map): Set name to 'part_apple'.
1702 * partmap/gpt.c (grub_gpt_partition_map): Set name to 'part_gpt'.
1703 All users updated.
1704 * partmap/msdos.c (grub_msdos_partition_map): Set name to 'part_msdos'.
1705 All users updated.
1706 * partmap/sun.c (grub_sun_partition_map): Set name to 'part_sun'.
1707 * util/grub-probe.c (probe_partmap): Don't transform partition name
1708 to get module name.
1709
dd103c4e 17102009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1711
1712 Fix OpenBSD and NetBSD support.
1713
1714 * include/grub/i386/bsd.h (GRUB_BSD_TEMP_BUFFER): Change to resolve
1715 memory address conflict.
1716 (OPENBSD_MMAP_ACPI): New definition.
1717 (OPENBSD_MMAP_NVS): Likewise.
1718 * loader/i386/bsd.c (grub_openbsd_boot): Support OPENBSD_MMAP_ACPI
1719 and OPENBSD_MMAP_NVS.
1720 Add memory map terminator
1721 Explicit cast when calling grub_unix_real_boot.
ad8ea1f4 1722 (grub_netbsd_boot): Explicit cast when calling grub_unix_real_boot.
dd103c4e 1723
16c84d74 17242009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1725
1726 Let user specify NetBSD root device.
1727
1728 * loader/i386/bsd.c (netbsd_root): New variable.
1729 (netbsd_opts): New option 'root'.
1730 (NETBSD_ROOT_ARG): New macro.
1731 (grub_netbsd_boot): Use 'netbsd_root'.
1732 (grub_bsd_unload): Free 'netbsd_root'.
1733 (grub_cmd_netbsd): Fill 'netbsd_root'.
1734
adb29902 17352009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1736
1737 Support for 64-bit NetBSD.
1738
1739 * loader/i386/bsd.c (grub_bsd_load_elf): Apply correct mask to entry
1740 point when booting non-FreeBSD.
1741
f5ae9f74 17422009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1743
1744 Support --no-smp and --no-acpi for NetBSD.
1745
1746 * include/grub/i386/bsd.h (NETBSD_AB_NOSMP): New definition.
1747 (NETBSD_AB_NOACPI): Likewise.
1748 * loader/i386/bsd.c (netbsd_opts): New entries no-smp and no-acpi.
1749 (netbsd_flags): Add NETBSD_AB_NOSMP, NETBSD_AB_NOACPI.
1750
de74f136 17512009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
1752
1753 * fs/hfsplus.c (grub_hfsplus_mount): Don't ignore grub_hfsplus_read_file
1754 errors.
1755 (grub_hfsplus_btree_iterate_node): Don't ignore grub_hfsplus_read_file
1756 errors. Call grub_error when needed.
1757
e9a925da 17582009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
1759
1760 * commands/search.c (search_fs): Try searching without autoload first.
1761 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Load
1762 filesystem module explicitly for faster booting.
1763
5174302b 17642009-08-23 Colin Watson <cjwatson@ubuntu.com>
1765
1766 * util/grub-mkconfig.in: Export GRUB_DISABLE_OS_PROBER.
1767
c8c80635 17682009-08-23 Colin Watson <cjwatson@ubuntu.com>
1769
1770 * util/grub.d/30_os-prober.in: Disable os-prober if
1771 `GRUB_DISABLE_OS_PROBER' was set to true.
1772
71acf5e5 17732009-08-23 Robert Millan <rmh.grub@aybabtu.com>
1774
1775 * partmap/pc.c: Rename to ...
1776 * partmap/msdos.c: ... this. Update all users.
1777 (grub_pc_partition_map): Rename to ...
1778 (grub_msdos_partition_map): ... this. Update all users.
1779
1780 * parttool/pcpart.c: Rename to ...
1781 * parttool/msdospart.c: ... this. Update all users.
1782
1783 * include/grub/pc_partition.h: Rename to ...
1784 * include/grub/msdos_partition.h: ... this. Update all users.
1785 (grub_pc_partition_bsd_entry): Rename to ...
1786 (grub_msdos_partition_bsd_entry): ... this. Update all users.
1787 (grub_pc_partition_disk_label): Rename to ...
1788 (grub_msdos_partition_disk_label): ... this. Update all users.
1789 (grub_pc_partition_entry): Rename to ...
1790 (grub_msdos_partition_entry): ... this. Update all users.
1791 (grub_pc_partition_mbr): Rename to ...
1792 (grub_msdos_partition_mbr): ... this. Update all users.
1793 (grub_pc_partition): Rename to ...
1794 (grub_msdos_partition): ... this. Update all users.
1795 (grub_pc_partition_is_empty): Rename to ...
1796 (grub_msdos_partition_is_empty): ... this. Update all users.
1797 (grub_pc_partition_is_extended): Rename to ...
1798 (grub_msdos_partition_is_extended): ... this. Update all users.
1799 (grub_pc_partition_is_bsd): Rename to ...
1800 (grub_msdos_partition_is_bsd): ... this. Update all users.
1801
1802 * conf/common.rmk (amiga_mod_SOURCES, amiga_mod_CFLAGS)
1803 (amiga_mod_LDFLAGS, apple_mod_SOURCES, apple_mod_CFLAGS)
1804 (apple_mod_LDFLAGS, msdos_mod_SOURCES, msdos_mod_CFLAGS)
1805 (msdos_mod_LDFLAGS, sun_mod_SOURCES, sun_mod_CFLAGS)
1806 (sun_mod_LDFLAGS, acorn_mod_SOURCES, acorn_mod_CFLAGS)
1807 (acorn_mod_LDFLAGS, gpt_mod_SOURCES, gpt_mod_CFLAGS)
1808 (gpt_mod_LDFLAGS): Rename to ...
1809 (part_amiga_mod_SOURCES, part_amiga_mod_CFLAGS, part_amiga_mod_LDFLAGS)
1810 (part_apple_mod_SOURCES, part_apple_mod_CFLAGS, part_apple_mod_LDFLAGS)
1811 (part_msdos_mod_SOURCES, part_msdos_mod_CFLAGS, part_msdos_mod_LDFLAGS)
1812 (part_sun_mod_SOURCES, part_sun_mod_CFLAGS, part_sun_mod_LDFLAGS)
1813 (part_acorn_mod_SOURCES, part_acorn_mod_CFLAGS, part_acorn_mod_LDFLAGS)
1814 (part_gpt_mod_SOURCES, part_gpt_mod_CFLAGS)
1815 (part_gpt_mod_LDFLAGS): ... this.
1816 (pkglib_MODULES): Prefix partition modules with `part_'. Rename
1817 `pcpart.mod' to `msdospart.mod'.
1818 (pcpart_mod_SOURCES, pcpart_mod_CFLAGS, pcpart_mod_LDFLAGS): Rename
1819 to ...
1820 (msdospart_mod_SOURCES, msdospart_mod_CFLAGS)
1821 (msdospart_mod_LDFLAGS): ... this.
1822
c11fded5 18232009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
1824
1825 * loader/i386/bsd.c (freebsd_opts): Rewritten to use extcmd.
1826 (openbsd_opts): Likewise.
1827 (netbsd_opts): Likewise.
1828 (freebsd_flags): Added 0 terminator.
1829 (openbsd_flags): Likewise.
1830 (netbsd_flags): Likewise.
1831 (grub_bsd_parse_flags): Rewritten to use extcmd. All users updated.
1832 (grub_cmd_freebsd): Transformed into extended command.
1833 (grub_cmd_openbsd): Likewise.
1834 (grub_cmd_netbsd): Likewise.
1835 (cmd_freebsd): Changed type to grub_extcmd_t.
1836 (cmd_openbsd): Likewise.
1837 (cmd_netbsd): Likewise.
1838 (GRUB_MOD_INIT (bsd)): Register grub_cmd_freebsd, grub_cmd_netbsd and
1839 grub_cmd_openbsd as extended commands.
1840 (GRUB_MOD_FINI (bsd)): Use grub_unregister_extcmd for cmd_freebsd,
1841 cmd_netbsd and cmd_openbsd
1842
11d1c769 18432009-08-22 Vladimir Serbinenko <phcoder@gmail.com>
1844
1845 * commands/xnu_uuid.c (transform): Use grub_memcpy instead of memcpy.
1846
7a9094e5 18472009-08-21 Pavel Roskin <proski@gnu.org>
1848
5496c37e 1849 * Makefile.in (install-local): When checking if a file is in the
1850 build directory, use "test -e" to detect symlinks.
1851
7a9094e5 1852 * Makefile.in (install-local): Remove all files in
1853 $(DESTDIR)$(pkglibdir) before installing new files there.
1854
e53cea11 18552009-08-18 Felix Zielcke <fzielcke@z-51.de>
1856
1857 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Use
1858 grub-mkelfimage.
1859
9aced544 18602009-08-18 Felix Zielcke <fzielcke@z-51.de>
1861
1862 * util/grub-mkconfig.in: Don't use gfxterm by default if not
1863 explicitly specified by the user.
1864
b7da6bab 18652009-08-18 Pavel Roskin <proski@gnu.org>
1866
1867 * include/grub/fbfill.h (struct grub_video_fbrender_target): Use
1868 grub_uint8_t pointer for data.
1869 * include/grub/fbutil.h (struct grub_video_fbblit_info):
1870 Likewise.
1871 * video/fb/fbutil.c: Remove unnecessary casts.
1872
19f1b335 18732009-08-17 Michal Suchanek <hramrach@centrum.cz>
1874
1875 VBE cleanup.
1876
1877 * video/i386/pc/vbe.c (vbe_mode_in_use): Removed (duplicate).
1878 (grub_vbe_set_video_mode): Save active mode info
1879 only after setting the mode.
1880 (grub_video_vbe_setup): Call 'grub_vbe_set_video_mode' with NULL as
1881 second argument.
1882
2f467aa9 18832009-08-17 Michal Suchanek <hramrach@centrum.cz>
1884
1885 Rename variables for clarity.
1886
1887 * video/i386/pc/vbe.c (active_mode_info): Renamed to ...
1888 (active_vbe_mode_info): ... this. All users updated.
1889 (framebuffer): Rename 'active_mode' to 'active_vbe_mode'.
1890 All users updated.
1891 (initial_mode): Rename to ...
1892 (initial_vbe_mode): ... this. All users updated.
1893 (mode_in_use): Rename to ..
1894 (vbe_mode_in_use): ... this. All users updated.
1895 (mode_list): Rename to ..
1896 (vbe_mode_list): ... this. All users updated.
1897 (grub_vbe_set_video_mode): Rename 'mode' to 'vbe_mode', 'mode_info' to
1898 'vbe_mode_info' and 'old_mode' to 'old_vbe_mode'.
1899 (grub_video_vbe_init): Rename 'rm_mode_list' to 'rm_vbe_mode_list' and
1900 'mode_list_size' to 'vbe_mode_list_size'.
1901 (grub_video_vbe_setup): Rename 'mode_info' to 'vbe_mode_info',
1902 'best_mode_info' to 'best_vbe_mode_info' and
1903 'best_mode' to 'best_vbe_mode'
1904
6025fcd7 19052009-08-17 Michal Suchanek <hramrach@centrum.cz>
1906
1907 Remove duplicate grub_video_fb_get_video_ptr.
1908
1909 * include/grub/fbutil.h (get_data_ptr): Rename to ...
1910 (grub_video_fb_get_video_ptr): ... this.
1911 * include/grub/video_fb.h (grub_video_fb_get_video_ptr): Removed.
1912 * video/fb/fbutil.c: Add comment about addressing.
1913 (get_data_ptr): Rename to ...
1914 (grub_video_fb_get_video_ptr): ... this. All users updated.
1915 * video/fb/video_fb.c (grub_video_fb_get_video_ptr): Remove.
1916
cc8c6faf 19172009-08-17 Robert Millan <rmh.grub@aybabtu.com>
1918
1919 * fs/fat.c (grub_fat_read_data): Remove `#if 0' braces around the
1920 grub_dprintf() that was just added.
1921
08aa61f0 19222009-08-17 Robert Millan <rmh.grub@aybabtu.com>
1923
1924 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT)
1925 (DEFAULT_VIDEO_MODE): Remove macros.
1926 (grub_linux_boot): Remove assumption that Linux has FB support,
1927 and use "text" as default video mode.
1928
7cef4f75 19292009-08-15 Vladimir Serbinenko <phcoder@gmail.com>
1930
1931 * fs/affs.c (grub_affs_read_symlink): Change leftover grub_printf into
1932 grub_dprintf.
1933 * fs/fat.c (grub_fat_read_data): Likewise.
1934
e1f39873 19352009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
1936
1937 * loader/i386/multiboot.c (grub_multiboot): Don't pass filename to
1938 payload.
1939 (grub_module): Likewise.
1940
c166d79e 19412009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
1942
1943 * loader/i386/multiboot.c (grub_multiboot_unload): Don't free mbi and
1944 mbi->cmdline but free playground.
1945
c60cee8e 19462009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
1947
1948 Handle group offset on UFS1.
1949
1950 * fs/ufs.c (grub_ufs_sblock): New field 'cylg_mask'.
1951 (grub_ufs_read_inode) [!MODE_UFS2]: handle cylg_offset and cylg_mask.
1952
c0d8b5d4 19532009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
1954
1955 Split ufs.mod into ufs1.mod and ufs2.mod.
1956
1957 * conf/common.rmk (grub_probe_SOURCES): Add fs/ufs2.c.
1958 (grub_fstest_SOURCES): Likewise.
1959 (pkglib_MODULES): Remove ufs.mod. Add ufs1.mod and ufs2.mod.
1960 (ufs_mod_SOURCES): Remove.
1961 (ufs_mod_CFLAGS): Likewise.
1962 (ufs_mod_LDFLAGS): Likewise.
1963 (ufs1_mod_SOURCES): New variable.
1964 (ufs1_mod_CFLAGS): Likewise.
1965 (ufs1_mod_LDFLAGS): Likewise.
25fbd77a 1966 (ufs2_mod_SOURCES): New variable.
1967 (ufs2_mod_CFLAGS): Likewise.
1968 (ufs2_mod_LDFLAGS): Likewise.
c0d8b5d4 1969 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add fs/ufs2.c.
1970 * conf/i386-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
1971 Likewise.
1972 (grub_emu_SOURCES): Likewise.
1973 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1974 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1975 (grub_setup_SOURCES): Likewise.
1976 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1977 * conf/sparc64.rmk (grub_emu_SOURCES): Likewise.
1978 (grub_setup_SOURCES): Likewise.
1979 * conf/x86_64-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
1980 Likewise.
1981 * fs/ufs2.c: New file.
1982 * fs/ufs.c: Separate UFS1 from UFS2 by using preprocessor.
1983
d3539132 19842009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
1985
1986 Framebuffer split.
1987
1988 * commands/i386/pc/vbetest.c (grub_cmd_vbetest): Restore video
1989 subsystem at the end.
1990 * conf/common.rmk (pkglib_MODULES): Add video_fb.mod.
1991 (video_fb_mod_SOURCES): New variable.
1992 (video_fb_mod_CFLAGS): Likewise.
1993 (video_fb_mod_LDFLAGS): Likewise.
1994 * conf/i386-pc.rmk (vbe_mod_SOURCES): Remove video/i386/pc/vbeblit.c,
1995 video/i386/pc/vbefill.c and video/i386/pc/vbeutil.c.
1996 * video/i386/pc/vbeblit.c: Moved from here ...
1997 * video/fb/fbblit.c: ..here. Replaced 'vbe' with 'fb'.
1998 * video/i386/pc/vbefill.c: Moved from here ...
1999 * video/fb/fbfill.c: ..here. Replaced 'vbe' with 'fb'.
2000 * video/i386/pc/vbeutil.c: Moved from here ...
2001 * video/fb/fbutil.c: ..here. Replaced 'vbe' with 'fb'.
2002 * include/grub/i386/pc/vbeblit.h: Moved from here ...
2003 * include/grub/fbblit.h: ... here. Replaced 'vbe' with 'fb'.
2004 * include/grub/i386/pc/vbefill.h: Moved from here ...
2005 * include/grub/fbfill.h: ... here. Replaced 'vbe' with 'fb'.
2006 * include/grub/i386/pc/vbeutil.h: Moved from here ...
2007 * include/grub/fbutil.h: ... here. Replaced 'vbe' with 'fb'.
2008 * include/grub/i386/pc/vbe.h: Moved framebuffer part ...
2009 * include/grub/video_fb.h: ... here. Replaced 'vbe' with 'fb'.
2010 * include/grub/video.h (GRUB_VIDEO_RENDER_TARGET_FRONT_BUFFER): Removed.
2011 (GRUB_VIDEO_RENDER_TARGET_BACK_BUFFER): Likewise.
2012 (grub_video_adapter): Added 'get_info_and_fini'.
2013 (grub_video_get_info_and_fini): New prototype.
2014 (grub_video_set_mode): make modestring const char *.
2015 * loader/i386/linux.c (grub_linux_setup_video): Use
2016 grub_video_get_info_and_fini.
2017 (grub_linux_boot): Move modesetting just before booting.
2018 * loader/i386/pc/xnu.c (grub_xnu_set_video): Use
2019 grub_video_get_info_and_fini.
2020 * video/i386/pc/vbe.c: Moved framebuffer part ...
2021 * video/fb/video_fb.c: ... here. Replaced 'vbe' with 'fb'.
2022 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): Use
2023 grub_video_fbstd_colors and grub_video_fb_set_palette.
2024 (grub_video_vbe_init): Clear 'framebuffer' variable and use
2025 grub_video_fb_init.
2026 (grub_video_vbe_fini): Use grub_video_fb_fini.
2027 (grub_video_vbe_setup): Use framebuffer.render_target instead of
2028 render_target and use grub_video_fb_set_active_render_target and
2029 grub_video_fb_set_palette.
2030 (grub_video_vbe_set_palette): Use grub_video_fb_set_palette.
2031 (grub_video_vbe_set_viewport): Use grub_video_fb_set_viewport.
2032 (grub_video_vbe_adapter): Use framebuffer.
2033 * video/video.c (grub_video_get_info_and_fini): New function.
2034 (grub_video_set_mode): Make modestring const char *.
2035 (GRUB_MOD_INIT(video_video)): Don't set variables to 0 since these
2036 values are already initialised.
2037
d404ee56 20382009-08-14 Pavel Roskin <proski@gnu.org>
2039
2040 * boot/i386/pc/cdboot.S: Use LOCAL for local labels. Eliminate
2041 ABS and APPLE_CC.
2042 * boot/i386/pc/diskboot.S: Likewise.
2043 * boot/i386/pc/lnxboot.S: Likewise. Hardcode the number of code
2044 sectors allow compilation on MacOSX.
2045 * conf/i386-pc.rmk: Enable unconditional compilation of
2046 lnxboot.img.
2047
9a10df16 20482009-08-13 Colin Watson <cjwatson@ubuntu.com>
2049
2050 * util/grub-mkconfig.in: Export GRUB_HIDDEN_TIMEOUT.
2051 * util/grub.d/00_header.in: Enter interruptible sleep if
2052 GRUB_HIDDEN_TIMEOUT is set.
2053
be3c9ca7 20542009-08-13 Yves Blusseau <blusseau@zetam.org>
2055
2056 * include/grub/symbol.h: Add the LOCAL macro.
2057 * boot/i386/pc/boot.S: Use the LOCAL macro for all labels
2058 starting with "L_".
2059
1f9e557e 20602009-08-13 Pavel Roskin <proski@gnu.org>
2061
9ca62843 2062 * boot/i386/pc/boot.S: Remove ABS macro, it's not required by
2063 any modern compilers we support.
2064
1f9e557e 2065 * boot/i386/pc/boot.S: Remove all code dependent on APPLE_CC.
2066 Use local labels starting with "L_" so that Apple assembler
2067 knows they are local.
2068
81623db6 20692009-08-10 Robert Millan <rmh.grub@aybabtu.com>
2070
2071 * include/grub/i386/bsd.h (KERNEL_TYPE_NONE, KERNEL_TYPE_FREEBSD)
2072 (KERNEL_TYPE_OPENBSD, KERNEL_TYPE_NETBSD): Convert to ...
2073 (bsd_kernel_types): ... this enum.
2074
2075 * loader/i386/bsd.c (grub_cmd_freebsd_loadenv, grub_cmd_freebsd_module)
2076 (grub_cmd_freebsd_module_elf): Abort with "You need to load the
2077 kernel first." when `kernel_type' is set to KERNEL_TYPE_NONE.
2078
2079 (grub_bsd_load_aout, grub_bsd_load, grub_cmd_freebsd_loadenv)
2080 (grub_cmd_freebsd_module, grub_cmd_freebsd_module_elf)
2081 (GRUB_MOD_INIT (bsd)): Fix capitalization in a few error
2082 messages.
2083
f5d35e7a 20842009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2085
2086 * util/grub-dumpdevtree: Moved from here ...
2087 * util/i386/efi/grub-dumpdevtree: ... to here.
2088 (hexify): New function. Converts a string to its hex version.
2089 Generate hex versions of "efi" and "device-properties" by calling
2090 hexify() on the ASCII strings rather than by hardcoding numbers.
2091
d1e1d527 20922009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2093
2094 * fs/jfs.c: Update copyright year.
2095
1ebbe064 20962009-08-08 Felix Zielcke <fzielcke@z-51.de>
2097
2098 * util/grub.d/00_header.in: Fix a comment.
2099 * util/grub.d/10_linux.in: Likewise.
2100 * util/grub.d/10_windows.in: Likewise.
2101 * util/grub.d/10_hurd.in: Likewise.
2102
a78c8d24 21032009-08-08 Felix Zielcke <fzielcke@z-51.de>
2104
2105 * util/grub-mkconfig.in: Allow the user to specify the used font
2106 with GRUB_FONT.
2107
29a6b9e8 21082009-08-08 Pavel Roskin <proski@gnu.org>
2109
b5f16cc4 2110 * include/grub/powerpc/libgcc.h: Export __ashrdi3() if
2111 available, xfs.mod needs it now.
2112
2f5cb827 2113 * util/grub-mkconfig_lib.in (version_test_numeric): Don't use
2114 the "g" modifier in sed when the intention is to strip something
2115 once. This fixes comparison of kernels with multiple dashes.
2116
29a6b9e8 2117 * util/grub-mkconfig.in: Define datarootdir, datadir may depend
2118 on it. Add missing space before closing bracket. Fix
2119 misleading formatting.
2120
892a3d98 21212009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2122
2123 * docs/grub.texi: Major overhaul. Remove all sections that are
2124 specific to GRUB Legacy, or mostly composed of Legacy-specific
2125 information.
2126
ed94253f 21272009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2128
2129 * docs/version.texi: New file. Provides version information for
2130 grub.texi.
2131
126d6628 21322009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2133
2134 * docs/grub.texi: Update CVS information to SVN.
2135 Replace outdated "GRUB 2 will include" phrase with "GRUB 2 includes".
2136
998b5aa9 21372009-08-07 Felix Zielcke <fzielcke@z-51.de>
2138
2139 * util/grub-mkconfig.in: Remove a wrong `fi'.
2140
818e094a 21412009-08-07 Felix Zielcke <fzielcke@z-51.de>
2142
2143 * fs/uuid.c (grub_jfs_superblock): New fields unused2 and uuid.
2144 (grub_jfs_uuid): New function.
2145 (grub_jfs_fs): Set uuid field to grub_jfs_uuid.
2146
b969c52f 21472009-08-07 Felix Zielcke <fzielcke@z-51.de>
2148
2149 * util/grub-mkconfig_lib.in (font_path): Move the functionality
2150 of it to ...
2151 * util/grub-mkconfig.in: ... here. Prefer unicode.pf2 and
2152 unifont.pf2 over ascii.pf2. Export LANG=C in case ascii.pf2 gets used.
2153
7a4894cc 21542009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2155
2156 * util/grub.d/10_linux.in (test_numeric): Moved from here ...
2157 * util/grub-mkconfig_lib.in (version_test_numeric): ... to here.
2158 Update all users.
2159
2160 * util/grub.d/10_linux.in (test_gt): Strip any basename prefix,
2161 not just "vmlinu[zx]".
2162 Moved from here ...
2163 * util/grub-mkconfig_lib.in (version_test_gt): ... to here. Update
2164 all users.
2165
2166 * util/grub.d/10_linux.in (find_latest): Moved from here ...
2167 * util/grub-mkconfig_lib.in (version_find_latest): ... to here. Update
2168 all users.
2169
4e2171f8 21702009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2171
2172 * util/grub.d/10_freebsd.in: Use an absolute device path for
2173 `vfs.root.mountfrom'. Set `vfs.root.mountfrom.options=rw'.
2174
6dcfcb32 21752009-08-06 Felix Zielcke <fzielcke@z-51.de>
2176
2177 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Fix
2178 handling of multiple abstraction modules.
2179
f56a8756 21802009-08-04 Robert Millan <rmh.grub@aybabtu.com>
2181
2182 Fix a bug resulting in black screen when loading Linux using a
2183 packed video mode.
2184
2185 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette_width): New
2186 function.
2187
2188 * include/grub/i386/pc/vbe.h (GRUB_VBE_CAPABILITY_DACWIDTH): New macro.
2189 (grub_vbe_bios_getset_dac_palette_width): New function.
2190 (grub_vbe_bios_get_dac_palette_width)
2191 (grub_vbe_bios_set_dac_palette_width): New macros (act as wrappers for
2192 grub_vbe_bios_getset_dac_palette_width()).
2193
2194 * video/i386/pc/vbe.c (grub_vbe_probe): Use `GRUB_VBE_STATUS_OK' to
2195 check for return status.
2196 (grub_vbe_get_video_mode_info): When getting information for a packed
2197 mode (<= 8 bpp), obtain DAC palette width using
2198 grub_vbe_bios_getset_dac_palette_width(), and use that for initializing
2199 {red,green,blue}_mark_size.
2200
222671b2 22012009-08-04 Felix Zielcke <fzielcke@z-51.de>
2202
ecb1a6d9 2203 * commands/search.c (options): Fix help output to match actual code.
222671b2 2204
f84114f5 22052009-08-02 Vladimir Serbinenko <phcoder@gmail.com>
2206
2207 * commands/hexdump.c (grub_cmd_hexdump): Use grub_disk_read instead
2208 of homegrown code.
2209
bd288a20 22102009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
e768b770 2211
2212 * util/hostfs.c (grub_hostfs_dir): Don't use DT_DIR: It doesn't work
2213 on XFS or ReiserFS.
2214
8aab5e25 22152009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
2216
2217 Support Apple partition map with sector size different from 512 bytes.
2218
2219 * partmap/apple.c (grub_apple_header): New field 'blocksize'.
2220 (apple_partition_map_iterate): Respect 'aheader.blocksize'
2221 and 'apart.partmap_size'.
2222
6ad6258a 22232009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
22242009-08-01 Robert Millan <rmh.grub@aybabtu.com>
2225
2226 Fix cpuid command.
2227
2228 * commands/i386/cpuid.c (options): New variable.
2229 (grub_cmd_cpuid): Return real error.
2230 (GRUB_MOD_INIT(cpuid)): Declare options.
2231
67459bc6 22322009-07-31 Vladimir Serbinenko <phcoder@gmail.com>
2233
2234 * partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
2235 valid.
2236
fbc6ab54 22372009-07-31 Bean <bean123ch@gmail.com>
2238
2239 * fs/xfs.c (grub_xfs_sblock): Change unused5 field to log2_sect and
2240 log2_inode.
2241 (grub_fshelp_node): Move inode field to the end.
2242 (grub_xfs_data): Remove inode field.
2243 (grub_xfs_inode_block): Calculate inode size using sblock.
2244 (grub_xfs_inode_offset): Likewise.
2245 (grub_xfs_read_inode): Calculate inode size using sblock.
2246 (grub_xfs_read_block): Replace XFS_INODE_EXTENTS with nrec.
2247 (grub_xfs_iterate_dir): Calculate inode size using sblock.
2248 (grub_xfs_mount): Use grub_zalloc instead of grub_malloc. Realloc data
2249 to match inode size.
2250 (grub_xfs_dir): goto mount_fail when mount fails, as data->diropen is
2251 not accessible when data is null.
2252 (grub_xfs_open): Likewise.
2253
f45d6cfc 22542009-07-31 Bean <bean123ch@gmail.com>
2255
2256 * disk/lvm.c (grub_lvm_scan_device): Ignore extra copy of metadata.
2257 Don't change pv->disk if it's already set.
2258
2259 * disk/raid.c (grub_raid_scan_device): Merge this function into ...
2260 (grub_raid_register): ... here.
2261 (grub_raid_rescan): Removed.
2262
2263 * include/grub/raid.h (grub_raid_rescan): Removed.
2264
2265 * util/grub-fstest.c: Remove include file <grub/raid.h>.
2266 (fstest): Replace grub_raid_rescan with module fini function followed
2267 by init function.
2268
2269 * util/grub-probe.c: Add include file <grub/raid.h>.
2270 (probe_raid_level): New function.
2271 (probe): Detect abstraction by walking the disk device, support two
2272 level of abstraction (LVM on RAID) when detecting partition map.
2273
24443b5a 22742009-07-31 Pavel Roskin <proski@gnu.org>
2275
2276 * disk/raid5_recover.c (grub_raid5_recover): Revert conversion
2277 to grub_zalloc(), it was erroneous.
2278 Reported by Bean <bean123ch@gmail.com>
2279
a275d9e7 22802009-07-30 Vladimir Serbinenko <phcoder@gmail.com>
2281
2282 * util/i386/pc/grub-setup.c (setup): Check that no partition is in
ad8ea1f4 2283 embedding zone, not only the first one.
a275d9e7 2284
56c5a47f 22852009-07-29 Joe Auricchio <jauricchio@gmail.com>
2286
2287 * term/gfxterm.c (clear_char): New function.
2288 (grub_virtual_screen_setup): Use clear_char.
2289 (scroll_up): Likewise.
2290 (grub_virtual_screen_cls): Likewise.
2291
67bb323a 22922009-07-29 Felix Zielcke <fzielcke@z-51.de>
2293
2294 * util/deviceiter.c (get_acceleraid_disk_name): New static
2295 function.
2296 (grub_util_iterate_devices): Handle Accelraid devices.
2297 * util/hostdisk.c (convert_system_partition_to_system_disk): Likewise.
2298
388a7c75 22992009-07-28 Robert Millan <rmh.grub@aybabtu.com>
2300
2301 * loader/i386/linux.c (grub_cmd_linux): Use ',' rather than ';' as
2302 separator for the suggested gfxpayload string (';' collides with the
2303 parser and needs escaping).
2304
3bb7abcf 23052009-07-28 Vladimir Serbinenko <phcoder@gmail.com>
2306
2307 * loader/i386/multiboot_helper.S (grub_multiboot_backward_relocator):
2308 Clear direction flag before jumping to OS.
2309 (grub_multiboot2_real_boot): Likewise.
2310
2ddd36d7 23112009-07-28 Felix Zielcke <fzielcke@z-51.de>
2312
2313 * util/i386/pc/grub-install: Fix parsing of --disk-module
2314 option.
2315
c521b62b 23162009-07-28 Felix Zielcke <fzielcke@z-51.de>
2317
2318 * util/i386/pc/grub-setup.c (setup): Fix 2 incorrect checks
2319 when embedding.
2320
880e0a0c 23212009-07-26 Felix Zielcke <fzielcke@z-51.de>
2322
2323 * util/grub-mkconfig.in (package_version): New variable.
2324 Use it do display the version.
2325
2366e356 23262009-07-25 Felix Zielcke <fzielcke@z-51.de>
2327
2328 * kern/file.c (grub_file_open): Revert to previous check with
2329 grub_errno.
2330
7ad8c80e 23312009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2332
2333 * commands/probe.c (GRUB_MOD_INIT (probe)): Remove "[--target=target]"
2334 from help line. It's out of sync with code.
2335
72b9658b 23362009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2337
2338 * kern/parser.c (grub_parser_execute): Fix a bug causing truncated
2339 entries on failed boot.
2340
77435277 23412009-07-25 Felix Zielcke <fzielcke@z-51.de>
2342
2343 * kern/file.c (grub_file_open): Fix an error check.
2344
fcaa8b21 23452009-07-24 Vladimir Serbinenko <phcoder@gmail.com>
2346
35d16c74 2347 * util/i386/pc/grub-setup.c (setup): Fix segmentation fault when
2348 partition map couldn't be identified.
fcaa8b21 2349
48904cd1 23502009-07-23 Pavel Roskin <proski@gnu.org>
2351
ef3c317f 2352 * commands/xnu_uuid.c (transform): Use GRUB_CPU_WORDS_BIGENDIAN
2353 instead of WORDS_BIGENDIAN. Use grub_le_to_cpu32(), so that the
2354 case of little endian words becomes just an optimization.
2355 Respect const modifier.
ad8ea1f4 2356 (md5_final): Use code that doesn't depend on endianness.
ef3c317f 2357
48904cd1 2358 * include/grub/misc.h (ALIGN_UP): Cast align to the type of addr
2359 to avoid loss of upper bits if align is unsigned and shorter
2360 than addr.
2361
260c9a89 23622009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2363
2364 UUID support for UFS
2365
2366 * fs/ufs.c (grub_ufs_sblock): Add uuidhi and uuidlow.
2367 (grub_ufs_uuid): New function.
2368 (grub_ufs_fs): add .uuid
2369
f76ce889 23702009-07-21 Pavel Roskin <proski@gnu.org>
2371
2372 * kern/dl.c (grub_dl_check_header): Make static.
2373
6a6cbcaf 23742009-07-21 Felix Zielcke <fzielcke@z-51.de>
2375
2376 * util/grub.d/30_os-prober.in: Remove unused CHAINROOT. Don't
2377 add drivemap for Vista. It breaks Windows 7.
2378
cffcddb2 23792009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2380
2381 * fs/ufs.c (grub_ufs_sblock): Fix offset of mtime2 which was off by
2382 128 bytes
2383
1ef44b80 23842009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2385
2386 Add BFS support
2387
2388 * conf/common.rmk (grub_probe_SOURCES): Add fs/befs.c.
2389 (grub_fstest_SOURCES): Likewise.
2390 (pkglib_MODULES): Add befs.mod.
2391 (befs_mod_SOURCES): New variable.
2392 (befs_mod_CFLAGS): Likewise.
2393 (befs_mod_LDFLAGS): Likewise.
2394 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
2395 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2396 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2397 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2398 (grub_setup_SOURCES): Likewise.
2399 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2400 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2401 (grub_setup_SOURCES): Likewise.
2402 * fs/befs.c: New file.
2403 * fs/afs.c (GRUB_AFS_FSNAME): New declaration.
2404 (GRUB_AFS_SBLOCK_SECTOR): Likewise.
2405 (GRUB_AFS_SBLOCK_MAGIC1) [MODE_BFS]: New conditional declaration.
2406 (GRUB_AFS_BTREE_MAGIC) [MODE_BFS]: Likewise
2407 (B_KEY_INDEX_ALIGN): New declaration.
2408 (B_KEY_INDEX_OFFSET): Use B_KEY_INDEX_ALIGN.
2409 (grub_afs_bnode) [MODE_BFS]: Make key_count and key_size 16-bit
2410 (grub_afs_btree) [MODE_BFS]: New conditional declaration.
2411 (grub_afs_sblock) [MODE_BFS]: Remove link_count.
2412 (grub_afs_validate_sblock) [MODE_BFS]: Support BFS
2413 (grub_afs_mount) [MODE_BFS]: Likewise.
2414 (grub_afs_dir) [MODE_BFS]: Divide mtime by 65536 and not 1000000.
2415 (grub_afs_fs): Use GRUB_AFS_FSNAME
2416 (GRUB_MOD_INIT (afs)) [MODE_BFS]: Rename to ...
2417 (GRUB_MOD_INIT (befs)) [MODE_BFS]: ... this
2418 (GRUB_MOD_FINI (afs)) [MODE_BFS]: Rename to ...
2419 (GRUB_MOD_FINI (befs)) [MODE_BFS]: ... this
2420
4f253044 24212009-07-19 Yves BLUSSEAU <yves.grub-devel@zetam.org>
2422
2423 * util/getroot.c (find_root_device): Add support for MacOSX.
2424 * util/hostdisk.c: Likewise.
2425
57a55913 24262009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2427
2428 * font/font.c (find_glyph): Check whether a font is present to avoid
2429 segmentation fault.
75421ca9 2430
24312009-07-20 Joe Auricchio <jauricchio@gmail.com>
04c7c429 2432
2433 * term/gfxterm.c (grub_virtual_screen_setup): Clear virtual_screen.
2434
e98cd0c2 24352009-07-20 Pavel Roskin <proski@gnu.org>
2436
2437 * configure.ac: Trim excessively wordy excuses.
2438
1d2d169a 24392009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2440
2441 Add symlink, mtime and label support to AtheFS.
2442
2443 * fs/afs.c (grub_afs_sblock): Declare `name' as char.
2444 (grub_afs_iterate_dir): Handle symlinks.
2445 (grub_afs_open): Use grub_afs_read_symlink.
2446 (grub_afs_dir): Likewise.
2447 Pass mtime.
2448 (grub_afs_label): New function.
2449 (grub_afs_fs): Add grub_afs_label.
2450 (grub_afs_read_symlink): New function.
2451
186f3189 24522009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2453
2454 Fix AtheFS support.
2455
2456 * fs/afs.c: Fix comments style.
2457 (grub_afs_blockrun): Declare as packed.
2458 (grub_afs_datastream): Likewise.
2459 (grub_afs_bnode): Likewise.
2460 (grub_afs_btree): Likewise.
2461 (grub_afs_sblock): Likewise.
2462 Declare `name' as char.
2463 (grub_afs_inode): Declare as packed.
2464 Change void *vnode to grub_uint32_t unused.
2465 (grub_afs_iterate_dir): Check that key_size is positive.
2466 (grub_afs_mount): Don't read superblock twice.
75421ca9 2467 (grub_afs_dir): Don't free node in case of error,
186f3189 2468 grub_fshelp_find_file already handles this.
2469 (grub_afs_open): Likewise.
2470
5680109e 24712009-07-19 Pavel Roskin <proski@gnu.org>
2472
2473 * Makefile.in: Remove LIBLZO and enable_lzo.
2474 * conf/i386-pc.rmk: Remove lzo support.
2475 * configure.ac: Remove checks for lzo, don't define ENABLE_LZMA.
2476 * include/grub/i386/pc/kernel.h: Define ENABLE_LZMA. Remove lzo
2477 support.
2478 * kern/i386/pc/lzo1x.S: Remove.
2479 * kern/i386/pc/startup.S: Remove lzo support.
2480 * util/i386/pc/grub-mkimage.c: Likewise.
2481
ac70fa32 24822009-07-19 Vladimir Serbinenko <phcoder@gmail.com>
2483
2484 * disk/usbms.c (grub_usbms_transfer): Fix double semicolon.
2485 * fs/xfs.c (grub_xfs_dir): Likewise.
2486 * fs/afs.c (grub_afs_dir): Likewise.
2487 * fs/iso9660.c (grub_iso9660_iterate_dir): Likewise.
2488 (grub_iso9660_open): Likewise.
2489 * fs/jfs.c (grub_jfs_open): Likewise.
2490 * fs/ext2.c (grub_ext2_dir): Likewise.
2491 * include/grub/macho.h (grub_macho_fat_arch): Likewise.
2492 * script/sh/lexer.c (grub_script_yylex): Likewise.
75421ca9 2493
eab58da2 24942009-07-16 Pavel Roskin <proski@gnu.org>
2495
d2838156 2496 * configure.ac: Never add "-c" to CFLAGS.
2497
55c70904 2498 * configure.ac: Fix incorrect comparison for grub_cv_cc_efiemu.
2499
43e6200c 2500 * configure.ac: Fix wrong use of grub_cv_cc_no_red_zone where
2501 grub_cv_cc_efiemu should be used.
2502
ce7a733d 2503 * configure.ac: Typo fixes.
2504
eab58da2 2505 * kern/mm.c (grub_zalloc): New function.
2506 (grub_debug_zalloc): Likewise.
2507 * include/grub/mm.h: Declare grub_zalloc() and
2508 grub_debug_zalloc().
2509 * util/misc.c (grub_zalloc): New function.
2510 * bus/usb/uhci.c (grub_uhci_pci_iter): Use grub_zalloc()
2511 instead of grub_malloc(), remove unneeded initializations.
2512 * bus/usb/usbhub.c (grub_usb_hub_add_dev): Likewise.
2513 * commands/extcmd.c (grub_extcmd_dispatcher): Likewise.
2514 * commands/parttool.c (grub_cmd_parttool): Likewise.
2515 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Likewise.
2516 * disk/raid5_recover.c (grub_raid5_recover): Likewise.
2517 * disk/raid6_recover.c (grub_raid6_recover): Likewise.
2518 * disk/usbms.c (grub_usbms_finddevs): Likewise.
2519 * efiemu/mm.c (grub_efiemu_request_memalign): Likewise.
2520 * efiemu/pnvram.c (grub_efiemu_pnvram): Likewise.
2521 (grub_cmd_efiemu_pnvram): Likewise.
2522 * fs/i386/pc/pxe.c (grub_pxefs_open): Likewise.
2523 * fs/iso9660.c (grub_iso9660_mount): Likewise.
2524 (grub_iso9660_iterate_dir): Likewise.
2525 * fs/jfs.c (grub_jfs_opendir): Likewise.
2526 * fs/ntfs.c (list_file): Likewise.
2527 (grub_ntfs_mount): Likewise.
2528 * kern/disk.c (grub_disk_open): Likewise.
2529 * kern/dl.c (grub_dl_load_core): Likewise.
2530 * kern/elf.c (grub_elf_file): Likewise.
2531 * kern/env.c (grub_env_context_open): Likewise.
2532 (grub_env_set): Likewise.
2533 (grub_env_set_data_slot): Likewise.
2534 * kern/file.c (grub_file_open): Likewise.
2535 * kern/fs.c (grub_fs_blocklist_open): Likewise.
2536 * loader/i386/multiboot.c (grub_module): Likewise.
2537 * loader/xnu.c (grub_xnu_create_key): Likewise.
2538 (grub_xnu_create_value): Likewise.
2539 * normal/main.c (grub_normal_add_menu_entry): Likewise.
2540 (read_config_file): Likewise.
2541 * normal/menu_entry.c (make_screen): Likewise.
2542 * partmap/sun.c (sun_partition_map_iterate): Likewise.
2543 * script/sh/lexer.c (grub_script_lexer_init): Likewise.
2544 * script/sh/script.c (grub_script_parse): Likewise.
2545 * video/bitmap.c (grub_video_bitmap_create): Likewise.
2546 * video/readers/jpeg.c (grub_video_reader_jpeg): Likewise.
2547 * video/readers/png.c (grub_png_output_byte): Likewise.
2548 (grub_video_reader_png): Likewise.
2549
830afef7 25502009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
5ce5507f 2551
2552 Enable all targets that can be built by default
2553
830afef7 2554 * configure.ac: enable efiemu runtime, grub-emu, grub-emu-usb,
5ce5507f 2555 grub-mkfont and grub-fstest if they can be built
2556
ee293aee 25572009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2558
2559 Fix hang and segmentation fault in grub-emu-usb
2560
2561 * disk/scsi.c (grub_scsi_open): return err and not grub_errno
2562 * util/usb.c (grub_libusb_devices): likewise
2563 (grub_libusb_init): rename to ...
2564 (GRUB_MOD_INIT (libusb)):...this
2565 (grub_libusb_fini): rename to ..
2566 (GRUB_MOD_FINI (libusb)):...this
2567 * disk/usbms.c (grub_usbms_transfer): fix retry logic
2568 * include/grub/disk.h (grub_raid_init): removed, it's useless
2569 (grub_raid_fini): likewise
2570 (grub_lvm_init): likewise
2571 (grub_lvm_fini): likewise
2572 * util/grub-emu.c (main): don't call grub_libusb_init, it's done
2573 by grub_init_all
2574
94414221 25752009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2576
2577 Fix libusb
2578
2579 * Makefile.in (LIBUSB): new macro
2580 * genmk.rb (Utility/print_tail): new method
2581 (Utility/rule): use intermediary variable #{prefix}_OBJECTS
2582 (top level): call util.print_tail at the end.
2583
59ade63d 25842009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2585
2586 Make FreeBSD accept zpool.cache
2587
2588 * loader/i386/bsd.c (grub_freebsd_add_meta_module): spoof filename if
2589 type is /boot/zfs/zpool.cache
2590
a58da8c7 25912009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2592
2593 Fix 64-bit efiemu
2594
2595 * include/grub/efiemu/efiemu.h (grub_efiemu_configuration_table64_t):
2596 correct wrong typedef
2597 * efiemu/prepare.c (SUFFIX (grub_efiemu_prepare)): minor style fixes
2598
20591577 25992009-07-15 Pavel Roskin <proski@gnu.org>
2600
560ca572 2601 * include/grub/disk.h (struct grub_disk_dev): Use enum for id.
2602 * kern/disk.c (struct grub_disk_cache): Likewise.
2603
e8e8e4fd 2604 * commands/probe.c (options): Typo fix.
2605
fde24e10 2606 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_BPB_END):
2607 Increase to 0x5a to accommodate FAT32. Adjust other offsets
2608 accordingly.
2609 Original patch by Yves Blusseau <yves.grub-devel@zetam.org>
2610
379c54c1 2611 * boot/i386/pc/boot.S (general_error_string): Add DOS newline at
2612 the end of "Error" to make the message more readable.
2613
7bd8f5bf 2614 * boot/i386/pc/boot.S (kernel_segment): Remove.
2615 (copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
2616 for destination.
2617
40b132c5 2618 * boot/i386/pc/boot.S (boot_version): Remove.
2619 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
2620 Remove.
2621
20591577 2622 * include/grub/i386/pc/boot.h: Sort all offsets.
2623 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Remove, it's unused.
2624 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Likewise.
2625 * boot/i386/pc/boot.S: Assert location of every offset listed in
2626 include/grub/i386/pc/boot.h.
2627
2df32b2c 26282009-07-13 Pavel Roskin <proski@gnu.org>
2629
44b5d879 2630 * include/grub/i386/coreboot/machine.h: Rename
2631 GRUB_MACHINE_LINUXBIOS to GRUB_MACHINE_COREBOOT.
2632 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Allow
2633 multiboot 1 for GRUB_MACHINE_COREBOOT and GRUB_MACHINE_QEMU.
2634
17dc3751 2635 * kern/dl.c: Force native word size to suppress warnings when
2636 compiling grub-emu.
2637
2df32b2c 2638 * kern/device.c (grub_device_iterate): Change struct part_ent to
2639 hold the name, not a pointer to it. Use one grub_malloc() per
2640 partition, not two. Free partition_name if grub_malloc() fails.
2641 Set ents to NULL only before grub_partition_iterate() is called.
2642
75c59f59 26432009-07-11 Bean <bean123ch@gmail.com>
2644
2645 * kern/ieee1275/openfw.c (grub_children_iterate): Fix size of
2646 childname.
2647
0ae1bf88 26482009-07-10 Bean <bean123ch@gmail.com>
26492009-07-10 Robert Millan <rmh.grub@aybabtu.com>
2650
2651 * kern/ieee1275/openfw.c (grub_children_iterate)
2652 (grub_devalias_iterate): Fix size evaluation for property or path
2653 strings, which was broken since r2132.
2654
8279cade 26552009-07-07 Pavel Roskin <proski@gnu.org>
2656
7d8a52d3 2657 * commands/search.c (search_file): Merge into ...
2658 (search_fs): ... this. Accept search type as argument.
2659 (grub_cmd_search): Pass search type to search_fs().
2660
25f9a05a 2661 * include/grub/util/console.h: New file.
2662 * util/console.c: Use it instead of grub/machine/console.h.
2663 * util/grub-emu.c: Likewise.
2664
8279cade 2665 * lib/arg.c (find_long_option): Remove.
2666 (find_long): Add `len' argument, make `s' const char *.
2667 (grub_arg_parse): Parse long options in place, not in a
2668 temporary buffer.
2669
4a11b60f 26702009-07-06 Pavel Roskin <proski@gnu.org>
2671
99f68041 2672 * commands/search.c (search_fs): Fix potential NULL pointer
2673 dereference.
2674
4a11b60f 2675 * commands/search.c (search_fs): Replace QUID macro with quid_fn
2676 function pointer.
2677
e110f4de 26782009-07-06 Daniel Mierswa <impulze@impulze.org>
2679
2680 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
2681 comparison.
2682
46eeb6a2 26832009-07-05 Pavel Roskin <proski@gnu.org>
2684
bab74958 2685 * include/grub/i386/linux.h (struct linux_kernel_params):
2686 Restore padding3, it's still needed.
2687
46eeb6a2 2688 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
2689 FreeBSD.
2690 * util/osdetect.lua: Likewise.
2691
b4a1dc79 26922009-07-05 Bean <bean123ch@gmail.com>
2693
2694 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
2695
2696 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
2697 (grub_lua_getenv): Likewise.
2698 (grub_lua_setenv): Likewise.
2699 (save_errno): New function.
2700 (push_result): Likewise.
2701 (grub_lua_enum_device): Likewise.
2702 (grub_lua_enum_file): Likewise.
2703 (grub_lua_file_open): Likewise.
2704 (grub_lua_file_close): Likewise.
2705 (grub_lua_file_seek): Likewise.
2706 (grub_lua_file_read): Likewise.
2707 (grub_lua_file_getline): Likewise.
2708 (grub_lua_file_getsize): Likewise.
2709 (grub_lua_file_getpos): Likewise.
2710 (grub_lua_file_eof): Likewise.
2711 (grub_lua_file_exist): Likewise.
2712 (grub_lua_add_menu): Likewise.
2713
2714 * script/lua/grub_lua.h (isupper): New inline function.
2715 (islower): Likewise.
2716 (ispunct): Likewise.
2717 (isxdigit): Likewise.
2718 (strcspn): Change to normal function.
2719 (strpbkr): New function declaration.
2720 (memchr): Likewise.
2721
2722 * script/lua/grub_main.c (scan_str): New function.
2723 (strcspn): Likewise.
2724 (strpbrk): Likewise.
2725 (memchr): Likewise.
2726
2727 * script/lua/linit.c (lualibs): Enable the string library.
2728
2729 * util/osdetect.lua: New file.
2730
2da92295 27312009-07-04 Robert Millan <rmh.grub@aybabtu.com>
2732
2733 * include/grub/i386/linux.h (struct linux_kernel_params): Add
2734 `capabilities' member.
2735
b2582ec9 27362009-07-02 Pavel Roskin <proski@gnu.org>
2737
2738 * genparttoollist.sh: Add missing newline at the end.
2739
32622956 27402009-07-01 Pavel Roskin <proski@gnu.org>
2741
87a7339e 2742 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
2743
d23af54e 2744 * util/hostdisk.c (open_device): Remove `const' from
2745 `sysctl_size', as sysctlbyname() can change it (in this case it
2746 doesn't actually happen).
2747
c94b18a9 2748 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
2749 using signed long int constants.
2750
c6cd3ef0 2751 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
2752 constant to avoid a warning on FreeBSD.
2753
0df63420 2754 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
2755 where it's needed.
2756
999577f1 2757 * Makefile.in: Install include/grub/machine symlink.
2758
6f41557f 2759 * Makefile.in: When installing symlinks, use "cp -fR", which
2760 works on FreeBSD and MacOSX.
2761 From Yves Blusseau <cl7m42e02@sneakemail.com>
2762
c8d22988 2763 * kern/dl.c (grub_dl_resolve_symbol): Make static.
2764 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
2765
1b96e952 2766 * util/misc.c: Move grub_reboot() and grub_halt() ...
2767 * util/grub-emu.c: ... here. Make main_env static.
2768 * include/grub/util/misc.h: Remove main_env.
2769
2ef0084d 2770 * kern/mm.c: Use correct format to print size_t.
2771
32622956 2772 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
2773 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
2774 * kern/powerpc/dl.c: Likewise.
2775 * kern/sparc64/dl.c: Likewise.
2776 * kern/x86_64/dl.c: Likewise.
2777
3f7f0cd0 27782009-07-01 Robert Millan <rmh.grub@aybabtu.com>
2779
2780 Fix grub-emu build on sparc64-ieee1275.
2781
75421ca9 2782 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Synchronize with ...
3f7f0cd0 2783 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
2784
211d06b5 27852009-07-01 Robert Millan <rmh.grub@aybabtu.com>
2786
2787 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
2788 (grub_reboot, grub_halt): New functions.
2789
2790 * util/i386/pc/misc.c: Delete. Update all users.
2791 * util/sparc64/ieee1275/misc.c: Likewise.
2792 * util/powerpc/ieee1275/misc.c: Likewise.
2793
aaf53e3c 27942009-07-01 Robert Millan <rmh.grub@aybabtu.com>
2795
2796 * conf/i386.rmk (setjmp_mod_SOURCES)
2797 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
2798 * conf/common.rmk (setjmp_mod_SOURCES)
2799 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
2800 to use $(target_cpu).
2801 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
2802 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
2803 * conf/powerpc-ieee1275.rmk: Likewise.
2804 * conf/sparc64-ieee1275.rmk: Likewise.
2805
2806 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
2807 $(target_cpu) for kern/$(target_cpu)/dl.c.
2808 * conf/i386-efi.rmk: Likewise.
2809 * conf/i386-ieee1275.rmk: Likewise.
2810 * conf/x86_64-efi.rmk: Likewise.
2811 * conf/i386-coreboot.rmk: Likewise.
2812 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
2813 $(target_cpu) for kern/$(target_cpu)/dl.c and for
2814 kern/$(target_cpu)/cache.S.
2815 * conf/sparc64-ieee1275.rmk: Likewise.
2816
a337130b 28172009-07-01 Robert Millan <rmh.grub@aybabtu.com>
2818
2819 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
2820 type to `grub_uint8_t', and adjust `padding9' accordingly.
2821
c6fe4d53 28222009-06-29 Robert Millan <rmh.grub@aybabtu.com>
2823
b09db61d 2824 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
2825
c6fe4d53 2826 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
2827 assembly in final jump, using register constraints.
2828
b09db61d 2829 (grub_linux_boot): For text mode, initialize `have_vga' using
2830 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
2831
2832 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
2833 right before the final jump.
2834
2835 Set `video_mode' to 0x3.
2836
2837 Document initialization of `video_page', `video_mode' and
2838 `video_ega_bx'.
2839
28333ad0 28402009-06-29 Robert Millan <rmh.grub@aybabtu.com>
2841
2842 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
2843 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
75421ca9 2844 and set GRUB_LINUX_FLAG_QUIET appropriately.
28333ad0 2845
02164e1b 28462009-06-29 Robert Millan <rmh.grub@aybabtu.com>
2847
2848 Fix build on Debian / sparc.
2849
2850 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
2851
18b6c557 28522009-06-28 Pavel Roskin <proski@gnu.org>
2853
85f2aab6 2854 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
2855 fix a warning.
2856
18b6c557 2857 * util/grub.d/10_linux.in: Match SUSE style initrd names.
2858
ad760f81 28592009-06-27 Robert Millan <rmh.grub@aybabtu.com>
2860
2861 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
2862 `err'.
2863
87a4623b 28642009-06-27 Robert Millan <rmh.grub@aybabtu.com>
2865
2866 Revert r2338.
2867
2868 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
2869 file can't be opened. grub_file_open() is already supposed to set
75421ca9 2870 grub_errno / grub_errmsg appropriately.
87a4623b 2871 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
2872
8231fb77 28732009-06-27 Pavel Roskin <proski@gnu.org>
28742009-06-27 Robert Millan <rmh.grub@aybabtu.com>
2875
2876 * include/grub/dl.h: Include grub/elf.h.
2877 (struct grub_dl): Add symtab field.
2878 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
2879 GRUB_MODULES_MACHINE_READONLY.
2880 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
2881 of the header for read-only modules.
2882 (grub_dl_unload): Free mod->symtab for read-only modules.
2883 * kern/i386/dl.c: Use mod->symtab.
2884 * kern/powerpc/dl.c: Likewise.
2885 * kern/sparc64/dl.c: Likewise.
2886 * kern/x86_64/dl.c: Likewise.
2887
2888 * conf/i386-qemu.rmk: New file.
2889 * kern/i386/qemu/startup.S: Likewise.
2890 * kern/i386/qemu/mmap.c: Likewise.
2891 * boot/i386/qemu/boot.S: Likewise.
2892 * include/grub/i386/qemu/time.h: Likewise.
2893 * include/grub/i386/qemu/serial.h: Likewise.
2894 * include/grub/i386/qemu/kernel.h: Likewise.
2895 * include/grub/i386/qemu/console.h: Likewise.
2896 * include/grub/i386/qemu/boot.h: Likewise.
2897 * include/grub/i386/qemu/init.h: Likewise.
2898 * include/grub/i386/qemu/machine.h: Likewise.
2899 * include/grub/i386/qemu/loader.h: Likewise.
2900 * include/grub/i386/qemu/memory.h: Likewise.
2901
2902 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
2903 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
2904 [qemu] (pkglib_IMAGES): Add `boot.img'.
2905 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
2906 [qemu] (boot_img_FORMAT): New variables.
2907 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
2908 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
2909 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
2910 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
2911 [qemu] (kernel_img_FORMAT): New variables.
2912
2913 * configure.ac: Recognise `i386-qemu'.
2914
2915 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
2916 (for no compression).
2917 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
2918 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
2919 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
2920 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
2921 ifdefs).
2922
97fe384e 29232009-06-27 Pavel Roskin <proski@gnu.org>
2924
2925 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
2926 read.
2927 * efiemu/prepare32.c: Likewise.
2928 * efiemu/prepare64.c: Likewise.
2929
c402ab17 29302009-06-26 Pavel Roskin <proski@gnu.org>
2931
2932 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
2933 * include/grub/elf.h: Define symbols without "32" or "64" based
2934 on GRUB_TARGET_WORDSIZE.
2935 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
2936 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
2937 ELF definitions.
2938 * efiemu/loadcore64.c: Likewise.
2939 * loader/i386/bsd32.c: Likewise.
2940 * loader/i386/bsd64.c: Likewise.
2941 * kern/dl.c: Remove own ELF definitions.
2942 * util/i386/efi/grub-mkimage.c: Likewise.
2943
9bbdfd4d 29442009-06-23 Robert Millan <rmh.grub@aybabtu.com>
2945
2946 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
2947 segment 0x0 unconditionally, because the reference generated by
2948 GAS is an absolute address.
2949
a42ce6e9 29502009-06-22 Robert Millan <rmh.grub@aybabtu.com>
2951
2952 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
2953 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
2954
c952cf92 29552009-06-22 Robert Millan <rmh.grub@aybabtu.com>
2956
2957 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
2958 indexes. Check for -f explicitly.
cc3752ad 2959 (search_file): Improve error message.
2960 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
c952cf92 2961
132a0a59 29622009-06-22 Robert Millan <rmh.grub@aybabtu.com>
2963
2964 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
2965 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
2966
387a140c 29672009-06-22 Robert Millan <rmh.grub@aybabtu.com>
2968
2969 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
2970 * conf/i386-ieee1275.rmk: Likewise.
2971 * conf/i386-coreboot.rmk: Likewise.
2972
2973 * kern/i386/pc/startup.S (grub_stop): Remove function.
2974 * kern/i386/ieee1275/startup.S: Likewise.
2975 * kern/i386/coreboot/startup.S: Likewise.
2976 * kern/i386/misc.S (grub_stop): New function.
2977
41da9665 29782009-06-22 Robert Millan <rmh.grub@aybabtu.com>
2979
2980 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
2981 * kern/i386/realmode.S (real_to_prot): ... to here.
2982
bf337234 29832009-06-22 Robert Millan <rmh.grub@aybabtu.com>
2984
2985 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
2986 with `kernel.img'.
2987 (kernel_elf_SOURCES): Rename to ...
2988 (kernel_img_SOURCES): ... this.
2989 (kernel_elf_HEADERS): Rename to ...
2990 (kernel_img_HEADERS): ... this. Update all users.
2991 (kernel_elf_ASFLAGS): Rename to ...
2992 (kernel_img_ASFLAGS): ... this.
2993 (kernel_elf_CFLAGS): Rename to ...
2994 (kernel_img_CFLAGS): ... this.
2995 (kernel_elf_LDFLAGS): Rename to ...
2996 (kernel_img_LDFLAGS): ... this.
2997 * conf/i386-coreboot.rmk: Likewise.
2998 * conf/powerpc-ieee1275.rmk: Likewise.
2999
3000 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
3001 with "kernel.img".
3002
f52196ff 30032009-06-21 Pavel Roskin <proski@gnu.org>
3004
c3cee413 3005 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
3006 to match nested functions.
3007 * loader/sparc64/ieee1275/linux.c: Likewise.
3008
f52196ff 3009 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
3010
58750afc 30112009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3012
3013 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
3014 all i386 platforms.
3015
15355c7d 30162009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3017
3018 Fix asm file handling on ELF, and remove workarounds.
3019
3020 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
75421ca9 3021 and -DASM_FILE=1 appropriately (copied from `class Images' stanza).
15355c7d 3022 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
3023 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
3024
3f3ec72b 30252009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
3026
3027 Load BSD ELF modules
3028
3029 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
3030 and loader/i386/bsd64.c
3031 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
3032 (FREEBSD_MODTYPE_ELF_MODULE): New definition
3033 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
3034 (grub_freebsd_load_elfmodule32): New declaration
3035 (grub_freebsd_load_elfmoduleobj64): Likewise
3036 (grub_freebsd_load_elf_meta32): Likewise
3037 (grub_freebsd_load_elf_meta64): Likewise
3038 (grub_freebsd_add_meta): Likewise
3039 (grub_freebsd_add_meta_module): Likewise
3040 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
3041 (grub_freebsd_add_meta_module): Likewise and move module-specific
3042 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
3043 (grub_cmd_freebsd): Add elf-kernel specific parts
3044 based on grub_freebsd_add_meta_module
3045 (grub_cmd_freebsd_module): Add type parsing moved from
3046 grub_freebsd_add_meta_module
3047 (grub_cmd_freebsd_module_elf): New function
3048 (cmd_freebsd_module_elf): New variable
3049 (GRUB_MOD_INIT): Register freebsd_module_elf
3050 * loader/i386/bsd32.c: New file
3051 * loader/i386/bsd64.c: Likewise
3052 * loader/i386/bsdXX.c: Likewise
3053 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
3054 (grub_elf64_load): Likewise
3055 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
3056 All users updated
3057 (grub_elf64_load_hook_t): Likewise
3058
0db15301 30592009-06-21 Colin Watson <cjwatson@ubuntu.com>
3060
3061 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
3062 variable.
3063 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
3064 don't write a menu entry for recovery mode.
3065
546796c1 30662009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3067
3068 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
3069 after it's no longer needed.
3070
cd7310d5 30712009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3072
3073 * include/grub/i386/loader.h (grub_linux_prot_size)
3074 (grub_linux_tmp_addr, grub_linux_real_addr)
3075 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
3076 GRUB_MACHINE_PCBIOS.
3077 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
3078 common grub_util_info() call to ...
3079 (generate_image): ... here.
3080 Fix use of uninitialized memory, comparison of signed with
3081 unsigned integers and memory leak.
3082 Remove bogus module address message.
3083
ab32d3b5 30842009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
3085
3086 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
3087 grub_raid_register
3088 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
3089
024ef597 30902009-06-19 Pavel Roskin <proski@gnu.org>
3091
3092 * configure.ac: Remove stray AC_MSG_CHECKING.
3093
3ac72b51 30942009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
3095
3096 * disk/scsi.c (grub_scsi_open): use continue instead of big if
dd74360c 3097
e14cd814 30982009-06-18 Pavel Roskin <proski@gnu.org>
3099
3100 * conf/common.rmk: Add fs_file.mod.
3101 * disk/fs_file.c: New file.
3102 * include/grub/disk.h (enum grub_disk_dev_id): Add
3103 GRUB_DISK_DEVICE_FILE_ID.
3104
26586d98 31052009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3106
3107 Fix build with Apple's toolchain. Part 2
3108
3109 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
3110 a fake start
3111
26de2bcd 31122009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3113
3114 Fix build with Apple's toolchain. Part 1
3115
3116 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
3117 for long calls
3118 * configure.ac: remove a leftover AC_MSG_RESULT
dd74360c 3119 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
26de2bcd 3120 Apple's toolchain
3121
09b3490b 31222009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3123
3124 Fix warnings
3125
3126 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
3127 (decomp_block): initialize ch
3128 use grub_memcpy instead of memcpy
3129
c22a006a 31302009-06-17 Pavel Roskin <proski@gnu.org>
3131
d3638678 3132 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
3133 version, use declarations needed to use vga_text as the startup
3134 console.
3135
c22a006a 3136 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
3137 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
3138 the kernel.
3139 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
3140 and grub_at_keyboard_fini(), it's done on module load and
3141 unload.
3142
05b129e0 31432009-06-17 Felix Zielcke <fzielcke@z-51.de>
3144
3145 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
3146 file can't be found.
3147 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3148
cf24ed9e 31492009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3150
3151 Fix newline handling
3152
3153 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
dd74360c 3154 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
cf24ed9e 3155 (grub_script_yylex): don't segfault on unterminated script
3156 newline terminates command and variable
3157
74aa8e4b 31582009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3159
3160 avoid double grub_adjust_range call. Bug reported by David Simner
3161
3162 * kern/disk.c (grub_disk_write): change to raw disk access before
3163 calling disk_read
3164
1bd265f3 31652009-06-17 Colin Watson <cjwatson@ubuntu.com>
3166
3167 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
3168 spaces, for the benefit of help2man.
3169 * util/i386/efi/grub-mkimage.c (usage): Likewise.
3170
a2d08c06 31712009-06-16 Pavel Roskin <proski@gnu.org>
3172
3173 * kern/i386/halt.c: Include grub/machine/init.h.
3174 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
3175
b97bcb19 31762009-06-16 Felix Zielcke <fzielcke@z-51.de>
3177
3178 * util/grub.d/30_os-prober.in: Use ${root} in the generated
3179 drivemap menuentry.
3180
0644f96c 31812009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
3182
3183 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
3184 `echo' command.
3185
3ef17a2e 31862009-06-16 Pavel Roskin <proski@gnu.org>
3187
3188 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
3189 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
3190 save %dx, we only need %dl and we never change it.
3191 * boot/i386/pc/cdboot.S: Don't set the root drive.
3192 * boot/i386/pc/pxeboot.S: Likewise.
3193 * include/grub/i386/pc/boot.h: Remove
3194 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
3195 GRUB_BOOT_MACHINE_DRIVE_CHECK.
3196 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
3197 * kern/i386/pc/init.c (make_install_device): Remove references
3198 to grub_root_drive.
3199 * kern/i386/pc/startup.S: Likewise.
3200 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
3201
693fe637 32022009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3203
3204 xnu_uuid command
3205
3206 * commands/xnu_uuid.c: new file
3207 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
3208 (xnu_uuid_mod_SOURCES): new variable
3209 (xnu_uuid_mod_CFLAGS): likewise
3210 (xnu_uuid_mod_LDFLAGS): likewise
3211 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3212 * conf/i386-ieee1275.rmk: likewise
3213 * conf/i386-pc.rmk: likewise
3214 * conf/powerpc-ieee1275.rmk: likewise
3215 * conf/sparc64-ieee1275.rmk: likewise
3216 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
3217
c9da87d0 32182009-06-16 Pavel Roskin <proski@gnu.org>
3219
3220 * configure.ac: Avoid '==' in test command, it's not portable.
3221
9c6f4596 32222009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3223
3224 Probe command
3225
3226 * commands/probe.c: new file
3227 * conf/common.rmk (pkglib_MODULES): add probe.mod
3228 (probe_mod_SOURCES): new variable
3229 (probe_mod_CFLAGS): likewise
3230 (probe_mod_LDFLAGS): likewise
3231 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3232 * conf/i386-ieee1275.rmk: likewise
3233 * conf/i386-pc.rmk: likewise
3234 * conf/powerpc-ieee1275.rmk: likewise
3235 * conf/sparc64-ieee1275.rmk: likewise
3236
70b7f9fd 32372009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
3238
3239 Fix handling of string like \"hello\" and "a
3240 b"
3241
3242 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
3243 (grub_script_yylex): fix parsing of quoting, escaping and newline
3244
71c79a6b 32452009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
3246
dd74360c 3247 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
71c79a6b 3248 handling
dd74360c 3249
0644f96c 32502009-06-13 Jun Inoue <jun.lambda@gmail.com>
880fc3c4 3251
3252 * util/grub-mkconfig.in: Fix parsing of --output option.
3253
e40893c3 32542009-06-12 Pavel Roskin <proski@gnu.org>
3255
3256 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
3257 genmk.rb don't need to be generated or installed.
3258
3a1acfe2 32592009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
3260
3261 * commands/i386/pc/drivemap_int13h.S: add more comments
3262
3a4575d4 32632009-06-11 Pavel Roskin <proski@gnu.org>
3264
0658e928 3265 * Makefile.in (uninstall): Uninstall manuals.
3266
ca0388f0 3267 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
3268 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
3269 and update-grub_lib in two places.
3270 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
3271
e3b27c39 3272 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
3273 a compiler warning.
3274
3a4575d4 3275 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
3276 `entry_lo' to fix variable shadowing.
3277
af1f4f55 32782009-06-11 Christian Franke <franke@computer.org>
3279
3280 * kern/misc.c (__enable_execute_stack): Add missing return type
3281 to prevent gcc warning.
3282
5225e649 32832009-06-11 Felix Zielcke <fzielcke@z-51.de>
3284
3285 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
3286
7d83bd47 32872009-06-11 Pavel Roskin <proski@gnu.org>
3288
c1cb63ba 3289 * Makefile.in: Don't rely on any scripts being executable.
3290 Always use $(SHELL) to run shell scripts.
3291
7d83bd47 3292 * configure.ac: Always define ___main if using -nostdlib. This
3293 fixes tests on Cygwin.
3294
948f48e7 32952009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
3296
3297 UDF fix
3298
7d83bd47 3299 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
948f48e7 3300 is in bytes and not in blocks
7d83bd47 3301
8ada9bc1 33022009-06-11 Pavel Roskin <proski@gnu.org>
3303
3304 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
3305 warning.
3306
25ad2323 33072009-06-11 Felix Zielcke <fzielcke@z-51.de>
3308
3309 * util/grub.d/30_os-prober.in: Fix a comment. Source
3310 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
3311 to set the root device. Place drivemap command in the generated
3312 chain entry.
3313
e65acb0c 33142009-06-11 Pavel Roskin <proski@gnu.org>
3315
3316 * configure.ac: Remove host_m32. Issues with 64-bit utilities
3317 have long been resolved.
3318
f285fe2d 33192009-06-11 Colin Watson <cjwatson@ubuntu.com>
3320
bd47b0b5 3321 * util/grub.d/10_linux.in: Capitalise "Linux".
3322
f285fe2d 3323 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
3324
a0c62e4e 33252009-06-11 Pavel Roskin <proski@gnu.org>
3326
b6783cb2 3327 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
3328 fix a gcc warning and ensure that the function won't ever exit.
3329
dde032e8 3330 * kern/i386/ieee1275/init.c: Add missing prototype for
3331 grub_stop_floppy().
3332
22cd079d 3333 * loader/ieee1275/multiboot2.c [__i386__]: Include
3334 grub/cpu/multiboot.h.
3335
a0c62e4e 3336 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
3337 casts to short - they are not portable and cause warnings. Fix
3338 use of uninitialized values in input_buf. Use ARRAY_SIZE.
3339
63963d17 33402009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
3341
3342 Drivemap fixes
3343
3344 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
3345 new function
3346 (grub_get_root_biosnumber_saved): new variable
3347 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
3348 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
775dbc4d 3349 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
63963d17 3350 %dx after the call if necessary
3351 * conf/common.rmk (pkglib_MODULES): remove boot.mod
3352 (boot_mod_SOURCES): remove
3353 (boot_mod_CFLAGS): remove
3354 (boot_mod_LDFLAGS): remove
3355 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
3356 (boot_mod_SOURCES): new variable
3357 (boot_mod_CFLAGS): likewise
3358 (boot_mod_LDFLAGS): likewise
3359 * conf/i386-efi.rmk: likewise
3360 * conf/i386-ieee1275.rmk: likewise
3361 * conf/i386-pc.rmk: likewise
3362 * conf/powerpc-ieee1275.rmk: likewise
3363 * conf/sparc64-ieee1275.rmk: likewise
3364 * conf/x86_64-efi.rmk: likewise
3365 * include/grub/i386/pc/biosnum.h: new file
3366 * lib/i386/pc/biosnum.c: likewise
3367 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
3368 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
3369 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
775dbc4d 3370
33abf7ae 33712009-06-10 Pavel Roskin <proski@gnu.org>
3372
5ac35b35 3373 * io/gzio.c (test_header): Don't reuse one buffer for all data.
3374 Use separate variables. Read only the file size at the end, but
3375 not the checksum that we don't use.
3376
5c5215d5 3377 * kern/file.c (grub_file_read): Use void pointer for the buffer.
3378 Adjust all callers.
3379
27d5fef7 3380 * kern/ieee1275/openfw.c: Remove libc includes.
3381 * kern/ieee1275/cmain.c: Likewise.
3382 * include/grub/ieee1275/ieee1275.h: Likewise.
3383
33abf7ae 3384 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
3385 compiler warnings.
3386
19d50c2b 33872009-06-10 Felix Zielcke <fzielcke@z-51.de>
3388
3389 * Makefile.in: Remove all trailing whitespace.
3390 * conf/i386-pc.rmk: Likewise.
3391 * conf/powerpc-ieee1275.rmk: Likewise.
3392 * conf/sparc64-ieee1275.rmk: Likewise.
3393 * docs/grub.texi: Likewise.
3394 * docs/texinfo.tex: Likewise.
3395 * disk/fs_uuid.c: Likewise.
3396 * disk/lvm.c: Likewise.
3397 * disk/scsi.c: Likewise.
3398 * disk/ata.c: Likewise.
3399 * disk/ieee1275/ofdisk.c: Likewise.
3400 * disk/i386/pc/biosdisk.c: Likewise.
3401 * disk/host.c: Likewise.
3402 * disk/raid.c: Likewise.
3403 * disk/efi/efidisk.c: Likewise.
3404 * disk/usbms.c: Likewise.
3405 * disk/memdisk.c: Likewise.
3406 * disk/loopback.c: Likewise.
3407 * kern/powerpc/dl.c: Likewise.
3408 * kern/device.c: Likewise.
3409 * kern/dl.c: Likewise.
3410 * kern/sparc64/dl.c: Likewise.
3411 * kern/ieee1275/ieee1275.c: Likewise.
3412 * kern/term.c: Likewise.
3413 * kern/fs.c: Likewise.
3414 * kern/i386/dl.c: Likewise.
3415 * kern/i386/pc/startup.S: Likewise.
3416 * kern/i386/pc/init.c: Likewise.
3417 * kern/i386/pc/mmap.c: Likewise.
3418 * kern/i386/pc/lzo1x.S: Likewise.
3419 * kern/i386/ieee1275/init.c: Likewise.
3420 * kern/i386/realmode.S: Likewise.
3421 * kern/i386/tsc.c: Likewise.
3422 * kern/partition.c: Likewise.
3423 * kern/corecmd.c: Likewise.
3424 * kern/file.c: Likewise.
3425 * kern/efi/efi.c: Likewise.
3426 * kern/efi/init.c: Likewise.
3427 * kern/efi/mm.c: Likewise.
3428 * kern/main.c: Likewise.
3429 * kern/err.c: Likewise.
3430 * kern/env.c: Likewise.
3431 * kern/disk.c: Likewise.
3432 * kern/generic/millisleep.c: Likewise.
3433 * kern/generic/rtc_get_time_ms.c: Likewise.
3434 * kern/misc.c: Likewise.
3435 * kern/parser.c: Likewise.
3436 * genmk.rb: Likewise.
3437 * configure.ac: Likewise.
3438 * boot/i386/pc/diskboot.S: Likewise.
3439 * boot/i386/pc/pxeboot.S: Likewise.
3440 * boot/i386/pc/boot.S: Likewise.
3441 * boot/i386/pc/lnxboot.S: Likewise.
3442 * boot/i386/pc/cdboot.S: Likewise.
3443 * parttool/pcpart.c: Likewise.
3444 * video/readers/tga.c: Likewise.
3445 * video/video.c: Likewise.
3446 * video/bitmap.c: Likewise.
3447 * lib/envblk.c: Likewise.
3448 * lib/i386/setjmp.S: Likewise.
3449 * fs/xfs.c: Likewise.
3450 * fs/afs.c: Likewise.
3451 * fs/fat.c: Likewise.
3452 * fs/ntfs.c: Likewise.
3453 * fs/udf.c: Likewise.
3454 * fs/affs.c: Likewise.
3455 * fs/iso9660.c: Likewise.
3456 * fs/hfs.c: Likewise.
3457 * fs/fshelp.c: Likewise.
3458 * fs/ext2.c: Likewise.
3459 * fs/jfs.c: Likewise.
3460 * fs/reiserfs.c: Likewise.
3461 * fs/hfsplus.c: Likewise.
3462 * fs/minix.c: Likewise.
3463 * fs/cpio.c: Likewise.
3464 * fs/sfs.c: Likewise.
3465 * fs/ufs.c: Likewise.
3466 * efiemu/prepare.c: Likewise.
3467 * efiemu/loadcore_common.c: Likewise.
3468 * efiemu/runtime/efiemu.sh: Likewise.
3469 * efiemu/runtime/efiemu.S: Likewise.
3470 * efiemu/runtime/efiemu.c: Likewise.
3471 * efiemu/pnvram.c: Likewise.
3472 * efiemu/main.c: Likewise.
3473 * efiemu/i386/pc/cfgtables.c: Likewise.
3474 * efiemu/i386/loadcore64.c: Likewise.
3475 * efiemu/i386/loadcore32.c: Likewise.
3476 * efiemu/loadcore.c: Likewise.
3477 * efiemu/symbols.c: Likewise.
3478 * efiemu/mm.c: Likewise.
3479 * include/grub/autoefi.h: Likewise.
3480 * include/grub/datetime.h: Likewise.
3481 * include/grub/term.h: Likewise.
3482 * include/grub/hfs.h: Likewise.
3483 * include/grub/lvm.h: Likewise.
3484 * include/grub/i386/tsc.h: Likewise.
3485 * include/grub/i386/linux.h: Likewise.
3486 * include/grub/i386/xnu.h: Likewise.
3487 * include/grub/i386/efiemu.h: Likewise.
3488 * include/grub/i386/pc/biosdisk.h: Likewise.
3489 * include/grub/i386/pc/memory.h: Likewise.
3490 * include/grub/i386/pc/vbe.h: Likewise.
3491 * include/grub/parttool.h: Likewise.
3492 * include/grub/video.h: Likewise.
3493 * include/grub/memory.h: Likewise.
3494 * include/grub/fs.h: Likewise.
3495 * include/grub/partition.h: Likewise.
3496 * include/grub/xnu.h: Likewise.
3497 * include/grub/efi/api.h: Likewise.
3498 * include/grub/efi/pe32.h: Likewise.
3499 * include/grub/efi/memory.h: Likewise.
3500 * include/grub/multiboot.h: Likewise.
3501 * include/grub/usbdesc.h: Likewise.
3502 * include/grub/multiboot2.h: Likewise.
3503 * include/grub/acpi.h: Likewise.
3504 * include/grub/efiemu/efiemu.h: Likewise.
3505 * include/grub/disk.h: Likewise.
3506 * include/grub/ieee1275/ieee1275.h: Likewise.
3507 * include/grub/net.h: Likewise.
3508 * include/grub/machoload.h: Likewise.
3509 * include/grub/macho.h: Likewise.
3510 * include/multiboot.h: Likewise.
3511 * genmoddep.awk: Likewise.
3512 * normal/main.c: Likewise.
3513 * normal/menu_entry.c: Likewise.
3514 * normal/menu_viewer.c: Likewise.
3515 * normal/completion.c: Likewise.
3516 * normal/cmdline.c: Likewise.
3517 * normal/misc.c: Likewise.
3518 * normal/datetime.c: Likewise.
3519 * bus/usb/usbtrans.c: Likewise.
3520 * bus/usb/ohci.c: Likewise.
3521 * bus/usb/uhci.c: Likewise.
3522 * bus/usb/usb.c: Likewise.
3523 * mmap/efi/mmap.c: Likewise.
3524 * mmap/i386/pc/mmap_helper.S: Likewise.
3525 * mmap/i386/pc/mmap.c: Likewise.
3526 * mmap/i386/mmap.c: Likewise.
3527 * mmap/i386/uppermem.c: Likewise.
3528 * mmap/mmap.c: Likewise.
3529 * commands/acpi.c: Likewise.
3530 * commands/echo.c: Likewise.
3531 * commands/blocklist.c: Likewise.
3532 * commands/loadenv.c: Likewise.
3533 * commands/usbtest.c: Likewise.
3534 * commands/boot.c: Likewise.
3535 * commands/parttool.c: Likewise.
3536 * commands/search.c: Likewise.
3537 * commands/cat.c: Likewise.
3538 * commands/i386/pc/play.c: Likewise.
3539 * commands/i386/pc/drivemap.c: Likewise.
3540 * commands/i386/pc/vbeinfo.c: Likewise.
3541 * commands/i386/pc/acpi.c: Likewise.
3542 * commands/i386/pc/vbetest.c: Likewise.
3543 * commands/ls.c: Likewise.
3544 * commands/cmp.c: Likewise.
3545 * commands/test.c: Likewise.
3546 * commands/efi/acpi.c: Likewise.
3547 * commands/gptsync.c: Likewise.
3548 * commands/help.c: Likewise.
3549 * partmap/amiga.c: Likewise.
3550 * partmap/apple.c: Likewise.
3551 * partmap/acorn.c: Likewise.
3552 * partmap/pc.c: Likewise.
3553 * partmap/sun.c: Likewise.
3554 * partmap/gpt.c: Likewise.
3555 * script/sh/lexer.c: Likewise.
3556 * script/sh/function.c: Likewise.
3557 * font/font.c: Likewise.
3558 * font/font_cmd.c: Likewise.
3559 * loader/powerpc/ieee1275/linux.c: Likewise.
3560 * loader/efi/chainloader.c: Likewise.
3561 * loader/multiboot_loader.c: Likewise.
3562 * loader/macho.c: Likewise.
3563 * loader/i386/multiboot.c: Likewise.
3564 * loader/i386/linux.c: Likewise.
3565 * loader/i386/pc/linux.c: Likewise.
3566 * loader/i386/pc/multiboot2.c: Likewise.
3567 * loader/i386/pc/chainloader.c: Likewise.
3568 * loader/i386/pc/xnu.c: Likewise.
3569 * loader/i386/bsd_trampoline.S: Likewise.
3570 * loader/i386/efi/linux.c: Likewise.
3571 * loader/i386/multiboot_elfxx.c: Likewise.
3572 * loader/i386/bsd_helper.S: Likewise.
3573 * loader/i386/bsd.c: Likewise.
3574 * loader/i386/linux_trampoline.S: Likewise.
3575 * loader/i386/xnu_helper.S: Likewise.
3576 * loader/i386/xnu.c: Likewise.
3577 * loader/i386/bsd_pagetable.c: Likewise.
3578 * loader/i386/multiboot_helper.S: Likewise.
3579 * loader/xnu.c: Likewise.
3580 * loader/xnu_resume.c: Likewise.
3581 * io/gzio.c: Likewise.
3582 * term/efi/console.c: Likewise.
3583 * term/terminfo.c: Likewise.
3584 * term/ieee1275/ofconsole.c: Likewise.
3585 * term/i386/pc/serial.c: Likewise.
3586 * term/i386/pc/vesafb.c: Likewise.
3587 * term/i386/pc/vga.c: Likewise.
3588 * term/usb_keyboard.c: Likewise.
3589 * term/gfxterm.c: Likewise.
3590 * aclocal.m4: Likewise.
3591 * util/lvm.c: Likewise.
3592 * util/grub.d/30_os-prober.in: Likewise.
3593 * util/grub.d/10_hurd.in: Likewise.
3594 * util/console.c: Likewise.
3595 * util/grub-macho2img.c: Likewise.
3596 * util/grub-probe.c: Likewise.
3597 * util/hostfs.c: Likewise.
3598 * util/i386/pc/grub-mkimage.c: Likewise.
3599 * util/i386/pc/grub-setup.c: Likewise.
3600 * util/i386/efi/grub-mkimage.c: Likewise.
3601 * util/grub-mkconfig.in: Likewise.
3602 * util/raid.c: Likewise.
3603 * util/resolve.c: Likewise.
3604 * util/grub-mkdevicemap.c: Likewise.
3605 * util/grub-emu.c: Likewise.
3606 * util/getroot.c: Likewise.
3607 * util/hostdisk.c: Likewise.
3608 * util/usb.c: Likewise.
3609 * util/grub-editenv.c: Likewise.
3610 * util/misc.c: Likewise.
3611
d2d49665 36122009-06-10 Felix Zielcke <fzielcke@z-51.de>
3613
3614 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
3615 `genparttoollist.sh'.
3616 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
3617 Add `*.sh' to the list find searches for and change `mdate.sh'
3618 to `mdate-sh'.
3619
fe052e37 36202009-06-10 Pavel Roskin <proski@gnu.org>
3621
2763ac18 3622 * include/grub/multiboot2.h: Provide compatibility defines for
3623 multiboot2.h.
3624 * include/multiboot2.h: Include stdint.h only if needed, using
3625 angle brackets.
3626 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
3627 grub/multiboot2.h.
3628 * loader/ieee1275/multiboot2.c: Likewise.
3629 * loader/multiboot2.c: Likewise.
3630 * loader/multiboot_loader.c: Likewise.
3631
437e6adc 3632 * configure.ac: Use -nostdlib when probing for the target. It
3633 should not be required to have libc for the target.
3634
06a6836c 3635 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
3636 they fail without libc headers for the target.
3637 * include/grub/powerpc/libgcc.h: Use weak attribute for all
3638 exports.
3639 * include/grub/sparc64/libgcc.h: Likewise. Don't use
3640 preprocessor conditionals.
3641
fe052e37 3642 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
3643 build system doesn't need to be aware of the tar.c internals.
3644
afd22553 36452009-06-09 Michel Hermier <michel.hermier@gmail.com>
87b8f28c 3646
afd22553 3647 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
8ec4a6d0 3648
6b787c4f 36492009-06-09 Robert Millan <rmh.grub@aybabtu.com>
3650
3651 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
3652 disk limit to 26 for IDE, Virtio, Xen and SCSI.
3653
36542009-06-09 Felix Zielcke <fzielcke@z-51.de>
3655
3656 * util/i386/pc/grub-install.in: Change the error message if UUIDs
473d1e45 3657 aren't available if ata.mod gets used.
6b787c4f 3658
473d1e45 36592009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
e23721e8 3660
473d1e45 3661 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
e23721e8 3662 initialising controller.
473d1e45 3663 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
e23721e8 3664
255a27d4 36652009-06-08 Felix Zielcke <fzielcke@z-51.de>
3666
3667 * util/i386/pc/grub-install.in: Add a parameter --disk-module
3668 to choose between ata and biosdisk module on i386-pc.
3669
473d1e45 36702009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
69da8877 3671
d55842d8 3672 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
3673 Subclass and Programming Interface fields in terms of the 3 byte
3674 Class Code register.
3675 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
3676
fa5db0b1 3677 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
3678 interface is OHCI. Add grub_dprintf for symmetry with
3679 bus/usb/uhci.c.
3680 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
3681 interface is UHCI. Add interf variable for programming
3682 interface. Print interface with class/subclass.
3683
c0947beb 3684 * bus/usb/ohci.c: Set interf with correct field.
3685
69da8877 3686 * bus/usb/uhci.c: Remove unneeded doubled lines.
3687 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
3688 Remove whitespace inside comment.
3689
9e172e30 36902009-06-08 Robert Millan <rmh.grub@aybabtu.com>
3691
3692 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
3693 as fallback an equivalent option without depth.
3694
de65ee2b 36952009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
3696
3697 Not fail if unable to retrieve C/H/S on LBA disks
3698
473d1e45 3699 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
de65ee2b 3700 if unable to retrieve C/H/S on LBA disks
3701
b57ea2c9 37022009-06-08 Pavel Roskin <proski@gnu.org>
3703
3704 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
3705 about aliasing.
3706
af361263 37072009-06-08 Felix Zielcke <fzielcke@z-51.de>
3708
3709 * Makefile.in (uninstall): Remove all $lib_DATA files.
3710
4c9ec6b3 37112009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
3712
3713 Bugfix: install on partitionless device
3714
3715 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
3716 is a whole disk
3717
e76fc924 37182009-06-08 Felix Zielcke <fzielcke@z-51.de>
3719
3720 * Makefile.in (uninstall): Remove all $include_DATA files.
3721
ba5a0d05 37222009-06-08 Felix Zielcke <fzielcke@z-51.de>
3723
3724 * commands/true.c: New file. Implement the true and false commands.
3725 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
3726 (true_mod_SOURCES): New variable.
3727 (true_mod_CFLAGS): Likewise.
3728 (true_mod_LDFLAGS): Likewise.
3729
c8048e32 37302009-06-05 Colin D Bennett <colin@gibibit.com>
3731
3732 Optimized font character lookup using binary search instead of linear
3733 search. Fonts now are required to have the character index ordered by
3734 code point.
3735
3736 * font/font.c (load_font_index): Verify that fonts have ordered
3737 character indices.
3738 (find_glyph): Use binary search instead of linear search to find a
3739 character in a font.
3740
408305be 37412009-06-05 Michael Scherer <misc@mandriva.org>
3742
3743 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
3744 uses case sensitive btree.
3745 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
3746 only for case insensitive filesystems.
3747
8ee1e0d9 37482009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
3749
3750 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
3751 * conf/common.rmk (search_mod_CFLAGS): likewise
3752
a9966eb1 37532009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3754
473d1e45 3755 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
a9966eb1 3756 compensate a compiler bug
3757
9e7100fb 37582009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3759
473d1e45 3760 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
9e7100fb 3761 instead of '\b'
473d1e45 3762
ede21d71 37632009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3764
3765 Definitions for creating asm symbols with Apple's CC
3766
3767 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
3768 [APPLE_CC] (VARIABLE): likewise
3769
9dbf7653 37702009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3771
3772 Disable lnxboot.img when compiled
3773 with Apple's CC
3774
3775 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
3776 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
3777 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
3778 [! APPLE_CC] (CODE_LENG): skip
3779 [! APPLE_CC] (setup_sects): likewise
3780 [! APPLE_CC]: skip filling
473d1e45 3781
e93cdc3d 37822009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3783
3784 Address in trampolines based on 32-bit registers when compiled
3785 with Apple's CC
3786
473d1e45 3787 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
e93cdc3d 3788 for addresses
3789 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
3790
6c688477 37912009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3792
3793 Avoid aliases when compiling with Apple's CC for PCBIOS machine
3794
3795 * kern/misc.c [APPLE_CC] (memcpy): new function
3796 [APPLE_CC] (memmove): likewise
3797 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
473d1e45 3798 (memcpy): define alias conditionally on !APPLE_CC
6c688477 3799 (memset): likewise
3800 (abort): likewise
3801 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
3802 APPLE_CC are defined
3803 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
3804 (grub_assert_fail): make prototype conditional
3805
e37ffc5c 38062009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3807
3808 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
3809
473d1e45 3810 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
3811 grub-macho2img
e37ffc5c 3812 (CLEANFILES): add grub-macho2img
3813 (grub_macho2img_SOURCES): new variable
3814 * kern/i386/pc/startup.S (bss_start): new variable
3815 (bss_end): likewise
3816 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
3817 * util/grub-macho2img.c: new file
3818
cf00df31 38192009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3820
3821 Use objconv when compiling with Apple's CC
3822
3823 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
3824 (efiemu64.o): likewise
3825 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
3826 when compiling with Apple's CC
3827 (efiemu64_s.o): likewise
3828 * configure.ac: check for objconv when compiling with Apple's CC
3829 * genmk.rb: use objconv for modules when compiled with Apple's CC
473d1e45 3830
d119a20c 38312009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3832
3833 Define segment as well as section when compiling with
3834 Apple's CC
3835
3836 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
3837 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
3838 (efiemu_convert_pointer): likewise
3839 (efiemu_set_virtual_address_map): likewise
3840 (efiemu_convert_pointer): likewise
3841 (efiemu_getcrc32): likewise
3842 (init_crc32_table): likewise
3843 (reflect): likewise
3844 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
3845 (GRUB_MOD_DEP): likewise
473d1e45 3846
c8600122 38472009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3848
3849 Allow a compilation without -mcmodel=large
3850
3851 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
3852 when compiled without -mcmodel=large
473d1e45 3853 (filter_memory_map): remove memory post 4 GiB when compiled
c8600122 3854 without -mcmodel=large
473d1e45 3855 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
c8600122 3856 TARGET_CFLAGS when -mcmodel=large isn't supported
473d1e45 3857
e8df1d4e 38582009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3859
3860 Remove nested functions in efiemu core
3861
3862 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
473d1e45 3863
cc6c3ac1 38642009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3865
3866 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
3867
3868 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
3869 temporary storage
473d1e45 3870 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
3871 using Apple's CC
cc6c3ac1 3872 (grub_cpu_is_tsc_supported): likewise
3873 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
473d1e45 3874
3e325901 38752009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3876
3877 Absolute addressing through constant with Apple's cc
3878
3879 * kern/i386/pc/startup.S: Define necessary constants
3880 and address through it when using ABS with Apple's CC
3881 * boot/i386/pc/diskboot.S: likewise
3882 * boot/i386/pc/boot.S: likewise
3883 * boot/i386/pc/lnxboot.S: likewise
3884 * boot/i386/pc/cdboot.S: likewise
3885 * mmap/i386/pc/mmap_helper.S: likewise
3886 * commands/i386/pc/drivemap_int13h.S: likewise
3887
2b167a72 38882009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3889
3890 Check if compiler is apple cc
3891
3892 * Makefile.in (ASFLAGS): new variable
3893 (TARGET_ASFLAGS): likewise
3894 (TARGET_MODULE_FORMAT): likewise
3895 (TARGET_APPLE_CC): likewise
3896 (OBJCONV): likewise
3897 (TARGET_IMG_CFLAGS): likewise
3898 (TARGET_CPPFLAGS): add includedir
3899 * configure.ac: call grub_apple_cc and grub_apple_target_cc
3900 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
3901 Check for linker script only if compiler isn't Apple's CC
3902 (TARGET_MODULE_FORMAT): set
3903 (TARGET_APPLE_CC): likewise
3904 (TARGET_ASFLAGS): likewise
3905 (ASFLAGS): likewise
3906 Check for objcopy only if compiler isn't Apple's CC
3907 Check for BSS symbol only if compiler isn't Apple's CC
3908 * genmk.rb: adapt nm options if we use Apple's utils
3909 * aclocal.m4 (grub_apple_cc): new test
3910 (grub_apple_target_cc): likewise
473d1e45 3911
fb14123e 39122009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3913
3914 Simplify sed expressions and improve awk
3915
3916 * Makefile.in (install-local): simplify sed expression
3917 * gencmdlist.sh: likewise
3918 * genmoddep.awk: avoid adding module as a dependency of itself
3919
5b889789 39202009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3921
3922 Add missing start symbols
3923
3924 * boot/i386/pc/boot.S: add start
fb14123e 3925 * boot/i386/pc/pxeboot.S: likewise
473d1e45 3926
fd2bf2e3 39272009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3928
3929 Fix wrong assumptions with grub-mkimage on EFI
473d1e45 3930
3931 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
fd2bf2e3 3932 (relocate_addresses): consider both r_addend and value at offset
3933 (make_mods_section): zerofill modinfo and header
3934 (convert_elf): write prefix here
473d1e45 3935
5389763d 39362009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3937
3938 Use .asciz instead of .string
3939
3940 * i386/pc/diskboot.S: use .asciz instead of .string
3941 * i386/pc/boot.S: likewise
3942 * include/grub/dl.h (GRUB_MOD_DEP): likewise
3943 (GRUB_MOD_NAME): likewise
473d1e45 3944
3eb5ed4e 39452009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3946
3947 gfxpayload support
3948
3949 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
3950 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
3951 (grub_video_setup): remove
3952 (grub_video_set_mode): new prototype
3953 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
3954 (vid_mode): remove
3955 (linux_vesafb_res): compile only on PCBIOS
3956 (grub_linux_boot): support gfxpayload
3957 * loader/i386/pc/xnu.c (video_hook): new function
3958 (grub_xnu_set_video): support gfxpayload
3959 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
3960 (DEFAULT_VIDEO_HEIGHT): likewise
3961 (DEFAULT_VIDEO_FLAGS): likewise
3962 (DEFAULT_VIDEO_MODE): new definition
3963 (video_hook): new function
3964 (grub_gfxterm_init): use grub_video_set_mode
473d1e45 3965 * util/grub.d/30_os-prober.in: remove explicit modesetting before
3eb5ed4e 3966 loading xnu
3967 * video/video.c (grub_video_setup): removed
473d1e45 3968 (grub_video_set_mode): new function based on grub_gfxterm_init and
3eb5ed4e 3969 grub_video_setup
3970
4b0e1143 39712009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3972
3973 Avoid calling biosdisk in drivemap
3974
3975 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
3976 (revparse_biosdisk): likewise
3977 (list_mappings): derive name from id directly
3978 (grub_cmd_drivemap): use tryparse_diskstring
473d1e45 3979
fda6cb98 39802009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
3981
3982 Script fixes
3983
3984 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
3985 (grub_lexer_param): add tokenonhold
3986 (grub_script_create_cmdline): remove cmdline. All callers updated
3987 (grub_script_function_create): make functionname
3988 grub_script_arg. All callers updated
3989 (grub_script_execute_argument_to_string): new prototype
3990 * kern/parser.c (state_transitions): reorder
3991 (grub_parser_cmdline_state): fix a bug and make more compact
473d1e45 3992 * script/sh/execute.c (grub_script_execute_argument_to_string):
fda6cb98 3993 make global
3994 (grub_script_execute_cmdline): use new format
3995 * script/sh/function.c (grub_script_function_create): make functionname
3996 grub_script_arg. All callers updated
473d1e45 3997 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
fda6cb98 3998 (grub_script_yylex): remove
3999 (grub_script_yylex2): renamed to ...
4000 (grub_script_yylex): ...renamed
4001 parse the expressions like a${b}c
4002 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
4003 (GRUB_PARSER_TOKEN_VAR): remove
4004 (GRUB_PARSER_TOKEN_NAME): likewise
4005 ("if"): declare as typeless
4006 ("while"): likewise
4007 ("function"): likewise
4008 ("else"): likewise
4009 ("then"): likewise
4010 ("fi"): likewise
4011 (text): remove
4012 (argument): likewise
4013 (script): accept empty scripts and make exit on error
4014 (arguments): use GRUB_PARSER_TOKEN_ARG
4015 (function): likewise
4016 (command): move error handling to script
4017 (menuentry): move grub_script_lexer_ref before
473d1e45 4018 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
fda6cb98 4019 argument. All callers updated
4020
f4448a07 40212009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4022
4023 Prevent GRUB from probing floppies during boot.
4024
4025 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
4026 * commands/search.c (options): Add --no-floppy.
4027 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
4028 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
4029 --no-floppy when searching for UUIDs.
4030
2bf5885a 40312009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4032
4033 Simplify the code duplication in commands/search.c.
4034
4035 * commands/search.c (search_label, search_fs_uuid): Merge into ...
4036 (search_fs): ... this. Update all users.
4037
f6fd460a 40382009-06-03 Felix Zielcke <fzielcke@z-51.de>
4039
4040 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
4041
cbb3c83e 40422009-05-28 Pavel Roskin <proski@gnu.org>
4043
57788cfd 4044 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
4045 Remove the original symlink explicitly.
4046
cbb3c83e 4047 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
4048 just one slash. That's how grub_fshelp_find_file() does it.
4049
cd0d5e30 40502009-05-26 Pavel Roskin <proski@gnu.org>
4051
f0f8bbe2 4052 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
4053 to `str'.
4054
cd0d5e30 4055 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
4056 possibly unused.
4057
8c2cab51 40582009-05-25 Christian Franke <franke@computer.org>
4059
4060 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
4061 register.
4062 (grub_atapi_identify): Add wait after drive select.
4063 (grub_ata_identify): Do more strict status register check before
4064 calling grub_atapi_identify (). Suppress error message if status
4065 register is 0x00 after command failure. Add status register
4066 check after PIO read to avoid bogus identify due to stuck DRQ.
4067 Thanks to Pavel Roskin for testing.
4068 (grub_device_initialize): Remove unsafe status register check.
4069 Thanks to 'phcoder' for problem report and patch.
4070 Prevent sign extension in debug message.
4071
230c0ad6 40722009-05-23 Colin D Bennett <colin@gibibit.com>
4073
4074 Cleaned up `include/grub/normal.h'. Grouped prototypes by
4075 definition file, and functions defined in `normal/menu.c' have had
4076 their prototypes moved to `include/grub/menu.h' for consistency.
4077
4078 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
4079 from normal.h.
4080 (grub_menu_get_entry): Likewise.
4081 (grub_menu_get_timeout): Likewise.
4082 (grub_menu_set_timeout): Likewise.
4083 (grub_menu_execute_entry): Likewise.
4084 (grub_menu_execute_with_fallback): Likewise.
4085 (grub_menu_entry_run): Likewise.
4086
4087 * include/grub/normal.h: Re-ordered and grouped function
4088 prototypes by file that the function is defined in.
4089 (grub_menu_execute_callback): Removed; moved to menu.h.
4090 (grub_menu_get_entry): Likewise.
4091 (grub_menu_get_timeout): Likewise.
4092 (grub_menu_set_timeout): Likewise.
4093 (grub_menu_execute_entry): Likewise.
4094 (grub_menu_execute_with_fallback): Likewise.
4095 (grub_menu_entry_run): Likewise.
4096 (grub_menu_addentry): Renamed from this ...
4097 (grub_normal_add_menu_entry): ... to this.
4098
4099 * normal/main.c (grub_menu_addentry): Renamed from this ...
4100 (grub_normal_add_menu_entry): ... to this.
4101
4102 * script/sh/execute.c (grub_script_execute_menuentry): Update
4103 reference to renamed grub_menu_addentry function.
4104
861f03a5 41052009-05-23 Felix Zielcke <fzielcke@z-51.de>
4106
4107 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
4108
96b1619a 41092009-05-22 Pavel Roskin <proski@gnu.org>
4110
bf6a5fb2 4111 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
4112 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
4113 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
4114 compiling for the i386 targets, but not for the utilities.
4115
96b1619a 4116 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
4117 to grub_uint8_t.
4118 (grub_root_drive): Likewise.
4119 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
4120 remove alignment.
4121 (grub_root_drive): Change size to byte.
4122 (grub_start_addr): Remove.
4123 (grub_end_addr): Likewise.
4124 (grub_apm_bios_info): Likewise.
4125
b729776b 41262009-05-21 Felix Zielcke <fzielcke@z-51.de>
4127
4128 * normal/i386: Remove.
4129 * normal/powerpc: Likewise.
4130 * normal/sparc64: Likewise.
4131 * normal/x86_64: Likewise.
4132
0a15ce80 41332009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
4134
4135 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
473d1e45 4136 * loader/i386/linux_trampoline.S: Fix indentation
0a15ce80 4137 * loader/i386/xnu_helper.S: Likewise
d6da58e6 4138
33db9015 41392009-05-18 Colin D Bennett <colin@gibibit.com>
4140
d6da58e6 4141 Display error messages when parsing a Lua statement fails.
4142 Previously, executing a syntactically invalid statement like
4143 ")foo" or "bar;" would silently fail.
33db9015 4144
4145 * script/lua/grub_main.c (handle_lua_error): New function.
d6da58e6 4146 (grub_lua_parse_line): Improved reporting of Lua parser and
4147 execution errors.
33db9015 4148
46422c89 41492009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4150
4151 Remove -Werror which causes build to fail on some systems
4152
4153 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
4154 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
4155 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
18f547ad 4156
22f53a96 41572009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4158
4159 trampoline for linux on 64-bit platform
4160
18f547ad 4161 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
4162 loader/i386/efi/linux_trampoline.S
4163 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
473d1e45 4164 declaration
d6da58e6 4165 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
4166 here
22f53a96 4167 * loader/i386/linux_trampoline.S: moved here
d6da58e6 4168 * loader/i386/efi/linux.c (allocate_pages): reserve space for
4169 trampoline
22f53a96 4170 (jumpvector): removed
4171 (grub_linux_trampoline_start): new declaration
4172 (grub_linux_trampoline_end): likewise
4173 (grub_linux_boot): use trampoline when on 64-bit platform
4174 * loader/i386/linux.c: likewise
4175
cb5a0f40 41762009-05-16 Pavel Roskin <proski@gnu.org>
4177
4178 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
4179 const to avoid a warning.
4180 (grub_lua_setenv): Likewise.
4181 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
4182 lmsg to fix a warning.
4183
334f2c28 41842009-05-16 Felix Zielcke <fzielcke@z-51.de>
4185
4186 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
7dd10fce 4187 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4188 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
4189 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4190 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4191 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4192 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4193 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
334f2c28 4194
59e5d3ec 41952009-05-16 Felix Zielcke <fzielcke@z-51.de>
4196
4197 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
4198
9d87a1ba 41992009-05-16 Bean <bean123ch@gmail.com>
4200
4201 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
4202 (lua_mod_SOURCES): New variable.
4203 (lua_mod_CFLAGS): Likewise.
4204 (lua_mod_LDFLAGS): Likewise.
4205
4206 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
4207 (setjmp_mod_SOURCES): New variable.
4208 (setjmp_mod_CFLAGS): Likewise.
4209 (setjmp_LDFLAGS): Likewise.
4210
4211 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
4212 (setjmp_mod_SOURCES): New variable.
4213 (setjmp_mod_CFLAGS): Likewise.
4214 (setjmp_LDFLAGS): Likewise.
4215
4216 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4217 (setjmp_mod_SOURCES): New variable.
4218 (setjmp_mod_CFLAGS): Likewise.
4219 (setjmp_LDFLAGS): Likewise.
4220
4221 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4222 (setjmp_mod_SOURCES): New variable.
4223 (setjmp_mod_CFLAGS): Likewise.
4224 (setjmp_LDFLAGS): Likewise.
4225
4226 * normal/i386/setjmp.S: Moved from here ...
4227 * lib/i386/setjmp.S: ... Moved here
4228 * normal/x86_64/setjmp.S: Moved from here ...
4229 * lib/x86_64/setjmp.S: ... Moved here
4230 * normal/powerpc/setjmp.S: Moved from here ...
4231 * lib/powerpc/setjmp.S: ... Moved here
4232 * normal/sparc64/setjmp.S: Moved from here ...
4233 * lib/sparc64/setjmp.S: ... Moved here
4234
4235 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
4236 returns_twice in mingw.
4237
4238 * script/lua/grub_lib.c: New file.
4239 * script/lua/grub_lib.h: Likewise.
4240 * script/lua/grub_lua.h: Likewise.
4241 * script/lua/grub_main.c: Likewise.
4242 * script/lua/lapi.c: Likewise.
4243 * script/lua/lapi.h: Likewise.
4244 * script/lua/lauxlib.c: Likewise.
4245 * script/lua/lauxlib.h: Likewise.
4246 * script/lua/lbaselib.c: Likewise.
4247 * script/lua/lcode.c: Likewise.
4248 * script/lua/lcode.h: Likewise.
4249 * script/lua/ldblib.c: Likewise.
4250 * script/lua/ldebug.c: Likewise.
4251 * script/lua/ldebug.h: Likewise.
4252 * script/lua/ldo.c: Likewise.
4253 * script/lua/ldo.h: Likewise.
4254 * script/lua/ldump.c: Likewise.
4255 * script/lua/lfunc.c: Likewise.
4256 * script/lua/lfunc.h: Likewise.
4257 * script/lua/lgc.c: Likewise.
4258 * script/lua/lgc.h: Likewise.
4259 * script/lua/linit.c: Likewise.
4260 * script/lua/liolib.c: Likewise.
4261 * script/lua/llex.c: Likewise.
4262 * script/lua/llex.h: Likewise.
4263 * script/lua/llimits.h: Likewise.
4264 * script/lua/lmathlib.c: Likewise.
4265 * script/lua/lmem.c: Likewise.
4266 * script/lua/lmem.h: Likewise.
4267 * script/lua/loadlib.c: Likewise.
4268 * script/lua/lobject.c: Likewise.
4269 * script/lua/lobject.h: Likewise.
4270 * script/lua/lopcodes.c: Likewise.
4271 * script/lua/lopcodes.h: Likewise.
4272 * script/lua/loslib.c: Likewise.
4273 * script/lua/lparser.c: Likewise.
4274 * script/lua/lparser.h: Likewise.
4275 * script/lua/lstate.c: Likewise.
4276 * script/lua/lstate.h: Likewise.
4277 * script/lua/lstring.c: Likewise.
4278 * script/lua/lstring.h: Likewise.
4279 * script/lua/lstrlib.c: Likewise.
4280 * script/lua/ltable.c: Likewise.
4281 * script/lua/ltable.h: Likewise.
4282 * script/lua/ltablib.c: Likewise.
4283 * script/lua/ltm.c: Likewise.
4284 * script/lua/ltm.h: Likewise.
4285 * script/lua/lua.h: Likewise.
4286 * script/lua/luaconf.h: Likewise.
4287 * script/lua/lualib.h: Likewise.
4288 * script/lua/lundump.c: Likewise.
4289 * script/lua/lundump.h: Likewise.
4290 * script/lua/lvm.c: Likewise.
4291 * script/lua/lvm.h: Likewise.
4292 * script/lua/lzio.c: Likewise.
4293 * script/lua/lzio.h: Likewise.
4294
5e898c9d 42952009-05-16 Bean <bean123ch@gmail.com>
4296
4297 * include/grub/kernel.h (grub_module_header_types): Add type
4298 OBJ_TYPE_CONFIG.
4299
4300 * kern/main.c (grub_load_config): New function.
4301 (grub_main): Call grub_load_config to read boot config.
4302
4303 * grub-mkimage (generate_image): New parameter config_path.
4304 (options): New option --config.
4305 (main): Parse --config option, and pass it to generate_image.
4306
cf353a47 43072009-05-14 Christian Franke <franke@computer.org>
4308
4309 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
4310 This fixes build on Cygwin.
4311
3834887f 43122009-05-14 Pavel Roskin <proski@gnu.org>
4313
4314 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
4315 jump. This saves two bytes, so the typical case of 2 swapped
4316 drives would fit 32 bytes.
4317
8090fc01 43182009-05-13 Pavel Roskin <proski@gnu.org>
4319
ac963883 4320 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
4321 grub_uint32_t to avoid a warning.
4322
8090fc01 4323 * loader/i386/linux.c (allocate_pages): When assigning
4324 real_mode_mem, cast through grub_size_t to fix a warning. The
4325 code already makes sure that the value would fit a pointer.
4326 (grub_linux_setup_video): Cast render_target->data to
4327 grub_size_t to fix a warning.
4328
18f547ad 43292009-05-13 Javier Martín <lordhabbit@gmail.com>
4246b8a9 4330
4331 * commands/i386/pc/drivemap.c: New file - implement drivemap
4332 command.
4333 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
4334 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
4335
6f6a8b28 43362009-05-13 Pavel Roskin <proski@gnu.org>
4337
4338 * util/i386/pc/grub-setup.c (setup): Remove unused variable
4339 embedding_area_exists.
4340
15fbf4c4 43412009-05-13 Robert Millan <rmh.grub@aybabtu.com>
4342
4343 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
4344 it easier to understand / work with.
59978c8a 4345 Improve warning messages for cases where there's no embedding area,
4346 or when it is too small (or core.img too large).
15fbf4c4 4347
238e871f 43482009-05-13 Pavel Roskin <proski@gnu.org>
4349
0ab3a9a4 4350 * loader/i386/pc/multiboot2.c: Add necessary includes for
4351 grub_multiboot2_real_boot().
4352
a2c8c5f8 4353 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
4354 PX record is always little-endian. We only need the lower 2
4355 bytes of the mode.
4356
faec96af 4357 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
4358 facilitate code reuse.
4359 (grub_cpio_mount): Use "struct head", not a char buffer. This
4360 fixes a warning reported by gcc 4.4.
4361
238e871f 4362 * kernel/disk.c (grub_disk_read): Use void pointer for the
4363 buffer.
4364 (grub_disk_write): Use const void pointer for the buffer.
4365 Adjust all callers. Remove unnecessary casts.
4366
901d2f0c 43672009-05-10 Robert Millan <rmh.grub@aybabtu.com>
4368
4369 * util/i386/pc/grub-install.in: Update copyright year.
4370
18f547ad 43712009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
2eac4c16 4372
4373 gptsync
4374
4375 * commands/gptsync.c: new file
4376 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
4377 (gptsync_mod_SOURCES): new variable
4378 (gptsync_mod_CFLAGS): likewise
4379 (gptsync_mod_LDFLAGS): likewise
18f547ad 4380 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
2eac4c16 4381 new definition
4382 (GRUB_PC_PARTITION_TYPE_HFS): likewise
4383 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
4384 * conf/i386-ieee1275.rmk: likewise
4385 * conf/i386-pc.rmk: likewise
4386 * conf/powerpc-ieee1275.rmk: likewise
4387
b4ba690a 43882009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
4389
4390 Fixed grub-emu
4391
4392 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
4393 (grub_dl_ref): likewise
4394
317e1a44 43952009-05-08 Robert Millan <rmh.grub@aybabtu.com>
4396
4397 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
4398 split in two functions (one for msdos and one for gpt).
4399
041b8094 44002009-05-08 Pavel Roskin <proski@gnu.org>
4401
752473c2 4402 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
4403 not modified.
4404
041b8094 4405 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
4406 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
4407 Initialize them with -1. Add sanity check for bad1. Eliminate
4408 nerr variable.
4409
172800ce 44102009-05-08 David S. Miller <davem@davemloft.net>
4411
4412 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
4413
29aa5e81 44142009-05-06 Robert Millan <rmh.grub@aybabtu.com>
4415
4416 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
473d1e45 4417 existence.
29aa5e81 4418
96613b62 44192009-05-05 Felix Zielcke <fzielcke@z-51.de>
4420
4421 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
1905c57b 4422 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
96613b62 4423
eef73c8a 44242009-05-05 David S. Miller <davem@davemloft.net>
4425
4426 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
4427
119494b5 44282009-05-05 Pavel Roskin <proski@gnu.org>
4429
4430 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
4431 of grub_dl_ref() and grub_dl_unref().
4432 * commands/parttool.c: Remove preprocessor conditionals around
4433 grub_dl_ref() and grub_dl_unref().
4434 * fs/affs.c: Likewise.
4435 * fs/afs.c: Likewise.
4436 * fs/cpio.c: Likewise.
4437 * fs/ext2.c: Likewise.
4438 * fs/fat.c: Likewise.
4439 * fs/hfs.c: Likewise.
4440 * fs/hfsplus.c: Likewise.
4441 * fs/iso9660.c: Likewise.
4442 * fs/jfs.c: Likewise.
4443 * fs/minix.c: Likewise.
4444 * fs/ntfs.c: Likewise.
4445 * fs/reiserfs.c: Likewise.
4446 * fs/sfs.c: Likewise.
4447 * fs/udf.c: Likewise.
4448 * fs/ufs.c: Likewise.
4449 * fs/xfs.c: Likewise.
4450 * include/grub/dl.h: Likewise.
4451 * loader/xnu.c: Likewise.
4452
de5fd76e 44532009-05-04 Pavel Roskin <proski@gnu.org>
4454
4455 * commands/acpi.c: Remove unused variable my_mod.
4456 * partmap/amiga.c: Likewise.
4457 * partmap/apple.c: Likewise.
4458 * partmap/gpt.c: Likewise.
4459 * partmap/pc.c: Likewise.
4460 * partmap/sun.c: Likewise.
4461 * term/gfxterm.c: Likewise.
4462 * term/i386/pc/vesafb.c: Likewise.
4463 * term/i386/pc/vga.c: Likewise.
4464
983598ad 44652009-05-04 David S. Miller <davem@davemloft.net>
4466
4467 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
4468 pointer args to grub_ieee1275_get_property().
4469
8aadec43 4470 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
4471
9554b15e 4472 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
4473 devices, and do not traverse down under controller nodes.
4474
67e23c90 4475 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
4476 (grub_ofdisk_open): Use it to un-escape "," characters.
4477 * kern/disk.c (find_part_sep): New.
4478 (grub_disk_open): Use it to find the first non-escaped ','
4479 character in the disk name.
4480 * util/ieee1275/devicemap.c (escape_of_path): New.
4481 (grub_util_emit_devicemap_entry): Use it.
4482 * util/sparc64/ieee1275/grub-install.in: Update script to
4483 strip partition specifiers properly by not triggering on
4484 '\' escaped ',' characters.
4485
74bfdd2f 44862009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4487
4488 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
4489 to 0x300.
4490 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
4491 resolutions.
4492 (linux_vesafb_modes): Add a lot of additional modes to the list (based
4493 on documentation from Wikipedia).
4494
4241d2b1 44952009-05-04 Pavel Roskin <proski@gnu.org>
4496
4497 * disk/ata.c: Spelling fixes.
4498 * disk/raid.c: Likewise.
4499 * disk/usbms.c: Likewise.
4500 * disk/dmraid_nvidia.c: Likewise.
4501 * kern/ieee1275/openfw.c: Likewise.
4502 * kern/ieee1275/init.c: Likewise.
4503 * kern/ieee1275/cmain.c: Likewise.
4504 * boot/i386/pc/cdboot.S: Likewise.
4505 * video/readers/png.c: Likewise.
4506 * video/i386/pc/vbe.c: Likewise.
4507 * fs/udf.c: Likewise.
4508 * fs/hfs.c: Likewise.
4509 * fs/reiserfs.c: Likewise.
4510 * efiemu/runtime/efiemu.c: Likewise.
4511 * efiemu/main.c: Likewise.
4512 * efiemu/mm.c: Likewise.
4513 * include/grub/elf.h: Likewise.
4514 * include/grub/xnu.h: Likewise.
4515 * include/grub/usbdesc.h: Likewise.
4516 * include/grub/usb.h: Likewise.
4517 * include/grub/script_sh.h: Likewise.
4518 * include/grub/lib/LzmaEnc.h: Likewise.
4519 * include/grub/efiemu/efiemu.h: Likewise.
4520 * include/grub/command.h: Likewise.
4521 * normal/menu.c: Likewise.
4522 * normal/main.c: Likewise.
4523 * normal/datetime.c: Likewise.
4524 * bus/usb/uhci.c: Likewise.
4525 * mmap/i386/uppermem.c: Likewise.
4526 * mmap/mmap.c: Likewise.
4527 * commands/acpi.c: Likewise.
4528 * commands/test.c: Likewise.
4529 * partmap/apple.c: Likewise.
4530 * font/font.c: Likewise.
4531 * loader/sparc64/ieee1275/linux.c: Likewise.
4532 * loader/macho.c: Likewise.
4533 * loader/i386/bsd_trampoline.S: Likewise.
4534 * loader/i386/bsd.c: Likewise.
4535 * loader/xnu.c: Likewise.
4536 * term/i386/pc/vesafb.c: Likewise.
4537 * term/usb_keyboard.c: Likewise.
4538 * util/resolve.c: Likewise.
4539 * util/getroot.c: Likewise.
4540
0cfc0083 45412009-05-04 Felix Zielcke <fzielcke@z-51.de>
4542
4543 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
4544
7c1d00cd 45452009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4546
4547 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
4548 build error.
4549
b01f0548 45502009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4551
4552 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
4553 parameter only available on BIOS.
4554
ecc3eb22 45552009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4556
4557 Removed wrong semicolon in declaration
4558
4559 * grub/misc.h (grub_dprintf): remove semicolon
4560
112972a9 45612009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4562
4563 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
4564 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
4565 is done by grub_cmd_linux() now).
4566 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
4567 restore video to text mode.
4568 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
4569 indicates lack of "vga=" parameter. "vga=0" is mapped to
4570 `GRUB_LINUX_VID_MODE_NORMAL'.
4571
afd5c115 45722009-05-04 Felix Zielcke <fzielcke@z-51.de>
4573
4574 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
4575 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
4576 and `normal/script.c'. Add `kern/rescue_reader.c',
18f547ad 4577 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
afd5c115 4578 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
4579 `grub_script.tab.c'.
4580
4581 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4582 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4583 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4584 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
4585 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4586
faa517ce 4587 * Makefile.in: Remove duplicated 2008 in Copyright line.
4588
ae0c0bdc 45892009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4590
473d1e45 4591 * util/misc.c (grub_util_warn): New function. Emits a warning
ae0c0bdc 4592 unconditionally.
4593 * include/grub/util/misc.h (grub_util_warn): New declaration.
4594
4595 * util/i386/pc/grub-install.in: Understand --force and pass it down
4596 to grub-setup.
4597
4598 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
4599 down to setup().
4600 (setup): Improve error messages and add warnings when requested to
4601 install in odd layouts. Refuse to install using blocklists unless
4602 --force was set.
4603
18f547ad 46042009-05-04 martin f. krafft <madduck@madduck.net>
c149b500 4605
4606 * disk/raid.c (grub_raid_scan_device): Improve debug message.
4607
6d260daa 46082009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4609
4610 Updated copyright year
4611
4612 * fs/hfsplus.c: updated copyright year
18f547ad 4613
69f853f8 46142009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4615
4616 HFS+ UUID
4617
18f547ad 4618 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
69f853f8 4619 in the space previously used by unused3
4620 (grub_hfsplus_uuid): new function
4621 (grub_hfsplus_fs): added uuid field
4622
4c402e73 46232009-05-03 Pavel Roskin <proski@gnu.org>
4624
4625 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
4626 suppress warnings. It's no longer needed.
4627 * disk/host.c: Likewise.
4628 * disk/ata_pthru.c: Likewise.
4629 * disk/loopback.c: Likewise.
4630 * hook/datehook.c: Likewise.
4631 * parttool/pcpart.c: Likewise.
4632 * fs/i386/pc/pxe.c: Likewise.
4633 * fs/ntfscomp.c: Likewise.
4634 * efiemu/main.c: Likewise.
4635 * mmap/mmap.c: Likewise.
4636 * commands/crc.c: Likewise.
4637 * commands/hexdump.c: Likewise.
4638 * commands/hdparm.c: Likewise.
4639 * commands/acpi.c: Likewise.
4640 * commands/echo.c: Likewise.
4641 * commands/minicmd.c: Likewise.
4642 * commands/blocklist.c: Likewise.
4643 * commands/memrw.c: Likewise.
4644 * commands/loadenv.c: Likewise.
4645 * commands/usbtest.c: Likewise.
4646 * commands/lsmmap.c: Likewise.
4647 * commands/boot.c: Likewise.
4648 * commands/parttool.c: Likewise.
4649 * commands/configfile.c: Likewise.
4650 * commands/search.c: Likewise.
4651 * commands/ieee1275/suspend.c: Likewise.
4652 * commands/cat.c: Likewise.
4653 * commands/i386/pc/pxecmd.c: Likewise.
4654 * commands/i386/pc/play.c: Likewise.
4655 * commands/i386/pc/halt.c: Likewise.
4656 * commands/i386/pc/vbeinfo.c: Likewise.
4657 * commands/i386/pc/vbetest.c: Likewise.
4658 * commands/lspci.c: Likewise.
4659 * commands/date.c: Likewise.
4660 * commands/handler.c: Likewise.
4661 * commands/ls.c: Likewise.
4662 * commands/test.c: Likewise.
4663 * commands/cmp.c: Likewise.
4664 * commands/efi/loadbios.c: Likewise.
4665 * commands/efi/fixvideo.c: Likewise.
4666 * commands/halt.c: Likewise.
4667 * commands/help.c: Likewise.
4668 * commands/reboot.c: Likewise.
4669 * hello/hello.c: Likewise.
4670 * script/sh/main.c: Likewise.
4671 * loader/xnu.c: Likewise.
4672 * term/terminfo.c: Likewise.
4673 * term/i386/pc/serial.c: Likewise.
4674 * term/usb_keyboard.c: Likewise.
4675
515b5079 46762009-05-03 David S. Miller <davem@davemloft.net>
4677
4678 * normal/menu.c: Include grub/parser.h
4679
dfc31a22 46802009-05-03 Pavel Roskin <proski@gnu.org>
4681
2fee74f1 4682 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
4683 not char*.
4684 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
4685 Suggested by Javier Martín <lordhabbit@gmail.com>
4686
dfc31a22 4687 * util/i386/pc/grub-mkrescue.in: Allow for the case when
4688 efiemu??.o doesn't exist.
4689 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
4690 copying.
4691
18f547ad 46922009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
cef17233 4693
4694 FreeBSD 64-bit support
4695
18f547ad 4696 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
cef17233 4697 and loader/i386/bsd_trampoline.S
4698 (bsd_mod_ASFLAGS): new variable
4699 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
4700 (FREEBSD_MODTYPE_KERNEL64): likewise
4701 (grub_bsd64_trampoline_start): likewise
4702 (grub_bsd64_trampoline_end): likewise
4703 (grub_bsd64_trampoline_selfjump): likewise
4704 (grub_bsd64_trampoline_gdt): likewise
4705 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
4706 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
4707 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
4708 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
18f547ad 4709 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
cef17233 4710 of "attrib" member
4711 * loader/i386/bsd_pagetable.c: new file
4712 * loader/i386/bsd_trampoline.S: likewise
4713 * loader/i386/bsd.c (ALIGN_QWORD): new macro
4714 (ALIGN_VAR): likewise
4715 (entry_hi): new variable
4716 (kern_end_mdofs): likewise
4717 (is_64bit): likewise
4718 (grub_freebsd_add_meta): use ALIGN_VAR
4719 (grub_e820_mmap): new declaration
4720 (grub_freebsd_add_mmap): new function
4721 (grub_freebsd_add_meta_module): support 64 bit kernels
4722 (grub_freebsd_list_modules): use ALIGN_VAR
4723 (gdt_descriptor): new declaration
4724 (grub_freebsd_boot): support 64 bit kernels
4725 (grub_bsd_elf64_hook): new function
4726 (grub_bsd_load_elf): support elf64
4727
038c5720 47282009-05-03 Bean <bean123ch@gmail.com>
4729
4730 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
4731 after we get the result of if statement.
4732
fc45fb58 47332009-05-03 Bean <bean123ch@gmail.com>
4734
4735 * Makefile.in (enable_efiemu): New variable.
4736
4737 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
4738 set.
4739 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
4740 path.
4741 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
4742 path, add -mno-red-zone option.
4743 (efiemu64_s.o): Likewise.
4744 (efiemu64.o): Use macro $^ for source file.
4745
4746 * configure.ac (--enable-efiemu): New option.
4747
bbee0f2b 47482009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
4749
4750 xnu support
4751
4752 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
4753 (pkglib_MODULES): add xnu.mod
4754 (xnu_mod_SOURCES): new variable
4755 (xnu_mod_CFLAGS): likewise
4756 (xnu_mod_LDFLAGS): likewise
4757 (xnu_mod_ASFLAGS): likewise
4758 * conf/i386-pc.rmk: likewise
4759 * conf/x86_64-efi.rmk: likewise
7dd4a573 4760 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
bbee0f2b 4761 new declaration
4762 * include/grub/i386/macho.h: new file
4763 * include/grub/i386/xnu.h: likewise
4764 * include/grub/macho.h: likewise
4765 * include/grub/machoload.h: likewise
4766 * include/grub/x86_64/macho.h: likewise
4767 * include/grub/x86_64/xnu.h: likewise
4768 * include/grub/xnu.h: likewise
4769 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
4770 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
4771 * loader/i386/efi/xnu.c: new file
4772 * loader/i386/pc/xnu.c: likewise
4773 * loader/i386/xnu.c: likewise
4774 * loader/i386/xnu_helper.S: likewise
4775 * loader/macho.c: likewise
4776 * loader/xnu.c: likewise
4777 * loader/xnu_resume.c: likewise
4778 * util/grub-dumpdevtree: likewise
4779 * include/grub/i386/pit.h: include grub/err.h
4780 (grub_pit_wait): export
4781 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
7dd4a573 4782
5caf964d 47832009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
4784
4785 Efiemu
7dd4a573 4786
5caf964d 4787 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
7dd4a573 4788 _linux_efi, linux_efi.
4789 new files in grub-emu
5caf964d 4790 new targets efiemu32.o and efiemu64.o
4791 * loader/linux_normal_efiemu.c: likewise
4792 * loader/i386/efi/linux.c: added preliminary efiemu support
7dd4a573 4793 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
5caf964d 4794 files to copy
4795 * include/grub/autoefi.h: new file
7dd4a573 4796 * include/grub/i386/efiemu.h: likewise
5caf964d 4797 * include/grub/i386/pc/efiemu.h: likewise
4798 * include/grub/efi/api.h: add LL suffix when necessary
4799 new definitions relating to tables
4800 * include/grub/efiemu/efiemu.h: new file
4801 * include/grub/efiemu/runtime.h: likewise
4802 * efiemu/prepare.c: likewise
4803 * efiemu/loadcore_common.c: likewise
4804 * efiemu/loadcore64.c: likewise
4805 * efiemu/runtime/efiemu.sh: likewise
4806 * efiemu/runtime/efiemu.S: likewise
4807 * efiemu/runtime/efiemu.c: likewise
4808 * efiemu/runtime/config.h: likewise
4809 * efiemu/prepare32.c: likewise
4810 * efiemu/main.c: likewise
4811 * efiemu/modules/pnvram.c: likewise
4812 * efiemu/modules/i386: likewise
4813 * efiemu/modules/i386/pc: likewise
4814 * efiemu/modules/acpi.c: likewise
4815 * efiemu/i386/pc/cfgtables.c: likewise
4816 * efiemu/i386/loadcore64.c: likewise
4817 * efiemu/i386/loadcore32.c: likewise
4818 * efiemu/prepare64.c: likewise
4819 * efiemu/loadcore.c: likewise
4820 * efiemu/symbols.c: likewise
4821 * efiemu/mm.c: likewise
4822 * efiemu/loadcore32.c: likewise
7dd4a573 4823
48242009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
f8efe3ad 4825
4826 ACPI spoofing
4827
4828 * commands/acpi.c: new file
4829 * commands/i386/pc/acpi.c: likewise
4830 * commands/efi/acpi.c: likewise
4831 * include/grub/acpi.h: likewise
4832 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
4833 (acpi_mod_SOURCES): new variable
4834 (acpi_mod_CFLAGS): likewise
4835 (acpi_mod_LDFLAGS): likewise
4836 * conf/i386-efi.rmk: likewise
4837 * conf/x86_64-efi.rmk: likewise
4838
7dd4a573 48392009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
28a85665 4840
4841 Missing part from mmap patch
4842
4843 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
4844 (grub_mmap_unregister)
4845 (grub_mmap_free_and_unregister): use grub_mmap_register
4846
7dd4a573 48472009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
09d842b9 4848
4849 Mmap services
4850
4851 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
4852 * loader/i386/linux.c (find_mmap_size): likewise
4853 (allocate_pages): likewise
4854 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
4855 (grub_fill_multiboot_mmap): likewise
4856 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
4857 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
4858 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
4859 (OPENBSD_MMAP_RESERVED): likewise
4860 * include/grub/i386/pc/memory.h: include grub/memory.h
4861 (grub_lower_mem): removed
4862 (grub_upper_mem): likewise
4863 (GRUB_MACHINE_MEMORY_ACPI): new definition
4864 (GRUB_MACHINE_MEMORY_NVS): likewise
4865 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
4866 (GRUB_MACHINE_MEMORY_HOLE): likewise
4867 (grub_machine_mmap_register): likewise
4868 (grub_machine_mmap_unregister): likewise
4869 (grub_machine_get_upper): likewise
4870 (grub_machine_get_lower): likewise
4871 (grub_machine_get_post64): likewise
4872 * include/grub/i386/efi/memory.h: new file
4873 * include/grub/x86_64/efi/memory.h: likewise
4874 * include/grub/efi/memory.h: likewise
4875 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
4876 (mmap_mod_SOURCES): new variable
4877 (mmap_mod_LDFLAGS): likewise
4878 (mmap_mod_ASFLAGS): likewise
4879 * conf/i386-coreboot.rmk: likewise
4880 * conf/i386-ieee1275.rmk: likewise
4881 * conf/i386-efi.rmk: likewise
4882 * conf/x86_64-efi.rmk: likewise
4883 * include/grub/types.h (UINT_TO_PTR): new macro
4884 (PTR_TO_UINT32): likewise
4885 (PTR_TO_UINT64): likewise
4886 * include/grub/memory.h: new file
4887 * mmap/i386/pc/mmap.c: likewise
4888 * mmap/i386/pc/mmap_helper.S: likewise
4889 * mmap/i386/uppermem.c: likewise
4890 * mmap/mmap.c: likewise
4891 * mmap/efi/mmap.c: likewise
7dd4a573 4892 * kern/i386/coreboot/init.c (grub_machine_init): don't use
09d842b9 4893 grub_upper_mem
4894 * kern/i386/pc/init.c (grub_lower_mem): removed variable
4895 (grub_upper_mem): likewise
4896 (grub_machine_init): don't use grub_upper_mem,
4897 make grub_lower_mem local
4898 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
4899 grub_mmap_iterate and grub_mmap_get_upper
4900 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
4901
d558e6b5 49022009-05-02 Bean <bean123ch@gmail.com>
4903
4904 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
4905 script/sh/parser.y.
4906 (pkglib_MODULES): Add normal.mod and sh.mod.
4907 (normal_SOURCES): New variable.
4908 (normal_mod_CFLAGS): Likewise.
4909 (normal_mod_LDFLAGS): Likewise.
4910 (sh_mod_SOURCES): Likewise.
4911 (sh_mod_CFLAGS): Likewise.
4912 (sh_mod_LDFLAGS): Likewise.
4913
4914 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
4915 script/sh/lexer.c_DEPENDENCIES.
4916 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
4917 kern/rescue_reader.c and kern/rescue_parser.c.
4918 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
4919 (grub_emu_SOURCES): Change source files.
4920 (pkglib_MODULES): Remove normal.mod.
4921 (normal_SOURCES): Removed.
4922 (normal_mod_CFLAGS): Likewise.
4923 (normal_mod_LDFLAGS): Likewise.
4924 * conf/i386-coreboot.rmk: Likewise.
4925 * conf/i386-efi.rmk: Likewise.
4926 * conf/i386-ieee1276.rmk: Likewise.
4927 * conf/powerpc-ieee1275.rmk: Likewise.
4928 * conf/sparc64-ieee1275.rmk: Likewise.
4929 * conf/x86_64-efi.rmk: Likewise.
4930
4931 * include/grub/command.h (grub_command_execute): New inline function.
4932
4933 * include/grub/menu.h (grub_menu_entry): Removed commands field.
4934
4935 * include/grub/normal.h: Remove <grub/setjmp.h>.
4936 (grub_fs_module_list): Moved to normal/autofs.c.
4937 (grub_exit_env): Removed.
4938 (grub_command_execute): Likewise.
4939 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
4940 parameter script.
4941 (read_command_list): New function declaration.
4942 (read_fs_list): Likewise.
4943
4944 * include/parser.h: Include <grub/reader.h>.
4945 (grub_parser_split_cmdline): Change type of getline parameter.
4946 (grub_parser): New structure.
4947 (grub_parser_class): New variable.
4948 (grub_parser_execute): New function declaration.
4949 (grub_register_rescue_parser): Likewise.
4950 (grub_parser_register): New inline function.
4951 (grub_parser_unregister): Likewise.
4952 (grub_parser_get_current): Likewise.
4953 (grub_parser_set_current): Likewise.
4954
4955 * include/grub/reader.h: New file.
4956 * kern/reader.c: Likewise.
4957 * kern/rescue_parser.c: Likewise.
4958 * kern/rescue_reader.c: Likewise.
4959 * normal/autofs.c: Likewise.
4960 * normal/dyncmd.c: Likewise.
4961
4962 * include/grub/rescue.h: Removed.
4963 * normal/command.h: Likewise.
4964
4965 * include/grub/script.h: Moved to ...
4966 * include/grub/script_sh.h: ... Moved here.
4967 * normal/execute.c: Moved to ...
4968 * script/sh/execute.c: ... Moved here.
4969 * normal/function.c: Moved to ...
4970 * script/sh/function.c: ... Moved here.
4971 * normal/lexer.c: Moved to ...
4972 * script/sh/lexer.c: ... Moved here.
4973 * normal/parser.y: Moved to ...
4974 * script/sh/parser.y: ... Moved here.
4975 * normal/script.c: Moved to ...
4976 * script/sh/script.c: ... Moved here.
4977
4978 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
4979 <grub/reader.h>.
4980 (grub_exit_env): Removed.
4981 (fs_module_list): Moved to normal/autofs.c.
4982 (grub_file_getline): Don't handle comment here.
4983 (free_menu): Skip removed field entry->commands.
4984 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
4985 script parameter.
4986 (read_config_file): Removed nested parameter, change getline function.
4987 (grub_enter_normal_mode): Removed.
4988 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
4989 (read_command_list): Likewise.
4990 (autoload_fs_module): Moved to normal/autofs.c.
4991 (read_fs_list): Likewise.
4992 (reader_nested): New variable.
4993 (grub_normal_execute): Run parser.sh to switch to sh parser.
4994 (grub_cmd_rescue): Removed.
4995 (cmd_normal): Removed.
4996 (grub_cmd_normal): Unregister itself at the beginning. Don't register
4997 rescue command.
4998 (grub_cmdline_run): New function.
4999 (grub_normal_reader_init): Likewise.
5000 (grub_normal_read_line): Likewise.
5001 (grub_env_write_pager): Likewise.
5002 (cmdline): New variable.
5003 (grub_normal_reader): Likewise.
5004 (GRUB_MOD_INIT): Register normal reader and set as current, register
5005 pager hook, register normal command with grub_register_command_prio,
5006 so that it won't show up in command.lst.
5007 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
5008 grub_fs_autoload_hook.
5009
5010 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
5011 (grub_menu_execute_entry): Replace grub_script_execute with
5012 grub_parser_execute, change parameter to grub_command_execute.
5013
5014 * normal/menu_text.c: Remove <grub/script.h>.
5015
5016 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
5017 and <grub/parser.h>.
5018 (run): Change editor_getline to use new parser interface. Change
5019 parameter to grub_command_execute.
5020
5021 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
5022 <grub/reader.h> and <grub/parser.h>.
5023 (grub_load_normal_mode): Execute normal command.
5024 (grub_main): Call grub_register_core_commands,
5025 grub_register_rescue_parser and grub_register_rescue_reader, use
5026 grub_reader_loop to enter input loop.
5027
7dd4a573 5028 * kern/parser.c (grub_parser_split_cmdline): Change type of
5029 getline parameter.
d558e6b5 5030 (grub_parser_class): New variable.
5031 (grub_parser_execute): New function.
5032
5033 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
5034 * loader/multiboot2.c: Likewise.
5035 * loader/sparc64/ieee1275/linux.c: Likewise.
5036
5037 * util/grub-emu.c (read_command_list): New dummy function.
5038
18db813d 50392009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5040
5041 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
5042 count to 16 for CCISS and IDA.
5043
6c67de15 50442009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5045
5046 * normal/menu_text.c (grub_wait_after_message): Print a newline
5047 after waiting for user input.
5048
5049 * loader/i386/linux.c: Include `<grub/normal.h>'.
5050 (grub_cmd_linux): Improve the error message about `ask' mode, by
5051 waiting for user input so it's not missed (we can do this, since
5052 user requested interaction).
5053
d9dc87b0 50542009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5055
5056 Added missing lst to grub-mkrescue
5057
5058 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
5059 and ${input_dir}/parttool.lst
5060
ac8a2baa 50612009-04-30 David S. Miller <davem@davemloft.net>
5062
ad22a610 5063 * util/hostdisk.c (device_is_wholedisk): New function.
5064 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
5065 zero only if device_is_wholedisk() returns true.
5066
6966215d 5067 * util/hostdisk.c (convert_system_partition_to_system_disk):
5068 Handle virtual disk devices named /dev/vdiskX as found on sparc
5069 and powerpc.
5070
ac8a2baa 5071 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
5072 lettered partition specifier is found, convert to numbered.
5073
979b4fb4 50742009-04-29 David S. Miller <davem@davemloft.net>
5075
e2bf39b2 5076 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
5077 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5078
3c64e104 5079 * normal/command.c: Add missing newline at end of file.
5080
979b4fb4 5081 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
5082 warnings.
5083 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
5084 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
5085 grub_ofdisk_read): Likewise, and deal similarly with the fact that
5086 ihandles have a 32-bit type but need to be stored in a "void *".
5087
136d9f82 50882009-04-28 Pavel Roskin <proski@gnu.org>
5089
9459c306 5090 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
5091 not disk. Adjust all dependencies.
2e08a26a 5092 (grub_fs_uuid_close): Use grub_device_close(), not
9459c306 5093 grub_disk_close().
5094
136d9f82 5095 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
5096 parent's partition, don't copy it by reference, as it gets freed
5097 on close.
5098
7dd4a573 50992009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
75a807cf 5100
5101 Preboot hooks support
5102
5103 * commands/boot.c (struct grub_preboot_t): new declaration
5104 (preboots_head): new variable
5105 (preboots_tail): likewise
5106 (grub_loader_register_preboot_hook): new function
5107 (grub_loader_unregister_preboot_hook): likewise
5108 (grub_loader_set): launch preboot hooks
5109 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
5110 (grub_loader_register_preboot_hook): new declaration
5111 (grub_loader_unregister_preboot_hook): likewise
5112
5af922b5 51132009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
5114
5115 Warning fix
5116
7dd4a573 5117 * disk/scsi.c (grub_scsi_open): added missing cast when
5af922b5 5118 calling grub_dprintf
5119
a5562c30 51202009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
5121
5122 Bug and warning fixes
5123
7dd4a573 5124 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
a5562c30 5125 declaration
5126 * commands/test.c (test_parse): fixed bug with file tests and corrected
5127 declaration of find_file
5128
4006f85c 51292009-04-26 Pavel Roskin <proski@gnu.org>
5130
5131 * Makefile.in: Don't install empty manual pages if help2man is
5132 missing. Use help2man option for output, not shell redirection.
5133
5c77c3de 51342009-04-26 David S. Miller <davem@davemloft.net>
5135
5136 * util/grub-mkdevicemap.c (make_device_map): Add missing
5137 NESTED_FUNC_ATTR to process_device().
5138
033b10a8 51392009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5140
5141 Test command
5142
5143 * commands/test.c: rewritten to use bash-like test
5144
e4343593 51452009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5146
5147 Parttool autoloading and improvements
5148
7dd4a573 5149 * Makefile.in (pkglib_DATA): add parttool.lst
e4343593 5150 (parttool.lst): new target
5151 * genmk.rb: generate parttool-*
5152 (CLEANFILES): add #{parttool}
5153 (PARTTOOLFILES): new variable
5154 * genparttoollist.sh: new file
7dd4a573 5155 * parttool/pcpart.c (grub_pcpart_boot): more feedback
e4343593 5156 (grub_pcpart_type): likewise
5157 * commands/parttool.c (helpmsg): new variable
5158 (grub_cmd_parttool): output help if not enough arguments are supplied
5159 autoload modules
5160 (GRUB_MOD_INIT(parttool)): use helpmsg
5161
0d312500 51622009-04-24 David S. Miller <davem@davemloft.net>
5163
7dd4a573 5164 Avoiding opening same device multiple times in device iterator.
0d312500 5165
5166 * kern/device.c: (grub_device_iterate): Define struct part_ent,
7dd4a573 5167 and use it to build a list of partitions in iterate_disk() and
0d312500 5168 iterate_partition().
5169
ac20caff 5170 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
5171 on disk->data.
5172
0dcf7495 5173 * disk/ieee1275/nand.c (grub_nand_iterate): Return
5174 grub_devalias_iterate() result instead of unconditional 0.
5175 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
5176 Also, capture hook return value, either directly or via
5177 grub_children_iterate(), and propagate to caller.
5178 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
5179 grub_children_iterate): Return value is now 'int' instead of
5180 'grub_err_t'.
5181 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
5182 like a proper iterator, stopping when hooks return non-zero.
5183 (grub_devalias_iterate): Likewise.
5184
c8c08833 51852009-04-23 David S. Miller <davem@davemloft.net>
5186
5187 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
5188
f01005a8 51892009-04-22 David S. Miller <davem@davemloft.net>
5190
5191 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
5192 is larger than address_cells, use that value for address_cells too.
5193
4e8269da 5194 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
5195 IEEE1275_MAX_PATH_LEN): Define.
5196 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
5197 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
5198 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
5199 'devtype'. Explicitly NULL terminate devalias expansion.
5200
a1447506 5201 * util/sparc64/ieee1275/misc.c: New file.
5202 * util/sparc64/ieee1275/grub-setup.c: New file.
5203 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
5204 * util/sparc64/ieee1275/grub-mkimage.c: New file.
5205 * util/sparc64/ieee1275/grub-install.in: New file.
5206 * util/ieee1275/ofpath.c: New file.
5207 * util/ieee1275/devicemap.c: New file.
5208 * util/devicemap.c: New file.
5209 * util/deviceiter.c: New file.
5210 * kern/sparc64/ieee1275/init.c: New file.
5211 * include/grub/util/ofpath.h: New file.
5212 * include/grub/util/deviceiter.h: New file.
5213 * util/grub-mkdevicemap.c: Include deviceiter.h.
5214 Implement using grub_util_emit_devicemap_entry and
5215 grub_util_iterate_devices.
5216 * conf/i386-corebook.rmk: Build util/deviceiter.c and
5217 util/devicemap.c into grub-mkdevicemap
5218 * conf/i386-efi.rmk: Likewise.
5219 * conf/i386-ieee1275.rmk: Likewise.
5220 * conf/i386-pc.rmk: Likewise.
5221 * conf/powerpc-ieee1275.rmk: Likewise.
5222 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
5223 images and installation utilities. Build kernel as image
5224 instead of as elf binary. Use common rules as much as possible.
5225
7dd4a573 52262009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
0aefc632 5227
5228 Correct GPT definition
5229
7dd4a573 5230 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
0aefc632 5231 of "attrib" member
5232
c6c5219f 52332009-04-19 Felix Zielcke <fzielcke@z-51.de>
5234
5235 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
5236
0552ff9f 52372009-04-19 David S. Miller <davem@davemloft.net>
5238
5239 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
5240 (grub_rescue_cmd_linux): Rename to...
5241 (grub_cmd_linux): and fix prototype.
5242 (grub_rescue_cmd_initrd): Rename to...
5243 (grub_cmd_initrd): and fix prototype.
5244 (cmd_linux, cmd_initrd): New.
5245 (GRUB_MOD_INIT(linux)): Use grub_register_command().
5246 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
5247
d1a282fc 52482009-04-17 Pavel Roskin <proski@gnu.org>
5249
07c5039f 5250 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
5251 format.
5252 (grub_ohci_transfer): Likewise.
5253
b012002d 5254 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
5255
1bc09c35 5256 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
5257 return without a value. Fix inconsistent indentation.
5258
e0ff9126 5259 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
5260 match struct grub_fs.
5261
d1a282fc 5262 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
5263 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
5264 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
5265 * commands/lspci.c (grub_lspci_iter): Likewise.
5266
a96df3f2 52672009-04-16 Bean <bean123ch@gmail.com>
5268
5269 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
5270 value.
5271
41bb0fe9 52722009-04-15 Pavel Roskin <proski@gnu.org>
5273
5274 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
5275 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
5276 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
5277 definitions.
5278
596c6970 52792009-04-15 Felix Zielcke <fzielcke@z-51.de>
5280
5281 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
7dd4a573 5282 that no multiple data or metadata areas are supported and `Unknown
596c6970 5283 metadata header'.
5284
7dd4a573 52852009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
0d5d5653 5286
5287 Move loader out of the kernel
5288
5289 * kern/loader.c: moved to ...
5290 * commands/boot.c: ... moved here
5291 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
5292 * commands/boot.c (grub_cmd_boot): moved here. All users updated
5293 * include/grub/kernel.h (grub_machine_fini): export
5294 * include/grub/loader.h (grub_loader_is_loaded): update declaration
5295 (grub_loader_set): likewise
5296 (grub_loader_unset): likewise
5297 (grub_loader_boot): likewise
5298 * conf/common.rmk: new module boot.mod
5299 (pkglib_MODULES): add boot.mod
5300 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
5301 (grub_emu_SOURCES): likewise
5302 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
5303 (grub_emu_SOURCES): likewise
5304 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
5305 (grub_emu_SOURCES): likewise
5306 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
5307 (grub_emu_SOURCES): likewise
5308 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
5309 (grub_emu_SOURCES): likewise
7dd4a573 5310 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
5311 (grub_emu_SOURCES): likewise
0d5d5653 5312 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
7dd4a573 5313 (grub_emu_SOURCES): likewise
0d5d5653 5314
7dd4a573 53152009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
5999d619 5316
5317 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
7dd4a573 5318
5999d619 5319 * kern/misc.c (grub_itoa): Removed function
5320 (grub_ltoa): likewise
5321 (grub_vsprintf): use grub_lltoa
5322
7dd4a573 53232009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
13c00781 5324
5325 Restore grub-emu
5326
5327 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
5328 * conf/i386-coreboot.rmk: likewise
5329 * conf/i386-ieee1275.rmk: likewise
5330 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 5331
20318222 53322009-04-15 Felix Zielcke <fzielcke@z-51.de>
5333
5334 * INSTALL: Add that `./autogen.sh' needs to be run before
5335 `./configure.'.
5336
d05f0df3 53372009-04-14 Bean <bean123ch@gmail.com>
5338
5339 * Makefile.in (pkglib_DATA): Add handler.lst.
5340 (handler.lst): New rule.
5341
5342 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
5343 * conf/i386-coreboot.rmk: Likewise.
5344 * conf/i386-ieee1275.rmk: Likewise.
5345 * conf/i386-efi.rmk: Likewise.
5346 * conf/x86_64-efi.rmk: Likewise.
5347 * conf/powerpc-ieee1275.rmk: Likewise.
5348 * conf/sparc64-ieee1275.rmk: Likewise.
5349
5350 * genhandlerlist.sh: New file.
5351
5352 * genmk.rb: Add rules to generate handler.lst.
5353
5354 * include/grub/normal.h (grub_file_getline): New function definition.
5355 (read_handler_list): Likewise.
5356 (free_handler_list): Likewise.
5357
5358 * include/grub/term.h (grub_term_register_input): Add name parameter
5359 for auto generation of handler.lst.
5360 (grub_term_register_output): Likewise.
5361
5362 * normal/handler.c: New file.
5363
5364 * normal/main.c (get_line): Renamed to grub_file_getline.
5365 (read_config_file): Use the newly renamed grub_file_getline.
5366 (read_command_list): Likewise.
5367 (read_fs_list): Likewise.
5368 (grub_normal_execute): Call read_handler_list to parse handler.lst.
5369 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
5370
5371 * term/efi/console.c (grub_console_init): Add name parameter for auto
5372 generation of handler.lst.
5373 * term/gfxterm.c: Likewise.
5374 * term/i386/pc/at_keyboard.c: Likewise.
5375 * term/i386/pc/console.c: Likewise.
5376 * term/i386/pc/serial.c: Likewise.
5377 * term/i386/pc/vesafb.c: Likewise.
5378 * term/i386/pc/vga.c: Likewise.
5379 * term/i386/pc/vga_text.c: Likewise.
5380 * term/ieee1275/ofconsole.c: Likewise.
5381 * term/usb_keyboard.c: Likewise.
5382
33c846be 53832009-04-14 Bean <bean123ch@gmail.com>
5384
5385 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
5386 properly with null character.
5387
4484e01e 53882009-04-14 Felix Zielcke <fzielcke@z-51.de>
5389
5390 * configure: Remove.
5391 * config.h.in: Likewise.
f93d668e 5392 * stamp-h.in: Likewise.
4484e01e 5393 * DISTLIST: Likewise.
5394 * conf/common.mk: Likewise.
5395 * conf/i386-coreboot.mk: Likewise.
5396 * conf/i386-efi.mk: Likewise.
5397 * conf/i386-ieee1275.mk: Likewise.
5398 * conf/i386.mk: Likewise.
5399 * conf/i386-pc.mk: Likewise.
5400 * conf/powerpc-ieee1275.mk: Likewise.
5401 * conf/sparc64-ieee1275.mk: Likewise.
5402 * conf/x86_64-efi.mk: Likewise.
5403
5404 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
5405 develop on GRUB.
5406
7dd4a573 54072009-04-14 John Stanley <jpsinthemix@verizon.net>
5c5bf96a 5408 David S. Miller <davem@davemloft.net>
5409
5410 * util/hostdisk.c (make_device_name): Fix buffer length
5411 calculations.
5412
e25b5a8c 54132009-04-14 Felix Zielcke <fzielcke@z-51.de>
5414
5415 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
5416 <sys/param.h> and <sys/sysctl.h>.
5417 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
5418 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
5419 opening the device and reset them afterwards.
5420
1f1f580c 54212009-04-13 Pavel Roskin <proski@gnu.org>
5422
5423 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
5424 Reported by John Stanley <jpsinthemix@verizon.net>
5425
7ebc2d6b 54262009-04-13 Robert Millan <rmh@aybabtu.com>
5427
5428 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
7dd4a573 5429 that name for menuentries when appropriate.
7ebc2d6b 5430
d8ba3667 54312009-04-13 Felix Zielcke <fzielcke@z-51.de>
5432
5433 * util/grub.d/10_freebsd.in: Add a missing `fi'.
5434
cba416eb 54352009-04-13 Robert Millan <rmh@aybabtu.com>
5436
5437 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
5438 to Linux, simply abort telling the user it's no longer supported.
5439
a547a745 54402009-04-13 Felix Zielcke <fzielcke@z-51.de>
5441
5442 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
7dd4a573 5443 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
a547a745 5444 `freebsd_loadenv' only when devices.hints exist.
5445
232a769c 54462009-04-13 Pavel Roskin <proski@gnu.org>
5447
5448 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
5449
c3012039 54502009-04-13 Felix Zielcke <fzielcke@z-51.de>
5451
5452 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
5453 partition number.
5454 (grub_drive): Likewise.
5455
234022fe 54562009-04-13 David S. Miller <davem@davemloft.net>
5457
5458 * kern/sparc64/ieee1275/ieee1275.c: New file.
5459 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
5460 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
5461 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
5462 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
5463 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
5464 grub_ieee1275_alloc_physmem): Declare new exported functions.
5465
d8e1836c 5466 * include/grub/sparc64/ieee1275/loader.h: New file.
5467 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5468 * include/grub/sparc64/kernel.h: Likewise.
5469 * loader/sparc64/ieee1275/linux.c: Likewise.
5470
96bd81ec 5471 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
5472 (grub_fstest_SOURCES): Likewise.
5473
6a4737e5 5474 * util/hostdisk.c (make_device_name): Do not make any assumptions
5475 about the length of drive names.
5476
1d7a72fd 5477 * kern/dl.c (grub_dl_load_file): Close file immediately when
5478 we are done using it.
5479
56bc2471 54802009-04-12 David S. Miller <davem@davemloft.net>
5481
5482 * kern/misc.c (grub_ltoa): Fix cast when handling negative
5483 values. Noticed by Pavel Roskin.
5484
df38d0bb 5485 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
5486 target compiler.
7dd4a573 5487
e382e93a 5488 * genmk.rb: Add more flexible image type specification, also
5489 pass --strip-unneeded to objcopy.
5490 * conf/i386-pc.rmk: Use *_FORMAT.
5491 * conf/i386-pc.mk: Rebuilt.
5492
f5dbbca9 5493 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
5494 (OFDISK_HASH_SZ): Define.
5495 (ofdisk_hash): New hash table.
5496 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
5497 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
5498 instead of device phandle which is not unique.
5499
91c88b12 5500 * kern/sparc64/ieee1275/init.c: Delete, replace with...
5501 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
5502 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
5503 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
5504 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
5505 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
5506 GRUB_KERNEL_MACHINE_DATA_END): Define.
5507 (grub_kernel_image_size, grub_total_module_size): Declare.
5508
5b5d4aa5 55092009-04-12 Pavel Roskin <proski@gnu.org>
5510
7dd4a573 5511 * configure.ac: Change the logic when we check for target tools.
5512 Do it when the target is specified and it's different from the
5513 specified value of the host.
5b5d4aa5 5514
c91e1793 55152009-04-11 Felix Zielcke <fzielcke@z-51.de>
5516
5517 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
5518 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
5519 GNU/kFreeBSD. Check if a device is a character device. Use
5520 DIOCGMEDIASIZE to get the size.
5521 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
5522 support for GNU/kFreeBSD.
5523 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
5524 is a character device instead of a block device. Add support for
5525 FreeBSD device names.
5526
5527 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
5528 is a character device instead of a block device.
5529
5530 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
5531 is a character device instead of a block device.
5532
b1ac8644 55332009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
5534
5535 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
5536 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
5537 FreeBSD. Check if a device is a character device. Use
5538 DIOCGMEDIASIZE to get the size.
5539 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
5540 support for FreeBSD.
5541 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
5542 is a character device instead of a block device. Add support for
5543 FreeBSD device names.
5544
5545 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
5546 a character device instead of a block device.
5547 (grub_util_check_char_device): New function.
5548
5549 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
5550 a character device instead of a block device.
5551
5552 * include/grub/util/getroot.h (grub_util_check_char_device): New
5553 prototype.
5554
a3f7515a 55552009-04-11 David S. Miller <davem@davemloft.net>
5556
5557 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
5558 static libgcc.
5559 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
5560 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
5561 function, if present.
5562 (__bswapdi2): Likewise.
5563
0d44993d 5564 * include/grub/sparc64/ieee1275/boot.h: New file.
5565 * boot/sparc64/ieee1275/boot.S: Likewise.
5566 * boot/sparc64/ieee1275/diskboot.S: Likewise.
5567
ed3d2bc2 5568 * kern/misc.c (grub_ltoa): New function.
5569 (grub_vsprintf): Use it to format 'long' integers.
5570
d3bfb59c 55712009-04-10 David S. Miller <davem@davemloft.net>
5572
5573 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
5574 slots are of type grub_ieee1275_cell_t.
5575 (grub_nand_read): Likewise.
5576 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
5577 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
5578 macros are used to compare values in arg/ret block of the call.
5579 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
5580 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
5581 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
5582 grub_ieee1275_instance_to_path, grub_ieee1275_write,
5583 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
5584 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
5585 grub_ieee1275_close, grub_ieee1275_set_property,
5586 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
5587 grub_ieee1275_cell_t.
5588 * kern/ieee1275/openfw.c (grub_map): Likewise.
5589 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
5590 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
5591
450e2238 5592 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
5593 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
5594 (grub_devalias_iterate): Likewise.
5595
7dd4a573 55962009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
6df8cc76 5597
5598 UFS improvements
5599
5600 * fs/ufs.c (INODE_NBLOCKS): new definition
5601 (struct grub_ufs_dirent): added fields for non-BSD dirents
5602 (grub_ufs_get_file_block): fixed double indirect handling
5603 (grub_ufs_lookup_symlink): use more robust way to determine whether
5604 symlink is inline
5605 (grub_ufs_find_file): support for non-BSD dirents
5606 (grub_ufs_dir): support for non-BSD dirents
5607
e7e6862a 56082009-04-10 Bean <bean123ch@gnail.com>
5609
5610 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
5611 attribute, otherwise the size would be wrong for i386 platform.
5612
5613 * include/grub/pci.h (grub_pci_read_word): New inline function.
5614 (grub_pci_read_byte): Likewise.
5615 (grub_pci_write): Likewise.
5616 (grub_pci_write_word): Likewise.
5617 (grub_pci_write_byte): Likewise.
5618
5619 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
5620
5621 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
5622 (find_framebuf): Scan pci to locate the frame buffer address.
5623
5624 * commands/efi/fixvideo.c: New file.
5625
5626 * commands/efi/loadbios.c: Likewise.
5627
5628 * commands/memrw.c: Likewise.
5629
5630 * util/grub-dumpbios.in: Likewise.
5631
5632 * conf/common.rmk (grub-dumpbios): New utility.
5633 (pkglib_MODULES): New module memrw.mod.
5634 (memrw_mod_SOURCE): New macro.
5635 (memrw_mod_CFLAGS): Likewise.
5636 (memrw_mod_LDFLAGS): Likewise.
5637
7dd4a573 5638 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 5639 fixvideo.mod.
5640 (loadbios_mod_SOURCE): New macro.
5641 (loadbios_mod_CFLAGS): Likewise.
5642 (loadbios_mod_LDFLAGS): Likewise.
5643 (fixvideo_mod_SOURCE): Likewise.
5644 (fixvideo_mod_CFLAGS): Likewise.
5645 (fixvideo_mod_LDFLAGS): Likewise.
5646
7dd4a573 5647 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 5648 fixvideo.mod.
5649 (loadbios_mod_SOURCE): New macro.
5650 (loadbios_mod_CFLAGS): Likewise.
5651 (loadbios_mod_LDFLAGS): Likewise.
5652 (fixvideo_mod_SOURCE): Likewise.
5653 (fixvideo_mod_CFLAGS): Likewise.
5654 (fixvideo_mod_LDFLAGS): Likewise.
5655
af63ada2 56562009-04-08 Felix Zielcke <fzielcke@z-51.de>
5657
5658 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
5659
c2cdde70 56602009-04-07 David S. Miller <davem@davemloft.net>
5661
5662 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
5663 support for R_SPARC_OLO10 relocations. Fix compile warning for
5664 R_SPARC_WDISP30 case.
ea3f72cf 5665 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
c2cdde70 5666
761319cf 56672009-04-06 Pavel Roskin <proski@gnu.org>
5668
1007d1f5 5669 * include/grub/misc.h (ARRAY_SIZE): New macro.
5670 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
5671 New macro.
5672 * loader/i386/linux.c (allocate_pages): Use free_pages().
5673 (grub_linux_unload): Don't use free_pages().
5674 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
5675 wrong index. Treat all other modes as text modes.
5676 (grub_cmd_linux): Initialize vid_mode unconditionally to
5677 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
5678
761319cf 5679 * commands/help.c (print_command_help): Use cmd->prio, not
5680 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
5681
ea761d40 56822009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
7dd4a573 5683
ea761d40 5684 Parttool
5685
5686 * parttool/pcpart.c: new file
5687 * commands/parttool.c: likewise
5688 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
5689 (parttool_mod_SOURCES): new variable
5690 (parttool_mod_CFLAGS): likewise
5691 (parttool_mod_LDFLAGS): likewise
5692 (pcpart_mod_SOURCES): likewise
5693 (pcpart_mod_CFLAGS): likewise
5694 (pcpart_mod_LDFLAGS): likewise
7dd4a573 5695 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
ea761d40 5696 and parttool/pcpart.c
5697 * conf/i386-efi.rmk: likewise
5698 * conf/i386-ieee1275.rmk: likewise
5699 * conf/i386-pc.rmk: likewise
5700 * conf/powerpc-ieee1275.rmk: likewise
5701 * conf/sparc64-ieee1275.rmk: likewise
5702 * conf/x86_64-ieee1275.rmk: likewise
5703
05aaebfb 57042009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
5705
5706 Support for mtime and further expandability of dir command
5707
5708 * include/grub/lib/datetime.h: moved to ...
7dd4a573 5709 * include/grub/datetime.h: ... moved here and added
05aaebfb 5710 declaration of grub_unixtime2datetime. All users updated
7dd4a573 5711 * include/grub/fs.h: new syntax for dir and mtime functions in
5712 struct grub_fs
05aaebfb 5713 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
5714 and GRUB_FSHELP_FLAGS_MASK
5715 * commands/ls.c (grub_ls_list_files): Write mtime in long format
5716 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
5717 (grub_ext2_mtime): new function
5718 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
5719 (grub_hfsplus_mtime): new function
5720 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
5721 (GRUB_UFS_ATTR_FILE): likewise
5722 (GRUB_UFS_ATTR_LNK): likewise
5723 (struct grub_ufs_sblock): new fields mtime
5724 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
5725 all users updated
5726 (grub_ufs_dir): mtime support
5727 (grub_ufs_mtime): new function
5728 * fs/affs.c (grub_affs_dir): use new dir syntax
5729 * fs/afs.c (grub_afs_dir): likewise
5730 * fs/cpio.c (grub_cpio_dir): likewise
5731 * fs/fat.c (grub_fat_find_dir): likewise
5732 * fs/hfs.c (grub_hfs_dir): likewise
5733 * fs/iso9660.c (grub_iso9660_dir): likewise
5734 * fs/jfs.c (grub_jfs_dir): likewise
5735 * fs/minix.c (grub_minix_dir): likewise
5736 * fs/ntfs.c (grub_ntfs_dir): likewise
5737 * fs/reiserfs.c (grub_reiserfs_dir): likewise
5738 * fs/sfs.c (grub_sfs_dir): likewise
5739 * fs/xfs.c (grub_xfs_dir): likewise
5740 * util/hostfs.c (grub_hostfs_dir): likewise
5741 * lib/datetime.c: moved to ...
5742 * normal/datetime.c: ... moved here
5743 (grub_unixtime2datetime): new function
5744 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
7dd4a573 5745 * normal/completion.c (iterate_dir): use new dir syntax
5746 * normal/misc.c (grub_normal_print_device_info): tell the
05aaebfb 5747 last modification time of a volume
7dd4a573 5748 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
05aaebfb 5749 * conf/common.rmk: added lib/datetime.c to ls.mod
7dd4a573 5750 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
05aaebfb 5751 (normal_mod_SOURCES): likewise
5752 (datetime_mod_SOURCES): Removed lib/datetime.c
5753 * conf/i386-efi.rmk: likewise
7dd4a573 5754 * conf/i386-ieee1275.rmk: likewise
05aaebfb 5755 * conf/i386-pc.rmk: likewise
5756 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 5757 * conf/sparc64-ieee1275.rmk: likewise
5758 * conf/x86_64-efi.rmk: likewise
05aaebfb 5759
8a7e1a14 57602009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
5761
5762 Trim trailing spaces in FAT label and support mtools-like labels
7dd4a573 5763
5764 * fs/fat.c (grub_fat_iterate_dir): New function based
8a7e1a14 5765 on grub_fat_find_dir
5766 (grub_fat_find_dir): use grub_fat_iterate_dir
5767 (grub_fat_label): likewise
5768
04186a9c 57692009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
5770
7dd4a573 5771 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
04186a9c 5772 and command.h
5773 remove extraneous kernel_elf_HEADERS
5774
da4c0bb6 57752009-04-04 Bean <bean123ch@gnail.com>
5776
5777 * include/grub/util/misc.h: Add dummy function fsync for mingw.
5778
5779 * util/misc.c: Likewise.
5780
54ad9555 57812009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
5782
5783 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
5784 instead of grub_printf.
5785
7a6bf9f2 57862009-04-03 Robert Millan <rmh@aybabtu.com>
5787
5788 * loader/i386/linux.c (grub_linux_setup_video): Fill
5789 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
5790 values from `mode info' structure instead of hardcoded
5791 values.
5792
3fcc2083 57932009-04-01 Pavel Roskin <proski@gnu.org>
5794
5795 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
5796 unused now.
5797 * genmk.rb: Likewise.
5798 * configure.ac: Likewise.
5799
5ec9740b 58002009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
5801
5802 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
5803 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
5804
5270cec8 58052009-04-01 David S. Miller <davem@davemloft.net>
5806
5807 * normal/sparc64/setjmp.S: Fix setjmp implementation.
7dd4a573 5808 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
5270cec8 5809 (grub_setjmp): Mark with 'returns_twice' attribute.
5810 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
5811 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
5812 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
5813
9c3dd854 58142009-04-01 Robert Millan <rmh@aybabtu.com>
5815
5816 Reapply fix from 2008-07-28 which was accidentally reverted; also
5817 perform the same fix to a similar check in same function.
5818
5819 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
5820 with the same number are found, just use issue a warning with
5821 grub_dprintf(), as this error has been reported to be non-fatal.
5822
0d818b7e 58232009-03-31 Pavel Roskin <proski@gnu.org>
5824
5825 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
5826 for cross-compilation.
5827
95646d92 58282009-03-30 Robert Millan <rmh@aybabtu.com>
5829
5830 Fix i386-ieee1275 build.
5831
5832 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
5833 Remove declaration.
5834
6a003ed1 58352009-03-30 Pavel Roskin <proski@gnu.org>
5836
5837 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
5838 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
5839 zero-terminated, rely only on the strlen value. Fix comparison
5840 of strings differing in length.
5841
92f33540 58422009-03-30 Robert Millan <rmh@aybabtu.com>
5843
5844 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
5845 checking for abi version. Improve error messages on BIOS to notify
5846 user about `linux16' command.
5847
a8c48fd5 58482009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
5849
f968172e 5850 Leak fixes
a8c48fd5 5851
f968172e 5852 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
5853 in case of collision
5854 * disk/scsi.c (grub_scsi_open): free scsi in case of error
a8c48fd5 5855
9c323f09 58562009-03-29 Robert Millan <rmh@aybabtu.com>
5857
5858 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
5859 set `vid_mode' accordingly.
5860 (grub_linux_boot): Process `vid_mode' and set video mode.
5861
ae68f423 58622009-03-29 Robert Millan <rmh@aybabtu.com>
5863
5864 * util/grub.d/10_linux.in (linux_entry): New function.
5865 Factorize generation of Linux boot entries.
5866
5709cfc4 58672009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
5868
5869 Make the format of Environment Block plain text. The boot loader
5870 part is not tested well yet.
7dd4a573 5871
5709cfc4 5872 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
5873 (buffer): Removed.
5874 (envblk): Likewise.
5875 (usage): Remove "info" and "clear". Add "unset". Update the
5876 description of "set", as this does not delete variables any
5877 longer.
5878 (create_envblk_file): Complete rewrite.
5879 (open_envblk_file): Likewise.
5880 (cmd_info): Removed.
5881 (cmd_list): Likewise.
5882 (cmd_set): Likewise.
5883 (cmd_clear): Likewise.
5884 (list_variables): New function.
5885 (write_envblk): Likewise.
5886 (set_variables): Likewise.
5887 (unset_variables): Likewise.
5888 (main): Complete rewrite.
5889
5890 * commands/loadenv.c (buffer): Removed.
5891 (envblk): Likewise.
5892 (open_envblk_file): New function.
5893 (read_envblk_file): Complete rewrite.
5894 (grub_cmd_load_env): Likewise.
5895 (grub_cmd_list_env): Likewise.
5896 (struct blocklist): New struct.
5897 (free_blocklists): New function.
5898 (check_blocklists): Likewise.
5899 (write_blocklists): Likewise.
5900 (grub_cmd_save_env): Complete rewrite.
5901
5902 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
5903 a plain text signature.
5904 (GRUB_ENVBLK_MAXLEN): Removed.
5905 (struct grub_envblk): Complete rewrite.
5906 (grub_envblk_find): Removed.
5907 (grub_envblk_insert): Likewise.
5908 (grub_envblk_open): New prototype.
5909 (grub_envblk_set): Likewise.
5910 (grub_envblk_delete): Put const to VALUE.
5911 (grub_envblk_iterate): Put const to NAME and VALUE.
5912 (grub_envblk_close): New prototype.
5913 (grub_envblk_buffer): New inline function.
5914 (grub_envblk_size): Likewise.
5915
5916 * lib/envblk.c: Include grub/mm.h.
5917 (grub_env_find): Removed.
5918 (grub_envblk_open): New function.
5919 (grub_envblk_close): Likewise.
5920 (escaped_value_len): Likewise.
5921 (find_next_line): Likewise.
5922 (grub_envblk_insert): Removed.
5923 (grub_envblk_set): New function.
5924 (grub_envblk_delete): Complete rewrite.
5925 (grub_envblk_iterate): Likewise.
5926
a9368fd3 59272009-03-28 Robert Millan <rmh@aybabtu.com>
5928
5929 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
5930 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
5931 variables. Use 16-bit loader.
5932 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
5933 loader.
5934 * kern/i386/loader.S (grub_linux_boot): Rename to ...
5935 (grub_linux16_boot): ... this. Update all users.
5936 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
5937 (grub_linux_boot): ... this. Update all users.
5938
5939 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
5940 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
5941 commands to `linux16' and `initrd16'.
5942 (GRUB_MOD_FINI(linux)): Rename to ...
5943 (GRUB_MOD_FINI(linux16)): ... this.
5944
e4dd5a7e 59452009-03-24 Pavel Roskin <proski@gnu.org>
5946
5947 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
5948 not just for compilation.
5949
c04d6e05 59502009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
5951
5952 Move multiboot helper out of kernel
5953
5954 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
5955 `loader/i386/multiboot_helper.S'.
5956 * conf/i386-coreboot.rmk: Likewise
5957 * conf/i386-ieee1275.rmk: Likewise
5958
5959 * kern/i386/loader.S: Move multiboot helpers from here...
5960 * loader/i386/multiboot_helper.S: ...moved here
5961 * include/grub/i386/loader.h: Move declarations of multiboot
5962 helpers from here...
5963 * include/grub/i386/multiboot.h: ...moved here
5964 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
5965
42a5b3fc 59662009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
5967
5968 * kern/env.c (grub_env_context_open): Added an argument to specify
5969 whether a new context inherits exported variables from current
5970 one. This is useful when making a sandbox to interpret a config
5971 file.
5972 All callers updated.
5973
5974 * include/grub/env.h (grub_env_context_open): Updated the prototype.
5975
b28bbc4e 59762009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
5977
5978 * kern/env.c (grub_env_context_close): Fix memory leaks.
5979
f04f02e4 59802009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
5981
5982 * normal/main.c (grub_normal_execute): Added an argument
5983 BATCH to specify if an interactive interface should be provided
5984 after reading a config file.
5985 All callers updated.
5986 (read_command_list): Prevent being executed twice.
5987 (read_fs_list): Likewise.
5988
42a5b3fc 5989 * include/grub/normal.h (grub_normal_execute): Updated the
5990 prototype.
f04f02e4 5991
41473ac2 59922009-03-22 Pavel Roskin <proski@gno.org>
5993
fbc00b0c 5994 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
5995 _start.
5996 * kern/i386/pc/startup.S: Likewise.
5997 * kern/i386/efi/startup.S: Likewise.
5998 * kern/i386/ieee1275/startup.S: Likewise.
5999 * kern/i386/coreboot/startup.S: Likewise.
6000 * kern/x86_64/efi/startup.S: Likewise.
6001
41473ac2 6002 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
6003 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
6004 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
6005
2274cc8f 60062009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
6007
6008 Bugfixes in multiboot for bugs uncovered by solaris kernel.
6009
6010 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
6011 limit detection.
6012 Use vaddr of correct segment for entry_point.
6013
b1b797cb 60142009-03-21 Bean <bean123ch@gmail.com>
6015
6016 * commands/blocklist.c: Add include file <grub/command.h>, remove
6017 <grub/normal.h> and <grub/arg.h>.
6018 (grub_cmd_blocklist): Use the new command interface.
6019 (GRUB_MOD_INIT): Likewise.
6020 (GRUB_MOD_FINI): Likewise.
6021 * commands/boot.c: Likewise.
6022 * commands/cat.c: Likewise.
6023 * commands/cmp.c: Likewise.
6024 * commands/configfile.c: Likewise.
6025 * commands/crc.c: Likewise.
6026 * commands/echo.c: Likewise.
6027 * commands/halt.c: Likewise.
6028 * commands/handler.c: Likewise.
6029 * commands/hdparm.c: Likewise.
6030 * commands/help.c: Likewise.
6031 * commands/hexdump.c: Likewise.
6032 * commands/loadenv.c: Likewise.
6033 * commands/ls.c: Likewise.
6034 * commands/lsmmap.c: Likewise.
6035 * commands/lspci.c: Likewise.
6036 * commands/loadenv.c: Likewise.
6037 * commands/read.c: Likewise.
6038 * commands/reboot.c: Likewise.
6039 * commands/search.c: Likewise.
6040 * commands/sleep.c: Likewise.
6041 * commands/test.c: Likewise.
6042 * commands/usbtest.c: Likewise.
6043 * commands/videotest.c: Likewise.
6044 * commands/i386/cpuid.c: Likewise.
6045 * commands/i386/pc/halt.c: Likewise.
6046 * commands/i386/pc/play.c: Likewise.
6047 * commands/i386/pc/pxecmd.c: Likewise.
6048 * commands/i386/pc/vbeinfo.c: Likewise.
6049 * commands/i386/pc/vbetest.c: Likewise.
6050 * commands/ieee1275/suspend.c: Likewise.
6051 * disk/loopback.c: Likewise.
6052 * font/font_cmd.c: Likewise.
6053 * hello/hello.c: Likewise.
6054 * loader/efi/appleloader.c: Likewise.
6055 * loader/efi/chainloader.c: Likewise.
6056 * loader/i386/bsd.c: Likewise.
6057 * loader/i386/efi/linux.c: Likewise.
6058 * loader/i386/ieee1275/linux.c: Likewise.
6059 * loader/i386/linux.c: Likewise.
6060 * loader/i386/pc/chainloader.c: Likewise.
6061 * loader/i386/pc/linux.c: Likewise.
6062 * loader/powerpc/ieee1275/linux.c: Likewise.
6063 * loader/multiboot_loader.c: Likewise.
6064 * term/gfxterm.c: Likewise.
6065 * term/i386/pc/serial.c: Likewise.
6066 * term/terminfo.c: Likewise.
6067
6068 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
6069 * term/i386/pc/vga.c: Likewise.
6070 * video/readers/jpeg.c: Likewise.
6071 * video/readers/png.c: Likewise.
6072 * video/readers/tga.c: Likewise.
6073
6074 * util/grub-fstest (cmd_loopback): Removed.
6075 (cmd_blocklist): Likewise.
6076 (cmd_ls): Likewise.
6077 (grub_register_command): Likewise.
6078 (grub_unregister_command): Likewise.
6079 (execute_command): Use grub_command_find to locate command and execute
6080 it.
6081
6082 * include/grub/efi/chainloader.h: Removed.
6083 * loader/efi/chainloader_normal.c: Likewise.
6084 * loader/i386/bsd_normal.c: Likewise.
6085 * loader/i386/pc/chainloader_normal.c: Likewise.
6086 * loader/i386/pc/multiboot_normal.c: Likewise.
6087 * loader/linux_normal.c: Likewise.
6088 * loader/multiboot_loader_normal.c: Likewise.
6089 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
6090
6091 * gencmdlist.sh: Scan new registration command grub_register_extcmd
6092 and grub_register_command_p1.
6093
6094 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
6095 kern/command.c, lib/arg.c and commands/extcmd.c.
6096 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
6097 (minicmd_mod_SOURCES): New variable.
6098 (minicmd_mod_CFLAGS): Likewise.
6099 (minicmd_mod_LDFLAGS): Likewise.
6100 (extcmd_mod_SOURCES): Likewise.
6101 (extcmd_mod_CFLAGS): Likewise.
6102 (extcmd_mod_LDFLAGS): Likewise.
6103 (boot_mod_SOURCES): Removed.
6104 (boot_mod_CFLAGS): Likewise.
6105 (boot_mod_LDFLAGS): Likewise.
6106
6107 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
6108 kern/corecmd.c.
6109 (kernel_img_HEADERS): Add command.h.
6110 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
6111 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
6112 and lib/arg.c.
6113 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
6114 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
6115 remove the corresponding normal mode command.
6116 (normal_mod_SOURCES): Remove normal/arg.c.
6117 * conf/i386-coreboot.rmk: Likewise.
6118 * conf/i386-efi.rmk: Likewise.
6119 * conf/i386-ieee1275.rmk: Likewise.
6120 * conf/powerpc-ieee1275.rmk: Likewise.
6121 * conf/x86_64-efi.rmk: Likewise.
6122
6123 * include/grub/arg.h: Move from here ...
6124 * include/grub/lib/arg.h: ... to here.
6125
6126 * normal/arg.c: Move from here ...
6127 * lib/arg.c: ... to here.
6128
6129 * commands/extcmd.c: New file.
6130 * commands/minicmd.c: Likewise.
6131 * include/grub/command.h: Likewise.
6132 * include/grub/extcmd.h: Likewise.
6133 * kern/command.c: Likewise.
6134 * kern/corecmd.c: Likewise.
6135
6136 * kern/list.c (grub_list_iterate): Return int instead of void.
6137 (grub_list_insert): New function.
6138 (grub_prio_list_insert): Likewise.
6139
6140 * kern/rescue.c (grub_rescue_command): Removed.
6141 (grub_rescue_command_list): Likewise.
6142 (grub_rescue_register_command): Likewise.
6143 (grub_rescue_unregister_command): Likewise.
6144 (grub_rescue_cmd_boot): Move to minicmd.c
6145 (grub_rescue_cmd_help): Likewise.
6146 (grub_rescue_cmd_info): Likewise.
6147 (grub_rescue_cmd_boot): Likewise.
6148 (grub_rescue_cmd_testload): Likewise.
6149 (grub_rescue_cmd_dump): Likewise.
6150 (grub_rescue_cmd_rmmod): Likewise.
6151 (grub_rescue_cmd_lsmod): Likewise.
6152 (grub_rescue_cmd_exit): Likewise.
6153 (grub_rescue_print_devices): Moved to corecmd.c.
6154 (grub_rescue_print_files): Likewise.
6155 (grub_rescue_cmd_ls): Likewise.
6156 (grub_rescue_cmd_insmod): Likewise.
6157 (grub_rescue_cmd_set): Likewise.
6158 (grub_rescue_cmd_unset): Likewise.
7d074e3c 6159 (attempt_normal_mode): Use grub_command_find to get normal module.
b1b797cb 6160 (grub_enter_rescue_mode): Use grub_register_core_commands to register
7d074e3c 6161 commands, remove grub_rescue_register_command calls.
b1b797cb 6162
7d074e3c 6163 * normal/command.c (grub_register_command): Removed.
b1b797cb 6164 (grub_unregister_command): Likewise.
6165 (grub_command_find): Likewise.
6166 (grub_iterate_commands): Likewise.
6167 (rescue_command): Likewise.
6168 (export_command): Moved to corecmd.c.
6169 (set_command): Removed.
6170 (unset_command): Likewise.
6171 (insmod_command): Likewise.
6172 (rmmod_command): Likewise.
6173 (lsmod_command): Likewise.
6174 (grub_command_init): Likewise.
6175
6176 * normal/completion.c (iterate_command): Use cmd->prio to check for
6177 active command.
6178 (complete_arguments): Use grub_extcmd_t structure to find options.
6179 (grub_normal_do_completion): Change function grub_iterate_commands to
6180 grub_command_iterate.
6181
6182 * normal/execute.c (grub_script_execute_cmd): No need to parse
6183 argument here.
6184
6185 * normal/main.c (grub_dyncmd_dispatcher): New function.
6186 (read_command_list): Register unload commands as dyncmd.
6187 (grub_cmd_normal): Use new command interface, register rescue,
6188 unregister normal at entry, register normal, unregister rescue at exit.
6189
6190 * include/grub/list.h (grub_list_test_t): New type.
6191 (grub_list_iterate): Return int instead of void.
6192 (grub_list_insert): New function.
6193 (GRUB_AS_NAMED_LIST_P): New macro.
6194 (GRUB_AS_PRIO_LIST): Likewise.
6195 (GRUB_AS_PRIO_LIST_P): Likewise.
6196 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
6197 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
6198 (grub_prio_list): New structure.
6199 (grub_prio_list_insert): New function.
6200 (grub_prio_list_remove): New inline function.
6201
6202 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
6203 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
6204 (GRUB_COMMAND_FLAG_MENU): Likewise.
6205 (GRUB_COMMAND_FLAG_BOTH): Likewise.
6206 (GRUB_COMMAND_FLAG_TITLE): Likewise.
6207 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
6208 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
6209 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
6210 (grub_command): Likewise.
6211 (grub_register_command): Likewise.
6212 (grub_command_find): Likewise.
6213 (grub_iterate_commands): Likewise.
6214 (grub_command_init): Likewise.
6215 (grub_arg_parse): Likewise.
6216 (grub_arg_show_help): Likewise.
6217
6218 * include/grub/rescue.h (grub_rescue_register_command): Removed.
6219 (grub_rescue_unregister_command): Likewise.
6220
6221 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
6222 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
6223 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
6224
6225 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
6226 grub_rescue_cmd_initrd.
6227 * include/grub/i386/loader.h: Likewise.
6228 * include/grub/x86_64/loader.h: Likewise.
6229
6230 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
6231
1f4147aa 62322009-03-21 Bean <bean123ch@gmail.com>
6233
6234 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
6235 instead of stat in mingw environment.
6236
6237 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
6238
6239 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
6240
6241 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
6242 AC_CONFIG_LINKS.
6243
2156d5ba 62442009-03-21 Bean <bean123ch@gmail.com>
6245
6246 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
6247 out of range error.
6248
177b82ca 62492009-03-18 Michel Dänzer <michel@daenzer.net>
6250
6251 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
6252 checking inode flags for EXT4_EXTENTS_FLAG.
6253
14aad807 62542009-03-18 Robert Millan <rmh@aybabtu.com>
6255
6256 * loader/i386/linux.c: Include `<grub/video.h>' and
6257 `<grub/i386/pc/vbe.h>'..
6258 (grub_linux_setup_video): New function. Loosely based on the EFI one.
6259 (grub_linux32_boot): Attempt to configure video settings with
6260 grub_linux_setup_video().
6261 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
6262 to avoid grub_console_fini() which would step out of graphical mode
6263 unconditionally.
6264
8cf83a27 62652009-03-14 Robert Millan <rmh@aybabtu.com>
6266
6267 Fix build on powerpc.
6268 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
6269
40164e75 62702009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
6271
6272 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
6273 background image command.
6274
c58bc32a 62752009-03-12 Colin D Bennett <colin@gibibit.com>
6276
6277 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
6278 (grub_gfxterm_putchar): Extract pairs of identical calls to
6279 draw_cursor out of conditional blocks.
6280
5415144a 62812009-03-11 Pavel Roskin <proski@gnu.org>
6282
6283 * fs/hfs.c (grub_hfs_strncasecmp): New function.
6284 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
6285
6394042e 62862009-03-11 Robert Millan <rmh@aybabtu.com>
6287
6288 * loader/i386/multiboot_elfxx.c
6289 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
6290
b7b50e5f 62912009-03-11 Felix Zielcke <fzielcke@z-51.de>
6292
6293 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
6294 `kern/handler.c'.
6295
1ca7fc96 62962009-03-11 Robert Millan <rmh@aybabtu.com>
6297
6298 * loader/i386/multiboot.c (code_size): New variable.
6299 (grub_multiboot): Define offsets by adding to `code_size' rather
7d074e3c 6300 than subtracting from `grub_multiboot_payload_size'. Provide
1ca7fc96 6301 4-byte alignment to MBI and others by increasing
7d074e3c 6302 `boot_loader_name_length' appropriately.
1ca7fc96 6303
6304 * loader/i386/multiboot_elfxx.c
6305 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
6306
a83ea1d2 63072009-03-09 Felix Zielcke <fzielcke@z-51.de>
6308
6309 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
6310 `fs/ext2.c'.
6311
aa9f3bff 63122009-03-08 Robert Millan <rmh@aybabtu.com>
6313
6314 Make loader/i386/linux.c usable on i386-pc again.
6315
6316 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
6317 memory to heap.
6318 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
6319 `#error' stanza.
6320
d8b3b60e 63212009-03-07 Bean <bean123ch@gmail.com>
6322
6323 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
6324 allocation.
6325
b362c9e9 63262009-03-06 Robert Millan <rmh@aybabtu.com>
6327
6328 Fix display issue on terminals with screen size other than 80x25
6329 (e.g. gfxterm with resolution higher than 640x480).
6330
6331 * normal/main.c (grub_normal_init_page): Display title text in a
7d074e3c 6332 position relative to the center of the terminal instead of relying
b362c9e9 6333 on a hardcoded offset.
6334
9304eef1 63352009-03-04 Robert Millan <rmh@aybabtu.com>
6336
6337 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
6338 installed.
6339
6340 * Makefile.in (host_kernel): New variable.
6341 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
6342 scripts instead of just the windows one.
6343 * configure.ac: Initialize and AC_SUBST `host_kernel'.
6344
eabc95fb 63452009-03-04 Felix Zielcke <fzielcke@z-51.de>
2ba60b62 6346
6347 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
6348 `kern/handler.c'.
6349 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6350 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6351 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
6352 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6353 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6354 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6355
ceb1223c 63562009-03-04 Felix Zielcke <fzielcke@z-51.de>
6357
6358 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
6359 or if there's no space for the disk label and print the partition number on a
6360 invalid magic.
6361
4910684a 63622009-03-04 Felix Zielcke <fzielcke@z-51.de>
6363
6364 * util/misc.c: Include <time.h>.
6365 (grub_millisleep): New function.
6366
7e9ca17a 63672009-03-04 Bean <bean123ch@gmail.com>
6368
6369 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
6370 another option -mno-red-zone.
6371
6372 * commands/handler.c: Change module description.
6373
6374 * kern/handler.c: Add missing space at the end of description line.
6375
6376 * kern/list.c: Likewise.
6377
f501677c 63782009-03-03 Robert Millan <rmh@aybabtu.com>
6379
6380 Move more components to the relocation area, and fix mbi pointer
6381 handling to use the destination rather than the origin (thanks to
6382 Vladimir Serbinenko for spotting).
6383
6384 * loader/i386/multiboot.c (mbi_dest): New variable.
6385 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
6386 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
6387 relocation area.
6388
9902d047 63892009-03-01 Bean <bean123ch@gmail.com>
6390
50fb7002 6391 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
9902d047 6392 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
6393 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
6394 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
6395
6396 * loader/i386/efi/linux.c (acpi_guid): New variable.
6397 (acpi_guid): Likewise.
6398 (EBDA_SEG_ADDR): New constant.
6399 (LOW_MEM_ADDR): Likewise.
6400 (FAKE_EBDA_SEG): Likewise.
6401 (fake_bios_data): New function.
6402 (grub_linux_boot): Call fake_bios_data.
6403
71b9f361 64042009-03-01 Bean <bean123ch@gmail.com>
6405
6406 * commands/terminal.c: Removed.
6407
6408 * commands/handler.c: New file.
6409
6410 * include/grub/list.h: Likewise.
6411
6412 * include/grub/handler.h: Likewise.
6413
6414 * kern/list.c: Likewise.
6415
6416 * kern/handler.c: Likewise.
6417
6418 * kern/term.h: Include header file <grub/handler.h>.
6419 (grub_term_input): Move next field to the beginning.
6420 (grub_term_output): Likewise.
6421 (grub_term_input_class): New variable.
6422 (grub_term_output_class): Likewise.
6423 (grub_term_register_input): Changed to inline function.
6424 (grub_term_register_output): Likewise.
6425 (grub_term_unregister_input): Likewise.
6426 (grub_term_unregister_output): Likewise.
6427 (grub_term_set_current_input): Likewise.
6428 (grub_term_set_current_output): Likewise.
6429 (grub_term_get_current_input): Likewise.
6430 (grub_term_get_current_output): Likewise.
6431 (grub_term_iterate_input): Removed.
6432 (grub_term_iterate_output): Likewise.
6433
6434 * kern/term.c (grub_term_list_input): Removed.
6435 (grub_term_list_output): Likewise.
6436 (grub_term_input_class): New variable.
6437 (grub_term_output_class): Likewise.
50fb7002 6438 (grub_cur_term_input): Change variable as macro.
71b9f361 6439 (grub_cur_term_output): Likewise.
6440 (grub_term_register_input): Removed.
6441 (grub_term_register_output): Likewise.
6442 (grub_term_unregister_input): Likewise.
6443 (grub_term_unregister_output): Likewise.
6444 (grub_term_set_current_input): Likewise.
6445 (grub_term_set_current_output): Likewise.
6446 (grub_term_iterate_input): Likewise.
6447 (grub_term_iterate_output): Likewise.
6448 (grub_term_get_current_input): Likewise.
6449 (grub_term_get_current_output): Likewise.
6450
6451 * util/grub-editenv.c: Include header file <grub/handler.h>.
6452 (grub_term_get_current_input): Removed.
6453 (grub_term_get_current_output): Likewise.
6454 (grub_term_input_class): New variable.
50fb7002 6455 (grub_term_output_class): Likewise.
71b9f361 6456
6457 * util/grub-fstest.c (grub_term_get_current_input): Removed.
6458 (grub_term_get_current_output): Likewise.
6459 (grub_term_input_class): New variable.
50fb7002 6460 (grub_term_output_class): Likewise.
71b9f361 6461
6462 * util/grub-probe.c (grub_term_get_current_input): Removed.
6463 (grub_term_get_current_output): Likewise.
6464 (grub_term_input_class): New variable.
50fb7002 6465 (grub_term_output_class): Likewise.
71b9f361 6466
6467 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
6468 (grub_term_get_current_output): Likewise.
6469 (grub_term_input_class): New variable.
50fb7002 6470 (grub_term_output_class): Likewise.
71b9f361 6471
6472 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
6473 (terminal_mod_SOURCES): Likewise.
6474 (terminal_mod_CFLAGS): Likewise.
6475 (terminal_mod_LDFLAGS): Likewise.
6476
6477 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
6478 handler.c.
6479 (kernel_img_SOURCES): Add list.c and handler.c.
6480 (kernel_img_HEADERS): Add list.h and handler.h.
6481
6482 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6483 handler.c.
6484 (kernel_mod_SOURCES): Add list.c and handler.c.
6485 (kernel_mod_HEADERS): Add list.h and handler.h.
6486
6487 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
6488 handler.c.
6489 (kernel_elf_SOURCES): Add list.c and handler.c.
6490 (kernel_elf_HEADERS): Add list.h and handler.h.
6491
6492 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6493 handler.c.
6494 (kernel_elf_SOURCES): Add list.c and handler.c.
6495 (kernel_elf_HEADERS): Add list.h and handler.h.
6496
6497 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6498 handler.c.
6499 (kernel_mod_SOURCES): Add list.c and handler.c.
6500 (kernel_mod_HEADERS): Add list.h and handler.h.
6501
6502 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6503 handler.c.
6504 (kernel_elf_SOURCES): Add list.c and handler.c.
6505 (kernel_elf_HEADERS): Add list.h and handler.h.
6506
8a31787f 65072009-02-27 Robert Millan <rmh@aybabtu.com>
6508
6509 Factorize elf32 / elf64 code in Multiboot loader. This will
6510 prevent it from getting out of sync again.
6511
6512 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
6513 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
6514 grub_multiboot_load_elf64): Move from here ...
6515 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
6516 grub_multiboot_load_elf): ... to here (new file).
6517
51cd3dfc 65182009-02-27 Robert Millan <rmh@aybabtu.com>
6519
6520 * util/grub.d/10_linux.in: Rename "single-user mode" to
6521 "recovery mode".
6522
6e8c9c3a 65232009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
6524
6525 Don't leak in SCSI code.
6526 * disk/scsi.c (grub_scsi_close): free `scsi'.
6527
4b6bf4f9 65282009-02-27 Robert Millan <rmh@aybabtu.com>
6529
6530 * loader/i386/pc/multiboot.c: Move from here ...
6531 * loader/i386/multiboot.c: ... to here. Update all users.
6532
b9413424 65332009-02-27 Robert Millan <rmh@aybabtu.com>
6534
6535 Patch from Alexandre Bique <bique.alexandre@gmail.com>
6536 * util/i386/pc/grub-setup.c (setup): Fix directory path.
6537
50fb7002 65382009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
34519c3f 6539
6540 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
6541 b-tree.
6542
8cc50345 65432009-02-27 Robert Millan <rmh@aybabtu.com>
6544
6545 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
6546 `0x' qualifier as 0 when base is specified as parameter).
6547
6e09b8b7 65482009-02-24 Bean <bean123ch@gmail.com>
6549
6550 * configure.ac: Check for -mcmodel=large in x86_64 target.
6551
6552 * include/grub/efi/api.h (efi_call_10): New macro.
6553 (efi_wrap_10): New function.
6554
6555 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
6556 (GRUB_PE32_REL_BASED_HIGH): Likewise.
6557 (GRUB_PE32_REL_BASED_LOW): Likewise.
6558 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
6559 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
6560 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
6561 (GRUB_PE32_REL_BASED_SECTION): Likewise.
6562 (GRUB_PE32_REL_BASED_REL): Likewise.
6563 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
6564 (GRUB_PE32_REL_BASED_DIR64): Likewise.
6565 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
6566
6567 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
6568 issue.
6569
6570 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
6571 (efi_wrap_10): New function.
6572
6573 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
6574
6575 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
6576 MB/MBP model (NV chipset).
6577 (devdata_devs): Add devpath_5 to the list.
6578
6579 * load/i386/efi/linux.c (video_base): Remove variable.
6580 (RGB_MASK): New macro.
6581 (RGB_MAGIC): Likewise.
6582 (LINE_MIN): Likewise.
6583 (LINE_MAX): Likewise.
6584 (FBTEST_STEP): Likewise.
6585 (FBTEST_COUNT): Likewise.
6586 (fb_list): New variable.
6587 (grub_find_video_card): Remove function.
6588 (find_framebuf): New function.
6589 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
6590 line length.
6591
6592 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
6593 problem for x86_64.
6594
74b21bee 65952009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
6596
6597 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
6598
6599 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
6600 coding tool name.
6601
a455f472 66022009-02-22 Robert Millan <rmh@aybabtu.com>
6603
6604 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
6605 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
6606 in our relocation, instead of using it directly from heap. Also
6607 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
6608
6374daf3 66092009-02-21 Robert Millan <rmh@aybabtu.com>
6610
6611 Implement USB keyboard support (based on patch by Marco Gerards)
6612
6613 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
6614 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
6615 (usb_keyboard_mod_LDFLAGS): New variables.
6616
6617 * term/usb_keyboard.c: New file.
6618
8fa4ea70 66192009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
6620
6621 Corrected wrong declaration
6622
6623 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
6624
353976ac 66252009-02-14 Christian Franke <franke@computer.org>
6626
6627 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
6628 (grub_lspci_iter): Print class code and programming interface byte.
6629
6aa1169b 66302009-02-14 Christian Franke <franke@computer.org>
6631
6632 * gendistlist.sh: Ignore `.svn' directories.
6633
265372ca 66342009-02-14 Felix Zielcke <fzielcke@z-51.de>
6635
6636 * fs/fat.c: Add 2009 to Copyright line.
6637
9ff516f3 66382009-02-14 Christian Franke <franke@computer.org>
6639
6640 * commands/hdparm.c: New file. Provides `hdparm' command
6641 which sends ATA commands via grub_disk_ata_pass_through ().
6642
6643 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
6644
6645 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
6646 and <grub/cpu/io.h> to include/grub/ata.h.
6647 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
6648 (GRUB_CDROM_SECTOR_SIZE): Remove.
6649 (GRUB_ATA_*): Move to include/grub/ata.h.
6650 (GRUB_ATAPI_*): Likewise.
6651 (enum grub_ata_commands): Likewise.
6652 (enum grub_ata_timeout_milliseconds): Likewise.
6653 (struct grub_ata_device): Likewise.
6654 (grub_ata_regset): Likewise.
6655 (grub_ata_regget): Likewise.
6656 (grub_ata_regset2): Likewise.
6657 (grub_ata_regget2): Likewise.
6658 (grub_ata_check_ready): Likewise.
6659 (grub_ata_wait_not_busy): Remove static, exported in
6660 include/grub/ata.h.
6661 (grub_ata_wait_drq): Likewise.
6662 (grub_ata_pio_read): Likewise.
6663
6664 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
6665 function for hdparm.mod.
6666
6667 * include/grub/ata.h: New file, contains declarations from
6668 disk/ata.c.
6669 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
6670
6671 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
6672 (grub_disk_ata_pass_through): New exported variable.
6673
6674 * kern/disk.c (grub_disk_ata_pass_through): New variable.
6675
772e23da 66762009-02-13 Colin D Bennett <colin@gibibit.com>
6677
6678 Support multiple fallback entries, and provide an API to support
6679 executing default+fallback menu entries. Renamed the `terminal' menu
6680 viewer to `text'.
6681
6682 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
6683 variable declaration.
6684 (grub_menu_execute_callback): New structure declaration.
6685 (grub_menu_execute_callback_t): New typedef.
6686 (grub_menu_execute_with_fallback): New function declaration.
6687 (grub_menu_get_entry): Likewise.
6688 (grub_menu_get_timeout): Likewise.
6689 (grub_menu_set_timeout): Likewise.
6690
6691 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
6692
6693 * normal/menu.c (grub_wait_after_message): Moved to
6694 `normal/menu_text.c'.
6695 (draw_border): Likewise.
6696 (print_message): Likewise.
6697 (print_entry): Likewise.
6698 (print_entries): Likewise.
6699 (grub_menu_init_page): Likewise.
6700 (get_entry_number): Likewise.
6701 (print_timeout): Likewise.
6702 (run_menu): Likewise.
6703 (grub_menu_execute_entry): Likewise.
6704 (show_text_menu): Likewise.
6705 (get_and_remove_first_entry_number): New function.
6706 (grub_menu_execute_with_fallback): Likewise.
6707 (get_entry): Renamed to ...
6708 (grub_menu_get_entry): .. this and made it global.
6709 (get_timeout): Renamed to ...
6710 (grub_menu_get_timeout): ... this and made it global.
6711 (set_timeout): Renamed to ...
6712 (grub_menu_set_timeout): ... this and made it global.
6713 (grub_normal_terminal_menu_viewer): Renamed to ...
6714 (grub_normal_text_menu_viewer): ... this.
6715
6716 * normal/menu_text.c: New file. Extracted text-menu-specific code
6717 from normal/menu.c.
6718
6719 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
6720 (normal_mod_SOURCES): Likewise.
6721
6722 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6723 (normal_mod_SOURCES): Likewise.
6724
6725 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6726 (normal_mod_SOURCES): Likewise.
6727
6728 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
6729 (normal_mod_SOURCES): Likewise.
6730
6731 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6732 (normal_mod_SOURCES): Likewise.
6733
6734 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6735 (normal_mod_SOURCES): Likewise.
6736
6737 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6738 (normal_mod_SOURCES): Likewise.
6739
16ac430e 67402009-02-11 Robert Millan <rmh@aybabtu.com>
6741
6742 * util/grub.d/00_header.in: Update old reference to `font' command.
6743
06ff20fc 67442009-02-10 Felix Zielcke <fzielcke@z-51.de>
6745
6746 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
6747
6748 Based on patch from Javier Martín.
6749
96da9407 67502009-02-09 Felix Zielcke <fzielcke@z-51.de>
6751
6752 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
50fb7002 6753 to avoid false positives with FAT.
96da9407 6754 (grub_fstest_SOURCES): Likewise.
6755 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
6756 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6757 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6758 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
6759 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6760 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6761
6dca6fe4 67622009-02-09 Felix Zielcke <fzielcke@z-51.de>
6763
06ff20fc 6764 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
6dca6fe4 6765 bpb.version_specific.fat12_or_fat16.fstype and
6766 bpb.version_specific.fat32.fstype.
6767
2550c62f 67682009-02-08 Robert Millan <rmh@aybabtu.com>
6769
be110b30 6770 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
2550c62f 6771
56978920 67722009-02-08 Robert Millan <rmh@aybabtu.com>
6773
6774 * Makefile.in (host_os, host_cpu): New variables.
6775 (target_os): Remove. Update all users.
6776
d64399b5 67772009-02-08 Marco Gerards <marco@gnu.org>
6778
6779 * Makefile.in (enable_grub_emu_usb): New variable.
6780 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
6781 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
6782 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
6783 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
6784 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
6785 `usbtest.mod' and `usbms.mod'.
6786 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
6787 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
6788 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
6789 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
6790 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
6791 variables.
6792
6793 * disk/usbms.c: New file.
6794
6795 * include/grub/usb.h: Likewise.
6796
6797 * include/grub/usbtrans.h: Likewise.
6798
6799 * include/grub/usbdesc.h: Likewise.
6800
6801 * bus/usb/usbtrans.c: Likewise.
6802
6803 * bus/usb/ohci.c: Likewise.
6804
6805 * bus/usb/uhci.c: Likewise.
6806
6807 * bus/usb/usbhub.c: Likewise.
6808
6809 * bus/usb/usb.c: Likewise.
6810
6811 * commands/usbtest.c: Likewise.
6812
6813 * util/usb.c: Likewise.
50fb7002 6814
d64399b5 6815 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
6816
6817 * configure.ac: Test for libusb presence.
50fb7002 6818
d64399b5 6819 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
6820
2b40d6bb 68212009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
6822
6823 * kern/mm.c: Add more comments.
6824
73a4ce81 68252009-02-08 Robert Millan <rmh@aybabtu.com>
6826
6827 Patch from Javier Martín.
6828 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
6829 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
6830
f821ce59 68312009-02-08 Robert Millan <rmh@aybabtu.com>
6832
6833 * fs/cpio.c: Split tar functionality to ...
6834 * fs/tar.c: ... here (new file). Update all users.
6835
aebfc4b0 68362009-02-07 Robert Millan <rmh@aybabtu.com>
6837
6838 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
6839 backward-incompatible features.
6840
6841 Based on patch from Javier Martín, with some adjustments.
6842
50fb7002 68432009-02-07 Michael Scherer <misc@mandriva.org>
cea15bca 6844
6845 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
6846
0bb5115e 68472009-02-07 Robert Millan <rmh@aybabtu.com>
6848
6849 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
6850 position of `disk/lvm.c' to ensure grub_init_all() always picks it
6851 after the RAID stuff.
6852
38a0f8e7 68532009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
6854
50fb7002 6855 Fixes problem when running vbetest command as reported by
38a0f8e7 6856 Vladimir Serbinenko <phcoder@gmail.com>.
6857
6858 * (grub_vbe_set_video_mode): Fixed problem with text modes.
6859
3143cc1c 68602009-02-04 Felix Zielcke <fzielcke@z-51.de>
6861
6862 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
6863 /dev/md/NpN style mdraid devices.
6864
9cba6fce 68652009-02-03 Felix Zielcke <fzielcke@z-51.de>
6866
6867 * util/unifont2pff.rb: Remove.
6868
e507a2c1 68692009-02-03 Felix Zielcke <fzielcke@z-51.de>
6870
6871 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
6872 `#'.
6873
d2c2b4cd 68742009-02-03 Felix Zielcke <fzielcke@z-51.de>
6875
6876 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
6877 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6878 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6879 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
6880 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6881 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6882 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6883
b4315fb0 68842009-02-02 Christian Franke <franke@computer.org>
6885
6886 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
6887
de3aa260 68882009-02-01 Felix Zielcke <fzielcke@z-51.de>
6889
7c3ff286 6890 * INSTALL: Note that we now require at least autoconf 2.59 and
6891 that LZO is optional.
de3aa260 6892
825a182b 68932009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
6894
6895 Base on patch on bug #24154 created by Tomas Tintera
6896 <trosos@seznam.cz>.
6897
6898 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
6899
a69ef770 69002009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
6901
7c3ff286 6902 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
a69ef770 6903 <bero@arklinux.org>.
6904
6905 * normal/parser.y (script_init): Add missing semicolon.
6906
6fa42fa6 69072009-01-31 Colin D Bennett <colin@gibibit.com>
6908
7c3ff286 6909 * normal/main.c: Add include to grub/menu_viewer.h.
6fa42fa6 6910 (free_menu_entry_classes): Added.
6911 (grub_normal_menu_addentry): Added class property handling.
6912 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
6913 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
6914
6915 * normal/menu_viewer.c: New file.
6916
6917 * normal/menu.c (run_menu_entry): Renamed to ...
6918 (grub_menu_execute_entry): ... this and made it as global.
6919 (grub_menu_run): Renamed to ...
6920 (show_text_menu): ... this and made it local.
6921 (show_text_menu): Adapt to new function names.
6922 (grub_normal_terminal_menu_viewer): New global variable.
6923
6924 * include/grub/menu.h: New file.
6925
6926 * include/grub/menu_viewer.h: New file.
6927
6928 * include/grub/normal.h: Added include to grub/menu.h.
6929 (grub_menu_entry): Moved to include/grub/menu.h.
6930 (grub_menu_entry_t): Likewise.
6931 (grub_menu): Likewise.
6932 (grub_menu_t): Likewise.
6933 (grub_normal_terminal_menu_viewer): Added.
6934 (grub_menu_execute_entry): Likewise.
6935 (grub_menu_run): Removed.
6936
6937 * DISTLIST: Added include/grub/menu.h.
6938 Added include/grub/menu_viewer.h.
6939 Added normal/menu_viewer.c.
6940
69412009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
6942
6943 * normal/execute.c (grub_script_execute_menuentry): Changed to use
6944 arglist for menutitle arguments.
6945
6946 * normal/main.c (grub_normal_menu_addentry): Likewise.
6947
6948 * normal/parser.y (menuentry): Likewise.
6949
6950 * normal/script.c (grub_script_create_cmdmenu): Likewise.
6951
6952 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
6953 (grub_script_create_cmdmenu): Likewise.
6954
6955 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
6956
6957 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
6958 changes.
6959
6960 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
6961
6962 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
6963
6964 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
6965
6966 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
6967
6968 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
6969
6970 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
6971
56192c23 69722009-01-30 Christian Franke <franke@computer.org>
6973
6974 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
6975 in option help text.
6976
d72521b3 69772009-01-27 Pavel Roskin <proski@gnu.org>
6978
6979 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
6980
994b5e84 69812009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
6982
6983 * commands/lsmmap.c: Add include to grub/machine/memory.h.
6984
6985 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
6986
6987 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
6988 unregister function.
6989
6a7eab2c 69902009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
6991
6992 * disk/scsi.c (grub_scsi_read): Fix sign problem.
6993
6994 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
6995
6996 * util/grub-mkfont.c (usage): Fix typo.
6997
6998 * util/elf/grub-mkimage.c (load_modules): Fix warning.
6999
1806b56e 70002009-01-26 Daniel Mierswa <impulze@impulze.org>
7001
3fb18f09 7002 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
7003
336e1fb9 7004 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
7005
1806b56e 7006 * kern/misc.c (grub_strcasecmp): New function.
7007 (grub_strcasecmp): Use grub_size_t instead of int for length.
7008 Fix return value.
7009 * include/grub/misc.h: Update function prototypes.
7010
580b2a0f 70112009-01-26 Robert Millan <rmh@aybabtu.com>
7012
7013 * configure.ac: Fix cross-compilation check.
ef257b36 7014
d31c24f1 70152009-01-22 Christian Franke <franke@computer.org>
7016
7017 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
7018 (precision) digit string. Allow `.format2' without `format1' (width).
7019 Limit input chars for `%s' output to `format2' if specified. This is
7020 compatible with standard printf ().
7021
3138b44c 70222009-01-22 Christian Franke <franke@computer.org>
7023
7024 * disk/ata.c (grub_ata_wait_status): Replace by ...
7025 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
7026 other status bits may be invalid while BSY is asserted.
7027 (grub_ata_check_ready): New function.
7028 (grub_ata_cmd): Removed.
7029 (grub_ata_wait_drq): New function.
7030 (grub_ata_strncpy): Remove inline.
7031 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
7032 and error check now done by grub_ata_wait_drq ().
7033 (grub_ata_pio_write): Likewise.
7034 (grub_atapi_identify): Set DEV before check for !BSY. Use
7035 grub_ata_wait_drq () to wait for data.
7036 (grub_ata_device_initialize): Add status register check to
7037 detect missing SATA slave devices. Add debug messages.
7038 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
7039 (grub_atapi_packet): Set DEV before check for !BSY. Replace
7040 transfer loop by grub_ata_pio_write ().
7041 (grub_ata_identify): Set DEV before check for !BSY. Use
7042 grub_ata_wait_drq () to wait for data.
ef257b36 7043 (grub_ata_setaddress): Set DEV before check for !BSY.
3138b44c 7044 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
7045 read/write in one loop. Fix invalid command on write. Fix incomplete
7046 command on (size % batch) == 0. Add missing error check after write of
7047 last block. Add debug messages.
7048 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
7049
59a64ef6 70502009-01-19 Christian Franke <franke@computer.org>
7051
7052 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
7053 (GRUB_ATAPI_IREASON_*): Likewise.
7054 (grub_ata_pio_write): Fix timeout error return.
7055 (grub_atapi_identify): Add grub_ata_wait () after cmd.
7056 (grub_atapi_wait_drq): New function.
7057 (grub_atapi_packet): New parameter `size'.
7058 Use grub_atapi_wait_drq () and direct write instead of
7059 grub_ata_pio_write ().
7060 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
7061 reads the number of bytes requested by the device for each DRQ
7062 assertion.
7063 (grub_atapi_write): Remove old implementation, return not
7064 implemented instead.
7065
1cfe20b3 70662009-01-19 Christian Franke <franke@computer.org>
7067
7068 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
7069 of 512 to calculate data size.
7070 (grub_scsi_read12): Likewise.
7071 (grub_scsi_write10): Likewise.
7072 (grub_scsi_write12): Likewise.
7073 (grub_scsi_read): Adjust size according to blocksize.
7074 Add checks for invalid blocksize and unaligned transfer.
7075
bee5fe5d 70762009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
7077
7078 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
7079
ef257b36 7080 * term/gfxterm.c (write_char): Fix background rendering for wide
bee5fe5d 7081 width glyphs.
7082
3e643f8c 70832009-01-19 Robert Millan <rmh@aybabtu.com>
7084
7085 * config.guess: Update to latest version from config git.
7086 * config.sub: Likewise.
7087
4fa80998 70882009-01-17 Felix Zielcke <fzielcke@z-51.de>
7089
7090 * Makefile.in: Change font compilation to use new grub-mkfont instead
7091 of java version.
7092
7093 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
7094 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
7095 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7096 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7097 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
7098 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
7099 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
7100 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
7101 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7102
7086085b 71032009-01-16 Christian Franke <franke@computer.org>
7104
7105 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
7106 (enum grub_ata_timeout_milliseconds): New enum.
7107 (grub_ata_wait_status): Add parameter milliseconds.
7108 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
7109 recovery from timed-out commands.
7110 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
7111 return grub_errno instead of REG_ERROR.
7112 (grub_ata_pio_write): Add parameter milliseconds.
7113 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
7114 Pass milliseconds to grub_ata_wait_status () and
7115 grub_ata_pio_read ().
7116 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
7117 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
7118 grub_ata_wait_status (). Fix IDENTIFY timeout check.
7119 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
7120 It is not suitable for device detection, because DEV bit is ignored,
7121 the command may run too long, and not all devices set the signature
7122 properly.
7123 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
7124 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
7125 Fix device selection, DEV bit must be set first to address the registers
7126 of the correct device.
7127 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
7128 grub_ata_pio_read/write ().
7129 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
7130 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
7131
4a412913 71322009-01-13 Carles Pina i Estany <carles@pina.cat>
7133
7134 * util/grub-editenv.c (main): Use fseeko(), not fseek().
7135
7795c55e 71362009-01-13 Bean <bean123ch@gmail.com>
d913988c 7137
7138 * util/grub-mkfont.c (write_font): forget to remove some debug code.
7139
7795c55e 71402009-01-13 Bean <bean123ch@gmail.com>
e52db1f7 7141
7142 * Makefile.in: (enable_grub_mkfont): New variable.
7143 (freetype_cflags): Likewise.
7144 (freetype_libs): Likewise.
7145
7146 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
7147 (grub_mkfont_SOURCES): New variable.
7148 (grub_mkfont_CFLAGS): Likewise.
7149 (grub_mkfont_LDFLAGS): Likewise.
7150
7151 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
7152 library if `--enable-grub-mkfont' is requested.
7153 (enable_grub_mkfont): New variable.
7154 (freetype_cflags): Likewise.
7155 (freetype_libs): Likewise.
7156
7157 * util/grub-mkfont.c: New file.
7158
093af1fe 71592009-01-12 Christian Franke <franke@computer.org>
7160
7161 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
7162 mode check. Fix setting of compat_use[].
7163
f36cc108 71642009-01-10 Robert Millan <rmh@aybabtu.com>
7165
7166 Update a few copyright years which we forgot to do in 2008 (only for
7167 files whose changes made in 2008 were copyright-significant)
7168
7169 * Makefile.in: Add 2008 to Copyright line.
7170 * disk/ieee1275/ofdisk.c: Likewise.
7171 * disk/efi/efidisk.c: Likewise.
7172 * kern/dl.c: Likewise.
7173 * kern/sparc64/ieee1275/init.c: Likewise.
7174 * kern/mm.c: Likewise.
7175 * kern/efi/mm.c: Likewise.
7176 * boot/i386/pc/boot.S: Likewise.
7177 * genfslist.sh: Likewise.
7178 * fs/iso9660.c: Likewise.
7179 * fs/hfs.c: Likewise.
7180 * fs/jfs.c: Likewise.
7181 * fs/minix.c: Likewise.
7182 * fs/ufs.c: Likewise.
7183 * gensymlist.sh.in: Likewise.
7184 * genkernsyms.sh.in: Likewise.
7185 * include/grub/misc.h: Likewise.
7186 * include/grub/types.h: Likewise.
7187 * include/grub/symbol.h: Likewise.
7188 * include/grub/elf.h: Likewise.
7189 * include/grub/kernel.h: Likewise.
7190 * include/grub/disk.h: Likewise.
7191 * include/grub/dl.h: Likewise.
7192 * include/grub/i386/linux.h: Likewise.
7193 * include/grub/i386/pc/biosdisk.h: Likewise.
7194 * include/grub/efi/api.h: Likewise.
7195 * include/grub/efi/pe32.h: Likewise.
7196 * include/grub/util/misc.h: Likewise.
7197 * normal/execute.c: Likewise.
7198 * normal/arg.c: Likewise.
7199 * normal/completion.c: Likewise.
7200 * normal/lexer.c: Likewise.
7201 * normal/parser.y: Likewise.
7202 * normal/misc.c: Likewise.
7203 * commands/i386/pc/vbeinfo.c: Likewise.
7204 * commands/hexdump.c: Likewise.
7205 * commands/terminal.c: Likewise.
7206 * commands/ls.c: Likewise.
7207 * commands/help.c: Likewise.
7208 * partmap/pc.c: Likewise.
7209 * loader/efi/chainloader.c: Likewise.
7210 * loader/multiboot_loader.c: Likewise.
7211 * loader/i386/pc/multiboot2.c: Likewise.
7212 * term/efi/console.c: Likewise.
7213 * term/i386/pc/serial.c: Likewise.
7214 * util/lvm.c: Likewise.
7215 * util/console.c: Likewise.
7216 * util/i386/efi/grub-mkimage.c: Likewise.
7217 * util/raid.c: Likewise.
7218
7f02114b 72192009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
7220
7221 * commands/videotest.c: Removed include to grub/machine/memory.h.
7222
7223 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
7224 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
7225 (video_mod_SOURCES): Removed.
7226 (video_mod_CFLAGS): Likewise.
7227 (video_mod_LDFLAGS): Likewise.
7228 (gfxterm_mod_SOURCES): Likewise.
7229 (gfxterm_mod_CFLAGS): Likewise.
7230 (gfxterm_mod_LDFLAGS): Likewise.
7231 (videotest_mod_SOURCES): Likewise.
7232 (videotest_mod_CFLAGS): Likewise.
7233 (videotest_mod_LDFLAGS): Likewise.
7234 (bitmap_mod_SOURCES): Likewise.
7235 (bitmap_mod_CFLAGS): Likewise.
7236 (bitmap_mod_LDFLAGS): Likewise.
7237 (tga_mod_SOURCES): Likewise.
7238 (tga_mod_CFLAGS): Likewise.
7239 (tga_mod_LDFLAGS): Likewise.
7240 (jpeg_mod_SOURCES): Likewise.
7241 (jpeg_mod_CFLAGS): Likewise.
7242 (jpeg_mod_LDFLAGS): Likewise.
7243 (png_mod_SOURCES): Likewise.
7244 (png_mod_CFLAGS): Likewise.
7245 (png_mod_LDFLAGS): Likewise.
7246
7247 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
7248 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
7249 (video_mod_SOURCES): Added.
7250 (video_mod_CFLAGS): Likewise.
7251 (video_mod_LDFLAGS): Likewise.
7252 (videotest_mod_SOURCES): Likewise.
7253 (videotest_mod_CFLAGS): Likewise.
7254 (videotest_mod_LDFLAGS): Likewise.
7255 (bitmap_mod_SOURCES): Likewise.
7256 (bitmap_mod_CFLAGS): Likewise.
7257 (bitmap_mod_LDFLAGS): Likewise.
7258 (tga_mod_SOURCES): Likewise.
7259 (tga_mod_CFLAGS): Likewise.
7260 (tga_mod_LDFLAGS): Likewise.
7261 (jpeg_mod_SOURCES): Likewise.
7262 (jpeg_mod_CFLAGS): Likewise.
7263 (jpeg_mod_LDFLAGS): Likewise.
7264 (png_mod_SOURCES): Likewise.
7265 (png_mod_CFLAGS): Likewise.
7266 (png_mod_LDFLAGS): Likewise.
7267 (gfxterm_mod_SOURCES): Likewise.
7268 (gfxterm_mod_CFLAGS): Likewise.
7795c55e 7269 (gfxterm_mod_LDFLAGS): Likewise.
7f02114b 7270
7271 * term/gfxterm.c: Removed include to grub/machine/memory.h,
7272 grub/machine/console.h.
7273
644fff97 72742009-01-04 Jerone Young <jerone@gmail.com>
7275
7276 Make on screen instructions clearer
7277
7278 Based on patch created by Jidanni <jidanni@jidanni.org>
7279
7280 * normal/menu.c: print clearer instructions on the screen
7281
1e901a75 72822009-01-02 Colin D Bennett <colin@gibibit.com>
7283
7284 New font engine.
34c44600 7285
1e901a75 7286 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
7287 build system and fixed gfxterm.c to work with different sized fonts.
7288
7289 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
34c44600 7290
1e901a75 7291 * configure: Re-generated.
34c44600 7292
1e901a75 7293 * DISTLIST: Removed font/manager.c.
7294 Added font/font.c.
7295 Added font/font_cmd.c.
34c44600 7296
1e901a75 7297 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
7298 compilation.
34c44600 7299
1e901a75 7300 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
34c44600 7301
7302 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
1e901a75 7303
7304 * kern/term.c: Changed users of grub_utf8_to_ucs4.
34c44600 7305
1e901a75 7306 * normal/menu.c: Likewise.
34c44600 7307
1e901a75 7308 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
7309 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
34c44600 7310
1e901a75 7311 * include/grub/font.h: Replaced with new file.
34c44600 7312
1e901a75 7313 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
7314 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
7315 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
7316 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
7317 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
34c44600 7318 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
1e901a75 7319 fg_red, fg_green, fg_blue, fg_alpha.
7320 (grub_video_adapter): Removed blit_glyph.
34c44600 7321 (grub_video_blit_glyph): Removed.
7322
1e901a75 7323 * font/manager.c: Removed file.
34c44600 7324
7325 * font/font.c: New file.
7326
1e901a75 7327 * font/font_cmd.c: Likewise.
34c44600 7328
1e901a75 7329 * video/video.c (grub_video_blit_glyph): Removed.
34c44600 7330
1e901a75 7331 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
7332 (grub_video_vbe_map_rgba): Likewise.
7333 (grub_video_vbe_unmap_color_int): Likewise.
7334 (grub_video_vbe_blit_glyph): Removed.
7335 (grub_video_vbe_adapter): Removed blit_glyph.
34c44600 7336
1e901a75 7337 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
7338 (get_pixel): Likewise.
34c44600 7339 (set_pixel): Likewise.
7340
1e901a75 7341 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
34c44600 7342
1e901a75 7343 * term/gfxterm.c: Adapted to new font engine.
34c44600 7344
1e901a75 7345 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
34c44600 7346
1e901a75 7347 * term/i386/pc/vga.c: Likewise.
34c44600 7348
1e901a75 7349 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
34c44600 7350
1e901a75 7351 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
34c44600 7352
1e901a75 7353 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7354
1e901a75 7355 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7356
1e901a75 7357 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
34c44600 7358
1e901a75 7359 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
34c44600 7360
1e901a75 7361 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
34c44600 7362
1e901a75 7363 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
34c44600 7364
1e901a75 7365 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7366
7367 * util/grub.d/00_header.in: Changed to use new loadfont command.
34c44600 7368
1e901a75 7369 * util/grub-mkconfig_lib.in: Changed font extension.
7370
278922e8 73712008-12-28 Felix Zielcke <fzielcke@z-51.de>
7372
7373 * util/getroot.c (grub_util_get_grub_dev): Add support for
7374 /dev/md/dNNpNN style partitionable mdraid devices.
7375
3ced05cf 73762008-12-12 Alex Smith <alex@alex-smith.me.uk>
7377
7378 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
7379 at a time limit of the PXE TFTP API correctly.
7380 (grub_pxefs_close): Likewise.
7381
7fd0ee30 73822008-11-29 Robert Millan <rmh@aybabtu.com>
7383
34c44600 7384 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
7fd0ee30 7385 grub_ata_device_initialize() calls.
7386
34c44600 73872008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
0c5e79ab 7388
7389 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
7390 iteration failed.
7391 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
7392
89313780 73932008-11-28 Robert Millan <rmh@aybabtu.com>
7394
7395 Fix build on powerpc-ieee1275. Based on patch created by
7396 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
7397 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
7398 `kern/ieee1275/mmap.c'.
7399 * include/grub/powerpc/ieee1275/memory.h: New file.
7400
15257703 7401 Provide grub-install on coreboot.
7402 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
7403 (grub_install_SOURCES): New variable.
7404 * util/i386/pc/grub-install.in: Add a few condition checks to make it
7405 usable on coreboot.
7406
9fc5388a 74072008-11-25 Felix Zielcke <fzielcke@z-51.de>
7408
7409 * util/grub-fstest.c (grub_term_get_current_input): Change return type
7410 to `grub_term_input_t'.
7411 (grub_term_get_current_output): Change return type to
7412 `grub_term_output_t'.
7413
bc3a2f31 74142008-11-22 Robert Millan <rmh@aybabtu.com>
7415
34c44600 7416 Fix breakage on coreboot due to declaration mismatch.
bc3a2f31 7417 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
7418 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
7419 grub_vga_text_cls().
7420
80fc88f2 7421 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
34c44600 7422 comments. Avoid copying one more byte than necessary (just in case).
80fc88f2 7423
cbf36fd3 7424 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
7425 to 0x200000 (avoids trouble with some OFW implementations, and matches
7426 with the one in Yaboot).
7427 Reported by Manoel Abranches
7428
73e8e268 74292008-11-20 Robert Millan <rmh@aybabtu.com>
3cf6ac19 7430
7431 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
7432 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
7433
73e8e268 7434 * util/grub-mkconfig_lib.in (grub_warn): New function.
7435 (convert_system_path_to_grub_path): Use grub_warn() when issuing
7436 warnings, to obtain consistent formatting.
7437 * util/grub.d/00_header.in: Likewise.
7438 * util/update-grub_lib.in: Likewise.
7439
e94045a1 7440 * loader/i386/linux.c (allocate_pages): Fix a warning.
40f9faa4 7441 Move comment text to `#error' stanza.
e94045a1 7442
79d29fd7 7443 Harmonize ieee1275's grub_available_iterate() with the generic
7444 grub_machine_mmap_iterate() interface (fixes a recently-introduced
7445 build problem on i386-ieee1275):
7446 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
7447 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
7448 parameter `type'. Update all users of this function.
7449 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
7450 `kern/ieee1275/mmap.c'.
7451 * kern/ieee1275/init.c
7452 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
7453 with ...
7454 (grub_machine_mmap_iterate): ... this.
7455 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
7456 return type to `grub_err_t'. Update all implementations of this
7457 function prototype.
7458 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
7459 Likewise.
7460
60d6b16e 7461 Add `lsmmap' command (lists firmware-provided memory map):
7462 * commands/lsmmap.c: New file.
7463 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
7464 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
7465 variables.
7466 * conf/powerpc-ieee1275.rmk: Likewise.
7467 * conf/i386-coreboot.rmk: Likewise.
7468 * conf/i386-ieee1275.rmk: Likewise.
7469
ebaaf49b 74702008-11-19 Robert Millan <rmh@aybabtu.com>
7471
7472 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
92907110 7473 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
7474 constraints to initrd allocation (based on code from
7475 loader/i386/pc/linux.c). Without them, initrd was allocated too high
7476 for Linux to find it.
ebaaf49b 7477
dfab719f 74782008-11-14 Robert Millan <rmh@aybabtu.com>
7479
7480 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
7481 order to cope with duplicate slashes.
7482
10fc3eb9 74832008-11-14 Robert Millan <rmh@aybabtu.com>
7484
7485 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
7486 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
7487 don't want to mess with lower memory, because it is used in the Linux
7488 loader.
7489
7490 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
34c44600 7491 an appropriate place in lower memory, between 0x10000 and 0x90000,
10fc3eb9 7492 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
7493 is in our heap (probably as a result of it being corrupted during
2f2a3442 7494 decompression). Add #error instance with comment to explain why this
7495 loader isn't currently usable on PC/BIOS.
10fc3eb9 7496
e2e07847 74972008-11-14 Robert Millan <rmh@aybabtu.com>
7498
7499 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
34c44600 7500 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
e2e07847 7501
fe8e8d69 75022008-11-12 Robert Millan <rmh@aybabtu.com>
7503
7504 Make loader/i386/linux.c buildable on i386-pc (although disabled).
7505
7506 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
7507 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
7508 from here ...
7509 * include/grub/i386/pc/memory.h: ... to here.
7510
976b07d0 75112008-11-12 Robert Millan <rmh@aybabtu.com>
7512
7513 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
7514 split).
7515
7516 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
7517 (grub_console_cur_color, grub_console_real_putchar)
7518 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7519 (grub_console_setcolorstate, grub_console_setcolor)
7520 (grub_console_getcolor): Move from here ...
7521 * include/grub/i386/vga_common.h: ... to here (new file).
7522
7523 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
7524 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
7525 `<grub/i386/io.h>'.
7526 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
7527 `<grub/i386/vga_common.h>'.
7528
76679cd3 75292008-11-12 Robert Millan <rmh@aybabtu.com>
7530
7531 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
7532 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
7533 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
7534 variables.
7535 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7536 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
7537
7538 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
7539 grub_console_init() with call to grub_vga_text_init().
7540 (grub_machine_fini): Replace call to
7541 grub_console_fini() with call to grub_vga_text_fini() and
7542 grub_at_keyboard_fini().
7543
7544 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
7545 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7546 (grub_console_setcolorstate, grub_console_setcolor)
7547 (grub_console_getcolor): New function prototypes.
7548
7549 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
7550 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
7551 (grub_vga_text_setcursor): Static-ize.
7552 (grub_vga_text_term): New structure.
7553 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
7554
7555 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
7556 (grub_console_cur_color, grub_console_standard_color)
7557 (grub_console_normal_color, grub_console_highlight_color)
7558 (map_char, grub_console_putchar, grub_console_getcharwidth)
7559 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
7560 (grub_console_getcolor): Move from here ...
7561 * term/i386/vga_common.c: ... to here (same function names).
7562
95b841d3 75632008-11-12 Robert Millan <rmh@aybabtu.com>
7564
7565 Use newly-added Multiboot support in coreboot.
7566
7567 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7568 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
7569
7570 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
7571 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
7572 (codestart): Store the MBI in `startup_multiboot_info' when we're
7573 being loaded using Multiboot.
7574
7575 * kern/i386/coreboot/init.c (grub_machine_init): Move
7576 grub_at_keyboard_init() call to beginning of function (useful for
7577 debugging). Call grub_machine_mmap_init() before attempting to use
7578 grub_machine_mmap_iterate().
7579 (grub_lower_mem, grub_upper_mem): Move from here ...
7580 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
7581 here (new file).
7582
7583 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
7584 function prototype.
7585
761ca975 75862008-11-12 Robert Millan <rmh@aybabtu.com>
7587
7588 Fix a regression introduced by the at_keyboard.mod split. Because
7589 some terminals are default on some platforms and non-default on
7590 others, the first terminal being registered determines which is
7591 going to be default.
7592
7593 * kern/term.c (grub_term_register_input): If this is the first
7594 terminal being registered, set it as the current one.
7595 (grub_term_register_output): Likewise.
7596
7597 * term/efi/console.c (grub_console_init): Do not call
7598 grub_term_set_current_output() or grub_term_set_current_input().
7599 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
7600 * term/i386/pc/console.c (grub_console_init): Likewise.
7601 (grub_console_fini): Do not call grub_term_set_current_input()
7602 (but leave grub_term_set_current_output() to restore text mode).
7603
6c529df7 76042008-11-10 Robert Millan <rmh@aybabtu.com>
7605
7606 * util/grub.d/00_header.in: Add backward compatibility check for
7607 versions of terminal.mod that don't understand `terminal_input' or
7608 `terminal_output'.
7609
132e4113 76102008-11-09 Robert Millan <rmh@aybabtu.com>
7611
7612 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
7613 `terminal_input' / `terminal_output', not `terminal'.
7614
ac293d50 76152008-11-08 Robert Millan <rmh@aybabtu.com>
7616
7617 * Makefile.in (include_DATA): Fix srcdir=. assumption.
2a9c5940 7618 (DISTCLEANFILES): Add `build_env.mk'.
ac293d50 7619
0025933a 76202008-11-08 Robert Millan <rmh@aybabtu.com>
7621
7622 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
dba3f844 7623 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
0025933a 7624 members. Update all users.
7625 * util/console.c (grub_ncurses_term): Split in ...
7626 (grub_ncurses_term_input): ... this, and ...
7627 (grub_ncurses_term_output): ... this. Update all users.
dcb6fa0a 7628 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
0025933a 7629
37c86336 76302008-11-08 Robert Millan <rmh@aybabtu.com>
7631
7632 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
7633 (PKGDATA): Add $(pkgdata_SRCDIR).
7634 (pkglib_BUILDDIR): New variable.
7635 (pkgdata_SRCDIR): New variable.
7636 (build_env.mk): New target.
7637 (include_DATA): New variable.
7638 (install-local): Install $(include_DATA) files in $(includedir).
7639
b6c15a2d 76402008-11-07 Pavel Roskin <proski@gnu.org>
7641
d99d46f1 7642 * gendistlist.sh: Use C locale for sorting to ensure consistent
7643 output on all systems.
7644
b6c15a2d 7645 * util/grub.d/00_header.in: Remove incorrect space before
7646 "serial".
7647
c32ee8c9 76482008-11-07 Robert Millan <rmh@aybabtu.com>
7649
7650 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
7651 per specification.
7652 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
7653 * loader/multiboot_loader.c (find_multi_boot2_header): New function
7654 (based on find_multi_boot1_header).
7655 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
7656 using find_multi_boot2_header(), and abort if neither Multiboot or
7657 Multiboot headers were found.
7658
651c29b7 76592008-11-07 Robert Millan <rmh@aybabtu.com>
7660
7661 Modularize at_keyboard.mod:
7662
7663 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
7664 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
7665 (at_keyboard_mod_LDFLAGS): New variables.
7666
7667 Actual terminal split:
7668
7669 * include/grub/term.h (struct grub_term): Split in ...
7670 (struct grub_term_input): ... this, and ...
7671 (struct grub_term_output): ... this. Update all users.
7672 (grub_term_set_current): Split in ...
7673 (grub_term_set_current_input): ... this, and ...
7674 (grub_term_set_current_output): ... this.
7675 (grub_term_get_current): Split in ...
7676 (grub_term_get_current_input): ... this, and ...
7677 (grub_term_get_current_output): ... this.
7678 (grub_term_register): Split in ...
7679 (grub_term_register_input): ... this, and ...
7680 (grub_term_register_output): ... this.
7681 (grub_term_unregister): Split in ...
7682 (grub_term_unregister_input): ... this, and ...
7683 (grub_term_unregister_output): ... this.
7684 (grub_term_iterate): Split in ...
7685 (grub_term_iterate_input): ... this, and ...
7686 (grub_term_iterate_output): ... this.
7687
7688 * kern/term.c (grub_term_list): Split in ...
7689 (grub_term_list_input): ... this, and ...
7690 (grub_term_list_output): ... this. Update all users.
7691 (grub_cur_term): Split in ...
7692 (grub_cur_term_input): ... this, and ...
7693 (grub_cur_term_output): ... this. Update all users.
7694 (grub_term_set_current): Split in ...
7695 (grub_term_set_current_input): ... this, and ...
7696 (grub_term_set_current_output): ... this.
7697 (grub_term_get_current): Split in ...
7698 (grub_term_get_current_input): ... this, and ...
7699 (grub_term_get_current_output): ... this.
7700 (grub_term_register): Split in ...
7701 (grub_term_register_input): ... this, and ...
7702 (grub_term_register_output): ... this.
7703 (grub_term_unregister): Split in ...
7704 (grub_term_unregister_input): ... this, and ...
7705 (grub_term_unregister_output): ... this.
7706 (grub_term_iterate): Split in ...
7707 (grub_term_iterate_input): ... this, and ...
7708 (grub_term_iterate_output): ... this.
7709
7710 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
7711 a check for input and one for output (and only attempt to get keys
7712 from user when input works).
7713
7714 * util/grub-probe.c (grub_term_get_current): Split in ...
7715 (grub_term_get_current_input): ... this, and ...
7716 (grub_term_get_current_output): ... this.
7717 * util/grub-fstest.c: Likewise.
7718 * util/i386/pc/grub-setup.c: Likewise.
7719 * util/grub-editenv.c: Likewise.
7720
7721 Portability adjustments:
7722
7723 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
7724 `term/i386/pc/at_keyboard.c'.
7725 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
7726 grub_keyboard_controller_init() (now handled by terminal .init).
7727 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
7728 grub_at_keyboard_init().
7729 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
7730 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
7731 at_keyboard.mod via input terminal interface).
7732 * include/grub/i386/coreboot/console.h: Convert into a stub for
7733 `<grub/i386/pc/console.h>'.
7734
7735 Migrate full terminals to new API:
7736
7737 * term/efi/console.c (grub_console_term): Split into ...
7738 (grub_console_term_input): ... this, and ...
7739 (grub_console_term_output): ... this. Update all users.
7740 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
7741 (grub_ofconsole_init): Split into ...
7742 (grub_ofconsole_init_input): ... this, and ...
7743 (grub_ofconsole_init_output): ... this.
7744 (grub_ofconsole_term): Split into ...
7745 (grub_ofconsole_term_input): ... this, and ...
7746 (grub_ofconsole_term_output): ... this. Update all users.
7747 * term/i386/pc/serial.c (grub_serial_term): Split into ...
7748 (grub_serial_term_input): ... this, and ...
7749 (grub_serial_term_output): ... this. Update all users.
7750 * term/i386/pc/console.c (grub_console_term): Split into ...
7751 (grub_console_term_input): ... this, and ...
7752 (grub_console_term_output): ... this. Update all users.
7753 (grub_console_term_input): Only enable it on PC/BIOS platform.
7754 (grub_console_init): Remove grub_keyboard_controller_init() call.
7755
7756 Migrate input terminals to new API:
7757
7758 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
7759 `i386' and `i386/pc' to enable build on x86_64 (this driver is
7760 i386-specific anyway).
7761 (grub_console_checkkey): Rename to ...
7762 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
7763 users.
7764 (grub_keyboard_controller_orig): New variable.
7765 (grub_console_getkey): Rename to ...
7766 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
7767 users.
7768 (grub_keyboard_controller_init): Static-ize. Save original
7769 controller value so that it can be restored ...
7770 (grub_keyboard_controller_fini): ... here (new function).
7771 (grub_at_keyboard_term): New structure.
7772 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
7773 functions.
7774
7775 Migrate output terminals to new API:
7776
7777 * term/i386/pc/vga.c (grub_vga_term): Change type to
7778 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
7779 members. Update all users.
7780 * term/gfxterm.c (grub_video_term): Change type to
7781 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
7782 members. Update all users.
7783 * include/grub/i386/pc/console.h (grub_console_checkkey)
7784 (grub_console_getkey): Do not export (no longer needed by gfxterm,
7785 etc).
7786
7787 Migrate `terminal' command and userland tools to new API:
7788
7789 * commands/terminal.c (grub_cmd_terminal): Split into ...
7790 (grub_cmd_terminal_input): ... this, and ...
7791 (grub_cmd_terminal_output): ... this.
7792 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
7793 `terminal_input' and `terminal_output'.
7794 * util/grub.d/00_header.in: Adjust `terminal' calls to new
7795 `terminal_input' / `terminal_output' API.
7796 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
7797 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
7798 provided ${GRUB_TERMINAL}, convert it).
7799
96e5d876 78002008-11-04 Robert Millan <rmh@aybabtu.com>
7801
7802 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
7803 for FreeBSD.
7804 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
7805
556f3775 78062008-11-03 Bean <bean123ch@gmail.com>
7807
7808 * kern/elf.c (grub_elf32_load): Revert to previous code.
7809 (grub_elf64_load): Likewise.
7810
7811 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
7812
926b9823 78132008-11-01 Robert Millan <rmh@aybabtu.com>
7814
7815 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
7816 (TARGET_CPPFLAGS): Likewise.
7817 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
7818
1432e958 78192008-11-01 Carles Pina i Estany <carles@pina.cat>
7820
7821 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
7822
dba3f844 78232008-10-29 Guillem Jover <guillem.jover@nokia.com>
de4fa71c 7824
7825 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
7826 addition of objects until the code is not going to be able to fail.
7827
dba3f844 78282008-10-29 Guillem Jover <guillem.jover@nokia.com>
b7279447 7829
7830 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
7831 (add a missing NULL check, and correct them by moving the pointer
7832 operations after the actual check).
7833
7ab28c21 78342008-10-29 Robert Millan <rmh@aybabtu.com>
7835
7836 * util/i386/pc/grub-install.in: Handle empty string as output from
7837 make_system_path_relative_to_its_root().
7838
1b7748eb 78392008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
7840
7841 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
7842 circular metadata worst case scenario. If the metadata is circular
7843 then copy the wrap in place.
7844 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
7845 project lib/format_text/layout.h
7846 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
7847
c9618ab2 78482008-10-03 Felix Zielcke <fzielcke@z-51.de>
7849
7a36edca 7850 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
c9618ab2 7851
bf981c62 78522008-10-03 Felix Zielcke <fzielcke@z-51.de>
7853
7854 * util/update-grub_lib.in: Mention filename in warning message.
7855
6d994591 78562008-09-29 Felix Zielcke <fzielcke@z-51.de>
7857
7858 * NEWS: Update for rename of update-grub to grub-mkconfig.
7859
18ade780 78602008-09-29 Felix Zielcke <fzielcke@z-51.de>
7861
7862 * util/update-grub_lib.in: Copy to ...
7863 * util/grub-mkconfig_lib.in: ... this. Update all users.
7c3ff286 7864 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
18ade780 7865 * util/update-grub.in: Rename to ...
7866 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
7867 option. Add `--output' option to allow users to specify the generated
7868 configuration file. Default to stdout.
7869 (update_grub_dir): Rename to ...
7870 (grub_mkconfig_dir): ... this.
7871 (grub_cfg): Default to an empty string.
7872 * conf/common.rmk (update-grub): Rename to ...
7873 (grub-mkconfig): ... this.
7874 (update-grub_lib): Copy to ...
7875 (grub-mkconfig_lib): ... this.
7876 (update-grub_SCRIPTS): Copy to ...
7877 (grub-mkconfig_SCRIPTS): ... this. Update all users.
7878 (update-grub_DATA): Rename to ...
7879 (grub-mkconfig_DATA): ... this.
7880
556ce6ac 78812008-09-28 Robert Millan <rmh@aybabtu.com>
7882
7883 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
7884 to `modified'. Add the real `created' field.
7885 (grub_iso9660_uuid): Use `modified' rather than `created' for
7886 constructing the UUID.
7887
78882008-09-28 Felix Zielcke <fzielcke@z-51.de>
eb079ba9 7889
7890 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
7891 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
7892
92274e85 78932008-09-28 Bean <bean123ch@gmail.com>
7894
7895 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
7896 Thanks to Christian Franke for finding this bug.
7897
add6f17a 78982008-09-25 Robert Millan <rmh@aybabtu.com>
7899
7900 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
7901 instances of grub_util_get_disk_name() (see previous commit).
7902
d2a367b8 79032008-09-25 Robert Millan <rmh@aybabtu.com>
7904
7905 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
7906 `util/i386/get_disk_name.c'.
7907 * conf/i386-efi.rmk: Likewise.
7908 * conf/x86_64-efi.rmk: Likewise.
7909 * conf/i386-coreboot.rmk: Likewise.
7910 * conf/i386-ieee1275.rmk: Likewise.
7911 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
7912 `util/ieee1275/get_disk_name.c'.
7913 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
7914 * util/ieee1275/get_disk_name.c: Remove file.
7915 * util/i386/get_disk_name.c: Remove file.
7916 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
7917 "hd%d" for device.map entries, rather than using
7918 grub_util_get_disk_name().
7919
81a06771 79202008-09-24 Carles Pina i Estany <carles@pina.cat>
b0c301f7 7921
7922 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
7923 warning.
7924 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
7925
5a004279 79262008-09-24 Carles Pina i Estany <carles@pina.cat>
7927
7928 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
7929 Changed to 0x5100.
7930 (GRUB_TERM_PPAGE): Changed to 0x4900.
7931
397093d3 79322008-09-24 Robert Millan <rmh@aybabtu.com>
7933
7934 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
7935 macros (they were i386-pc specific).
7936 * include/grub/sparc64/ieee1275/console.h: Likewise.
7937 * include/grub/efi/console.h: Likewise.
7938
a91b6c7c 79392008-09-22 Bean <bean123ch@gmail.com>
7940
7941 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
7942 resident and in attribute list.
7943
7944 * include/grub/ntfs.h (BMP_LEN): Removed.
7945
c40fd116 79462008-09-22 Bean <bean123ch@gmail.com>
7947
81a06771 7948 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
c40fd116 7949 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
7950
7951 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
7952 error occurs, as grub_disk_open will call grub_disk_close, which will
7953 call p->close (scsi).
7954
81a06771 79552008-09-21 Felix Zielcke <fzielcke@z-51.de>
eb73121d 7956
7957 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
7958 (AC_PREREQ): Bumped to 2.59.
7959 (AC_TRY_COMPILE): Replace obsolete macro with ...
7960 (AC_COMPILE_IFELSE): ... this.
7961 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
7962 (AC_LINK_IFELSE): ... this.
7963
5dc43410 79642008-09-21 Felix Zielcke <fzielcke@z-51.de>
7965
7966 * autogen.sh: Add a call to `gendistlist.sh'.
7967
9035dce4 79682008-09-19 Christian Franke <franke@computer.org>
7969
7970 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
7971 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
7972 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
7973 Export __enable_execute_stack() to modules.
7974 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
7975 New function.
7976
7fd75377 79772008-09-09 Felix Zielcke <fzielcke@z-51.de>
7978
040030b3 7979 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
7980 Sort the list.
7981
79822008-09-09 Felix Zielcke <fzielcke@z-51.de>
7983
7984 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
7fd75377 7985 #include <grub/util/hostdisk.h>.
7986
89d5ffcf 79872008-09-08 Robert Millan <rmh@aybabtu.com>
7988
7989 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
7990 segments when their filesz is zero (grub_file_read() interprets
81a06771 7991 zero-size as "read until EOF", which results in memory corruption).
89d5ffcf 7992 Use `lowest_segment' rather than 0 for calculating the current
7993 segment load address.
7994
40da438f 79952008-09-08 Robert Millan <rmh@aybabtu.com>
7996
7997 * util/hostdisk.c (open_device): Replace a grub_util_info() call
7998 with grub_dprintf("hostdisk", ...), as it was so verbose that it
7999 clobbered useful information.
8000
ddbf5556 80012008-09-08 Robert Millan <rmh@aybabtu.com>
8002
8003 * include/grub/util/biosdisk.h: Move to ...
8004 * include/grub/util/hostdisk.h: ... here. Update all users.
8005 * util/biosdisk.c: Move to ...
8006 * util/hostdisk.c: ... here. Update all users.
8007
783d0f48 80082008-09-07 Robert Millan <rmh@aybabtu.com>
8009
8010 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
8011 variables.
8012 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
8013 and length can be stored directly in the `mbi->mmap_addr' and
8014 `mbi->mmap_length' struct fields.
8015
548e2ea5 80162008-09-07 Robert Millan <rmh@aybabtu.com>
8017
8018 * conf/i386.rmk: New file. Provides declaration for building
8019 `cpuid.mod'.
8020 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
8021 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
8022 variables.
8023 Include `conf/i386.mk'.
8024 * conf/i386-efi.rmk: Likewise.
8025 * conf/x86_64-efi.rmk: Likewise.
8026 * conf/i386-coreboot.rmk: Likewise.
8027 * conf/i386-ieee1275.rmk: Likewise.
8028
0ea85a37 80292008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
8030
8031 Based on patch created by Colin D Bennett <colin@gibibit.com>.
8032 Adds optimization support for BGR based modes.
8033
8034 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
8035 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8036 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8037 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8038 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8039 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8040 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8041 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8042 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8043 (grub_video_i386_vbeblit_index_index): Likewise.
8044 (grub_video_i386_vbeblit_replace_directN): Added.
8045 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8046 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8047 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8048 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8049 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8050 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
81a06771 8051 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
0ea85a37 8052 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8053 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8054 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8055 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8056 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8057 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
8058
8059 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
8060 (grub_video_i386_vbefill_R8G8B8): Likewise.
8061 (grub_video_i386_vbefill_index): Likewise.
8062 (grub_video_i386_vbefill_direct32): Added.
8063 (grub_video_i386_vbefill_direct24): Likewise.
8064 (grub_video_i386_vbefill_direct16): Likewise.
8065 (grub_video_i386_vbefill_direct8): Likewise.
8066
81a06771 8067 * include/grub/video.h (grub_video_blit_format): Removed
0ea85a37 8068 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
8069 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
8070 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
8071 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
8072 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
81a06771 8073
0ea85a37 8074 * video/video.c (grub_video_get_blit_format): Updated to use new
8075 blit formats. Added handling for 16 bit color modes.
81a06771 8076
8077 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
0ea85a37 8078 fillers.
8079 (common_blitter): Updated to use new blitters.
8080
8081 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
8082 Removed.
8083 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8084 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8085 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8086 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8087 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8088 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8089 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8090 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8091 (grub_video_i386_vbeblit_index_index): Likewise.
8092 (grub_video_i386_vbeblit_replace_directN): Added.
8093 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8094 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8095 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8096 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8097 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8098 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
8099 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
8100 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8101 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8102 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8103 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8104 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8105 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
81a06771 8106
0ea85a37 8107 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
8108 (grub_video_i386_vbefill_R8G8B8): Likewise.
8109 (grub_video_i386_vbefill_index): Likewise.
8110 (grub_video_i386_vbefill_direct32): Added.
8111 (grub_video_i386_vbefill_direct24): Likewise.
8112 (grub_video_i386_vbefill_direct16): Likewise.
8113 (grub_video_i386_vbefill_direct8): Likewise.
81a06771 8114
0ea85a37 8115 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
8116 types.
81a06771 8117
0ea85a37 8118 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
8119 types.
81a06771 8120
0ea85a37 8121 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
8122 blitter types.
81a06771 8123
0ea85a37 8124 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
8125 types.
8126
e8a83df6 81272008-09-06 Felix Zielcke <fzielcke@z-51.de>
8128
8129 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
8130 RAID level 1.
8131
6bcd8ee5 81322008-09-06 Felix Zielcke <fzielcke@z-51.de>
c375ae58 8133
6bcd8ee5 8134 * fs/iso9660.c (grub_iso9660_date): New structure.
8135 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
8136 (grub_iso9660_uuid): New function.
c375ae58 8137
59261157 81382008-09-05 Bean <bean123ch@gmail.com>
8139
8140 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
8141
8142 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
8143 insensitive bit for names in Win32 and Win32 & DOS namespace.
8144
8145 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
8146
8147 * include/grub/types.h (LONG_MAX): Likewise.
8148
58b6645a 81492008-09-04 Felix Zielcke <fzielcke@z-51.de>
8150
4ee55921 8151 * util/getroot.c: Include <config.h>.
8152 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
8153 add support for /dev/md/N devices and handle LVM double dash escaping.
8154
81552008-09-04 Felix Zielcke <fzielcke@z-51.de>
8156
8157 * config.guess: Update to latest version from config git.
8158 * config.sub: Likewise.
58b6645a 8159
9124f65d 81602008-09-03 Robert Millan <rmh@aybabtu.com>
8161
8162 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
8163 `disk->total_sectors'.
8164
81a06771 81652008-09-01 Colin D Bennett <colin@gibibit.com>
a0224a4e 8166
8167 * include/grub/normal.h: Fixed incorrect comment for
8168 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
8169
81a06771 81702008-09-01 Colin D Bennett <colin@gibibit.com>
f0619958 8171
8172 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
8173 values with defines.
8174
8175 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
8176 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
8177 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
8178 (GRUB_VBE_MODEATTR_COLOR): Likewise.
8179 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
8180 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
8181 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
8182 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
8183 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
8184 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
8185 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
8186 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
8187 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
8188 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
8189 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
8190 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
8191 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
8192 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
8193 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
8194
93d5cbf8 81952008-08-31 Robert Millan <rmh@aybabtu.com>
8196
8197 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
8198 declaration.
8199 (grub_multiboot): Fix a few warnings.
8200
21751d50 82012008-08-31 Robert Millan <rmh@aybabtu.com>
8202
8203 * loader/i386/pc/multiboot.c: Update comment not to say that
8204 boot_device support is unimplemented.
8205
e27a75c5 82062008-08-31 Robert Millan <rmh@aybabtu.com>
8207
8208 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
8209 or memory map support are unimplemented.
8210
81a06771 82112008-08-31 Colin D Bennett <colin@gibibit.com>
64d2d53c 8212
8213 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
8214
81a06771 82152008-08-31 Colin D Bennett <colin@gibibit.com>
c08a6c18 8216
8217 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
8218 total video memory in 'vbeinfo' output; show color format details for
8219 each video mode.
8220
7c5d8d95 82212008-08-30 Pavel Roskin <proski@gnu.org>
8222
8223 * util/genmoddep.c: Remove for real this time.
8224 * DISTLIST: Remove util/genmoddep.c.
8225
4cebd25a 82262008-08-30 Robert Millan <rmh@aybabtu.com>
8227
8228 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
8229 as required by Multiboot spec (it was already 4-byte aligned, but
8230 only by chance).
8231
b497a269 82322008-08-29 Pavel Roskin <proski@gnu.org>
8233
e3925185 8234 * kern/powerpc/ieee1275/crt0.S: Rename to ...
8235 * kern/powerpc/ieee1275/startup.S: ... this.
8236 * conf/powerpc-ieee1275.rmk: Adjust for the above.
8237 * DISTLIST: Likewise.
8238
b497a269 8239 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
8240 grub/cpu/kernel.h. Add start label for consistency with other
8241 platforms. Add grub_prefix immediately after start. Add jump
8242 to the code after grub_prefix.
8243 * include/grub/powerpc/kernel.h: Provide valid values for
8244 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
8245
6e5a42fe 82462008-08-29 Bean <bean123ch@gmail.com>
8247
8248 * configure.ac: Change host_os to cygwin for mingw.
8249 (asprintf): New check for function.
8250
8251 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
8252 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
8253
8254 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
81a06771 8255 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
6e5a42fe 8256 sync, sleep and grub_util_get_disk_size for mingw.
8257
8258 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
8259 to get size in mingw.
8260 (open_device): Use flag O_BINARY if it's defined.
8261 (find_root_device): Add dummy code for mingw.
8262
8263 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
8264 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
8265 (get_scsi_disk_name): Return 0 for mingw.
8266
8267 * util/hostfs.c: #include <grub/util/misc.h>.
8268 (grub_hostfs_open): Use "rb" flag to open file, use
8269 grub_util_get_disk_size to get disk size for mingw.
8270
8271 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
8272 (asprintf): New function if HAVE_ASPRINTF is not set.
8273 (sync): New function for mingw.
8274 (sleep): Likewise.
8275 (grub_util_get_disk_size): Likewise.
8276
ab3f2673 82772008-08-28 Pavel Roskin <proski@gnu.org>
8278
8279 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
8280 kern/time.c.
8281
1c282483 82822008-08-28 Robert Millan <rmh@aybabtu.com>
8283
8284 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
8285
678e849c 82862008-08-28 Robert Millan <rmh@aybabtu.com>
8287
8288 Change find_grub_drive() syntax so it doesn't prevent it from
8289 detecting NULL names as errors.
8290
8291 * util/biosdisk.c (find_grub_drive): Move free slot search code
8292 from here ...
8293 (find_free_slot): ... to here.
8294 (read_device_map): Use find_free_slot() to search for free slots.
8295
965c75ca 82962008-08-27 Marco Gerards <marco@gnu.org>
8297
8298 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
8299 (scsi_mod_SOURCES): New variable.
8300 (scsi_mod_CFLAGS): Likewise
8301 (scsi_mod_LDFLAGS): Likewise.
8302
8303 * disk/scsi.c: New file.
8304
8305 * include/grub/scsi.h: Likewise.
8306
8307 * include/grub/scsicmd.h: Likewise.
8308
8309 * disk/ata.c: Include <grub/scsi.h>.
8310 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
8311 instead.
8312 (grub_ata_iterate): Skip ATAPI devices.
8313 (grub_ata_open): Only handle ATAPI devices.
8314 (struct grub_atapi_read): Removed.
8315 (grub_atapi_readsector): Likewise.
8316 (grub_ata_read): No longer handle ATAPI devices.
8317 (grub_ata_write): Likewise.
8318 (grub_atapi_iterate): New function.
8319 (grub_atapi_read): Likewise.
8320 (grub_atapi_write): Likewise.
8321 (grub_atapi_open): Likewise.
8322 (grub_atapi_close): Likewise.
8323 (grub_atapi_dev): New variable.
8324 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
8325 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
8326
8327 * include/grub/disk.h (enum grub_disk_dev_id): Add
8328 `GRUB_DISK_DEVICE_SCSI_ID'.
8329
c07ae501 83302008-08-26 Robert Millan <rmh@aybabtu.com>
8331
8332 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
8333 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
8334 descriptive.
8335
5ed20adc 83362008-08-23 Bean <bean123ch@gmail.com>
8337
8338 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
8339 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8340 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
8341 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
8342 dm_nv.mod.
8343 (raid5rec_mod_SOURCES): New macro.
8344 (raid5rec_mod_CFLAGS): Likewise.
8345 (raid5rec_mod_LDFLAGS): Likewise.
8346 (raid6rec_mod_SOURCES): Likewise.
8347 (raid6rec_mod_CFLAGS): Likewise.
8348 (raid6rec_mod_LDFLAGS): Likewise.
8349 (mdraid_mod_SOURCES): Likewise.
8350 (mdraid_mod_CFLAGS): Likewise.
8351 (mdraid_mod_LDFLAGS): Likewise.
8352 (dm_nv_mod_SOURCES): Likewise.
8353 (dm_nv_mod_CFLAGS): Likewise.
8354 (dm_nv_mod_LDFLAGS): Likewise.
8355
8356 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
8357 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8358 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8359
8360 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
8361 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8362
8363 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8364
8365 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
8366
8367 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8368
8369 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8370
8371 * disk/raid5_recover.c: New file.
8372
8373 * disk/raid6_recover.c: Likewise.
8374
8375 * disk/mdraid_linux.c: Likewise.
8376
8377 * disk/dmraid_nvidia.c: Likewise.
8378
8379 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
8380 ULONG_MAX.
8381
8382 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
8383 calculate the size of raid device.
8384 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
8385 different layout of raid5.
8386 (grub_raid_scan_device): Remove code specific to mdraid.
8387 (grub_raid_list): New variable.
8388 (free_array): New function.
8389 (grub_raid_register): Likewise.
8390 (grub_raid_unregister): Likewise.
8391 (grub_raid_rescan): Likewise.
8392 (GRUB_MOD_INIT): Don't iterate device here.
8393 (GRUB_MOD_FINI): Use free_array to release resource.
8394
8395 * include/grub/raid.h: Remove macro and structure specific to mdraid.
8396 (grub_raid5_recover_func_t): New function variable type.
8397 (grub_raid6_recover_func_t): Likewise.
8398 (grub_raid5_recover_func): New variable.
8399 (grub_raid6_recover_func): Likewise.
8400 (grub_raid_register): New function.
8401 (grub_raid_unregister): Likewise.
8402 (grub_raid_rescan): Likewise.
8403 (grub_raid_block_xor): Likewise.
8404
8405 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
8406 (CMD_CRC): New macro.
8407 (part): Removed.
8408 (read_file): Handle device as well as file.
8409 (cmd_crc): New function.
8410 (fstest): Handle multiple disks.
8411 (options): Remove part, raw and long, add root and diskcount.
8412 (usage): Add crc, remove -p, -r, -l, add -r and -c.
dba3f844 8413 (main): Find the first non option entry and ignore subsequent options,
5ed20adc 8414 add handling for the new options, support multiple disks.
8415
8416 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
8417
29c18915 84182008-08-23 Bean <bean123ch@gmail.com>
8419
8420 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
8421
8422 * genfslist.sh: Ignore kernel.mod.
8423
8424 * genpartmaplist.sh: Likewise.
8425
8415f261 84262008-08-23 Robert Millan <rmh@aybabtu.com>
8427
8428 * util/getroot.c (find_root_device): Skip anything that starts with
8429 a dot, not just directories. This avoids things like /dev/.tmp.md0.
8430
d5a7dc5b 84312008-08-22 Felix Zielcke <fzielcke@z-51.de>
81a06771 8432
d5a7dc5b 8433 * util/update-grub.in (GRUB_GFXMODE): Export variable.
8434 * util/grub.d/00_header.in: Allow the administrator to change default
8435 gfxmode via ${GRUB_GFXMODE}.
8436
380cfbb4 84372008-08-21 Felix Zielcke <fzielcke@z-51.de>
8438
8439 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
8440
c9baafe7 84412008-08-21 Robert Millan <rmh@aybabtu.com>
8442
8443 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
8444 loader.
8445 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
8446 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
8447
e290bef2 84482008-08-20 Carles Pina i Estany <carles@pina.cat>
8449
8450 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
8451 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
8452
f9dbfc96 84532008-08-19 Robert Millan <rmh@aybabtu.com>
8454
8455 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
8456 (struct grub_virtual_screen): Remove `cursor_color'.
8457 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
8458 initialization.
8459 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
8460
dd6bd6ab 84612008-08-18 Robert Millan <rmh@aybabtu.com>
8462
8463 Unify (identical) linux_normal.c files.
8464 * loader/i386/efi/linux_normal.c: Move from here ...
8465 * loader/linux_normal.c: ... to here. Update all users.
8466 * loader/i386/pc/linux_normal.c: Delete. Update all users.
8467 * loader/i386/ieee1275/linux_normal.c: Likewise.
8468
7f42f83e 84692008-08-18 Robert Millan <rmh@aybabtu.com>
8470
8471 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
8472 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
8473 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
8474 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
8475 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
8476 New macros.
8477 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
8478 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
8479 (GRUB_LINUX_CL_END_OFFSET): ... to here.
8480 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
8481 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
8482 (GRUB_EFI_CL_END_OFFSET): Rename to ...
8483 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
8484 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
8485 Initialize `params->video_cursor_x' and `params->video_cursor_y'
8486 portably using grub_getxy().
8487 Replace `-EFI' with `-bzImage' in boot message.
8488
38487ddb 84892008-08-17 Robert Millan <rmh@aybabtu.com>
8490
8491 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
8492
deceb3ec 84932008-08-17 Robert Millan <rmh@aybabtu.com>
8494
8495 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
8496
8497 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
8498 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
8499 (grub_machine_mmap_iterate): New function declaration.
8500 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
8501 structure.
8502 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
8503 macros.
8504
8505 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
8506 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
8507 Move e820 parsing from here ...
8508 * kern/i386/pc/mmap.c: New file.
8509 (grub_machine_mmap_iterate): ... to here.
8510
8511 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
8512 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
8513 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
8514 (grub_available_iterate): Redeclare to return `void', and redeclare
8515 its hook to use grub_uint64_t as addr and size parameters, and rename
8516 to ...
8517 (grub_machine_mmap_iterate): ... this. Update all users.
8518
8519 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
8520 to make it more readable. Rename to ...
8521 (grub_machine_mmap_iterate): ... this.
8522
8523 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
8524 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
8525 (grub_multiboot): Allocate an extra region after the payload, and fill
8526 it with a Multiboot memory map. Adjust a.out loader to calculate size
8527 with the extra space.
8528 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
8529 with the extra space.
8530
f8aa0f43 85312008-08-17 Carles Pina i Estany <carles@pina.cat>
8532
9807deb9 8533 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
f8aa0f43 8534
605f5bb6 85352008-08-17 Felix Zielcke <fzielcke@z-51.de>
8536
8537 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
8538 mdate-sh to the list `find' searches for.
8539 * DISTLIST: Regenerated.
8540
210db6c6 85412008-08-16 Felix Zielcke <fzielcke@z-51.de>
8542
8543 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
8544 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
48cdbfd4 8545 genmoddep.awk, gensymlist.sh.in.
8546 (DISTDIRS): Add bus, docs, hook, lib.
210db6c6 8547 * DISTLIST: Regenerated.
48cdbfd4 8548 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
210db6c6 8549
1082b929 85502008-08-16 Robert Millan <rmh@aybabtu.com>
8551
8552 * disk/raid.c (grub_raid_init): Handle/report errors set by
8553 grub_device_iterate().
8554 * disk/lvm.c (grub_lvm_init): Likewise.
8555
42ce5170 85562008-08-15 Bean <bean123ch@gmail.com>
8557
8558 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8559 and datehook.mod.
8560 (datetime_mod_SOURCES): New macro.
8561 (datetime_mod_CFLAGS): Likewise.
8562 (datetime_mod_LDFLAGS): Likewise.
8563 (date_mod_SOURCES): Likewise.
8564 (date_mod_CFLAGS): Likewise.
8565 (date_mod_LDFLAGS): Likewise.
8566 (datehook_mod_SOURCES): Likewise.
8567 (datehook_mod_CFLAGS): Likewise.
8568 (datehook_mod_LDFLAGS): Likewise.
8569
8570 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8571 and datehook.mod.
8572 (datetime_mod_SOURCES): New macro.
8573 (datetime_mod_CFLAGS): Likewise.
8574 (datetime_mod_LDFLAGS): Likewise.
8575 (date_mod_SOURCES): Likewise.
8576 (date_mod_CFLAGS): Likewise.
8577 (date_mod_LDFLAGS): Likewise.
8578 (datehook_mod_SOURCES): Likewise.
8579 (datehook_mod_CFLAGS): Likewise.
8580 (datehook_mod_LDFLAGS): Likewise.
8581
8582 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8583 and datehook.mod.
8584 (datetime_mod_SOURCES): New macro.
8585 (datetime_mod_CFLAGS): Likewise.
8586 (datetime_mod_LDFLAGS): Likewise.
8587 (date_mod_SOURCES): Likewise.
8588 (date_mod_CFLAGS): Likewise.
8589 (date_mod_LDFLAGS): Likewise.
8590 (datehook_mod_SOURCES): Likewise.
8591 (datehook_mod_CFLAGS): Likewise.
8592 (datehook_mod_LDFLAGS): Likewise.
8593
8594 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8595 and datehook.mod.
8596 (datetime_mod_SOURCES): New macro.
8597 (datetime_mod_CFLAGS): Likewise.
8598 (datetime_mod_LDFLAGS): Likewise.
8599 (date_mod_SOURCES): Likewise.
8600 (date_mod_CFLAGS): Likewise.
8601 (date_mod_LDFLAGS): Likewise.
8602 (datehook_mod_SOURCES): Likewise.
8603 (datehook_mod_CFLAGS): Likewise.
8604 (datehook_mod_LDFLAGS): Likewise.
8605
8606 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8607 and datehook.mod.
8608 (datetime_mod_SOURCES): New macro.
8609 (datetime_mod_CFLAGS): Likewise.
8610 (datetime_mod_LDFLAGS): Likewise.
8611 (date_mod_SOURCES): Likewise.
8612 (date_mod_CFLAGS): Likewise.
8613 (date_mod_LDFLAGS): Likewise.
8614 (datehook_mod_SOURCES): Likewise.
8615 (datehook_mod_CFLAGS): Likewise.
8616 (datehook_mod_LDFLAGS): Likewise.
8617
8618 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
8619
8620 * commands/date.c: New file.
8621
8622 * hook/datehook.c: Likewise.
8623
8624 * include/grub/lib/datetime.h: Likewise.
8625
8626 * include/grub/i386/cmos.h: Likewise.
8627
8628 * lib/datetime.c: Likewise.
8629
8630 * lib/i386/datetime.c: Likewise.
8631
8632 * lib/efi/datetime.c: Likewise.
8633
0e9242da 86342008-08-14 Robert Millan <rmh@aybabtu.com>
8635
8636 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
8637 (grub_mkelfimage_SOURCES): New variable.
8638 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
8639
8640 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
8641 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
8642 * conf/powerpc-ieee1275.rmk: Likewise.
8643 * conf/i386-ieee1275.rmk: Likewise.
8644
8645 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
8646 * kern/i386/coreboot/init.c: Likewise.
8647
8648 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
8649 with `<grub/cpu/kernel.h>'.
8650 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
8651 to ...
8652 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
8653 * kern/i386/coreboot/startup.S: Likewise.
8654
8655 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
8656 (GRUB_MOD_GAP): Remove.
8657 * include/grub/powerpc/kernel.h: New file.
8658 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
8659 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
8660 * include/grub/i386/kernel.h: New file.
8661 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
8662 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
8663 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
8664
8665 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
8666 `grub-mkelfimage'.
8667 Use --directory when invoking grub_mkimage.
8668
8669 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
8670 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
8671 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
8672 and GRUB_KERNEL_CPU_PREFIX.
8673
b86408f8 86742008-08-14 Felix Zielcke <fzielcke@z-51.de>
8675
d5e619ca 8676 * include/grub/err.h (grub_err_printf): New function prototype.
8677 * util/misc.c (grub_err_printf): New function.
8678 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
8679 grub_printf.
8680 * kern/err.c (grub_print_error): Use grub_err_printf.
b86408f8 8681
7161f0e0 86822008-08-13 Robert Millan <rmh@aybabtu.com>
8683
8684 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
8685
a1967522 86862008-08-13 Robert Millan <rmh@aybabtu.com>
8687
8688 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
8689 boot entry.
8690
371458b5 86912008-08-12 Robert Millan <rmh@aybabtu.com>
8692
8693 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
8694 of the relocation code from here ...
8695 (grub_multiboot): ... to here.
8696 (forward_relocator, backward_relocator): Move from here ...
8697 * kern/i386/loader.S (grub_multiboot_forward_relocator)
8698 (grub_multiboot_backward_relocator): ... to here.
8699 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
8700 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
8701 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
8702 (grub_multiboot_forward_relocator_end)
8703 (grub_multiboot_backward_relocator)
8704 (grub_multiboot_backward_relocator_end): New variables.
8705
05f9452b 87062008-08-12 Bean <bean123ch@gmail.com>
8707
8708 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
8709
20024ab0 87102008-08-11 Robert Millan <rmh@aybabtu.com>
8711
8712 * kern/i386/linuxbios/startup.S: Move from here ...
8713 * kern/i386/coreboot/startup.S: ... to here.
8714
8715 * kern/i386/linuxbios/init.c: Move from here ...
8716 * kern/i386/coreboot/init.c: ... to here.
8717
8718 * kern/i386/linuxbios/table.c: Move from here ...
8719 * kern/i386/coreboot/mmap.c: ... to here.
8720
8721 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
8722
e352e9cd 87232008-08-11 Robert Millan <rmh@aybabtu.com>
8724
8725 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
8726 errors. Leave it to the upper layer to handle them.
8727
2d05bc6a 87282008-08-09 Christian Franke <franke@computer.org>
8729
8730 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
8731 * conf/common.rmk: Install `grub-pe2elf' only if requested.
8732 Install `grub.d/10_windows' only on Cygwin.
8733 * configure.ac: Add subst of `target_os'.
8734 Check `target_os' also before setting TARGET_OBJ2ELF.
8735 Add `--enable-grub-pe2elf'.
8736
042bd419 87372008-08-08 Robert Millan <rmh@aybabtu.com>
8738
8739 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
8740 (grub_last_time): Change type to grub_uint64_t.
8741 (grub_disk_open): Migrate code from to using grub_get_time_ms().
8742 (grub_disk_close): Likewise.
8743
8744 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
8745 (run_menu): Migrate code from to using grub_get_time_ms().
8746
8747 * util/misc.c (grub_get_time_ms): New function.
8748
7f280db5 87492008-08-08 Marco Gerards <marco@gnu.org>
8750
8751 * disk/ata.c (grub_ata_regget): Change return type to
8752 `grub_uint8_t'.
8753 (grub_ata_regget2): Likewise.
8754 (grub_ata_wait_status): New function.
8755 (grub_ata_wait_busy): Removed function, updated all users to use
8756 `grub_ata_wait_status'.
8757 (grub_ata_wait_drq): Likewise.
8758 (grub_ata_cmd): New function.
8759 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
8760 error handling.
8761 (grub_ata_pio_write): Add error handling.
8762 (grub_atapi_identify): Likewise.
8763 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
8764 handling.
8765 (grub_ata_identify): Use `grub_ata_cmd' and improve error
8766 handling. Actually use the detected registers. Reorder the
8767 detection logic such that it is easier to read.
8768 (grub_ata_pciinit): Do not assign the same ID to each controller.
8769 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
8770 handling.
8771 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
8772
8773 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
8774
1fbc5e66 87752008-08-08 Marco Gerards <marco@gnu.org>
8776
8777 * NEWS: Update.
8778
819ce6c0 87792008-08-07 Bean <bean123ch@gmail.com>
8780
8781 * include/grub/x86_64/pci.h: New file.
8782
5c41d44d 87832008-08-07 Christian Franke <franke@computer.org>
8784
8785 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
8786 (TIMER2_GATE): Likewise.
8787 (grub_pit_wait): Add enable/disable of the timer2 gate
8788 bit of port 0x61. This fixes a possible infinite loop.
8789
5ebc275d 87902008-08-07 Bean <bean123ch@gmail.com>
8791
8792 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
8793 kern/i386/tsc.c and kern/i386/pit.c.
8794
8795 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
8796 x86_64 platform.
8797
8798 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
8799 <grub/i386/tsc.h>.
8800
8801 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
8802
e383b3d0 88032008-08-07 Bean <bean123ch@gmail.com>
8804
8805 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
8806
8807 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
8808
8809 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
8810 multiple inclusion. Add #include <grub/types.h>.
8811
1cbb58ac 88122008-08-06 Christian Franke <franke@computer.org>
8813
8814 * conf/common.rmk: Build and install `10_windows'.
8815 * util/grub.d/10_windows.in: New script.
8816
337f5a1e 88172008-08-06 Pavel Roskin <proski@gnu.org>
8818
8819 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
8820
057bc4ac 88212008-08-06 Robert Millan <rmh@aybabtu.com>
8822
8823 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
8824 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
8825
2b99f123 88262008-08-06 Bean <bean123ch@gmail.com>
8827
8828 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
8829 (grub_pxefs_fs_int): Remove dummy definition.
8830 (grub_pxefs_open): Use data->block_size to store the current block
8831 size setting.
8832 (grub_pxefs_read): Use block size stored in data->block_size. As the
8833 value of grub_pxe_blksize can be changed after the file is opened.
8834
9f0234cb 88352008-08-06 Bean <bean123ch@gmail.com>
8836
8837 * fs/i386/pc/pxe.c (curr_file): new variable.
8838 (grub_pxefs_open): Simply the handling of pxe file system. Don't
8839 require the dummy internal file system anymore.
8840 (grub_pxefs_read): Removed.
8841 (grub_pxefs_close): Likewise.
8842 (grub_pxefs_fs_int): Likewise.
8843 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
8844 connection when we switch file.
8845 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
8846
a55d42e0 88472008-08-06 Robert Millan <rmh@aybabtu.com>
8848
8849 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
8850 `halt.mod'.
8851 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
8852 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
8853
8854 * kern/i386/halt.c: New file.
8855 * kern/i386/reboot.c: Likewise.
8856 * include/grub/i386/reboot.h: Likewise.
8857 * include/grub/i386/halt.h: Likewise.
8858
8859 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
8860 Include `<grub/cpu/halt.h>'.
8861 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
8862 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
8863
8864 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
8865 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
8866 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
8867 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
8868 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
8869 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
8870 from here ...
8871 * include/grub/i386/at_keyboard.h: ... to here.
8872
24371d26 88732008-08-05 Robert Millan <rmh@aybabtu.com>
8874
8875 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
8876 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
8877 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
8878 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
8879 `kern/generic/millisleep.c'.
8880
8881 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
8882 instead of grub_get_rtc().
8883 (grub_tsc_init): Initialize `tsc_boot_time'.
8884
8885 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
8886 (grub_machine_init): Use grub_tsc_init() rather than
8887 installing an RTC-based handler via grub_install_get_time_ms().
8888
8889 * kern/i386/pit.c: New file.
8890 * include/grub/i386/pit.h: Likewise.
8891
9e7007b3 88922008-08-05 Bean <bean123ch@gmail.com>
8893
8894 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
8895
8896 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
8897 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
8898 (pxe_mod_SOURCES): New macro.
8899 (pxe_mod_CFLAGS): Likewise.
8900 (pxe_mod_LDFLAGS): Likewise.
8901 (pxecmd_mod_SOURCES): Likewise.
8902 (pxecmd_mod_CFLAGS): Likewise.
8903 (pxecmd_mod_LDFLAGS): Likewise.
8904
8905 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
8906 (grub_pxe_call): Likewise.
8907
8908 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
8909
8910 * commands/i386/pc/pxecmd.c: New file.
8911
9f0234cb 8912 * fs/i386/pc/pxe.c: Likewise.
9e7007b3 8913
8914 * include/grub/i386/pc/pxe.h: Likewise.
8915
6977d49f 89162008-08-05 Bean <bean123ch@gmail.com>
8917
8918 * util/console.c (grub_console_cur_color): New variable.
8919 (grub_console_standard_color): Likewise.
8920 (grub_console_normal_color): Likewise.
8921 (grub_console_highlight_color): Likewise.
8922 (color_map): Likewise.
8923 (use_color): Likewise.
8924 (NUM_COLORS): New macro.
8925 (grub_ncurses_setcolorstate): Handle color properly.
8926 (grub_ncurses_setcolor): Don't change color here, just remember the
8927 settings, color will be set in grub_ncurses_setcolorstate.
8928 (grub_ncurses_getcolor): New function.
8929 (grub_ncurses_init): Initialize color pairs.
8930 (grub_ncurses_term): New member grub_ncurses_getcolor.
8931
9c2ff3ee 89322008-08-05 Colin D Bennett <colin@gibibit.com>
337f5a1e 8933
9c2ff3ee 8934 High resolution timer support. Implemented for x86 CPUs using TSC.
8935 Extracted generic grub_millisleep() so it's linked in only as needed.
8936 This requires a Pentium compatible CPU; if the RDTSC instruction is
8937 not supported, then it falls back on the generic grub_get_time_ms()
8938 implementation that uses the machine's RTC.
8939
8940 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
8941 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
8942 `kern/generic/millisleep.c'.
8943
8944 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
8945 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
8946
8947 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
8948 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
8949
8950 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
8951
8952 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
8953 `kern/generic/millisleep.c'.
8954
8955 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
8956
8957 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
8958
8959 * kern/generic/rtc_get_time_ms.c: New file.
8960
8961 * kern/generic/millisleep.c: New file.
337f5a1e 8962
9c2ff3ee 8963 * kern/misc.c: Don't include
8964 <kern/time.h> anymore.
8965 (grub_millisleep_generic): Removed.
8966
8967 * commands/sleep.c (grub_interruptible_millisleep): Uses
8968 grub_get_time_ms() instead of grub_get_rtc().
8969
8970 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
8971 function.
8972 (grub_cpu_is_cpuid_supported): New inline function.
8973 (grub_cpu_is_tsc_supported): New inline function.
8974 (grub_tsc_init): New function prototype.
8975 (grub_tsc_get_time_ms): New function prototype.
8976
8977 * kern/i386/tsc.c (grub_get_time_ms): New file.
8978
8979 * include/grub/time.h: Include <grub/types.h.
8980 (grub_millisleep_generic): Removed.
8981 (grub_get_time_ms): New prototype.
8982 (grub_install_get_time_ms): New prototype.
8983 (grub_rtc_get_time_ms): New prototype.
8984
8985 * kern/time.c (grub_get_time_ms): New function.
8986 (grub_install_get_time_ms): New function.
8987
8988 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
8989 <grub/time.h> anymore.
8990 (grub_millisleep): Removed.
8991 (grub_machine_init): Call grub_tsc_init.
8992
8993 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
8994 get_time_ms() implementation.
8995
8996 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
8997 (ieee1275_get_time_ms): New function.
8998 (grub_machine_init): Install get_time_ms() implementation.
8999
9000 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
9001 (grub_machine_init): Call grub_tsc_init().
9002 (grub_millisleep): Removed.
bf06a93f 9003
9c2ff3ee 9004 * kern/ieee1275/init.c (grub_millisleep): Removed.
9005 (grub_machine_init): Install ieee1275_get_time_ms()
9006 implementation.
9007 (ieee1275_get_time_ms): New function.
9008 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
9009 real work.
9010
9ec92aaf 90112008-08-05 Marco Gerards <marco@gnu.org>
9012
9013 * disk/ata.c: Include <grub/pci.h>.
9014 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
9015 (grub_ata_initialize): Rewritten.
9016 (grub_ata_device_initialize): New function.
9017
8d23f507 90182008-08-04 Pavel Roskin <proski@gnu.org>
9019
9020 * kern/main.c: Include grub/mm.h.
9021
5e15ee3d 90222008-08-04 Robert Millan <rmh@aybabtu.com>
9023
9024 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
9025 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
9026 corruption problem).
9027
a9053f8f 90282008-08-04 Robert Millan <rmh@aybabtu.com>
9029
9030 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
9031 warnings introduced in my last commit.
9032
dd19c7d7 90332008-08-03 Robert Millan <rmh@aybabtu.com>
9034
9035 Make PCI available on all i386 architectures.
9036
9037 * include/grub/i386/pc/pci.h: Move from here ...
9038 * include/grub/i386/pci.h: ... to here.
9039
9040 * include/grub/i386/pc/pci.h: Remove.
9041 * include/grub/i386/efi/pci.h: Remove.
9042 * include/grub/x86_64/efi/pci.h: Remove.
9043
9044 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
9045 `<grub/cpu/pci.h>'.
9046
9047 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
9048 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
9049 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
9050
9051 * conf/i386-ieee1275.rmk: Likewise.
9052
e14a6184 90532008-08-03 Robert Millan <rmh@aybabtu.com>
9054
9055 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
9056 (grub_console_setcursor): Make it possible to set cursor off.
9057
52768e37 90582008-08-03 Robert Millan <rmh@aybabtu.com>
9059
9060 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
9061 of modules instead of assuming which platform provides what.
9062 * util/update-grub.in: Likewise.
9063
2d52f57f 90642008-08-03 Robert Millan <rmh@aybabtu.com>
9065
9066 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
9067 instead of `grub_install_dos_part' to determine whether a drive needs
9068 to be prepended to prefix (`grub_install_dos_part' is not reliable,
825aa57a 9069 because it can be overridden when loading GRUB via Multiboot).
2d52f57f 9070
2a5cd121 90712008-08-02 Robert Millan <rmh@aybabtu.com>
9072
9073 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
9074
93808428 90752008-08-02 Robert Millan <rmh@aybabtu.com>
9076
9077 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
9078 of informational grub_dprintf() calls.
9079
3bd0a12a 90802008-08-02 Robert Millan <rmh@aybabtu.com>
9081
9082 * disk/memdisk.c (memdisk_size): Don't initialize.
9083 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
9084
9085 * include/grub/i386/pc/kernel.h
9086 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
9087 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
9088 (grub_memdisk_image_size, grub_arch_memdisk_addr)
9089 (grub_arch_memdisk_size): Remove.
9090
9091 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
9092 field (was only used to transfer a constant). Add `type' field to
9093 support multiple module types.
9094 (grub_module_iterate): New function.
9095
9096 * kern/device.c (grub_device_open): Do not hide error messages
9097 when grub_disk_open() fails. Use grub_print_error() instead.
9098
9099 * kern/i386/pc/init.c (grub_arch_modules_addr)
9100 (grub_arch_memdisk_size): Remove functions.
9101 (grub_arch_modules_addr): Return the module address in high memory
9102 (now that it isn't copied anymore).
9103
9104 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
9105 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
9106 decompression routine (grub_total_module_size already includes that
9107 now). Don't copy modules back to low memory.
9108
9109 * kern/main.c: Include `<grub/mm.h>'.
9110 (grub_load_modules): Split out (and use) ...
9111 (grub_module_iterate): ... this function, which iterates through
9112 module objects and runs a hook.
9113 Comment out grub_mm_init_region() call, as it would cause non-ELF
9114 modules to be overwritten.
9115
9116 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
9117 the memdisk image in its own region, make it part of the module list.
9118 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
9119 (main): Parse --memdisk|-m option, and pass user-provided path as
9120 parameter to generate_image().
9121 (add_segments): Pass `memdisk_path' down to load_modules().
9122 (load_modules): Embed memdisk image in module section when requested.
9123 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
9124 `header.type' instead of `header.offset'.
9125
9126 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
9127 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
9128 (memdisk_mod_LDFLAGS): New variables.
9129 * conf/i386-coreboot.rmk: Likewise.
9130 * conf/i386-ieee1275.rmk: Likewise.
9131
a927cc73 91322008-08-02 Robert Millan <rmh@aybabtu.com>
9133
9134 * loader/i386/pc/multiboot.c (playground, forward_relocator)
9135 (backward_relocator): New variables. Used to allocate and relocate
9136 the payload, respectively.
9137 (grub_multiboot_load_elf32): Load into heap instead of requested
825aa57a 9138 address, install the appropriate relocator code in each bound of
a927cc73 9139 the payload, and set the entry point such that
9140 grub_multiboot_real_boot() will jump to one of them.
9141
9142 * kern/i386/loader.S (grub_multiboot_payload_size)
9143 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9144 (grub_multiboot_payload_entry_offset): New variables.
9145 (grub_multiboot_real_boot): Set cpu context to what the relocator
9146 expects, and jump to the relocator instead of the payload.
9147
9148 * include/grub/i386/loader.h (grub_multiboot_payload_size)
9149 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9150 (grub_multiboot_payload_entry_offset): Export.
9151
b15d8a0c 91522008-08-01 Bean <bean123ch@gmail.com>
9153
9154 * normal/menu_entry.c (editor_getline): Don't return the original
9155 string as result, as it will be released by lexer once it has done
9156 using it.
9157
cdfb3d22 91582008-08-01 Robert Millan <rmh@aybabtu.com>
9159
9160 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
9161 within menuentries, not before them.
9162 util/grub.d/10_hurd.in: Likewise.
9163
9175e93d 91642008-08-01 Bean <bean123ch@gmail.com>
9165
9166 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
9167 (bufio_mod_SOURCES): New macro.
9168 (bufio_mod_CFLAGS): Likewise.
9169 (bufio_mod_LDFLAGS): Likewise.
9170
9171 * include/grub/bufio.h: New file.
9172
9173 * io/bufio.c: Likewise.
9174
9175 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
9176 (grub_video_reader_png): Use grub_buffile_open to open file.
9177
9178 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
9179 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
9180
9181 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
9182 (grub_video_reader_tga): Use grub_buffile_open to open file.
9183
9184 * font/manager.c: Include <grub/bufio.h>.
9185 (add_font): Use grub_buffile_open to open file.
9186
3d8383e7 91872008-07-31 Robert Millan <rmh@aybabtu.com>
9188
9189 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
9190 ELF segments, use a macro for arbitrarily accessing any of them instead
9191 of preparing a pointer that allows access to one at a time.
9192 (grub_multiboot_load_elf64): Likewise.
9193
16e641b6 91942008-07-31 Bean <bean123ch@gmail.com>
9195
9196 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
9197 GRUB_KERNEL_MACHINE_DATA_END.
9198
59198b72 91992008-07-30 Robert Millan <rmh@aybabtu.com>
9200
9201 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
9202 Increase from 0x50 to 0x60.
9203 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
9204 use UUIDs to identify the root drive for them. If that's not
9205 possible, abort.
9206 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
9207 check, for cross-disk installs.
9208
ae88bca3 92092008-07-30 Robert Millan <rmh@aybabtu.com>
9210
9211 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
9212 is non-empty, use it to set the `prefix' environment variable instead
9213 of the usual approach.
9214 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
9215 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
9216 environment variable instead of dummy make_install_device().
9217
9218 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
9219 (start): Insert a data section, with `grub_prefix' variable.
825aa57a 9220 * kern/i386/linuxbios/startup.S: Likewise.
ae88bca3 9221
9222 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
9223 New variable reference.
9224 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
9225 New macro. Defines offset of `grub_prefix' within startup.S (relative
9226 to `start').
9227 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
9228 section within startup.S (relative to `start').
9229 * include/grub/i386/coreboot/kernel.h: Likewise.
9230
9231 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
9232 Overwrite grub_prefix with its contents, at the beginning of the
9233 first segment.
9234 (main): Understand -p|--prefix.
9235
14f41dd1 92362008-07-30 Robert Millan <rmh@aybabtu.com>
9237
9238 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
9239
4ca049a3 92402008-07-30 Robert Millan <rmh@aybabtu.com>
9241
9242 * term/i386/pc/vga_text.c (grub_console_cls): Use
9243 grub_console_gotoxy() to go back to beginning of the screen.
9244 Found by Patrick Georgi <patrick.georgi@coresystems.de>
9245
2921d337 92462008-07-29 Christian Franke <franke@computer.org>
9247
9248 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
9249 Add conversion of emulated mount points on Cygwin.
9250
b609876d 92512008-07-29 Christian Franke <franke@computer.org>
9252
9253 * util/update-grub.in: Add a check for admin
9254 group on Cygwin.
9255 Remove old `grub.cfg.new' before creation.
9256 Add `-f' to `mv' to handle the different filesystem
9257 semantics of Windows.
9258
e93e4679 92592008-07-29 Bean <bean123ch@gmail.com>
9260
9261 * normal/main.c (get_line): Fix buffer overflow bug.
9262
41694fd0 92632008-07-28 Robert Millan <rmh@aybabtu.com>
9264
9265 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
9266 (struct grub_apple_header): New struct. Describes the layout of
9267 the partmap header.
9268 (apple_partition_map_iterate): Check the header magic as well as the
9269 partition magic (which was already being checked).
9270
cfd0b4e6 92712008-07-28 Pavel Roskin <proski@gnu.org>
9272
9273 * genmk.rb: Add a warning to the beginning of the output that
9274 it's a generated file and should not be edited.
9275
93cce016 92762008-07-28 Robert Millan <rmh@aybabtu.com>
9277
9278 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
9279 with the same number are found, just use issue a warning with
9280 grub_dprintf(), as this error has been reported to be non-fatal.
c298def0 9281
cd1df915 92822008-07-27 Robert Millan <rmh@aybabtu.com>
9283
9284 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
9285 information.
9286
b70a8427 92872008-07-27 Bean <bean123ch@gmail.com>
9288
9289 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
9290 (grub_fat_find_dir): Ignore case when comparing filename.
9291
8f5e379f 92922008-07-27 Bean <bean123ch@gmail.com>
9293
9294 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
9295 smallino, as it's more descriptive, and i8count can be confused with
9296 the other field count.
9297 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
9298 inode type.
9299
a85cd5a0 93002008-07-27 Bean <bean123ch@gmail.com>
9301
9302 * commands/crc.c: New file.
9303
9304 * lib/crc.c: Likewise.
9305
9306 * include/grub/lib/crc.h: Likewise.
9307
9308 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
9309
9310 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
9311 (hexdump): Move this function to ...
9312
9313 * lib/hexdump.c: ... here.
9314
9315 * include/grub/hexdump.h: Renamed to ...
9316
9317 * include/grub/lib/hexdump.h: ... this.
9318
9319 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
9320
9321 * util/grub-editenv.c: Likewise.
9322
9323 * include/envblk.h: Renamed to ...
9324
9325 * include/lib/envblk.h: ... this.
9326
9327 * util/envblk.c: Renamed to ...
9328
9329 * lib/envblk.c: ... this.
9330
9331 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
9332 lib/hexdump.c.
9333 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
9334 (pkglib_MODULES): Add crc.mod.
9335 (hexdump_mod_SOURCES): Add lib/hexdump.c.
9336 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
9337 (crc_mod_SOURCES): New macro.
9338 (crc_mod_CFLAGS): Likewise.
9339 (crc_mod_LDFLAGS): Likewise.
9340
9341 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
9342
9343 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9344
9345 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
9346
9347 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9348
9349 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
9350
c298def0 93512008-07-27 Felix Zielcke <fzielcke@z-51.de>
8749e9e5 9352
9353 * commands/help.c: Include <grub/term.h>.
9354 (TERM_WIDTH): Removed. Updated all users.
9355
cc349fb3 93562008-07-27 Pavel Roskin <proski@gnu.org>
9357
9358 * util/getroot.c (find_root_device): Rephrase a comment to avoid
9359 spurious warnings about a comment within a comment.
9360
9051607e 93612008-07-25 Robert Millan <rmh@aybabtu.com>
9362
9363 * util/getroot.c (find_root_device): Skip devices that match
9364 /dev/dm-[0-9]. This lets the real device be found for any type of
9365 abstraction (LVM, EVMS, RAID..).
9366 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
9367 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
9368 device is found first, find_root_device() will now skip it.
9369
01453bfc 93702008-07-24 Pavel Roskin <proski@gnu.org>
9371
9372 * include/grub/types.h: Use __builtin_bswap32() and
9373 __builtin_bswap64() with gcc 4.3 and newer.
9374
6af9849f 93752008-07-24 Christian Franke <franke@computer.org>
9376
3a0fa256 9377 * util/i386/pc/grub-install.in: If `--debug' is specified,
9378 pass `--verbose' to grub-setup.
9379 Abort script if make_system_path_relative_to_its_root() fails.
9380
7810e747 93812008-07-24 Bean <bean123ch@gmail.com>
9382
9383 * configure.ac: Fixed a bug caused by the previous cygwin patch,
9384 variable `target_platform' should be `platform'.
9385
42290e17 93862008-07-24 Bean <bean123ch@gmail.com>
9387
51cc5193 9388 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
42290e17 9389 (grub_png_init_fixed_block): New function.
9390 (grub_png_decode_image_data): Handle fixed huffman code compression.
9391
2a8a80e4 93922008-07-24 Bean <bean123ch@gmail.com>
9393
9394 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
9395 (grub_pe2elf_SOURCES): New macro.
9396 (CLEANFILES): Add grub-pe2elf.
9397
9398 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
9399 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
9400 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
9401 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
9402 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
9403 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
9404 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
9405 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
9406 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
9407 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
9408 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
9409 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
9410 (GRUB_PE32_DT_FUNCTION): Likewise.
9411 (GRUB_PE32_REL_I386_DIR32): Likewise.
9412 (GRUB_PE32_REL_I386_REL32): Likewise.
9413 (grub_pe32_symbol): New structure.
9414 (grub_pe32_reloc): Likewise.
9415
9416 * util/grub-pe2elf.c: New file.
9417
9418 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
9419 start symbol in non pc platform.
9420
9421 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
9422
9423 The following patches are from Christian Franke.
9424
9425 * include/grub/dl.h: Remove .previous, gas supports this only
9426 for ELF format.
9427
9428 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
9429 Remove .type, gas supports this only for ELF format.
9430
9431 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
9432 nullbytes in symbol table. This fixes an infinite loop if table is
9433 zero filled.
9434
9435 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
9436 TARGET_IMG_LDFLAGS and EXEEXT.
9437
9438 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
9439 TARGET_IMG_LDFLAGS_AC.
9440 (grub_CHECK_STACK_ARG_PROBE): New function.
9441
9442 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
9443
9444 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
9445
9446 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
9447 to set TARGET_IMG_LD* accordingly.
9448 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
9449 Add call to grub_CHECK_STACK_ARG_PROBE.
9450 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
9451
9452 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
9453
9454 * genmk.rb: Add EXEEXT to CLEANFILES.
9455
12ccdb75 94562008-07-23 Robert Millan <rmh@aybabtu.com>
9457
9458 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
9459 define the codes for arrows and lines used for the menu).
9460 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
9461 as well.
9462
9463 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
9464 fonts, because the latter are too slow.
9465
18eeaf04 94662008-07-21 Bean <bean123ch@gmail.com>
9467
9468 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
9469 a20. Run keyboard test last, as it will cause macbook to halt.
9470
b095e2ad 94712008-07-18 Pavel Roskin <proski@gnu.org>
9472
9473 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
9474 load foreign architecture modules correctly anyway. Keep
9475 support for loading host architecture modules, whether we
9476 compile them or not.
9477
737feb35 94782008-07-17 Pavel Roskin <proski@gnu.org>
9479
3f4ce737 9480 * configure.ac: Use -m32 or -m64 regardless of whether we had to
9481 change target_cpu. The compiler default can mismatch target_cpu
9482 in any case.
9483
4ad2d049 9484 * disk/efi/efidisk.c: Fix format warnings on x86_64.
9485 * kern/efi/efi.c: Likewise.
9486
f6130a12 9487 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
9488 target compiler is functional.
9489 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
9490 are set up.
9491
58393a2d 9492 * configure.ac: Default to efi platform for x86_64-apple. Allow
9493 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
9494 adjustments from the rest, only do them if target is not
9495 explicitly given. Merge other adjustments with the final sanity
9496 check. Remove an extraneous check for supported CPU. Be
9497 specific which CPU and which platform is not supported.
9498
737feb35 9499 * configure.ac: Default to pc platform for x86_64.
9500
546f966a 95012008-07-17 Robert Millan <rmh@aybabtu.com>
9502
9503 Partial LinuxBIOS -> Coreboot rename.
9504
9505 * conf/i386-linuxbios.rmk: Renamed to ...
9506 * conf/i386-coreboot.rmk: ... this.
9507 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
9508 * configure.ac: Accept "coreboot" as input platform (but maintain
9509 compatibility with "linuxbios").
9510 * include/grub/i386/linuxbios: Renamed to ...
9511 * include/grub/i386/coreboot: ... this.
9512
20011694 95132008-07-17 Bean <bean123ch@gmail.com>
9514
9515 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
c11f6d16 9516 (appleldr_mod_SOURCE): New variable.
20011694 9517 (appleldr_mod_CFLAGS): Likewise.
9518 (appleldr_mod_LDFLAGS): Likewise.
9519 (pci_mod_SOURCES): Likewise.
9520 (pci_mod_CFLAGS): Likewise.
9521 (pci_mod_LDFLAGS): Likewise.
9522 (lspci_mod_SOURCES): Likewise.
9523 (lspci_mod_CFLAGS): Likewise.
9524 (lspci_mod_LDFLAGS): Likewise.
9525
9526 * conf/x86_64-efi.rmk: New file.
9527
9528 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
9529 macro.
9530 (grub_efidisk_write): Likewise.
9531
9532 * include/efi/api.h (efi_call_0): New macro.
9533 (efi_call_1): Likewise.
9534 (efi_call_2): Likewise.
9535 (efi_call_3): Likewise.
9536 (efi_call_4): Likewise.
9537 (efi_call_5): Likewise.
9538 (efi_call_6): Likewise.
9539
9540 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
9541 grub_rescue_cmd_chainloader.
9542
9543 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
9544 (grub_pe32_optional_header): Change some fields based on i386 or
9545 x86_64 platform.
9546 (GRUB_PE32_PE32_MAGIC): Likewise.
9547
9548 * include/grub/efi/uga_draw.h: New file.
9549
9550 * include/grub/elf.h (STN_ABS): New constant.
9551 (R_X86_64_NONE): Relocation constant for x86_64.
9552 (R_X86_64_64): Likewise.
9553 (R_X86_64_PC32): Likewise.
9554 (R_X86_64_GOT32): Likewise.
9555 (R_X86_64_PLT32): Likewise.
9556 (R_X86_64_COPY): Likewise.
9557 (R_X86_64_GLOB_DAT): Likewise.
9558 (R_X86_64_JUMP_SLOT): Likewise.
9559 (R_X86_64_RELATIVE): Likewise.
9560 (R_X86_64_GOTPCREL): Likewise.
9561 (R_X86_64_32): Likewise.
9562 (R_X86_64_32S): Likewise.
9563 (R_X86_64_16): Likewise.
9564 (R_X86_64_PC16): Likewise.
9565 (R_X86_64_8): Likewise.
9566 (R_X86_64_PC8): Likewise.
9567
9568 * include/grub/i386/efi/pci.h: New file.
9569
9570 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
9571 Change it value based on platform.
9572 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
9573 (GRUB_E820_RAM): Likewise.
9574 (GRUB_E820_RESERVED): Likewise.
9575 (GRUB_E820_ACPI): Likewise.
9576 (GRUB_E820_NVS): Likewise.
9577 (GRUB_E820_EXEC_CODE): Likewise.
9578 (GRUB_E820_MAX_ENTRY): Likewise.
9579 (grub_e820_mmap): New structure.
9580 (linux_kernel_header): Change the efi field according to different
9581 kernel version, also field from linux_kernel_header.
9582
9583 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
9584
9585 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
9586 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
9587 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
9588 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
9589 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
9590 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
9591 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
9592 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
9593 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
9594 (GRUB_PCI_ADDR_IO_MASK): Likewise.
9595
9596 * include/grub/x86_64/efi/kernel.h: New file.
9597
9598 * include/grub/x86_64/efi/loader.h: Likewise.
9599
9600 * include/grub/x86_64/efi/machine.h: Likewise.
9601
9602 * include/grub/x86_64/efi/pci.h: Likewise.
9603
9604 * include/grub/x86_64/efi/time.h: Likewise.
9605
9606 * include/grub/x86_64/linux.h: Likewise.
9607
9608 * include/grub/x86_64/setjmp.h: Likewise.
9609
9610 * include/grub/x86_64/time.h: Likewise.
9611
9612 * include/grub/x86_64/types.h: Likewise.
9613
9614 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
9615 GRUB_TARGET_SIZEOF_VOID_P.
9616
9617 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
9618 (grub_efi_locate_handle): Likewise.
9619 (grub_efi_open_protocol): Likewise.
9620 (grub_efi_set_text_mode): Likewise.
9621 (grub_efi_stall): Likewise.
9622 (grub_exit): Likewise.
9623 (grub_reboot): Likewise.
9624 (grub_halt): Likewise.
9625 (grub_efi_exit_boot_services): Likewise.
9626 (grub_get_rtc): Likewise.
9627
9628 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
9629 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
9630 (grub_efi_allocate_pages): Wrap efi calls.
9631 (grub_efi_free_pages): Wrap efi calls.
9632 (grub_efi_get_memory_map): Wrap efi calls.
9633
9634 * kern/x86_64/dl.c: New file.
9635
9636 * kern/x86_64/efi/callwrap.S: Likewise.
9637
9638 * kern/x86_64/efi/startup.S: Likewise.
9639
9640 * loader/efi/appleloader.c: Likewise.
9641
9642 * loader/efi/chainloader.c (cmdline): New variable.
9643 (grub_chainloader_unload): Wrap efi calls.
9644 (grub_chainloader_boot): Likewise.
9645 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
9646 command line.
9647
9648 * loader/efi/chainloader_normal.c (chainloader_command):
9649 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
9650 command line.
9651
9652 * loader/i386/efi/linux.c (allocate_pages): Change allocation
9653 method.
9654 (grub_e820_add_region): New function.
9655 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
9656 booting.
9657 (grub_find_video_card): New function.
9658 (grub_linux_setup_video): New function.
9659 (grub_rescue_cmd_linux): Probe for video information.
9660
9661 * normal/x86_64/setjmp.S: New file.
9662
9663 * term/efi/console.c (map_char): New function.
9664 (grub_console_putchar): Map unicode char.
9665 (grub_console_checkkey): Wrap efi calls.
9666 (grub_console_getkey): Likewise.
9667 (grub_console_getwh): Likewise.
9668 (grub_console_gotoxy): Likewise.
9669 (grub_console_cls): Likewise.
9670 (grub_console_setcolorstate): Likewise.
9671 (grub_console_setcursor): Likewise.
9672
9673 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
9674
59652a20 96752008-07-16 Pavel Roskin <proski@gnu.org>
9676
ef294055 9677 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
9678 format strings.
9679
59652a20 9680 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
9681 pointer, not an integer. This fixes a warning and prevents
9682 precision loss on 64-bit systems.
9683 (relocate_addresses): Remove unneeded cast.
9684
afc3b5d7 96852008-07-15 Pavel Roskin <proski@gnu.org>
9686
506b2b3e 9687 * kern/i386/ieee1275/init.c: Include grub/cache.h.
9688
62ead89c 9689 * term/ieee1275/ofconsole.c: Disable code unused on i386.
9690
c4cd51d7 9691 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
9692 Fix comparison between signed and unsigned.
9693
0d3d8f28 9694 * include/grub/i386/ieee1275/console.h: Declare
9695 grub_console_init() and grub_console_fini().
9696
8804b286 9697 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
9698 It's empty and unused.
9699
ee01cf35 9700 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
9701 beginning to avoid warnings with some compilers.
9702
afc3b5d7 9703 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
9704 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
9705
e4e8eaa5 97062008-07-14 Pavel Roskin <proski@gnu.org>
9707
407aceb4 9708 * kern/env.c (grub_register_variable_hook): Don't copy empty
9709 string, it leaks memory. Pass "" to grub_env_set(), it should
9710 handle constant strings.
9711
e4e8eaa5 9712 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
9713 * commands/cmp.c (grub_cmd_cmp): Likewise.
9714 * kern/dl.c (grub_dl_flush_cache): Likewise.
9715 (grub_dl_load_core): Likewise.
9716 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
9717 (grub_elf64_load_phdrs): Likewise.
9718
d4e2dad3 97192008-07-13 Pavel Roskin <proski@gnu.org>
9720
9721 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
9722 between signed and unsigned.
9723 (LzmaEnc_Finish): Fix warning about an unused parameter.
9724
aa24b516 97252008-07-13 Bean <bean123ch@gmail.com>
9726
9727 * Makefile.in (enable_lzo): New rule.
9728
9729 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
9730
9731 * configure.ac (ENABLE_LZO): New option --enable-lzo.
9732
9733 * boot/i386/pc/lnxboot.S: #include <config.h>.
9734
9735 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
fe987087 9736 its value according to the compression algorithm used, lzo or lzma.
aa24b516 9737
9738 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
9739 compression algorithm according to configure macro.
9740
9741 * kern/i386/pc/startup.S (codestart): Likewise.
9742
9743 * kern/i386/pc/lzma_decode.S: New file.
9744
9745 * include/grub/lib/LzFind.h: Likewise.
9746
9747 * include/grub/lib/LzHash.h: Likewise.
9748
9749 * include/grub/lib/LzmaDec.h: Likewise.
9750
9751 * include/grub/lib/LzmaEnc.h: Likewise.
9752
9753 * include/grub/lib/LzmaTypes.h: Likewise.
9754
9755 * lib/LzFind.c: Likewise.
9756
9757 * lib/LzmaDec.c: Likewise.
9758
9759 * lib/LzmaEnc.c: Likewise.
9760
4ae821ac 97612008-07-13 Bean <bean123ch@gmail.com>
9762
9763 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
9764 (grub_ext4_extent_header): New structure.
9765 (grub_ext4_extent): Likewise.
9766 (grub_ext4_extent_idx): Likewise.
9767 (grub_ext4_find_leaf): New function.
9768 (grub_ext2_read_block): Handle extents.
9769
9a745147 97702008-07-12 Robert Millan <rmh@aybabtu.com>
9771
9772 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
9773
d49a4cf6 97742008-07-11 Robert Millan <rmh@aybabtu.com>
9775
9776 * util/grub.d/40_custom.in: New file. Example on how to add custom
9777 entries to /etc/grub.d.
9778 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
9779 40_custom (implicitly, by merging all the grub.d rules).
9780
947414b4 97812008-07-11 Pavel Roskin <proski@gnu.org>
9782
0059cf6f 9783 * commands/read.c (grub_getline): Fix invalid memory access.
9784 Don't add newline to the variable value.
9785
947414b4 9786 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
9787 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
9788 (serial_hw_get_port): Check validity of the port number.
9789 (grub_cmd_serial): Check return value of serial_hw_get_port().
9790
62a02d00 97912008-07-07 Pavel Roskin <proski@gnu.org>
9792
9793 * boot/i386/pc/diskboot.S (notification_string): Replace
9794 "Loading kernel" with just "loading". This is shorter, less
9795 confusing and saves a few bytes for possible future changes.
9796
3e5581b0 97972008-07-05 Pavel Roskin <proski@gnu.org>
9798
ea387a48 9799 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
9800 size for ATAPI devices, they are undefined. Output sector
9801 number in decimal form.
9802
3e5581b0 9803 * disk/ata.c: Use named constants for status bits.
9804
fdecb8fd 98052008-07-04 Pavel Roskin <proski@gnu.org>
9806
bcd35b90 9807 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
9808 grub_addr_t before casting it to the void pointer to fix a
9809 warning. Non-addressable regions are discarded earlier.
9810 (grub_arch_modules_addr): Cast _end to grub_addr_t.
9811 * kern/i386/linuxbios/table.c: Include grub/misc.h.
9812 (check_signature): Don't shadow table_header.
9813 (grub_linuxbios_table_iterate): Cast numeric constants to
9814 grub_linuxbios_table_header_t.
9815 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
9816 grub_stop().
9817
af58ab3d 9818 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
9819 prevent warnings.
9820
1759aa57 9821 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
9822 pointer, which can cause warnings. Support 64-bit addresses.
9823
fdecb8fd 9824 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
9825 of sizeof(long). This fixes PowerPC image generation on x86_64.
9826
8516d2a8 98272008-07-04 Robert Millan <rmh@aybabtu.com>
9828
9829 This fixes a performance issue when pc & gpt partmap iterators
9830 didn't abort iteration even after our hook found what it was
fe987087 9831 looking for (often causing expensive probes of non-existent drives).
8516d2a8 9832
9833 Some callers relied on previous buggy behaviour, since they would
34c44600 9834 raise an error when their own hooks caused early abortion of its
8516d2a8 9835 iteration.
9836
9837 * kern/device.c (grub_device_open): Improve error message.
9838 * disk/lvm.c (grub_lvm_open): Likewise.
9839 * disk/raid.c (grub_raid_open): Likewise.
9840
9841 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
9842 when hook requests it, independently of grub_errno.
9843 (pc_partition_map_probe): Do not fail when find_func() caused
9844 early abortion of pc_partition_map_iterate().
9845
9846 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
9847 when hook requests it, independently of grub_errno.
9848 (gpt_partition_map_probe): Do not fail when find_func() caused
9849 early abortion of gpt_partition_map_iterate().
9850
9851 * kern/partition.c (grub_partition_iterate): Abort parent iteration
9852 when hook requests it, independently of grub_errno. Do not fail when
9853 part_map_iterate_hook() caused early abortion of p->iterate().
9854
9855 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
9856 when grub_partition_iterate() returned with non-zero.
9857
277d0de9 98582008-07-03 Pavel Roskin <proski@gnu.org>
9859
9860 * disk/ata.c (grub_ata_pio_write): Check status before writing,
9861 like we do in grub_ata_pio_read().
9862 (grub_ata_readwrite): Always write individual sectors. Fix the
9863 sector count for the remainder.
9864 (grub_ata_write): Enable writing to ATA devices. Correctly
9865 report error for ATAPI devices.
9866
d4c9b428 98672008-07-02 Pavel Roskin <proski@gnu.org>
9868
e43fc690 9869 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
9870 warning.
9871
f707af42 9872 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
9873 for every read sector, we already increment it for the whole
9874 batch. This fixes reading more than 256 sectors at once.
9875
11e16b15 9876 * util/grub-editenv.c (cmd_info): Cast argument to long
9877 explicitly. ptrdiff_t reduces to int on i386.
9878
cbabfdd4 9879 * util/grub-editenv.c (main): Be specific which parameter is
9880 missing.
9881
b8fbce0a 9882 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
9883 (memdisk): Make memdisk_orig_addr a pointer.
9884
c9c8e606 9885 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
9886 for file offsets, use grub_off_t instead. Fix printf format
9887 warnings.
9888
ca62e598 9889 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
9890 there. Real unexpected warnings should not drown in the noise
9891 about known problems.
9892
ce8d1766 9893 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
9894 grub_disk_addr_t for memory addresses.
9895
00c7a56a 9896 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
9897 explicitly to fix a warning.
9898
08d3ef09 9899 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
9900
cb71ba20 9901 * Makefile.in (MODULE_LDFLAGS): New variable.
9902 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
9903 the linker accepts --build-id=none.
9904 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
9905 MODULE_LDFLAGS.
9906 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
9907
d4c9b428 9908 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
9909 those in Linux XFS code. Provide a way to access 64-bit parent
9910 inode.
9911 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
9912 the end of struct grub_xfs_dir_header.
9913
d4156eee 99142008-07-02 Bean <bean123ch@gmail.com>
9915
9916 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
9917 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
9918 and GRUB_IEEE1275_FLAG_NO_ANSI.
9919
9920 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
9921 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
9922 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
9923
9924 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
9925 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
9926
9927 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
9928 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
9929
9930 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
9931 esc sequence on non ANSI terminal.
9932 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
9933
9934 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
9935 beginning of file.
9936
2270f77b 99372008-07-02 Bean <bean123ch@gmail.com>
9938
9939 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
9940 (grub_editenv_SOURCES): New variable.
9941 (pkglib_MODULES): Add loadenv.mod.
9942 (loadenv_mod_SOURCES): New variable.
9943 (loadenv_mod_CFLAGS): Likewise.
9944 (loadenv_mod_LDFLAGS): Likewise.
9945
9946 * include/grub/envblk.h: New file.
9947
9948 * util/envblk.c: New file.
9949
9950 * util/grub-editenv.c: New file.
9951
9952 * commands/loadenv.c: New file.
9953
0e9e51ec 99542008-07-01 Pavel Roskin <proski@gnu.org>
9955
d89b7634 9956 * include/multiboot2.h (struct multiboot_tag_module): Use char,
9957 not unsigned char. This fixes warnings and is consistent with
9958 other tags.
9959
bf1835b1 9960 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
9961
8222a04b 9962 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
9963
6a42d99d 9964 * term/tparm.c (analyze): Always set *popcount.
9965
10b159d1 9966 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
9967 cast to fix a warning.
9968
b8789f6c 9969 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
9970 cast to suppress a warning.
9971
29d7e38a 9972 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
9973 grub_fshelp_read_file() expects.
9974
f341f669 9975 * fs/fat.c: Fix UUID calculation on big-endian systems. We
9976 write uuid as a 32-bit value in CPU byte order, so declare and
9977 use it as such.
9978
0e9e51ec 9979 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
9980 long if the format specifier expects it.
9981 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
9982 * partmap/pc.c (pc_partition_map_iterate): Likewise.
9983 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
9984 long to fix a warning.
9985 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
9986 grub_dprintf() arguments to fix warnings.
9987
3aefa857 99882008-06-30 Pavel Roskin <proski@gnu.org>
9989
56c7668b 9990 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
9991 install_bsd_part immediately before core.img is embedded or
9992 modified on disk. This fixes core.img verification if core.img
9993 cannot be embedded.
9994
3aefa857 9995 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
9996 core_path to calculate the blocklist.
9997 Patch from Javier Martín <lordhabbit@gmail.com>
9998
5444088d 99992008-06-29 Robert Millan <rmh@aybabtu.com>
10000
10001 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
10002 block to disk block.
10003 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
10004 Patch from Niels Böhm <bitbucket@arcor.de>
10005
674835c8 100062008-06-29 Robert Millan <rmh@aybabtu.com>
10007
10008 * util/update-grub_lib.in (font_path): Search for fonts in
10009 /boot/grub first, which is more likely to be readable (we aren't
10010 deciding where fonts live, just looking for them).
10011
f527dbc8 100122008-06-26 Pavel Roskin <proski@gnu.org>
10013
6c2d8df6 10014 * util/biosdisk.c (read_device_map): Don't leave dead map
10015 entries for devices failing stat() check.
10016
f527dbc8 10017 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
10018 core_path_dev for the core.img path on the target device.
10019
aebe3d13 100202008-06-26 Robert Millan <rmh@aybabtu.com>
10021
10022 * disk/fs_uuid.c: New file.
10023 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
10024 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
10025 (fs_uuid_mod_LDFLAGS): New variables.
10026 * include/grub/disk.h (grub_disk_dev_id): Add
10027 `GRUB_DISK_DEVICE_UUID_ID'.
10028 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
10029 implement iterate().
10030
37aaf354 100312008-06-26 Robert Millan <rmh@aybabtu.com>
10032
10033 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
10034 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
10035 Linux image includes no initrd.
10036
25ff262a 100372008-06-21 Javier Martín <lordhabbit@gmail.com>
10038
10039 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
10040 call to resolve the core image location that effectively appended the
10041 name twice.
10042
76a2bd44 100432008-06-21 Robert Millan <rmh@aybabtu.com>
10044
10045 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
10046 call from here ...
10047
10048 * util/grub.d/10_hurd.in: ... to here ...
10049 * util/grub.d/10_linux.in: ... and here.
10050
650e1c79 100512008-06-19 Robert Millan <rmh@aybabtu.com>
10052
fe987087 10053 * kern/main.c (grub_main): Export `prefix' variable immediately
650e1c79 10054 after it has been set by grub_machine_set_prefix().
10055
6ce63911 100562008-06-19 Robert Millan <rmh@aybabtu.com>
10057
10058 * commands/search.c (search_label, search_fs_uuid, search_file): Print
10059 search result when not saving to variable, not the other way around.
10060 When saving to variable, abort iteration as soon as a match is found.
10061
73940cec 100622008-06-19 Robert Millan <rmh@aybabtu.com>
10063
10064 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
10065 check for partition that provides /boot/grub. Its logic is flawed,
10066 as it prevents prepare_grub_to_access_device() from being called
10067 multiple times.
10068
3c62a39d 100692008-06-19 Robert Millan <rmh@aybabtu.com>
10070
10071 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
10072 "insmod" command directly when abstraction modules are needed,
fe987087 10073 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
3c62a39d 10074 since it had already been processed).
10075
47395a42 100762008-06-19 Pavel Roskin <proski@gnu.org>
10077
10078 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
10079 changed. This is needed in case GRUB_LIBDIR changes.
10080 * conf/i386-ieee1275.rmk: Likewise.
10081 * conf/i386-linuxbios.rmk: Likewise.
10082 * conf/i386-pc.rmk: Likewise.
10083 * conf/powerpc-ieee1275.rmk: Likewise.
10084
a145ac2d 100852008-06-18 Pavel Roskin <proski@gnu.org>
10086
10087 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
10088 kernel_elf_symlist.c to symlist.c for consistency with other
10089 architectures. Update all users.
10090 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
10091
7847c51e 100922008-06-18 Robert Millan <rmh@aybabtu.com>
10093
10094 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
10095 it in prefix.
10096
10097 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
10098 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
10099 a RAID device, run setup() for all members independently on whether
10100 LVM abstraction is being used.
10101 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
10102 If grub-mkimage has set `*install_dos_part == -2', don't override this
10103 value.
10104 Perform *install_dos_part adjustments independently on whether
10105 we're embedding or not.
10106 Clarify error message when image is too big for embedding.
10107 Remove duplicate *install_dos_part stanza.
10108
b23e5644 101092008-06-17 Robert Millan <rmh@aybabtu.com>
10110
10111 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
10112 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
10113 variables.
10114 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
10115 values in grub_ofconsole_normal_color and
10116 grub_ofconsole_highlight_color (they're not directly related to
10117 background and foreground).
10118 (grub_ofconsole_setcolorstate): Extract background and foreground
10119 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
10120
0aac2f79 101212008-06-17 Robert Millan <rmh@aybabtu.com>
10122
10123 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
10124 /boot/grub for the check in last commit, not /boot (they could be
10125 different partitions).
10126
3cca7ef3 101272008-06-16 Robert Millan <rmh@aybabtu.com>
10128
10129 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
10130 asked to setup access for the same partition that provides /boot,
10131 don't bother using UUIDs since our root already has the value we
10132 want.
10133
347396d8 101342008-06-16 Robert Millan <rmh@aybabtu.com>
10135
10136 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
10137 I2O devices.
10138 Patch from Sven Mueller <sven@debian.org>.
10139
991477f8 101402008-06-16 Robert Millan <rmh@aybabtu.com>
10141
10142 * util/update-grub.in: Check for $EUID instead of $UID.
10143 Reported by Vincent Zweije.
10144
d31a32a1 101452008-06-16 Bean <bean123ch@gmail.com>
10146
fe987087 10147 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
d31a32a1 10148 (grub_ext2_read_block): Likewise.
10149 (grub_ext2_read_inode): Likewise.
10150 (grub_ext2_mount): Likewise.
10151 (grub_ext2_close): Likewise.
10152 (grub_ext3_get_journal): Removed.
10153
fe987087 10154 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
d31a32a1 10155 (grub_reiserfs_read_symlink): Likewise.
10156 (grub_reiserfs_mount): Likewise.
10157 (grub_reiserfs_open): Likewise.
10158 (grub_reiserfs_read): Likewise.
10159 (grub_reiserfs_close): Likewise.
10160 (grub_reiserfs_get_journal): Removed.
10161
10162 * fs/fshelp.c (grub_fshelp_read): Removed.
10163 (grub_fshelp_map_block): Likewise.
10164
10165 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
10166 (grub_fshelp_journal): Likewise.
10167 (grub_fshelp_read): Likewise.
10168 (grub_fshelp_map_block): Likewise.
10169
3540a760 101702008-06-16 Pavel Roskin <proski@gnu.org>
10171
10172 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
10173 floating point anymore.
10174 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
10175
95614c84 101762008-06-15 Pavel Roskin <proski@gnu.org>
10177
10178 * commands/ls.c (grub_ls_list_files): Use integer calculations
10179 for human readable format, avoid floating point use.
10180 * kern/misc.c (grub_ftoa): Remove.
10181 (grub_vsprintf): Remove floating point support.
10182
50465dd6 101832008-06-15 Robert Millan <rmh@aybabtu.com>
10184
fe6b695a 10185 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
50465dd6 10186 devices.
10187 Reported by Max Vozeler.
10188
a9207284 101892008-06-15 Robert Millan <rmh@aybabtu.com>
10190
10191 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
10192 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
10193 skipped later.
10194 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
10195 the beginning of the prefix.
10196
10197 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
10198 It is assumed that if we have a memdisk, grub-mkimage has set
10199 grub_prefix to include the "(memdisk)" drive in it.
10200
a7cbd45a 102012008-06-15 Robert Millan <rmh@aybabtu.com>
10202
10203 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
10204 Initialize keyboard controller after registering the terminal, so that
10205 grub_printf() can be called from grub_keyboard_controller_init().
10206
21cf716a 102072008-06-15 Robert Millan <rmh@aybabtu.com>
10208
10209 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
10210 extent-btree which is written as big endian on disk.
10211 Reported by Alain Greppin <al@chilibi.org>.
10212
23a64d8e 102132008-06-14 Robert Millan <rmh@aybabtu.com>
10214
10215 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
10216 * util/i386/pc/grub-install.in (modules): Likewise.
10217
d687651c 102182008-06-13 Pavel Roskin <proski@gnu.org>
10219
10220 * commands/ls.c (grub_ls_list_files): Fix format warnings.
10221
dfe9ddd4 102222008-06-13 Bean <bean123ch@gmail.com>
10223
10224 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
10225
10226 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
10227
10228 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
10229 to indicate sparse block.
10230
16ae7781 102312008-06-12 Pavel Roskin <proski@gnu.org>
10232
e6d1a308 10233 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
10234 number, grub_fshelp_read() does it for us.
10235
16ae7781 10236 * fs/fshelp.c (grub_fshelp_read): New function. Implement
10237 linear disk read with journal translation.
10238 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
10239 * include/grub/fshelp.h: Declare grub_fshelp_read().
10240
40fd3a2b 102412008-06-09 Pavel Roskin <proski@gnu.org>
10242
10243 * fs/minix.c (grub_minix_mount): Handle error reading
10244 superblock.
10245
f5679726 102462008-06-08 Robert Millan <rmh@aybabtu.com>
10247
10248 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
10249 don't append the RAID prefix afterwards.
10250 Reported by Clint Adams.
10251
ce525529 102522008-06-08 Robert Millan <rmh@aybabtu.com>
10253
10254 Based on description from Pavel:
10255 * kern/disk.c (grub_disk_check_range): Rename to ...
10256 (grub_disk_adjust_range): ... this. Add a comment explaining the
10257 tasks performed by this function.
10258
ad4936a0 102592008-06-08 Robert Millan <rmh@aybabtu.com>
10260
10261 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
10262 `num_serial' (for consistency with other variables).
10263 (struct grub_ntfs_data): Add `uuid' member.
10264 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
10265 (grub_ntfs_uuid): New function.
10266 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
10267
dc20b0f9 102682008-06-07 Pavel Roskin <proski@gnu.org>
10269
10270 * util/biosdisk.c (open_device): Revert last change to the
10271 function, it broke installation. The sector needs to be
10272 different dependent on which device is opened.
10273
c5e3cfba 102742008-06-06 Robert Millan <rmh@aybabtu.com>
10275
10276 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
10277 rest of GRUB, and breakage doesn't happen if its value were modified.
10278
10279 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
10280 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
10281 a constant (same value).
10282 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
10283 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
10284
26a1f8c4 102852008-06-06 Robert Millan <rmh@aybabtu.com>
10286
10287 * util/biosdisk.c (open_device): Do not modify sector offset when
10288 accessing a partition. kern/disk.c already handles this for us.
10289
25d6b327 102902008-06-06 Robert Millan <rmh@aybabtu.com>
10291
10292 * util/grub-emu.c (grub_machine_init): Move code in this function from
10293 here ...
10294 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
10295 segfault in case grub_printf() is called).
10296
10297 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
10298 grub_probe. Update all users not to explicitly add it again.
10299 (grub_device): New variable; contains corresponding device for grubdir.
10300 (fs_module, partmap_module, devabstraction_module): Pass
10301 `--device ${grub_device}' to grub_probe to avoid traversing /dev
10302 every time.
10303
9ece62fb 103042008-06-05 Robert Millan <rmh@aybabtu.com>
10305
10306 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
10307 is found, print it (same layout as with labels).
10308
1ad36d37 103092008-06-04 Robert Millan <rmh@aybabtu.com>
10310
10311 * util/biosdisk.c (get_drive): Rename to ...
10312 (find_grub_drive): ... this. Update all users.
10313
10314 (get_os_disk): Rename to ...
10315 (convert_system_partition_to_system_disk): ... this. Update all users.
10316
10317 (find_drive): Rename to ...
10318 (find_system_device): ... this. Update all users.
10319
e6a30859 103202008-06-04 Robert Millan <rmh@aybabtu.com>
10321
10322 * util/biosdisk.c (get_os_disk): Handle IDA devices.
10323 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10324 (make_device_map): Likewise.
10325
00c108a4 103262008-06-01 Robert Millan <rmh@aybabtu.com>
10327
10328 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
10329 before dereferencing it.
10330
10331 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
10332 union with fat12/fat16-specific ones. Add some new fields, including
10333 `num_serial' for both versions.
10334 (struct grub_fat_data): Add `uuid' member.
10335 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
10336 names. Initialize `data->uuid' using `num_serial'.
10337 (grub_fat_uuid): New function.
10338 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
10339
10340 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
10341 (grub_reiserfs_uuid): New function.
10342 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
10343 member.
10344
10345 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
10346 (grub_xfs_uuid): New function.
10347 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
10348
1385c5bb 103492008-06-01 Robert Millan <rmh@aybabtu.com>
10350
10351 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
10352 code that is backward compatible with pre-uuid search command.
10353
c682dfd7 103542008-05-31 Robert Millan <rmh@aybabtu.com>
10355
10356 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
10357 floppies after everything else, to ensure floppy drive isn't accessed
10358 unnecessarily (patch from Bean).
10359
b7db5d47 103602008-05-31 Robert Millan <rmh@aybabtu.com>
10361
10362 * commands/search.c (search_label, search_fs_uuid, search_file): Do
10363 not print device names when we were asked to set a variable.
10364
6e037aa9 103652008-05-31 Robert Millan <rmh@aybabtu.com>
10366
10367 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
10368 using "cursor-on" and "cursor-off" commands (understood at least by
10369 the Open Firmware flavour on OLPC).
10370
41305bc8 103712008-05-31 Michael Gorven <michael@gorven.za.net>
10372
10373 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
10374 on and off sequences.
10375
69ba137e 103762008-05-31 Robert Millan <rmh@aybabtu.com>
10377
10378 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
10379 * util/update-grub.in: Likewise.
10380
520ae21b 103812008-05-30 Pavel Roskin <proski@gnu.org>
10382
10383 * util/biosdisk.c (linux_find_partition): Simplify logic and
10384 make the code more universal. Keep special processing for
10385 devfs, but use a simple rule for all other devices. If the
10386 device ends with a number, append 'p' and the partition number.
10387 Otherwise, append only the partition number.
10388
5786569b 103892008-05-30 Robert Millan <rmh@aybabtu.com>
10390
10391 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
10392 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
10393 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
10394 the `root' parameter to Linux.
10395
51500452 103962008-05-30 Robert Millan <rmh@aybabtu.com>
10397
10398 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
10399 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
10400 --fs_uuid with --fs-uuid.
10401 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
10402 all filesystems support them).
10403
811d3878 104042008-05-30 Robert Millan <rmh@aybabtu.com>
10405
10406 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
f19dbdb7 10407 grub_printf() flags, since we're printing in units of 2 bytes.
811d3878 10408
cab63c95 104092008-05-30 Robert Millan <rmh@aybabtu.com>
10410
10411 * util/grub.d/00_header.in: Remove obsolete comment referencing
10412 convert_system_path_to_grub_path().
10413 * util/update-grub.in: Likewise.
10414 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
10415 (convert_system_path_to_grub_path): Add a warning message explaining
10416 that this function is deprecated. Rely on is_path_readable_by_grub()
10417 for the readability checks.
10418 (font_path): Use is_path_readable_by_grub() for the readability
10419 check rather than convert_system_path_to_grub_path().
10420
972e2f7a 104212008-05-30 Robert Millan <rmh@aybabtu.com>
10422
10423 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
10424 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
10425 converting it first.
10426 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
10427 grub.cfg for access to font file, and afterwards call it again to set
10428 the root device.
10429
62191274 104302008-05-30 Robert Millan <rmh@aybabtu.com>
10431
10432 * commands/search.c (options): Add --fs_uuid option.
10433 (search_fs_uuid): New function.
10434 (grub_cmd_search): Fix --set argument passing.
10435 Use search_fs_uuid() when requested via --fs_uuid.
10436 (grub_search_init): Update help message.
10437 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
10438 and redeclare it as an array of 16-bit words.
10439 (grub_ext2_uuid): New function.
10440 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
10441 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
10442 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
10443 (GRUB_DEVICE_BOOT_UUID): New variables.
10444 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
10445 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
10446 whenever possible.
10447 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
10448 just assume `root' variable has the right value.
10449 * util/grub.d/10_linux.in: Likewise.
10450 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
10451 via PRINT_FS_UUID.
10452 (main): Recognise `-t fs_uuid' argument.
10453
01b73ec8 104542008-05-30 Robert Millan <rmh@aybabtu.com>
10455
10456 * util/biosdisk.c (map): Redefine structure to hold information
10457 about GRUB drive name.
fe6b695a 10458 (get_drive): Reimplement without assuming (and verifying) BIOS-like
01b73ec8 10459 drive names.
10460 (call_hook): Remove.
10461 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
10462 member. Assume drive has partitions.
10463 (grub_util_biosdisk_open): Access device names via `.device' struct
10464 member.
10465 (open_device): Likewise.
10466 (find_drive): Likewise.
10467 (read_device_map): Adjust map[] usage to match the new struct
10468 definition. Don't check for duplicates (still possible, but not cheap
10469 anymore).
10470 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
10471 (make_device_name): Remove assumption of BIOS-like drive names.
10472
22f16596 104732008-05-30 Pavel Roskin <proski@gnu.org>
10474
10475 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
10476 compiling execute.c doesn't need grub_script.tab.h anymore.
10477 (normal/command.c_DEPENDENCIES): Likewise.
10478 (normal/function.c_DEPENDENCIES): Likewise.
10479 * conf/i386-ieee1275.rmk: Likewise.
10480 * conf/i386-linuxbios.rmk: Likewise.
10481 * conf/i386-pc.rmk: Likewise.
10482 * conf/powerpc-ieee1275.rmk: Likewise.
10483 * conf/sparc64-ieee1275.rmk: Likewise.
10484
528ad8f2 104852008-05-29 Pavel Roskin <proski@gnu.org>
10486
d1dff95d 10487 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
10488 when scanning metadata for volume group name.
10489
528ad8f2 10490 * include/grub/script.h: Don't include grub_script.tab.h. It's
10491 a generated file, which may only be included from the files with
10492 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
10493 use union YYSTYPE, as the later allows forward declaration.
10494 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
10495
47248e08 104962008-05-29 Robert Millan <rmh@aybabtu.com>
10497
10498 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
10499 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
10500 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
10501 (grub_console_checkkey): Add grub_dprintf() call to report unknown
10502 scan codes.
10503
ee632529 105042008-05-29 Robert Millan <rmh@aybabtu.com>
10505
10506 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
10507 control key combinations.
10508
eee96e08 105092008-05-29 Robert Millan <rmh@aybabtu.com>
10510
10511 * util/powerpc/ieee1275/grub-install.in: Move from here ...
10512 * util/ieee1275/grub-install.in: ... to here.
10513 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
10514 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
10515 (grub_install_SOURCES): Likewise.
10516
da9a6a94 105172008-05-29 Robert Millan <rmh@aybabtu.com>
10518
10519 * fs/affs.c: Update copyright year.
10520 * fs/ext2.c: Likewise.
10521 * fs/fshelp.c: Likewise.
10522 * fs/hfsplus.c: Likewise.
10523 * fs/ntfs.c: Likewise.
10524 * fs/xfs.c: Likewise.
10525 * include/grub/fshelp.h: Likewise.
10526 * util/grub-mkdevicemap.c: Likewise.
10527
12e65f3a 105282008-05-28 Robert Millan <rmh@aybabtu.com>
10529
10530 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
10531 might need to be fatfs to support some firmware implementations
10532 (e.g. OFW or EFI).
10533
23023641 105342008-05-28 Robert Millan <rmh@aybabtu.com>
10535
10536 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
10537 devices.
10538 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10539 (make_device_map): Likewise.
10540
887d2619 105412008-05-20 Bean <bean123ch@gmail.com>
10542
10543 * fs/fshelp.c (grub_fshelp_map_block): New function.
10544 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
10545 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
10546
10547 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
10548 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
10549 (grub_fshelp_journal): New structure.
10550 (grub_fshelp_map_block): New function prototype.
10551 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
10552 (grub_fshelp_map_block): Likewise.
10553
10554 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
10555 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
10556 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
10557 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
10558 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
10559 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
10560 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
10561 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
10562 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
10563 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
10564 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
10565 (grub_ext2_sblock): New members for journal support.
10566 (grub_ext3_journal_header): New structure.
10567 (grub_ext3_journal_revoke_header): Likewise.
10568 (grub_ext3_journal_block_tag): Likewise.
10569 (grub_ext3_journal_sblock): Likewise.
10570 (grub_fshelp_node): New members logfile and journal.
10571 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
10572 grub_fshelp_map_block to get real block number.
10573 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
10574 number.
10575 (grub_ext2_read_inode): Likewise.
10576 (grub_ext3_get_journal): New function.
10577 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
10578 (grub_ext2_close): Release memory used by journal.
10579
10580 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
10581 (REISERFS_MAGIC_DESC_BLOCK): New macro.
10582 (grub_reiserfs_transaction_header): Renamed to
10583 grub_reiserfs_description_block, replace field data with real_blocks.
10584 (grub_reiserfs_commit_block): New structure.
10585 (grub_reiserfs_data): New member journal.
10586 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
10587 number.
10588 (grub_reiserfs_read_symlink): Likewise.
10589 (grub_reiserfs_iterate_dir): Likewise.
10590 (grub_reiserfs_open): Likewise.
10591 (grub_reiserfs_read): Likewise.
10592 (grub_reiserfs_get_journal): New function.
10593 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
10594 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
10595 using grub_reiserfs_get_journal.
10596 (grub_reiserfs_close): Release memory used by journal.
10597
10598 * fs/affs.c (grub_affs_read_block): Change block type to
10599 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
10600
10601 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
10602
10603 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
10604
10605 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
10606
10607 * fs/udf.c (grub_udf_read_block): Change block type to
10608 grub_disk_addr_t. Use type cast to avoid warning.
10609
10610 * fs/xfs.c (grub_xfs_read_block): Likewise.
10611
b7c6bed5 106122008-05-16 Christian Franke <franke@computer.org>
10613
10614 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
10615 to ensure that break with ESC will always work.
10616 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
10617 Remove ESC from keyboard queue.
10618
eedf167f 106192008-05-16 Christian Franke <franke@computer.org>
10620
10621 * util/biosdisk.c: [__CYGWIN__] Add includes.
10622 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
10623 (get_os_disk): Move variable declarations to OS specific
10624 parts to avoid warning.
10625 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
10626 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
10627 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
10628 Cygwin.
10629 * util/getroot.c: [__CYGWIN__] Add includes.
10630 (strip_extra_slashes): Fix "/" case.
10631 [__CYGWIN__] (get_win32_path): New function.
10632 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
10633 [__CYGWIN__] (find_root_device): Disable.
10634 [__CYGWIN__] (get_bootsec_serial): New function.
10635 [__CYGWIN__] (find_cygwin_root_device): Likewise.
10636 [__linux__] (grub_guess_root_device): Add early returns to simplify
10637 structure.
10638 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
10639 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
10640 check for Linux only.
10641
a079699e 106422008-05-15 Bean <bean123ch@gmail.com>
10643
10644 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
10645 keyboard hang problem in apple's intel mac.
10646
1cf4059a 106472008-05-09 Robert Millan <rmh@aybabtu.com>
10648
10649 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
10650 devices.
10651 * util/grub-mkdevicemap.c (get_virtio_disk_name)
10652 (make_device_map): Likewise.
10653 Reported by Aurelien Jarno <aurel32@debian.org>
10654
ed759390 106552008-05-07 Ian Campbell <ijc@hellion.org.uk>
10656
10657 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
10658 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
10659 (make_device_map): Output entries for xvd type disks.
10660
b56c4eaa 106612008-05-07 Robert Millan <rmh@aybabtu.com>
10662
10663 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
10664 devices.
10665 * util/grub-mkdevicemap.c (get_cciss_disk_name)
10666 (make_device_map): Likewise.
10667 Reported by Roland Dreier <rdreier@cisco.com>
10668
7f8866ed 106692008-05-07 Robert Millan <rmh@aybabtu.com>
10670
10671 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
10672 grub_strstr() call. Correct a few mistakes in failure path handling.
10673
b0346e0f 106742008-05-06 Robert Millan <rmh@aybabtu.com>
10675
10676 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
10677 Do not print a trailing slash (therefore, the root directory is an
10678 empty string).
10679 (convert_system_path_to_grub_path): Do not remove trailing slash
10680 from make_system_path_relative_to_its_root() output.
10681
10682 * util/i386/pc/grub-install.in: Add trailing slash to output from
10683 make_system_path_relative_to_its_root().
10684
6cf12cbd 106852008-05-06 Robert Millan <rmh@aybabtu.com>
10686
10687 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
10688 ensures that output lines aren't intermangled with those sent to
10689 stderr (via grub_util_info()).
10690 * util/grub-probe.c (grub_refresh): Likewise.
10691 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
10692
0fbb3117 106932008-05-05 Christian Franke <franke@computer.org>
10694
10695 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
10696 Add Cygwin device names.
10697 (get_ide_disk_name) [__CYGWIN__]: Likewise.
10698 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
10699 (check_device): Return error instead of success on empty name.
10700 (make_device_map): Move label inside linux specific code to
10701 prevent compiler warning.
10702
8124cdb7 107032008-04-30 Robert Millan <rmh@aybabtu.com>
10704
10705 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
10706 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
10707 first boot option.
10708 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
10709
094c01d0 107102008-04-29 Robert Millan <rmh@aybabtu.com>
10711
10712 * docs/grub.cfg: New file (example GRUB configuration).
10713
f4b1fc02 107142008-04-26 Robert Millan <rmh@aybabtu.com>
10715
329ce2a5 10716 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
10717 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
10718 and `disk/ieee1275/nand.c'.
f4b1fc02 10719
25f16ec1 107202008-04-25 Bean <bean123ch@gmail.com>
f19dbdb7 10721
25f16ec1 10722 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
10723 i386-linuxbios.
10724
10725 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
10726 change the buffer size to 4096 for cdrom device.
10727
10728 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
10729 and nand.mod.
10730 (_linux_mod_SOURCES): New variable.
10731 (_linux_mod_CFLAGS): Likewise.
10732 (_linux_mod_LDFLAGS): Likewise.
10733 (linux_mod_SOURCES): Likewise.
10734 (linux_mod_CFLAGS): Likewise.
10735 (linux_mod_LDFLAGS): Likewise.
10736 (nand_mod_SOURCES): Likewise.
10737 (nand_mod_CFLAGS): Likewise.
10738 (nand_mod_LDFLAGS): Likewise.
10739
10740 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
10741 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
10742 type property. (nand device in olpc don't have this property)
10743
10744 * include/grub/disk.h (grub_disk_dev_id): New macro
10745 GRUB_DISK_DEVICE_NAND_ID.
10746
10747 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
10748 function prototype.
10749 (grub_rescue_cmd_initrd): Likewise.
10750
10751 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
10752 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
10753 ofw_cif_handler and ofw_idt, adjust padding number.
f19dbdb7 10754
25f16ec1 10755 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
10756 GRUB_MACHINE_IEEE1275 is defined.
10757
10758 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
10759 Use NESTED_FUNC_ATTR attribute on the hook parameter.
10760
10761 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
10762 on nested function heap_init.
10763 (grub_upper_mem): New variable for i386-ieee1275.
10764 (grub_get_extended_memory): New function for i386-ieee1275.
10765 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
10766
10767 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
10768 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
10769 property.
f19dbdb7 10770
25f16ec1 10771 * loader/i386/ieee1275/linux.c: New file.
10772
10773 * loader/i386/ieee1275/linux_normal.c: New file.
10774
10775 * disk/ieee1275/nand.c: New file.
10776
e89d61e9 107772008-04-18 Thomas Schwinge <tschwinge@gnu.org>
10778
10779 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
10780 value.
10781 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
10782
602566f6 107832008-04-18 Robert Millan <rmh@aybabtu.com>
10784
10785 Restructures early code path on ieee1275 to unify grub_main() as
10786 the first C function that is executed in every platform.
10787
10788 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
10789 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
10790 cmain().
10791 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
10792 * kern/ieee1275/cmain.c (cmain): Rename to ...
10793 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
10794 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
10795 at the beginning.
10796
57490c2b 107972008-04-18 Robert Millan <rmh@aybabtu.com>
10798
10799 * util/update-grub.in: Fix syntax error when setting
10800 `GRUB_PRELOAD_MODULES'.
10801 Reported by Stephane Chazelas <stephane@artesyncp.com>
10802
1977517d 108032008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
10804
10805 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
10806 section into account, newer toolchains generate unique build ids
10807 * configure.ac: remove the test for --build-id=none acceptance,
e0c5dacb 10808 we want build ids to be preserved
1977517d 10809 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
10810 far from other sections don't cause the raw binary images grow
10811 size
10812
bfb1f1a2 108132008-04-15 Robert Millan <rmh@aybabtu.com>
10814
10815 * disk/lvm.c: Update copyright year.
10816 * kern/misc.c: Likewise.
10817
01979850 108182008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
10819
10820 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
f19dbdb7 10821 there is no memory left for physical volume name.
01979850 10822
0a1150e2 108232008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
10824
10825 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
10826 volume name mapping to support bigger than 9 character names properly.
10827
82ead3fe 108282008-04-13 Robert Millan <rmh@aybabtu.com>
10829
10830 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
10831 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
10832
e54a72f5 108332008-04-13 Christian Franke <franke@computer.org>
10834
10835 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
10836 to create a floppy emulation boot CD when non emulation mode
10837 does not work.
10838 Enable Joliet CD filesystem extension.
10839
9fe86034 108402008-04-13 Robert Millan <rmh@aybabtu.com>
10841
10842 * kern/misc.c (grub_strncat): Fix off-by-one error.
10843 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
10844
10845 * kern/env.c (grub_env_context_close): Clear current context, not
10846 previous one.
10847 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
10848
10849 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
10850
7ceeee39 108512008-04-13 Robert Millan <rmh@aybabtu.com>
10852
10853 Improve robustness when handling LVM.
10854
10855 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
f19dbdb7 10856 (and leave `*p' unmodified).
7ceeee39 10857 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
10858 through it.
10859 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
10860 iterating through it.
10861 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
10862 through it.
fe6b695a 10863 (grub_lvm_scan_device): Check the return value (and fail gracefully
7ceeee39 10864 when due) on each grub_lvm_getvalue() or grub_strstr() call.
10865 Don't assume `vg->pvs != NULL' when iterating through it.
10866
58cd3d85 108672008-04-13 Robert Millan <rmh@aybabtu.com>
10868
10869 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
10870 * genmk.rb (partmap): New variable.
10871 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
10872 (#{partmap}): New target rule.
10873 * genpartmaplist.sh: New file.
10874 * Makefile.in (pkglib_DATA): Add partmap.lst.
10875 (partmap.lst): New target rule.
10876 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
10877 modules (including all partition maps), instead of preloading them.
10878
78b51059 108792007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
10880
10881 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
10882 `linux-boot-prober' (if installed) to detect other operating
10883 systems which are installed on the computer and add them to
10884 the boot menu.
10885 * conf/common.rmk: Build and install 30_os-prober.
10886
a91627b4 108872008-04-12 Robert Millan <rmh@aybabtu.com>
10888
10889 * kern/powerpc/ieee1275/init.c: Move from here ...
10890 * kern/ieee1275/init.c: ... to here. Update all users.
10891
10892 * kern/powerpc/ieee1275/cmain.c: Move from here ...
10893 * kern/ieee1275/cmain.c: ... to here. Update all users.
10894
10895 * kern/powerpc/ieee1275/openfw.c: Move from here ...
10896 * kern/ieee1275/openfw.c: ... to here. Update all users.
10897
10898 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
10899 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
10900
322562ea 109012008-04-10 Pavel Roskin <proski@gnu.org>
10902
10903 * configure.ac: Always use "_cv_" in cache variables for
10904 compatibility with Autoconf 2.62.
10905
a02a73c5 109062008-04-07 Robert Millan <rmh@aybabtu.com>
10907
10908 Revert grub/machine/init.h addition by Pavel (since it breaks on
10909 i386-ieee1275 and others):
10910 * util/i386/pc/misc.c: Remove grub/machine/init.h.
10911 * util/powerpc/ieee1275/misc.c: Likewise.
10912
25c024b1 109132008-04-07 Robert Millan <rmh@aybabtu.com>
10914
10915 * util/grub-probe.c (probe): Improve error message.
10916
3cbd2f98 109172008-04-07 Robert Millan <rmh@aybabtu.com>
10918
10919 * util/biosdisk.c (read_device_map): Skip devices that don't exist
10920 (this prevents the presence of a bogus entry from ruining the whole
10921 thing).
10922
87a297bf 109232008-04-06 Pavel Roskin <proski@gnu.org>
10924
36747a62 10925 * util/biosdisk.c: Include grub/util/biosdisk.h.
10926 * util/grub-fstest.c (execute_command): Make static.
10927 * util/grub-mkdevicemap.c (check_device): Likewise.
10928 * util/i386/pc/misc.c: Include grub/machine/init.h.
10929 * util/powerpc/ieee1275/misc.c: Likewise.
10930 * util/lvm.c: Include grub/util/lvm.h.
10931 * util/misc.c: Include grub/kernel.h, grub/misc.h and
10932 grub/cache.h.
10933 * util/raid.c: Include grub/util/raid.h.
10934 (grub_util_getdiskname): Make static.
10935
87a297bf 10936 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
10937 grub_hostfs_fini(), as they are called from grub_init_all() and
10938 grub_fini_all() respectively. This fixes an infinite loop in
10939 grub-fstest due to double registration of hostfs.
10940 Reported by Christian Franke <Christian.Franke@t-online.de>
10941
f6ce7629 109422008-04-05 Pavel Roskin <proski@gnu.org>
10943
10944 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
10945 all 8 functions. Otherwise, probe function 0 only.
10946
070e49e4 109472008-04-04 Pavel Roskin <proski@gnu.org>
10948
8b088a4c 10949 * commands/lspci.c (grub_lspci_iter): Print the bus number
10950 correctly.
10951
4f657021 10952 * commands/lspci.c (grub_pci_classes): Fix typos.
10953 (grub_lspci_iter): Don't print func twice. Print vendor ID
10954 before device ID, as it's normally done.
10955
070e49e4 10956 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
10957 Fix signedness warnings.
10958 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
10959 Likewise.
10960 * util/ieee1275/get_disk_name.c: Include config.h so that
10961 _GNU_SOURCE is defined and getline() is declared. Mark an
10962 unused argument as such. Fix a signedness warning.
10963
ba7328dc 109642008-04-02 Pavel Roskin <proski@gnu.org>
10965
26887f22 10966 * genkernsyms.sh.in: Use more robust assignments for CC and
10967 srcdir. Quote srcdir.
10968 * gensymlist.sh.in: Likewise. Assert at the compile time that
10969 the symbol table is not empty.
10970
ba7328dc 10971 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
10972 * fs/cpio.c (grub_cpio_read): Likewise.
10973
0f582c6b 109742008-04-01 Pavel Roskin <proski@gnu.org>
10975
4b6e1995 10976 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
10977 * disk/host.c (grub_host_open): Likewise.
10978 * disk/loopback.c (grub_loopback_open): Likewise.
10979 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
10980 disk->id as in disk/host.c, not a multi-character constant.
10981
828a2768 10982 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
10983 later is obsolete, potentially dangerous and sets a bad example.
10984 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
10985 * util/misc.c (grub_util_get_image_size): Likewise.
10986
2bb4fb47 10987 * disk/loopback.c (options): Improve help for "--partitions".
10988
0f582c6b 10989 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
10990 options to align them with the short options, e.g. "echo -e".
10991
a33224e0 109922008-03-31 Bean <bean123ch@gmail.com>
10993
10994 * video/reader/png.c (grub_png_data): New member is_16bit and
10995 image_data.
10996 (grub_png_decode_image_header): Detect 16 bit png image.
10997 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
10998 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
10999 (grub_video_reader_png): Release memory occupied by image_data.
11000
11001 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
11002 4096 bytes.
11003 (grub_nfs_mount): Skip the test for sector per cluster.
11004
11005 * include/grub/ntfs.h (MAX_SPC): Removed.
11006
86cb4f54 110072008-03-31 Bean <bean123ch@gmail.com>
11008
11009 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
11010 (grub_probe_SOURCES): Add fs/afs.c.
11011 (grub_fstest_SOURCES): Likewise.
11012 (afs_mod_SOURCES): New variable.
11013 (afs_mod_CFLAGS): Likewise.
11014 (afs_mod_LDFLAGS): Likewise.
11015
11016 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
11017 (grub_emu_SOURCES): Likewise.
11018
11019 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11020
11021 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11022
11023 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11024
11025 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11026
11027 * fs/afs.c: New file.
11028
17c74c21 110292008-03-30 Pavel Roskin <proski@gnu.org>
11030
4cb68e89 11031 * disk/host.c: Include grub/misc.h to fix a warning.
11032 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
11033 warnings about implicit declarations.
11034
8790bb04 11035 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
11036 variable.
11037 * include/grub/i386/loader.h: Change declaration of
11038 grub_linux_boot() to match what grub_loader_set() expects.
11039 * util/getroot.c (grub_guess_root_device): Return const char* to
11040 fix a warning.
11041 * util/grub-probe.c (probe): Fix a warning about uninitialized
11042 abstraction_name variable.
11043 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
11044 second argument as unused to fix a warning.
11045
9a3f3296 11046 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
11047 missing grub_error() call.
11048
0ecef90d 11049 * util/update-grub_lib.in: Define datarootdir, since Autoconf
11050 2.60 and newer uses it to define datadir.
11051
0bf6d401 11052 * commands/sleep.c: Fix warning about implicit declaration.
11053 * disk/memdisk.c: Likewise.
11054 * loader/aout.c: Likewise.
11055 * loader/i386/bsd_normal.c: Likewise.
11056 * util/grub-probe.c: Likewise.
11057
7cdacf97 11058 * commands/i386/cpuid.c (has_longmode): Make static.
11059 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
11060 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
11061
17c74c21 11062 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
11063 GDT. This is more robust, as %ds can change.
11064 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
11065 calling real_to_prot().
11066 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
11067
80a3e68b 110682008-03-28 Pavel Roskin <proski@gnu.org>
11069
11070 * kern/i386/pc/startup.S: Assert that uncompressed functions
11071 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
11072 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
11073 code, as they push parts of the code (error handlers) beyond
11074 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
11075 code as correctness and size.
11076
77bcd272 110772008-03-28 Pavel Roskin <proski@gnu.org>
11078
11079 * kern/i386/pc/startup.S
11080 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
11081 data block address to the real mode, keep offset minimal. This
11082 works around a bug in AWARD BIOS on old Athlon systems, which
11083 makes CD detection hang.
11084
c5dfd43b 110852008-03-26 Pavel Roskin <proski@gnu.org>
11086
11087 * normal/color.c (grub_parse_color_name_pair): Make `name' a
11088 const.
11089 * include/grub/normal.h: Add grub_parse_color_name_pair()
11090 declaration.
11091
bf962df2 110922008-03-24 Bean <bean123ch@gmail.com>
11093
11094 * disk/i386/pc/biosdisk.c (cd_start): Removed.
11095 (cd_count): Removed.
11096 (cd_drive): New variable.
11097 (grub_biosdisk_get_drive): Don't check for (cdN) device.
11098 (grub_biosdisk_call_hook): Likewise.
11099 (grub_biosdisk_iterate): Change cdrom detection method.
11100 (grub_biosdisk_open): Replace cd_start with cd_drive.
11101 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
11102 detect cdrom device.
11103
11104 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
11105 Removed.
11106 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
11107 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
11108 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
11109 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
11110 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
11111 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
11112 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
11113 (grub_biosdisk_cdrp): New structure.
11114 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
11115
11116 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
11117
11118 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
11119 device.
11120
11121 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
11122 New function.
11123
68e7fc7a 111242008-03-20 Robert Millan <rmh@aybabtu.com>
11125
11126 Remove 2 TiB limit in ata.mod.
11127 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
11128 (grub_ata_dumpinfo): Print sector count with 0x%llx.
11129 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
11130 grub_uint64_t instead of grub_uint32_t.
11131
38ad2cf5 111322008-03-05 Bean <bean123ch@gmail.com>
11133
11134 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
11135 (grub_multiboot): Set boot device.
11136
11137 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
11138
2b89344e 111392008-03-02 Bean <bean123ch@gmail.com>
11140
11141 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
11142 symlink_buffer.
11143
87a95d1f 111442008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
11145
11146 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
11147 texinfo.tex.
11148
11149 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
11150 modified.
11151
11152 * docs/fdl.texi: New file.
f19dbdb7 11153
87a95d1f 11154 * docs/mdate-sh: New file. Copied from gnulib.
11155 * docs/texinfo.tex: Likewise.
11156
11157 * config.guess: Updated from gnulib.
11158 * install-sh: Likewise.
11159
7dc15d8e 111602008-02-28 Robert Millan <rmh@aybabtu.com>
11161
11162 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
11163 (aout_mod_SOURCES): New variable.
11164 (aout_mod_CFLAGS): Likewise.
11165 (aout_mod_LDFLAGS): Likewise.
11166
11167 * conf/i386-ieee1275.rmk: Likewise.
11168
b00ab696 111692008-02-28 Robert Millan <rmh@aybabtu.com>
11170
11171 * util/update-grub.in: Reorganise terminal validity check. Accept
11172 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
11173 Based on suggestion by Franklin PIAT.
11174
79ca2d78 111752008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
11176
11177 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
11178 function.
11179 * util/getroot.c (grub_util_check_block_device): New function that
11180 returns the given argument if it is a block device and returns NULL else.
11181 * util/grub-probe.c (argument_is_device): New variable.
11182 (probe): Promote device_name from a variable to an argument. Receive
11183 device_name from grub_util_check_block_device() if path is NULL and from
11184 grub_guess_root_device() else. Do not free() device_name anymore.
f19dbdb7 11185 (options): Introduce new parameter '-d, --device'.
79ca2d78 11186 (main): Add description of the new parameter to the help screen.
11187 Rename path variable to argument. Set argument_is_device if the '-d'
11188 option is given. Pass argument to probe() depending on
11189 argument_is_device.
11190
0d16e571 111912008-02-24 Bean <bean123ch@gmail.com>
11192
11193 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
11194 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
11195 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
11196 (GRUB_ISO9660_VOLDESC_PART): Likewise.
11197 (GRUB_ISO9660_VOLDESC_END): Likewise.
11198 (grub_iso9660_primary_voldesc): New member escape.
11199 (grub_iso9660_data): New member joliet.
11200 (grub_iso9660_convert_string): New function.
11201 (grub_iso9660_mount): Detect joliet extension.
11202 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
11203 (grub_iso9660_iso9660_label): Likewise.
11204
11205 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
11206 (grub_setup_SOURCES): Add fs/udf.c.
11207 (grub_fstest_SOURCES): Likewise.
11208 (udf_mod_SOURCES): New variable.
11209 (udf_mod_CFLAGS): Likewise.
11210 (udf_mod_LDFLAGS): Likewise.
11211
11212 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
11213 (grub_emu_SOURCES): Likewise.
11214
11215 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11216
11217 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11218
11219 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11220
11221 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11222
11223 * fs/udf.c: New file.
11224
8a594a17 112252008-02-24 Robert Millan <rmh@aybabtu.com>
11226
11227 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
11228 (normal/lexer.c_DEPENDENCIES): New variables.
11229 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11230 (normal/lexer.c_DEPENDENCIES): Likewise.
11231 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
11232 (normal/lexer.c_DEPENDENCIES): Likewise.
11233 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
11234 (normal/lexer.c_DEPENDENCIES): Likewise.
11235 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11236 (normal/lexer.c_DEPENDENCIES): Likewise.
11237 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11238 (normal/lexer.c_DEPENDENCIES): Likewise.
11239
2dc33c03 112402008-02-23 Robert Millan <rmh@aybabtu.com>
11241
11242 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
11243 since they were intended to be in hex. This didn't break previously
11244 because of a bug in gpt_partition_map_iterate() (see below).
11245
11246 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
11247 when checking the validity of GPT header.
11248 Remove `partno', since it always provides the same information as `i'.
11249
f6f4cfb0 112502008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
11251
11252 * include/grub/efi/time.h: Fix a wrong comment.
11253
79ff665f 112542008-02-19 Pavel Roskin <proski@gnu.org>
11255
11256 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
11257 message.
11258
d38e24c2 112592008-02-19 Bean <bean123ch@gmail.com>
11260
11261 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
11262 (aout_mod_SOURCES): New variable.
11263 (aout_mod_CFLAGS): Likewise.
11264 (aout_mod_LDFLAGS): Likewise.
11265 (_bsd_mod_SOURCES): New variable.
11266 (_bsd_mod_CFLAGS): Likewise.
11267 (_bsd_mod_LDFLAGS): Likewise.
11268 (bsd_mod_SOURCES): New variable.
11269 (bsd_mod_CFLAGS): Likewise.
11270 (bsd_mod_LDFLAGS): Likewise.
11271
11272 * include/grub/aout.h: New file.
11273
11274 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
11275
11276 * include/grub/i386/bsd.h: New file.
11277
11278 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
11279 to make it public.
11280
11281 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
11282 function is called, so that it's possible to change it inside the hook.
11283 (grub_elf64_load): Likewise.
11284 (grub_elf_file): Don't close the file if elf header is not found.
11285 (grub_elf_close): Close the file if grub_elf_file fails (The new
11286 grub_elf_file won't close it).
11287 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
11288 (grub_elf64_size): Likewise.
11289
11290 * kern/i386/loader.S (grub_unix_real_boot): New function.
11291
11292 * loader/aout.c: New file.
11293
11294 * loader/i386/bsd.c: New file.
11295
11296 * loader/i386/bsd_normal.c: New file.
11297
11298 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
11299
11300 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
fe987087 11301 can test other formats.
d38e24c2 11302
b93bdb0f 113032008-02-19 Robert Millan <rmh@aybabtu.com>
11304
11305 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
11306 (grub_gpt_partition_type_empty): Redefine with macro from
11307 `<grub/gpt_partition.h>'.
11308 (gpt_partition_map_iterate): Adjust partition type comparison.
11309
11310 Export `entry' as partmap-specific `part.data' struct.
11311 (grub_gpt_header, grub_gpt_partentry): Move from here ...
11312
11313 * include/grub/gpt_partition.h (grub_gpt_header)
11314 (grub_gpt_partentry): ... to here (new file).
11315
11316 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
11317
11318 (grub_gpt_partition_type_bios_boot): New const variable, defined
11319 with macro from `<grub/gpt_partition.h>'.
11320
11321 (setup): Replace `first_start' with `embed_region', which keeps
11322 track of the embed region (and is partmap-agnostic).
11323
11324 Replace find_first_partition_start() with find_usable_region(),
11325 which finds a usable region for embedding using partmap-specific
11326 knowledge (supports PC/MSDOS and GPT).
11327
11328 Fix all assumptions that the embed region start at sector 1, using
11329 `embed_region.start' from now on. Similarly, use `embed_region.end'
11330 rather than `first_start' to calculate available size.
11331
11332 In grub_util_info() message, replace "into after the MBR" with an
11333 indication of the specific sector our embed region starts at.
11334
66cb40f6 113352008-02-19 Robert Millan <rmh@aybabtu.com>
11336
11337 * DISTLIST: Replace `commands/ieee1275/halt.c' and
11338 `commands/ieee1275/reboot.c' with `commands/halt.c' and
11339 `commands/reboot.c'.
11340 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11341 (halt_mod_SOURCES): Likewise.
11342 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11343 (halt_mod_SOURCES): Likewise.
11344
b7202015 113452008-02-17 Christian Franke <franke@computer.org>
11346
11347 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
11348
32b0fc49 113492008-02-17 Robert Millan <rmh@aybabtu.com>
11350
11351 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11352 set `first_start' to 0 for non-PC/MSDOS partition maps.
11353
aca63502 113542008-02-16 Robert Millan <rmh@aybabtu.com>
11355
11356 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11357 do not assume partition map is PC/MSDOS before performing checks that
11358 are specific to that layout.
11359
0de8be86 113602008-02-13 Robert Millan <rmh@aybabtu.com>
11361
11362 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
11363 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
11364 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
11365
c3db8364 113662008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
11367
11368 * configure.ac: Only a cosmetic change on the handling of
11369 -fno-stack-protector.
11370
f714229e 113712008-02-12 Alexandre Boeglin <alex@boeglin.org>
11372
c3db8364 11373 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
11374 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
11375 reboot.c.
f714229e 11376 (grub_install_SOURCES): Add halt.mod and reboot.mod.
11377 (halt_mod_SOURCES): New variable.
11378 (halt_mod_CFLAGS): Likewise.
11379 (halt_mod_LDFLAGS): Likewise.
11380 (reboot_mod_SOURCES): Likewise.
11381 (reboot_mod_CFLAGS): Likewise.
11382 (reboot_mod_LDFLAGS): Likewise.
11383
c3db8364 11384 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
11385 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
11386 reboot.c.
f714229e 11387 (halt_mod_SOURCES): Likewise.
11388 (reboot_mod_SOURCES): Likewise.
11389
c3db8364 11390 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
11391 commands/i386/pc/reboot.c by commands/reboot.c.
f714229e 11392 (reboot_mod_SOURCES): Likewise.
11393
11394 * commands/i386/pc/reboot.c: merge this file ...
11395
11396 * commands/ieee1275/reboot.c: ... and this file ...
11397
11398 * commands/reboot.c: ... to this file.
c3db8364 11399 Add some precompiler directive to include the correct header for
11400 each machine.
f714229e 11401
11402 * commands/ieee1275/halt.c: move this file ...
11403
11404 * commands/halt.c: ... to here.
c3db8364 11405 Add some precompiler directive to include the correct header for
11406 each machine.
f714229e 11407
11408 * include/grub/efi/efi.h (grub_reboot): New function declaration.
11409 (grub_halt): Likewise.
11410
11411 * kern/efi/efi.c (grub_reboot): New function.
11412 (grub_halt): Likewise.
11413
c74493e0 114142008-02-12 Robert Millan <rmh@aybabtu.com>
11415
11416 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
11417 /dev (like it is done for /dev/mapper). This doesn't provide support
11418 for EVMS, but at least it is now easy to identify the problem when it
11419 arises.
11420
d0db4b04 114212008-02-11 Robert Millan <rmh@aybabtu.com>
11422
11423 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
11424 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
11425 comparing it with -1, not 0.
11426
bf748642 114272008-02-10 Robert Millan <rmh@aybabtu.com>
11428
11429 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
11430 `disk/lvm.c'.
11431 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11432 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
11433
11434 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
11435 `disk/lvm.c' to the end of the list.
11436 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11437 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
11438
b5db202a 114392008-02-10 Robert Millan <rmh@aybabtu.com>
11440
11441 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
11442 grub_print_error() instead. This will let user know why we're entering
11443 rescue mode.
11444 Based on suggestions from Sam Morris.
11445
83abee31 114462008-02-10 Alexandre Boeglin <alex@boeglin.org>
11447
11448 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
11449 on remaining N args, instead of "--" arg N times.
11450
78d5a08b 114512008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
11452
11453 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
11454 (fill_with_default_glyph): Changed to use unknown_glyph for fill
11455 pattern for unknown glyphs.
11456
68807e5f 114572008-02-09 Robert Millan <rmh@aybabtu.com>
11458
11459 * configure.ac: Probe for `help2man'.
11460 * Makefile.in (builddir): New variable.
11461 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
11462 or otherwise add a few flags/options to it.
11463 (install-local): For every executable utility or script that is
11464 installed, invoke $(HELP2MAN) to install a manpage based on --help
11465 output.
11466
11467 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
11468 that it doesn't prevent --help from working in build tree.
11469
11470 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
11471 with `bug-grub@gnu.org'.
11472 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
11473 * util/update-grub.in (usage): New function.
11474 Implement proper argument check, with support for --help and --version
11475 (as well as existing -y).
11476
114772008-02-09 Christian Franke <franke@computer.org>
0d9ff7f0 11478
11479 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
11480 avoid overwriting previous output.
11481 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
11482
c1962162 114832008-02-09 Robert Millan <rmh@aybabtu.com>
11484
11485 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
11486 drawing the menu.
11487
3dac2e3f 114882008-02-09 Robert Millan <rmh@aybabtu.com>
11489
11490 * commands/sleep.c: New file.
11491 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
11492 (sleep_mod_SOURCES): New variable.
11493 (sleep_mod_CFLAGS): Likewise.
11494 (sleep_mod_LDFLAGS): Likewise.
11495
7a634e08 114962008-02-09 Robert Millan <rmh@aybabtu.com>
11497
11498 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
11499 situations in which we can deduce the RAID size and the superblock
11500 doesn't match it.
11501
b92f0c18 115022008-02-09 Robert Millan <rmh@aybabtu.com>
11503
11504 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
11505 and return a grub_diskmemberlist_t composed of LVM physical volumes.
11506 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
11507
11508 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
11509 and return a grub_diskmemberlist_t composed of physical array members.
11510 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
11511
11512 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
11513 prototype.
11514 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
11515 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
11516 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
11517
11518 * util/grub-probe.c (probe): Move partmap probing code from here ...
11519 (probe_partmap): ... to here.
11520 (probe): Use probe_partmap() once for the disk we're probing, and
11521 additionally, when such disk contains a memberlist() struct member,
11522 once for each disk that is contained in the structure returned by
11523 memberlist().
11524
91a4bf68 115252008-02-09 Robert Millan <rmh@aybabtu.com>
11526
11527 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
11528 environment variable to 'all' in order to obtain debug output from
11529 non-util/ code.
11530 * util/i386/pc/grub-setup.c (main): Likewise.
11531
a96f9caa 115322008-02-08 Robert Millan <rmh@aybabtu.com>
11533
11534 * disk/raid.c (grub_raid_scan_device): Check for
11535 `array->device[sb.this_disk.number]' rather than for
11536 `array->device[sb.this_disk.number]->name', since the latter is not
fe6b695a 11537 guaranteed to be accessible.
a96f9caa 11538
b37a9222 115392008-02-08 Robert Millan <rmh@aybabtu.com>
11540
11541 * disk/raid.c: Update copyright.
11542 * fs/cpio.c: Likewise.
11543 * include/grub/raid.h: Likewise.
11544 * loader/i386/pc/multiboot.c: Likewise.
11545 * util/hostfs.c: Likewise.
11546
5626aee1 115472008-02-08 Robert Millan <rmh@aybabtu.com>
11548
11549 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
11550 to a grub_disk_t array.
11551 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
11552 `device[x]'.
11553 (grub_raid_scan_device): Replace `device[x].name' accesses with
11554 `device[x]->name'. Simplify initialization of `array->device[x]'.
11555
554f0187 115562008-02-08 Robert Millan <rmh@aybabtu.com>
11557
11558 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
11559 grub_dprintf() calls.
11560 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
11561 error message.
11562
1ec8425d 115632008-02-07 Christian Franke <franke@computer.org>
11564
11565 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
11566 instead of fseek and ftell to support large files.
11567 (grub_hostfs_read): Likewise.
11568
f2156fda 115692008-02-07 Robert Millan <rmh@aybabtu.com>
11570
11571 Patch from Jeroen Dekkers.
11572 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
fe6b695a 11573 failure, since successfully reading all array members might not be
f2156fda 11574 required.
11575
9216e0e7 115762008-02-06 Robert Millan <rmh@aybabtu.com>
11577
11578 * util/grub-probe.c (probe): Simplify partmap probing (with the
11579 assumption that the first word up to the underscore equals to
11580 the module name).
11581
b0dfd29a 115822008-02-06 Christian Franke <franke@computer.org>
11583
11584 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
11585 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
11586 last block of a cpio or tar stream.
11587 Check for "TRAILER!!!" instead of any empty data
11588 block to detect last block of a cpio stream.
11589 (grub_cpio_dir): Fix constness of variable np.
11590 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
11591 cpio or tar trailer is detected. This fixes a crash
11592 on open of a non existing file.
11593
c32865bf 115942008-02-05 Bean <bean123ch@gmail.com>
11595
11596 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
11597 address of entry.
11598 (grub_multiboot_load_elf64): Likewise.
11599 (grub_multiboot): Initialize mbi structure.
11600
11601 * util/grub-fstest.c: Don't include unused header file script.h.
11602
fe6b695a 11603 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
c32865bf 11604 of file.
11605 (grub_fstest_SOURCES): Likewise.
11606
409480b7 116072008-02-05 Robert Millan <rmh@aybabtu.com>
11608
11609 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
11610 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
11611 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
11612 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
11613
11614 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
11615 (translation_table): Replace hardcoded values with macros
11616 provided by `<grub/term.h>'.
11617
11618 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
11619 (keyboard_map): Correct/add a few values, with macros provided
11620 by `<grub/term.h>'.
11621 (keyboard_map_shift): Zero values that don't differ from their
11622 `keyboard_map' equivalents.
11623 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
11624 Discard the second scan code that is always sent by Caps lock.
11625 Only use `keyboard_map_shift' when it provides a non-zero value,
11626 otherwise fallback to `keyboard_map'.
11627
99fadbaa 116282008-02-04 Bean <bean123ch@gmail.com>
11629
11630 * Makefile.in (enable_grub_fstest): New variable.
11631
11632 * conf/common.rmk (grub_fstest_init.lst): New rule.
11633 (grub_fstest_init.h): Likewise.
11634 (grub_fstest_init.c): Likewise.
11635 (util/grub-fstest.c_DEPENDENCIES): New variable.
11636 (grub_fstest_SOURCES): Likewise.
11637
11638 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
11639
11640 * util/grub-fstest.c: New file.
11641
bf567c50 116422008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11643
11644 Make grub-setup handle a separate root device.
f19dbdb7 11645
bf567c50 11646 * util/i386/pc/grub-setup.c (setup): Always open the root device,
11647 so that the root device can be compared with the destination
11648 device.
11649 When embedding the core image, if the root and destination devices
11650 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
11651 0xFF.
11652 When not embedding, set ROOT_DRIVE to 0xFF.
f19dbdb7 11653
9be6b98b 116542008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11655
11656 Add support for having a grub directory in a different drive. This
11657 is still only the data handling part.
f19dbdb7 11658
9be6b98b 11659 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
11660 (codestart): Save %dh in GRUB_ROOT_DRIVE.
11661 (grub_root_drive): New variable.
11662
11663 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
11664 instead of GRUB_BOOT_DRIVE to construct a device name. Set
11665 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
11666 as it was.
11667
11668 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
11669
11670 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
11671 macro.
11672 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
11673
11674 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
11675 is bogus, because PXE booting does not specify any drive
11676 correctly.
11677
11678 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
11679 am not sure if this is really correct.
11680
11681 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
11682 is always identical to the boot drive when booting from a CD.
11683
11684 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
11685 longer.
11686 (root_drive): New variable.
11687 (real_start): Unconditionally set %dh to ROOT_DRIVE.
11688 (setup_sectors): Push %dx right after popping it, because %dh will
11689 be modified later.
11690 (copy_buffer): Restore %dx.
11691
e0ca0677 116922008-02-03 Robert Millan <rmh@aybabtu.com>
11693
11694 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
11695 use `cdboot.img' for cdrom images.
11696
3b3f6629 116972008-02-03 Robert Millan <rmh@aybabtu.com>
11698
11699 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
11700 only setup gfxterm when `font' command has succeeded.
11701
d42b3672 117022008-02-03 Robert Millan <rmh@aybabtu.com>
11703
11704 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
11705 (grub_rescue_cmd_multiboot_loader)
11706 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
11707
fa370ea6 117082008-02-03 Pavel Roskin <proski@gnu.org>
11709
e0c5dacb 11710 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
fa370ea6 11711 %edx and %esi from stack only after grub_gate_a20() is called.
11712 grub_gate_a20() clobbers %edx.
11713
f2a76e1d 117142008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11715
11716 * configure.ac (AC_INIT): Bumped to 1.96.
11717
11718 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
11719 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
11720 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
11721 video/readers/png.c.
11722
90fd32d1 117232008-02-03 Bean <bean123ch@gmail.com>
9be665dd 11724
11725 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
11726 (cdboot_img_SOURCES): New variable.
11727 (cdboot_img_ASFLAGS): New variable.
11728 (cdboot_img_LDFLAGS): New variable.
11729
11730 * boot/i386/pc/cdboot.S: New file.
11731
11732 * disk/i386/pc/biosdisk.c (cd_start): New variable.
11733 (cd_count): Likewise.
11734 (grub_biosdisk_get_drive): Add support for cd device.
11735 (grub_biosdisk_call_hook): Likewise.
11736 (grub_biosdisk_iterate): Likewise.
11737 (grub_biosdisk_open): Likewise.
11738 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
11739 (grub_biosdisk_rw): Support reading from cd device.
11740 (GRUB_MOD_INIT): Iterate cd devices.
11741
11742 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
11743 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
11744 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
11745
11746 * kern/i386/pc/init.c (make_install_device): Check for cd device.
11747
4020aa53 117482008-02-02 Robert Millan <rmh@aybabtu.com>
11749
11750 * commands/read.c: New file.
11751 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
11752 (read_mod_SOURCES): New variable.
11753 (read_mod_CFLAGS): Likewise.
11754 (read_mod_LDFLAGS): Likewise.
11755
e03a1132 117562008-02-02 Robert Millan <rmh@aybabtu.com>
11757
11758 * normal/main.c (grub_normal_execute): Check for `menu->size' when
11759 determining whether menu has to be displayed.
11760
58c69220 117612008-02-02 Marco Gerards <marco@gnu.org>
11762
11763 * bus/pci.c: New file.
11764
11765 * include/grub/pci.h: Likewise.
11766
11767 * include/grub/i386/pc/pci.h: Likewise.
11768
11769 * commands/lspci.c: Likewise.
11770
11771 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
11772 `lspci.mod'.
11773 (pci_mod_SOURCES): New variable.
11774 (pci_mod_CFLAGS): Likewise.
11775 (pci_mod_LDFLAGS): Likewise.
11776 (lspci_mod_SOURCES): Likewise.
11777 (lspci_mod_CFLAGS): Likewise.
f19dbdb7 11778 (lspci_mod_LDFLAGS): Likewise.
58c69220 11779
c004e1b4 117802008-02-02 Bean <bean123ch@gmail.com>
11781
11782 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
11783 (grub_ufs_get_file_block): Fix indirect block calculation problem.
11784
11785 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
11786 (grub_xfs_btree_node): New structure.
11787 (grub_xfs_btree_root): New structure.
11788 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
11789 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
11790 (GRUB_XFS_EXTENT_BLOCK): Likewise.
11791 (GRUB_XFS_EXTENT_SIZE): Likewise.
11792 (grub_xfs_read_block): Support btree format type.
11793 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
11794 Use directory block as basic unit.
11795
11796 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
11797
11798 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
11799 __attribute__ ((__regparm__ (1))).
11800
f95562bf 118012008-02-01 Robert Millan <rmh@aybabtu.com>
11802
11803 Correct a mistake in previous commit.
11804
11805 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
11806 top.
11807 (normal/command.c_DEPENDENCIES): New variable.
11808
7d31f41f 118092008-02-01 Robert Millan <rmh@aybabtu.com>
11810
11811 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
11812 top.
11813 (normal/command.c_DEPENDENCIES): New variable.
11814 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
11815 * conf/i386-ieee1275.rmk: Likewise.
11816 * conf/i386-linuxbios.rmk: Likewise.
11817 * conf/i386-pc.rmk: Likewise.
11818 * conf/sparc64-ieee1275.rmk: Likewise.
11819 * conf/powerpc-ieee1275.rmk: Likewise.
11820 (grub_emu_SOURCES): Add `fs/fshelp.c'.
11821
11822 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
11823
60b6be74 118242008-02-01 Robert Millan <rmh@aybabtu.com>
11825
11826 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
11827 call at beginning of function.
11828
078522ab 118292008-01-31 Pavel Roskin <proski@gnu.org>
11830
11831 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
d2c11005 11832 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
11833 (grub_mkrescue_SOURCES): Likewise.
078522ab 11834 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
11835
ccaa8a5f 118362008-01-30 Robert Millan <rmh@aybabtu.com>
11837
11838 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
11839 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
11840 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
11841 (grub_probe_SOURCES): ... to here.
11842
11843 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
11844 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
11845 * conf/i386-ieee1275.rmk: Likewise.
11846 * conf/i386-linuxbios.rmk: Likewise.
11847 * conf/powerpc-ieee1275.rmk: Likewise.
11848
ae5a9cd7 118492008-01-30 Tristan Gingold <gingold@free.fr>
11850
11851 * kern/rescue.c: Silently accept empty lines.
11852
70bc2ef2 118532008-01-29 Bean <bean123ch@gmail.com>
11854
11855 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
11856 (real_code_2): Code cleanup and change comment style.
11857 (move_memory): Avoid using 32-bit address mode.
11858
6a4d50ea 118592008-01-29 Bean <bean123ch@gmail.com>
11860
11861 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
11862 (png_mod_SOURCES): New variable.
11863 (png_mod_CFLAGS): Likewise.
11864 (png_mod_LDFLAGS): Likewise.
11865
11866 * video/readers/png.c: New file.
11867
11cc30ac 118682008-01-28 Robert Millan <rmh@aybabtu.com>
11869
11870 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
11871 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
11872 `ifndef GRUB_MOD_GAP' hack.
11873 * util/elf/grub-mkimage.c (add_segments): Likewise.
11874
3abc589f 118752008-01-27 Robert Millan <rmh@aybabtu.com>
11876
11877 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
11878 `GRUB_MOD_GAP' for platforms in which it's not defined.
962ca133 11879 * util/elf/grub-mkimage.c (add_segments): Likewise.
3abc589f 11880
e1907778 118812008-01-27 Robert Millan <rmh@aybabtu.com>
11882
11883 Get grub-emu to build again (including parallel builds).
11884
11885 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
11886 Split into ...
11887 (util/grub-emu.c_DEPENDENCIES): ... this, ...
11888 (normal/execute.c_DEPENDENCIES): ... this, ...
11889 (grub-emu_DEPENDENCIES): ... and this.
11890
11891 * conf/i386-efi.rmk: Likewise.
11892 * conf/i386-linuxbios.rmk: Likewise.
11893 * conf/i386-ieee1275.rmk: Likewise.
11894 * conf/powerpc-ieee1275.rmk: Likewise.
11895 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
11896
2216b101 118972008-01-27 Robert Millan <rmh@aybabtu.com>
11898
11899 * NEWS: Add a few items.
11900
f75172d9 119012008-01-27 Robert Millan <rmh@aybabtu.com>
11902
11903 Fix parallel builds with grub-emu. Based on earlier commit for
11904 grub-probe and grub-setup.
11905
11906 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
11907 (util/grub-emu.c_DEPENDENCIES): ... this.
11908 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
11909 (util/grub-emu.c_DEPENDENCIES): ... this.
11910 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
11911 (util/grub-emu.c_DEPENDENCIES): ... this.
11912 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
11913 (util/grub-emu.c_DEPENDENCIES): ... this.
11914 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
11915 (util/grub-emu.c_DEPENDENCIES): ... this.
11916
3f51de77 119172008-01-27 Pavel Roskin <proski@gnu.org>
11918
11919 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
11920 to create a gap between _end and the modules added to the image
11921 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
11922 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
11923 * util/elf/grub-mkimage.c (add_segments): Likewise.
11924
2033f53e 119252008-01-26 Pavel Roskin <proski@gnu.org>
11926
11927 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
11928 just return an error.
11929
22da1f6f 119302008-01-26 Bean <bean123ch@gmail.com>
11931
11932 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
11933 (grub_reiserfs_get_item): Save offset of the next item.
11934 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
11935
2a9525e6 119362008-01-25 Robert Millan <rmh@aybabtu.com>
11937
11938 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
11939 make all filesystem sources appear together (possibly fixing omissions
11940 while at it).
11941 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11942 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11943 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11944 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11945
11946 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
11947 add `kern/file.c'.
11948 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
11949 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
11950 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
11951 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
11952
11953 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
11954 (probe): Add a sanity check to make sure of our ability to read
11955 requested files when probing for filesystem type.
11956
11957 * genmk.rb: Update copyright year (2007).
11958
11959 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
11960 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
11961 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
11962 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
11963 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
11964 : Remove function prototypes.
11965
b95f71b5 119662008-01-25 Robert Millan <rmh@aybabtu.com>
11967
11968 Revert my previous commits (based on wrong assumption of how grub_errno
11969 works).
11970
fe6b695a 11971 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
b95f71b5 11972 * kern/file.c (grub_file_open): Likewise.
11973
d08bbb49 119742008-01-24 Pavel Roskin <proski@gnu.org>
11975
11976 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
11977 that hang if GRUB tries to setup colors.
11978 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
11979 colors for firmwares that don't support it.
11980 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
11981 Recognize Open Hack'Ware, set flags to work around its
11982 limitations.
11983
605e36ed 119842008-01-24 Robert Millan <rmh@aybabtu.com>
11985
11986 * kern/file.c (grub_file_open): Do not account previous failures of
11987 unrelated functions when grub_errno is checked for.
11988 Reported by Oleg Strikov.
11989
bac332a1 119902008-01-24 Bean <bean123ch@gmail.com>
11991
11992 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
11993 (grub_ufs_sblock): New member volume name.
11994 (grub_ufs_find_file): Fix string copy bug.
11995 (grub_ufs_label): Implement this function properly.
11996
11997 * fs/hfs.c (grub_hfs_cnid_type): New enum.
11998 (grub_hfs_iterate_records): Use the correct file number for extents
11999 and catalog file. Fix problem in next index calculation.
12000 (grub_hfs_find_node): Replace recursive function call with loop.
12001 (grub_hfs_iterate_dir): Replace recursive function call with loop.
12002
15c80c09 120032008-01-23 Robert Millan <rmh@aybabtu.com>
12004
12005 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
12006 `<grub/symbol.h>' and `<grub/multiboot.h>'.
12007 (grub_multiboot2_real_boot): New function prototype.
12008
12009 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
12010 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
12011
12012 * kern/i386/ieee1275/init.c (grub_os_area_addr)
12013 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
12014
305338fd 120152008-01-23 Robert Millan <rmh@aybabtu.com>
12016
12017 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
12018 #ifdef'ed out grub_printf().
12019
3ea52685 120202008-01-23 Robert Millan <rmh@aybabtu.com>
12021
12022 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
12023 grub_dprintf calls, since they make "debug=all" mode unusable.
12024 (grub_console_checkkey): Likewise.
12025
5882ae4b 120262008-01-23 Robert Millan <rmh@aybabtu.com>
12027
12028 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
12029 `term/i386/pc/at_keyboard.c'.
12030 (pkglib_MODULES): Add `serial.mod'.
12031 (serial_mod_SOURCES): New variable.
12032 (serial_mod_CFLAGS): Likewise.
12033 (serial_mod_LDFLAGS): Likewise.
12034
12035 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
12036 `<grub/powerpc/ieee1275/console.h>'.
12037 (grub_keyboard_controller_init): New function prototype.
12038 (grub_console_checkkey): Likewise.
12039 (grub_console_getkey): Likewise.
12040
12041 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
12042 keyboard on i386.
12043
12044 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
12045 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
12046
06ab5303 120472008-01-23 Robert Millan <rmh@aybabtu.com>
12048
12049 * kern/i386/pc/init.c (make_install_device): When memdisk image is
12050 present, "(memdisk)/boot/grub" becomes the default prefix.
12051
12052 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
12053 a memdisk tarball with all the modules. Add --overlay=DIR option that
12054 allows users to overlay additional files into the image.
12055
dbb475a4 120562008-01-23 Robert Millan <rmh@aybabtu.com>
12057
12058 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
12059 and `machine/memory.h'.
12060 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
12061 (_multiboot_mod_SOURCES): New variable.
12062 (_multiboot_mod_CFLAGS): Likewise.
12063 (_multiboot_mod_LDFLAGS): Likewise.
12064 (multiboot_mod_SOURCES): Likewise.
12065 (multiboot_mod_CFLAGS): Likewise.
12066 (multiboot_mod_LDFLAGS): Likewise.
12067
12068 * include/grub/i386/ieee1275/loader.h: New file.
12069
12070 * include/grub/i386/ieee1275/machine.h: Likewise.
12071
12072 * include/grub/i386/ieee1275/memory.h: Likewise.
12073
12074 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
12075 variable declaration.
12076 (grub_os_area_size): Likewise.
12077
12078 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
12079 (grub_lower_mem, grub_upper_mem): New variables.
12080 (grub_stop_floppy): New function (just to make
12081 grub_multiboot2_real_boot() happy).
12082
12083 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
12084 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
12085 (grub_stop): New function.
12086 Include `"../realmode.S"' and `"../loader.S"'.
12087
12088 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
12089 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
12090
12091 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
12092 rely on grub_multiboot2_real_boot() for final boot.
12093
25638629 120942008-01-22 Robert Millan <rmh@aybabtu.com>
12095
12096 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
12097 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
12098 device that doesn't look like an SD card.
12099 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
12100 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
12101 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
12102 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
12103 found.
12104
9dad816d 121052008-01-22 Robert Millan <rmh@aybabtu.com>
12106
12107 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
12108 avoid claiming over our own code.
12109
34842f2d 121102008-01-22 Bean <bean123ch@gmail.com>
12111
12112 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
12113 (jpeg_mod_SOURCES): New variable.
12114 (jpeg_mod_CFLAGS): Likewise.
12115 (jpeg_mod_LDFLAGS): Likewise.
12116
12117 * video/readers/jpeg.c : New file.
12118
44023a28 121192008-01-22 Bean <bean123ch@gmail.com>
12120
12121 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
12122 there are no more items.
12123
bc2d8ac6 121242008-01-21 Robert Millan <rmh@aybabtu.com>
12125
12126 * kern/mm.c (grub_mm_init_region): Improve debug message.
12127
261bd4bc 121282008-01-21 Robert Millan <rmh@aybabtu.com>
12129
12130 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
12131 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
12132 address.
12133 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
12134 a C macro.
12135 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
12136 Indicates start of upper memory.
12137 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
12138 (generate_image): Abort when image size is big enough to corrupt
12139 upper memory.
12140
12141 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
12142 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
12143 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12144 instead of hardcoding 0xA0000.
12145 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
12146 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12147 instead of hardcoding 0xA0000.
12148
f970b55e 121492008-01-21 Robert Millan <rmh@aybabtu.com>
12150
12151 * disk/memdisk.c (memdisk_size): New variable.
12152 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
12153 `memdisk_size'.
12154 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
12155 image to dynamic memory.
12156 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
12157 `memdisk_size'. Free memdisk block.
12158
1a8b0526 121592008-01-21 Robert Millan <rmh@aybabtu.com>
12160
12161 Fix detection of very small filesystems (like tar).
12162
12163 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
12164 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
12165 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
12166 a problem with this disk).
12167
6e9b4aab 121682008-01-21 Robert Millan <rmh@aybabtu.com>
12169
12170 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
12171 on grub_biosdisk_rw_standard() error.
12172
0d8837b2 121732008-01-21 Robert Millan <rmh@aybabtu.com>
12174
12175 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
12176 recent changes.
12177 * kern/elf.c: Likewise.
12178 * kern/ieee1275/ieee1275.c: Likewise.
12179 * kern/powerpc/ieee1275/openfw.c: Likewise.
12180 * term/ieee1275/ofconsole.c: Likewise.
12181
ffd36e34 121822008-01-21 Robert Millan <rmh@aybabtu.com>
12183
12184 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
12185
3f0093d0 12186 * include/grub/kernel.h (grub_arch_memdisk_addr)
12187 (grub_arch_memdisk_size): Moved from here ...
ffd36e34 12188
3f0093d0 12189 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
12190 (grub_arch_memdisk_size): ... to here.
ffd36e34 12191
6c391b21 121922008-01-21 Robert Millan <rmh@aybabtu.com>
12193
12194 Mostly based on bugfix from Bean.
12195
12196 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
12197 attribute with hook() parameter.
12198 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
12199 declaration.
12200 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
12201 attribute with hook() parameter.
12202 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
12203 declaration.
12204
55a581dc 122052008-01-21 Robert Millan <rmh@aybabtu.com>
12206
12207 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
12208 (pkglib_MODULES): Add `memdisk.mod'.
12209 (memdisk_mod_SOURCES): New variable.
12210 (memdisk_mod_CFLAGS): Likewise.
12211 (memdisk_mod_LDFLAGS): Likewise.
12212
12213 * disk/memdisk.c: New file.
12214
12215 * include/grub/disk.h (grub_disk_dev_id): Add
12216 `GRUB_DISK_DEVICE_MEMDISK_ID'.
12217
12218 * include/grub/i386/pc/kernel.h
12219 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
12220 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
12221 (grub_kernel_image_size): New variable declaration.
12222 (grub_total_module_size): Likewise.
12223 (grub_memdisk_image_size): Likewise.
12224
12225 * include/grub/i386/pc/memory.h
12226 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
12227
12228 * include/grub/kernel.h: Include `<grub/symbol.h>'.
12229 (grub_arch_memdisk_addr): New variable declaration.
12230 (grub_arch_memdisk_size): Likewise.
12231
12232 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
12233 (grub_arch_memdisk_size): Likewise.
12234
12235 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
12236 (codestart): Replace hardcoded `0x100000' with
12237 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
12238
12239 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
12240 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
12241 not NULL, append the contents of the file it refers to, at the end of
12242 the compressed kernel image. Initialize `grub_memdisk_image_size'
12243 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
12244 (options): Add "memdisk"|'m' option.
12245 (main): Parse --memdisk|-m option, and pass user-provided path as
12246 parameter to generate_image().
12247
3d7f54c9 122482008-01-20 Robert Millan <rmh@aybabtu.com>
12249
12250 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
12251 grub_dprintf() calls from here ...
12252 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
12253
0bf74728 122542008-01-20 Robert Millan <rmh@aybabtu.com>
12255
12256 Fix detection of "real mode" when /options/real-mode? doesn't exist.
12257
12258 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
12259 declaration.
12260 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
12261 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
12262 `GRUB_IEEE1275_FLAG_REAL_MODE'.
fe6b695a 12263 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
0bf74728 12264 property).
12265 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
12266 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
12267
33bf70a7 122682008-01-19 Robert Millan <rmh@aybabtu.com>
12269
fe6b695a 12270 Get rid of confusing function (superseded by
33bf70a7 12271 `grub_ieee1275_get_integer_property')
12272 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
12273 prototype.
12274 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
12275 function.
12276 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
12277 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
fe987087 12278 in native endianness from grub_ieee1275_get_integer_property().
33bf70a7 12279
e2da7d26 122802008-01-19 Robert Millan <rmh@aybabtu.com>
12281
12282 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
12283 command after "shut-down", since implementations differ on which
12284 the command for halt is.
12285
59f1fd8d 122862008-01-19 Robert Millan <rmh@aybabtu.com>
12287
12288 * include/grub/i386/linuxbios/console.h: Add header protection.
12289 (grub_keyboard_controller_init): New function prototype.
12290 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
12291 (KEYBOARD_COMMAND_READ): Likewise.
12292 (KEYBOARD_COMMAND_WRITE): Likewise.
12293 (KEYBOARD_SCANCODE_SET1): Likewise.
12294 (grub_keyboard_controller_write): New function.
12295 (grub_keyboard_controller_read): Likewise.
12296 (grub_keyboard_controller_init): Likewise.
12297
12298 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
12299 (grub_console_init): On coreboot/LinuxBIOS, call
12300 grub_keyboard_controller_init().
12301
5f5a7c15 123022008-01-19 Robert Millan <rmh@aybabtu.com>
12303
12304 PowerPC changes provided by Pavel Roskin.
12305
12306 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
12307 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
12308 don't rely on cmain() doing it.
12309 * kern/i386/ieee1275/startup.S (_start): Store %eax in
12310 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
12311
1210e168 123122008-01-16 Robert Millan <rmh@aybabtu.com>
12313
12314 * include/grub/i386/linuxbios/memory.h
12315 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
12316 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
12317 receive `table_header' as argument. Instead, probe for it in the
12318 known memory ranges where it can be present.
12319 (grub_available_iterate): Do not pass a fixed `table_header' address
12320 to grub_linuxbios_table_iterate().
12321
3d04eab8 123222008-01-15 Robert Millan <rmh@aybabtu.com>
12323
12324 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
12325 * conf/i386-ieee1275.rmk: New file.
12326 * include/grub/i386/ieee1275/console.h: Likewise.
12327 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
12328 * include/grub/i386/ieee1275/kernel.h: Likewise.
12329 * include/grub/i386/ieee1275/time.h: Likewise.
12330 * kern/i386/ieee1275/init.c: Likewise.
12331 * kern/i386/ieee1275/startup.S: Likewise.
12332
d1bc1b73 123332008-01-15 Robert Millan <rmh@aybabtu.com>
12334
12335 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
12336 when pointers are 32-bit (but still do set it to one when they are
12337 64-bit).
12338
66a65807 123392008-01-15 Robert Millan <rmh@aybabtu.com>
12340
12341 * include/grub/ieee1275/ieee1275.h
12342 (grub_ieee1275_get_integer_property): New function prototype.
12343
12344 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
12345 (grub_ieee1275_get_integer_property): New function. Wraps around
fe987087 12346 grub_ieee1275_get_property() to handle endianness.
66a65807 12347
12348 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
12349 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
fe6b695a 12350 where appropriate.
66a65807 12351 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
12352 (grub_map): Likewise.
12353 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
12354
a83ccafd 123552008-01-15 Bean <bean123ch@gmail.com>
12356
12357 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
12358 (grub_script_execute_cmdline): Reset grub_errno.
12359
12360 * normal/main.c (read_config_file): Reset grub_errno.
12361
12362 * normal/parse.y (script_init): New.
12363 (script): Move function and menuentry here.
12364 (delimiter): New.
12365 (command): Add delimiter at the end of command.
12366 (commands): Adjust to match the new command.
12367 (commandblock): Remove grub_script_lexer_record_start.
f19dbdb7 12368 (menuentry): Add grub_script_lexer_record_start, use the new commands.
a83ccafd 12369 (if): Use the new commands.
12370
12371 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
12372
df6ecfc6 123732008-01-15 Robert Millan <rmh@aybabtu.com>
12374
12375 * normal/menu.c (run_menu): Move timeout message from here ...
12376 (print_timeout): ... to here.
12377 (run_menu): Use print_timeout() once during initial draw to print
12378 the whole message, and again in every clock tick to update only
12379 the number of seconds.
12380
87ae25eb 123812008-01-15 Robert Millan <rmh@aybabtu.com>
12382
12383 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
12384 actual size of `available' from grub_ieee1275_get_property(), and
12385 restrict parsing to that bound.
12386
47bf09a4 123872008-01-15 Christian Franke <franke@computer.org>
12388
12389 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
12390 (argp_program_version): Remove variable.
12391 (argp_program_bug_address): Likewise.
12392 (options): Convert from struct argp_option to struct option.
12393 (struct arguments): Remove.
12394 (parse_opt): Remove.
12395 (usage): New function.
12396 (main): Replace struct args members by simple variables.
12397 Replace argp_parse() by getopt_long().
12398 Add switch to evaluate options.
12399 Add missing "(...)" around root_dev in prefix string.
12400
c86f1469 124012008-01-14 Robert Millan <rmh@aybabtu.com>
12402
12403 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
12404 for grub_ieee1275_exit(), in order to improve portability.
12405
e622c559 124062008-01-14 Robert Millan <rmh@aybabtu.com>
12407
12408 * util/grub.d/10_linux.in (prefix): Define.
12409 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
12410
44cb1ec8 124112008-01-13 Pavel Roskin <proski@gnu.org>
12412
12413 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
12414 grub_errno if no errors have been detected.
12415
1eb8c802 124162008-01-12 Robert Millan <rmh@aybabtu.com>
12417
12418 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
12419 (grub_util_get_dev_abstraction): New function prototype.
12420
12421 * util/getroot.c: Include `<grub/util/getroot.h>'
12422 (grub_util_get_grub_dev): Move detection of abstraction type to ...
12423 (grub_util_get_dev_abstraction): ... here (new function).
12424
12425 * util/grub-probe.c: Convert PRINT_* to an enum. Add
12426 `PRINT_ABSTRACTION'.
12427 (probe): Probe for abstraction type when requested.
12428 (main): Understand `--target=abstraction'.
12429
12430 * util/i386/efi/grub-install.in: Add abstraction module to core
12431 image when it is found to be necessary.
12432 * util/i386/pc/grub-install.in: Likewise.
12433 * util/powerpc/ieee1275/grub-install.in: Likewise.
12434
12435 * util/update-grub_lib.in (font_path): Return system path without
12436 converting to GRUB path.
12437 * util/update-grub.in: Convert system path returned by font_path()
12438 to a GRUB path. Use `grub-probe -t abstraction' to determine what
12439 abstraction module is needed for loading fonts (if any). Export
12440 that as `GRUB_PRELOAD_MODULES'.
12441 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
12442 insmod commands).
12443
52bd3de9 124442008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
12445
12446 Remove some unused code from reiserfs.
f19dbdb7 12447
52bd3de9 12448 * fs/reiserfs.c (struct grub_reiserfs_key)
12449 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
12450 (struct grub_reiserfs_node_body): Removed.
12451 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12452 Likewise.
12453 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12454 Likewise.
12455 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12456 Likewise.
12457 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12458 Likewise.
12459 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12460 Likewise.
12461 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
12462 Likewise.
12463 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12464 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12465 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12466
2f80039d 124672008-01-10 Robert Millan <rmh@aybabtu.com>
12468
12469 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
12470 Determines if a file is garbage left by packaging systems, etc.
12471 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
12472 for processing /etc/grub.d scripts.
12473 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
12474 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
12475 as a condition for processing Linux images.
12476
87888032 124772008-01-10 Pavel Roskin <proski@gnu.org>
12478
12479 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
12480 to compile reiserfs.c on PowerPC.
12481
7e54fced 124822008-01-10 Robert Millan <rmh@aybabtu.com>
de9993e0 12483
12484 * kern/device.c (grub_device_iterate): Do not abort device iteration
12485 when one of the devices cannot be opened.
12486 * kern/disk.c (grub_disk_open): Do not account previous failures of
12487 unrelated functions when grub_errno is checked for.
12488
5aa541e6 124892008-01-08 Robert Millan <rmh@aybabtu.com>
12490
12491 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
12492 `! grub_linux_is_bzimage', change order of address comparison to make
12493 it more intuitive, and improve "too big zImage" error message.
12494
7076340d 124952008-01-08 Robert Millan <rmh@aybabtu.com>
12496
12497 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
12498 `$(update-grub_DATA)'.
12499 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
12500 targets.
12501
9ca70333 125022008-01-07 Robert Millan <rmh@aybabtu.com>
12503
12504 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
12505 which instruction is modified by grub-setup during installation
12506 (since it wasn't obvious by only looking at this file).
12507
38ccf575 125082008-01-07 Robert Millan <rmh@aybabtu.com>
12509
12510 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
12511 listing actual TODO items.
12512
f5db4291 125132008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12514
868967cf 12515 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
12516 correctly.
12517 (grub_reiserfs_get_key_offset): Likewise.
12518 (grub_reiserfs_set_key_offset): Likewise.
12519 (grub_reiserfs_set_key_type): Likewise.
fe6b695a 12520 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
868967cf 12521
12522 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
12523 better to remove the bitfield version completely.
f19dbdb7 12524
868967cf 125252008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 12526
f5db4291 12527 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
12528 allocated from the heap, due to the fshelp implementation.
12529 (grub_reiserfs_dir): Free NODE, due to the same reason.
12530
492e6d9d 125312008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12532
12533 Mostly from Vincent Pelletier:
f19dbdb7 12534
492e6d9d 12535 * fs/reiserfs.c: New file.
f19dbdb7 12536
492e6d9d 12537 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
12538 (reiserfs_mod_SOURCES): New variable.
12539 (reiserfs_mod_CFLAGS): Likewise.
12540 (reiserfs_mod_LDFLAGS): Likewise.
12541
12542 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
12543 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
12544 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
12545 normal/color.c.
12546
9ce3e7c1 125472008-01-06 Robert Millan <rmh@aybabtu.com>
12548
12549 * normal/color.c: Remove `<grub/env.h>'.
12550
f3b58148 125512008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
12552
12553 * include/grub/normal.h: Include <grub/env.h>.
12554
7ac3bcfa 125552008-01-05 Robert Millan <rmh@aybabtu.com>
12556
12557 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
12558 usage example with `(hd0,1)'.
fb358190 12559 Reported by Samuel Thibault.
7ac3bcfa 12560
c8ee99d7 125612008-01-05 Robert Millan <rmh@aybabtu.com>
12562
12563 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
12564 (grub_linux_boot_zimage): Rename to ...
12565 (grub_linux_boot): ... this.
12566 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
12567 (grub_linux_boot_zimage): Conditionalize zImage copy.
12568
12569 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
12570 (grub_linux_boot_bzimage): Remove prototype.
12571 (grub_linux_boot_zimage): Rename to ...
12572 (grub_linux_boot): ... this.
12573
12574 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
12575 (grub_linux_boot): Remove function.
12576
0ece25b1 125772008-01-05 Robert Millan <rmh@aybabtu.com>
12578
12579 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
12580 (grub_env_write_color_highlight): Likewise.
12581 (grub_wait_after_message): Likewise.
12582
12583 * normal/color.c: New file.
12584
12585 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12586 (normal_mod_DEPENDENCIES): Likewise.
12587
12588 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12589 (normal_mod_DEPENDENCIES): Likewise.
12590
12591 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12592 (normal_mod_DEPENDENCIES): Likewise.
12593
12594 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12595 (normal_mod_DEPENDENCIES): Likewise.
12596
12597 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
12598 for waiting after a message is printed.
12599 * normal/main.c (read_config_file): Likewise.
12600 (grub_normal_init): Register grub_env_write_color_normal() and
12601 grub_env_write_color_highlight() hooks. Mark `color_normal' and
12602 `color_highlight' variables as global.
12603
12604 * normal/menu.c (grub_wait_after_message): New function.
12605 (grub_color_menu_normal): New variable. Replaces ...
12606 (GRUB_COLOR_MENU_NORMAL): ... this macro.
12607 (grub_color_menu_highlight): New variable. Replaces ...
12608 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
12609 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
12610 `GRUB_TERM_COLOR_STANDARD'.
12611 (print_message): Use `grub_setcolorstate' to reload colors. Rename
12612 `normal_code' and `highlight_code' to `old_color_normal' and
12613 `old_color_highlight', respectively.
12614 (grub_menu_init_page): Update colors when drawing the menu, based on
12615 `menu_color_normal' and `menu_color_highlight' variables.
12616 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
12617 a message is printed.
12618
182dd4e5 126192008-01-05 Robert Millan <rmh@aybabtu.com>
12620
12621 * kern/env.c (grub_env_context_open): Propagate hooks for global
12622 variables to new context.
12623
12624 * kern/main.c (grub_set_root_dev): Export `root' variable.
12625
ddf8f6ad 126262008-01-05 Robert Millan <rmh@aybabtu.com>
12627
12628 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
fe6b695a 12629 discs unconditionally, since udev and others have options to provide
ddf8f6ad 12630 them.
12631
d8b43d9b 126322008-01-05 Robert Millan <rmh@aybabtu.com>
12633
12634 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
12635
2bff2de3 126362008-01-04 Christian Franke <franke@computer.org>
12637
12638 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
12639 of eisa_mmap.
12640
97eab917 126412008-01-03 Pavel Roskin <proski@gnu.org>
12642
12643 * kern/i386/linuxbios/init.c: Put "void" to all function
12644 declarations with no arguments.
12645 * kern/powerpc/ieee1275/init.c: Likewise.
12646 * term/i386/pc/at_keyboard.c: Likewise.
12647 * term/i386/pc/vga_text.c: Likewise.
12648 * util/grub-mkdevicemap.c: Likewise.
12649
b9416d00 126502008-01-02 Robert Millan <rmh@aybabtu.com>
12651
12652 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
12653 message when loaded image is out of bounds.
12654 (grub_multiboot_load_elf64): Likewise.
12655
92695df9 126562008-01-02 Pavel Roskin <proski@gnu.org>
12657
12658 * util/grub.d/10_linux.in: Try version without ".old" when
12659 looking for initrd. It's better to use initrd from the newer
12660 kernel of the same version than no initrd at all.
12661
d98d9cad 126622008-01-01 Robert Millan <rmh@aybabtu.com>
12663
12664 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
12665
dbfdce36 126662008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
12667
f19dbdb7 12668 * include/grub/video.h: Added grub_video_unmap_color and
dbfdce36 12669 grub_video_get_active_render_target.
12670 (grub_video_adapter): Added unmap_color and get_active_render_target.
12671
f19dbdb7 12672 * video/video.c: Added grub_video_unmap_color and
dbfdce36 12673 grub_video_get_active_render_target.
12674 (grub_video_get_info): Changed method to accept NULL pointer as an
12675 argument to allow detection of active video adapter.
12676
12677 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
12678 grub_video_vbe_unmap_color_int.
12679 Added grub_video_vbe_unmap_color and
12680 grub_video_vbe_get_active_render_target.
12681 (grub_video_vbe_adapter): Added unmap_color and
12682 get_active_render_target.
12683
f19dbdb7 12684 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
dbfdce36 12685 with grub_video_vbe_unmap_color_int.
12686
12687 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
12688 (DEFAULT_NORMAL_COLOR): Likewise.
12689 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
12690 (DEFAULT_FG_COLOR): Removed.
12691 (DEFAULT_BG_COLOR): Likewise.
12692 (DEFAULT_CURSOR_COLOR): Changed value.
12693 (grub_virtual_screen): Added standard_color_setting,
12694 normal_color_setting, highlight_color_setting and term_color.
12695 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
12696 (bitmap_width): Added.
12697 (bitmap_height): Likewise.
12698 (bitmap): Likewise.
12699 (set_term_color): Likewise.
12700 (grub_virtual_screen_setup): Changed to use new terminal coloring
12701 settings.
12702 (grub_gfxterm_init): Added init for bitmap.
12703 (grub_gfxterm_fini): Added destroy for bitmap.
12704 (redraw_screen_rect): Updated to use background bitmap and new
12705 terminal coloring.
12706 (scroll_up): Added optimization for case when there is no bitmap.
12707 (grub_gfxterm_cls): Fixed to use correct background color.
12708 (grub_virtual_screen_setcolorstate): Changed to use new terminal
12709 coloring.
12710 (grub_virtual_screen_setcolor): Likewise.
12711 (grub_virtual_screen_getcolor): Added.
12712 (grub_gfxterm_background_image_cmd): Likewise.
12713 (grub_video_term): Added setcolor and getcolor.
12714 (MOD_INIT): Added registration of background_image command.
12715 (MOD_TERM): Added unregistration for background_image command.
12716
c3c20931 127172007-12-30 Pavel Roskin <proski@gnu.org>
12718
12719 * loader/multiboot_loader.c: Fix multiboot command
12720 unregistration. Fix all typos in the word "multiboot".
12721
df266716 127222007-12-29 Pavel Roskin <proski@gnu.org>
94239199 12723
12724 * util/grub.d/10_linux.in: Refactor search for initrd. Add
12725 support for initrd names used in Fedora.
12726
fc6e896c 127272007-12-26 Bean <bean123ch@gmail.com>
12728
12729 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
12730 (cpio_mod_SOURCES): New variable.
12731 (cpio_mod_CFLAGS): Likewise.
12732 (cpio_mod_LDFLAGS): Likewise.
12733
12734 * fs/cpio.c: New file.
12735
12736 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
12737
12738 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
12739
12740 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
12741
12742 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12743
533110ad 127442007-12-25 Robert Millan <rmh@aybabtu.com>
12745
12746 * include/grub/term.h (struct grub_term): Add `getcolor' function.
12747 (grub_getcolor): New function.
12748
12749 * kern/term.c (grub_getcolor): New function.
12750 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
12751 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
12752 (print_entry): Set normal and highlight colors to
12753 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
12754 respectively, before printing and restore them to old
12755 values afterwards.
12756 (grub_menu_init_page): Likewise. Fill an additional colored space
12757 that would otherwise be left blank.
12758
12759 * term/efi/console.c (grub_console_getcolor): New function.
12760 (struct grub_console_term.getcolor): New variable.
12761 * term/i386/pc/console.c (grub_console_getcolor): New function.
12762 (struct grub_console_term.getcolor): New variable.
12763 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
12764 (struct grub_console_term.getcolor): New variable.
12765
12766 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
12767 (struct grub_console_term.setcolor): Remove variable.
12768 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
12769 (struct grub_console_term.setcolor): Remove variable.
12770 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
12771 (struct grub_console_term.setcolor): Remove variable.
12772 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
12773 (struct grub_console_term.setcolor): Remove variable.
12774
4931827f 127752007-12-25 Robert Millan <rmh@aybabtu.com>
12776
12777 * configure.ac: Search for possible unifont.hex locations, and
12778 define UNIFONT_HEX if found.
12779
12780 * Makefile.in (UNIFONT_HEX): Define variable.
12781 (DATA): Rename to ...
12782 (PKGLIB): ... this. Update all users.
12783 (PKGDATA): New variable.
12784 (pkgdata_IMAGES): Rename to ...
12785 (pkglib_IMAGES): ... this. Update all users.
12786 (pkgdata_MODULES): Rename to ...
12787 (pkglib_MODULES): ... this. Update all users.
12788 (pkgdata_PROGRAMS): Rename to ...
12789 (pkglib_PROGRAMS): ... this. Update all users.
12790 (pkgdata_DATA): Rename to ...
12791 (pkglib_DATA): ... this. Update all users.
12792 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
12793 (unicode.pff, ascii.pff): New rules.
12794 (all-local): Add `$(PKGDATA)' dependency.
12795 (install-local): Process `$(PKGDATA)'.
12796
12797 * util/update-grub_lib.in (font_path): Search for *.pff files in
12798 a few more locations, including `${pkgdata}'.
12799
57e57e31 128002007-12-23 Robert Millan <rmh@aybabtu.com>
12801
12802 Patch from Bean <bean123ch@gmail.com>:
12803 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
12804 `size'.
12805
4bc72aa9 128062007-12-21 Bean <bean123ch@gmail.com>
12807
12808 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
12809 (ntfscomp_mod_SOURCES): New variable.
12810 (ntfscomp_mod_CFLAGS): Likewise.
12811 (ntfscomp_mod_LDFLAGS): Likewise.
12812
12813 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
12814 (grub_probe_SOURCES): Likewise.
12815 (grub_emu_SOURCES): Likewise.
12816
12817 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
12818 (grub_emu_SOURCES): Likewise.
12819
12820 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
12821 (grub_emu_SOURCES): Likewise.
12822
12823 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
12824 (grub_emu_SOURCES): Likewise.
12825
12826 * fs/ntfs.c (grub_ntfscomp_func): New variable.
12827 (read_run_list): Renamed to grub_ntfs_read_run_list.
12828 (decomp_nextvcn): Moved to ntfscomp.c.
12829 (decomp_getch): Likewise.
12830 (decomp_get16): Likewise.
12831 (decomp_block): Likewise.
12832 (read_block): Likewise.
12833 (read_data): Partially moved to ntfscomp.c.
12834 (fixup): Change unsigned to grub_uint16_t.
12835 (read_mft): Change unsigned long to grub_uint32_t.
12836 (read_attr): Likewise.
12837 (read_data): Likewise.
12838 (read_run_data): Likewise.
12839 (read_run_list): Likewise.
12840 (read_mft): Likewise.
12841
12842 * fs/ntfscomp.c: New file.
12843
12844 * include/grub/ntfs.h: New file.
12845
af680a87 128462007-12-16 Robert Millan <rmh@aybabtu.com>
12847
12848 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
12849 IDE disk check, since Linux is known to support 20 IDE disks.
12850 Reported by Colin Watson.
12851
84be7599 128522007-12-15 Bean <bean123ch@gmail.com>
12853
12854 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
12855 (lnxboot_img_SOURCES): New variable.
12856 (lnxboot_img_ASFLAGS): Likewise.
12857 (lnxboot_img_LDFLAGS): Likewise.
12858
12859 * boot/i386/pc/lnxboot.S: New file.
12860
6af9db01 128612007-11-24 Pavel Roskin <proski@gnu.org>
12862
12863 * configure.ac: Test if '--build-id=none' is supported by the
12864 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
12865 objcopy to generate incorrect binary files (binutils
12866 2.17.50.0.18-1 as shipped by Fedora 8).
12867 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
12868 linking, so that build ID doesn't break the test.
12869
7361cfe6 128702007-11-24 Pavel Roskin <proski@gnu.org>
12871
12872 * include/grub/i386/time.h: use "void" in the argument list
12873 of grub_cpu_idle().
12874 * include/grub/powerpc/time.h: Likewise.
12875 * include/grub/sparc64/time.h: Likewise.
12876
1593e10c 128772007-11-18 Christian Franke <franke@computer.org>
12878
12879 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
12880 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
12881 This fixes the problem that function keys did not work in grub-emu.
12882
3b8db1a8 128832007-11-18 Christian Franke <franke@computer.org>
12884
12885 * disk/host.c (grub_host_open): Remove attribute unused from
12886 name parameter. Add check for "host". This fixes the problem
12887 that grub-emu does not find partitions.
12888
2e29408d 128892007-11-18 Christian Franke <franke@computer.org>
12890
12891 * util/hostfs.c (is_dir): New function.
12892 (grub_hostfs_dir): Handle missing dirent.d_type case.
12893 (grub_hostfs_read): Add missing fseek().
12894 (grub_hostfs_label): Clear label pointer. This fixes a crash
12895 of grub-emu on "ls (host)".
12896
398cd047 128972007-11-18 Christian Franke <franke@computer.org>
12898
12899 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
12900 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
12901 to 64 bit boundary by default.
12902
c405c391 129032007-11-18 Bean <bean123ch@gmail.com>
12904
12905 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
12906 (hexdump_mod_SOURCES): New variable.
12907 (hexdump_mod_CFLAGS): Likewise.
12908 (hexdump_mod_LDFLAGS): Likewise.
f19dbdb7 12909
c405c391 12910 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
12911
12912 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
12913
12914 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
12915
12916 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
12917
12918 * include/grub/hexdump.h: New file.
12919
12920 * commands/hexdump.c: New file.
12921
5cced7fd 129222007-11-10 Robert Millan <rmh@aybabtu.com>
12923
12924 * commands/i386/pc/play.c (beep_off): Switch order of arguments
12925 in grub_outb() calls.
12926 (beep_on): Likewise.
12927
8b714eb0 129282007-11-10 Christian Franke <franke@computer.org>
12929
12930 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
12931 (grub_menu_run): Likewise.
12932
ce0f1839 129332007-11-10 Robert Millan <rmh@aybabtu.com>
12934
12935 * include/grub/i386/efi/machine.h: New file.
12936 * include/grub/i386/linuxbios/machine.h: Likewise.
12937 * include/grub/i386/pc/machine.h: Likewise.
12938 * include/grub/powerpc/ieee1275/machine.h: Likewise.
12939 * include/grub/sparc64/ieee1275/machine.h: Likewise.
12940
12941 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
12942 (serial_hw_io_addr): New variable.
12943 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
12944 instead of `(unsigned short *) 0x400'.
12945
270c237d 129462007-11-10 Bean <bean123ch@gmail.com>
12947
12948 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
12949
a87783bf 129502007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
12951
12952 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
12953 (vga_mod_SOURCES): Added.
12954 (vga_mod_CFLAGS): Likewise.
12955 (vga_mod_LDFLAGS): Likewise.
12956
12957 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
12958 grub_outb() calls.
12959 (set_map_mask): Likewise.
12960 (set_read_map): Likewise.
12961 (set_read_address): Likewise.
12962 (vga_font): Removed variable.
12963 (get_vga_glyph): Removed function.
12964 (invalidate_char): Likewise.
12965 (write_char): Changed to use grub_font_get_glyph() for font
12966 information.
12967 (grub_vga_putchar): Likewise.
12968 (grub_vga_getcharwidth): Likewise.
12969
6433b448 129702007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
12971
12972 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
12973 flags.
12974 (pxeboot_img_LDFLAGS): Likewise.
12975 (diskboot_img_LDFLAGS): Likewise.
12976 (kernel_img_LDFLAGS): Likewise.
12977
49178511 129782007-11-06 Robert Millan <rmh@aybabtu.com>
12979
12980 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
12981 in grub_outb() calls.
12982 (serial_hw_init): Likewise.
12983
53b052de 129842007-11-05 Robert Millan <rmh@aybabtu.com>
12985
12986 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
12987 spaces. Skip non-regular files.
12988
5ab33bba 129892007-11-05 Robert Millan <rmh@aybabtu.com>
12990
12991 * kern/disk.c (grub_disk_firmware_fini)
12992 (grub_disk_firmware_is_tainted): New variables.
12993
12994 * include/grub/disk.h (grub_disk_firmware_fini)
12995 (grub_disk_firmware_is_tainted): Likewise.
12996
12997 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
12998 (grub_disk_biosdisk_fini): ... to here.
12999 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
13000 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
13001 is set. Register grub_disk_biosdisk_fini() in
13002 `grub_disk_firmware_fini'.
13003
13004 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
13005 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
13006 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
13007 to finish existing firmware disk interface.
13008
13009 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
13010 (ata_mod_SOURCES): New variable.
13011 (ata_mod_CFLAGS): Likewise.
13012 (ata_mod_LDFLAGS): Likewise.
13013
0149ab7c 130142007-11-05 Robert Millan <rmh@aybabtu.com>
13015
13016 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
13017 (grub_ata_wait): Reimplement using grub_millisleep().
13018
13019 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
13020 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
13021
be7ac41e 130222007-11-03 Marco Gerards <marco@gnu.org>
13023
13024 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
13025 (CRTC_ADDR_PORT): New macro.
13026 (CRTC_DATA_PORT): Likewise.
13027 (CRTC_CURSOR): Likewise.
13028 (CRTC_CURSOR_ADDR_HIGH): Likewise.
13029 (CRTC_CURSOR_ADDR_LOW): Likewise.
13030 (update_cursor): New function.
13031 (grub_console_real_putchar): Call `update_cursor'.
13032 (grub_console_gotoxy): Likewise.
13033 (grub_console_cls): Set the default color when clearing the
13034 screen.
13035 (grub_console_setcursor): Implemented.
13036
bb06ab2e 130372007-11-03 Marco Gerards <marco@gnu.org>
13038
13039 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
13040 become activate.
13041 (grub_ata_pio_write): Likewise.
13042
13043 (grub_atapi_identify): Wait after issuing an ATA command.
13044 (grub_atapi_packet): Likewise.
13045 (grub_ata_identify): Likewise.
13046 (grub_ata_readwrite): Likewise.
13047
cf8f780b 130482007-11-03 Marco Gerards <marco@gnu.org>
13049
13050 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
13051 (grub_ata_pio_write): Likewise.
13052 (grub_ata_readwrite): Use `grub_error', instead of
13053 returning `grub_errno'.
13054
ed649e54 130552007-11-03 Marco Gerards <marco@gnu.org>
13056
13057 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
13058 grub_ata_pio_write once for every single sector, instead of for
13059 multiple sectors.
13060
ca25d8f0 130612007-10-31 Robert Millan <rmh@aybabtu.com>
13062
13063 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
13064
13065 * conf/i386-linuxbios.rmk: New file.
13066
13067 * kern/i386/pc/hardware.c: Likewise.
13068 * term/i386/pc/at_keyboard.c: Likewise.
13069 * term/i386/pc/vga_text.c: Likewise.
13070
13071 * include/grub/i386/linuxbios/boot.h: Likewise.
13072 * include/grub/i386/linuxbios/console.h: Likewise.
13073 * include/grub/i386/linuxbios/init.h: Likewise.
13074 * include/grub/i386/linuxbios/kernel.h: Likewise.
13075 * include/grub/i386/linuxbios/loader.h: Likewise.
13076 * include/grub/i386/linuxbios/memory.h: Likewise.
13077 * include/grub/i386/linuxbios/serial.h: Likewise.
13078 * include/grub/i386/linuxbios/time.h: Likewise.
13079
13080 * kern/i386/linuxbios/init.c: Likewise.
13081 * kern/i386/linuxbios/startup.S: Likewise.
13082 * kern/i386/linuxbios/table.c: Likewise.
13083
e911ecc1 130842007-10-31 Marco Gerards <marco@gnu.org>
13085
13086 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
13087 (ata_mod_SOURCES): New variable.
13088 (ata_mod_CFLAGS): Likewise.
13089 (ata_mod_LDFLAGS): Likewise.
13090
13091 * disk/ata.c: New file.
13092
13093 * include/grub/disk.h (grub_disk_dev_id): Add
13094 `GRUB_DISK_DEV_ATA_ID'.
f19dbdb7 13095
7f66d0e0 130962007-10-31 Robert Millan <rmh@aybabtu.com>
13097
13098 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
13099 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
13100
13101 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
13102 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
13103
13104 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
13105 `<grub/types.h>'.
13106
13107 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
13108
5cd7dd46 131092007-10-27 Robert Millan <rmh@aybabtu.com>
13110
3236ca65 13111 * include/grub/types.h (ULONG_MAX): Define macro.
5cd7dd46 13112
2ebfc90f 131132007-10-22 Robert Millan <rmh@aybabtu.com>
13114
13115 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
13116 `"../realmode.S"'.
13117 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
13118
73fcb0f3 131192007-10-22 Robert Millan <rmh@aybabtu.com>
13120
13121 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
13122 (pkgdata_MODULES): Add `biosdisk.mod'.
13123 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
13124 variables.
13125
13126 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
13127 (grub_biosdisk_init): Replace with ...
13128 (GRUB_MOD_INIT(biosdisk)): ... this.
13129 (grub_biosdisk_fini): Replace with ...
13130 (GRUB_MOD_FINI(biosdisk)): ... this.
13131
13132 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
13133 (grub_machine_init): Remove call to grub_biosdisk_init().
13134 (grub_machine_fini): Remove call to grub_machine_fini().
13135
13136 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
13137
3381d274 131382007-10-22 Robert Millan <rmh@aybabtu.com>
13139
13140 * include/grub/time.h: New file.
13141 * include/grub/i386/time.h: Likewise.
13142 * include/grub/powerpc/time.h: Likewise.
13143 * include/grub/sparc64/time.h: Likewise.
13144
13145 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
13146 instances to ...
13147 (KERNEL_MACHINE_TIME_HEADER): ... this.
13148 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13149 instances to ...
13150 (KERNEL_MACHINE_TIME_HEADER): ... this.
13151 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13152 instances to ...
13153 (KERNEL_MACHINE_TIME_HEADER): ... this.
13154
13155 * kern/i386/efi/init.c: Include `<grub/time.h>'.
13156 (grub_millisleep): New function.
13157 * kern/i386/pc/init.c: Include `<grub/time.h>'.
13158 (grub_millisleep): New function.
13159 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
13160 Remove `grub/machine/time.h' include.
13161 (grub_millisleep): New function.
13162 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
13163 Remove `grub/machine/time.h' include.
13164 (grub_millisleep): New function.
13165
13166 * include/grub/misc.h (grub_div_roundup): New function.
13167
13168 * kern/misc.c: Include `<grub/time.h>'.
13169 (grub_millisleep_generic): New function.
13170
13171 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
13172 Add `time.h'.
13173 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
13174 Add `time.h'.
13175 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
13176 `machine/time.h'. Add `time.h'.
13177 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
13178
a39a0312 131792007-10-21 Robert Millan <rmh@aybabtu.com>
13180
13181 * include/grub/misc.h (grub_max): New function.
13182
2aad70e2 131832007-10-21 Robert Millan <rmh@aybabtu.com>
13184
13185 * util/misc.c (grub_util_info): Call fflush() before returning.
13186
54b71c4b 131872007-10-20 Robert Millan <rmh@aybabtu.com>
13188
13189 * genmk.rb (Image): Copy `extra_flags' from here ...
13190 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
13191
13192 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
13193 to `argc' and `args' arguments.
13194
a979f513 131952007-10-17 Robert Millan <rmh@aybabtu.com>
13196
13197 * kern/i386/loader.S: New file.
13198
13199 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
13200 * kern/i386/loader.S (grub_linux_prot_size)... to here.
13201 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
13202 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
13203 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
13204 * kern/i386/loader.S (grub_linux_real_addr)... to here.
13205 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
13206 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
13207 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
13208 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
13209 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
13210 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
13211 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
13212 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
13213
13214 * kern/i386/realmode.S: New file.
13215
13216 * kern/i386/pc/startup.S (protstack): Moved from here ...
13217 * kern/i386/realmode.S (protstack)... to here.
13218 * kern/i386/pc/startup.S (gdt): Moved from here ...
13219 * kern/i386/realmode.S (gdt)... to here.
13220 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
13221 * kern/i386/realmode.S (prot_to_real)... to here.
13222
13223 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
13224 `kern/i386/realmode.S'.
13225
825fc8fd 132262007-10-17 Robert Millan <rmh@aybabtu.com>
13227
13228 * include/grub/i386/loader.h: New file.
13229
13230 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
13231 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13232 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13233 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13234 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
13235 * include/grub/i386/loader.h (grub_linux_prot_size)
13236 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13237 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13238 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13239 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
13240
13241 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
13242
e179b2f4 132432007-10-15 Robert Millan <rmh@aybabtu.com>
13244
13245 * normal/misc.c (grub_normal_print_device_info): Do not probe for
13246 filesystem when dev->disk is unset.
13247 Do probe for filesystem even when dev->disk->has_partitions is set.
13248 In case a filesystem is found, always report it.
13249 In case it isn't, if dev->disk->has_partitions is set, report that
13250 a partition table was found instead of reporting that no filesystem
13251 could be identified.
13252
5db82af6 132532007-10-12 Robert Millan <rmh@aybabtu.com>
13254
13255 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
13256 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
13257
68f6ac74 13258 * include/grub/types.h (grub_host_to_target16): New macro.
13259 (grub_host_to_target32): Likewise.
13260 (grub_host_to_target64): Likewise.
13261 (grub_target_to_host16): Likewise.
13262 (grub_target_to_host32): Likewise.
13263 (grub_target_to_host64): Likewise.
5db82af6 13264
13265 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
13266 Renamed from to ...
13267 (GRUB_MOD_ALIGN): ...this. Update all users.
13268
68f6ac74 13269 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
13270 grub_host_to_target32.
13271 Replace grub_be_to_cpu32 with grub_target_to_host32.
13272 (load_modules): Likewise.
13273 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
13274 Replace grub_be_to_cpu32 with grub_target_to_host32.
13275 Replace grub_cpu_to_be16 with grub_host_to_target16.
13276 Replace grub_cpu_to_be32 grub_host_to_target32.
5db82af6 13277
3cf497cc 132782007-10-12 Robert Millan <rmh@aybabtu.com>
13279
13280 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
13281 * util/elf/grub-mkimage.c: ... here.
13282
13283 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
13284 `util/powerpc/ieee1275/grub-mkimage.c'.
13285
c8cc3692 132862007-10-07 Robert Millan <rmh@aybabtu.com>
adbc4c9d 13287
c8cc3692 13288 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
13289 and make it easier to figure out.
13290 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
13291 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
13292 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
13293 leave us with less than HEAP_MIN_SIZE total heap.
13294 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
adbc4c9d 13295
5c58b791 132962007-10-03 Robert Millan <rmh@aybabtu.com>
13297
13298 * include/grub/i386/io.h: New file.
13299 * commands/i386/pc/play.c (inb): Removed.
13300 (outb): Removed.
13301 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13302 with grub_outb().
afcd2ef8 13303 * term/i386/pc/serial.c (inb): Removed.
13304 (outb): Removed.
13305 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13306 with grub_outb().
13307 * term/i386/pc/vga.c (inb): Removed.
13308 (outb): Removed.
13309 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13310 with grub_outb().
5c58b791 13311
1a477ed6 133122007-10-02 Robert Millan <rmh@aybabtu.com>
13313
13314 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
13315 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13316 Reported by Marcin Kurek.
13317
6b5d80fa 133182007-09-07 Robert Millan <rmh@aybabtu.com>
13319
13320 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
13321 SmartFirmware version updates (as released by Sven Luther), and avoid
13322 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
13323 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
13324 known broken.
13325
5618afbf 133262007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13327
13328 From Hitoshi Ozeki:
13329 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
13330 when merging two regions.
13331
6139dcd9 133322007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13333
508e39ee 13334 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
13335 * normal/completion.c (grub_normal_do_completion): Likewise.
13336 Reported by Hitoshi Ozeki.
13337
133382007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 13339
6139dcd9 13340 Do not use devices at boot in chainloading.
f19dbdb7 13341
6139dcd9 13342 * loader/i386/pc/chainloader.c (boot_drive): New variable.
13343 (boot_part_addr): Likewise.
13344 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
13345 with BOOT_DRIVE and BOOT_PART_ADDR.
13346 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
13347 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
13348
38da6516 133492007-08-29 Robert Millan <rmh@aybabtu.com>
13350
13351 Patch from Simon Peter <dn.tlp@gmx.net>:
13352 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
13353 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
13354 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
13355 util/i386/pc/grub-setup.c_DEPENDENCIES.
13356 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
13357 util/grub-probe.c_DEPENDENCIES.
13358 * conf/powerpc-ieee1275.rmk: Likewise.
13359
29d0928c 133602007-08-28 Robert Millan <rmh@aybabtu.com>
13361
13362 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
13363 to tell grub-mkdevicemap how to name devices.
13364 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
13365 feature).
13366
13367 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
13368 util/i386/get_disk_name.c.
13369 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
13370 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
13371 util/ieee1275/get_disk_name.c.
13372
13373 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
13374
13375 * DISTLIST: Add util/i386/get_disk_name.c and
13376 util/ieee1275/get_disk_name.c.
13377
13378 * util/grub-mkdevicemap.c: Replace device naming logic with
13379 grub_util_get_disk_name() calls.
13380
5a0d3cca 133812007-08-20 Robert Millan <rmh@aybabtu.com>
13382
13383 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
13384 (so that it works for both plural and singular quantities).
13385
8b72db2f 133862007-08-05 Robert Millan <rmh@aybabtu.com>
13387
13388 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
13389 so that [xz] isn't taken into account when determining order.
13390
352466bf 133912007-08-02 Marco Gerards <marco@gnu.org>
13392
13393 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
13394 `include/multiboot2.h', `include/grub/elfload.h',
13395 `include/multiboot.h', `include/grub/multiboot.h',
13396 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
13397 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
13398 `kern/elf.c', `loader/multiboot_loader.c',
13399 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
13400 `loader/i386/pc/multiboot2.c',
13401 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
13402 `util/i386/pc/grub-mkrescue.in'. Remove
13403 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
13404 `include/grub/i386/pc/util/biosdisk.h' and
13405 `include/grub/powerpc/ieee1275/multiboot.h'.
13406
8f096014 134072007-08-02 Bean <bean123ch@gmail.com>
13408
13409 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
13410 (ntfs_mod_SOURCES): New variable.
13411 (ntfs_mod_CFLAGS): Likewise.
13412 (ntfs_mod_LDFLAGS): Likewise.
13413
13414 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
13415 (grub_probe_SOURCES): Likewise.
13416 (grub_emu_SOURCES): Likewise.
13417
13418 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13419 (grub_emu_SOURCES): Likewise.
13420
13421 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13422 (grub_emu_SOURCES): Likewise.
f19dbdb7 13423
8f096014 13424 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
13425
13426 * fs/ntfs.c: New file.
13427
9959f7db 134282007-08-02 Bean <bean123ch@gmail.com>
13429
13430 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
13431
13432 * file.h (grub_file): Likewise.
13433
13434 * fshelp.h (grub_fshelp_read_file): Likewise.
13435
13436 * util/i386/pc/grub-setup.c (setup): Likewise.
13437 (save_first_sector): Likewise.
13438 (save_blocklists): Likewise.
f19dbdb7 13439
9959f7db 13440 * fs/affs.c (grub_affs_read_file): Likewise.
13441
13442 * fs/ext2.c (grub_ext2_read_file): Likewise.
13443
13444 * fs/fat.c (grub_fat_read_data): Likewise.
13445
13446 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
13447
13448 * fs/hfs.c (grub_hfs_read_file): Likewise.
13449
13450 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
13451
13452 * fs/jfs.c (grub_jfs_read_file): Likewise.
13453
13454 * fs/minix.c (grub_minix_read_file): Likewise.
13455
13456 * fs/sfs.c (grub_sfs_read_file): Likewise.
13457
13458 * fs/ufs.c (grub_ufs_read_file): Likewise.
f19dbdb7 13459
9959f7db 13460 * fs/xfs.c (grub_xfs_read_file): Likewise.
13461
13462 * command/blocklist.c (read_blocklist): Likewise.
13463 (print_blocklist): Likewise.
13464
0a203f83 134652007-08-02 Marco Gerards <marco@gnu.org>
13466
13467 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
13468 `util/hostfs.c'.
13469
13470 * disk/host.c: New file.
13471
13472 * util/hostfs.c: Likewise.
13473
13474 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
13475 return `GRUB_ERR_BAD_FS'.
13476 * fs/sfs.c (grub_sfs_mount): Likewise.
13477 * fs/xfs.c (grub_xfs_mount): Likewise.
13478
13479 * include/grub/disk.h (enum grub_disk_dev_id): Add
13480 `GRUB_DISK_DEVICE_HOST_ID'.
13481
13482 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
13483
e5dfe777 134842007-07-24 Jerone Young <jerone@gmail.com>
13485
f19dbdb7 13486 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
e5dfe777 13487 modules for compilation.
13488 * conf/powerpc-ieee1275.rmk: Likewise.
13489
13490 * include/multiboot.h: Move multiboot definitions to one file. Rename
13491 many definitions to not get grub specific.
13492 * include/multiboot2.h: Create header with multiboot 2 definitions.
13493 * include/grub/multiboot.h: Header for grub specific function
13494 prototypes and definitions.
13495 * include/grub/multiboot2.h: Likewise.
13496 * include/grub/multiboot_loader.h: Likewise.
13497 * include/grub/i386/pc/multiboot.h: Removed.
13498 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
13499
13500 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
13501 and 2 to allow for one multiboot and module commands.
13502 * loader/multiboot2.c: Add multiboot2 functionality.
13503 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
13504 and definition names.
13505 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
13506 2 functions.
13507 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
13508 ieee1275 specific multiboot2 code.
13509
13510 * kern/i386/pc/startup.S: Change headers and definition names for
13511 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
13512
daf0f0ba 135132007-07-22 Robert Millan <rmh@aybabtu.com>
13514
13515 * geninitheader.sh: Process file specified in first parameter rather
13516 than hardcoding grub_modules_init.lst.
fe6b695a 13517 * geninit.sh: Likewise. Also, construct header name dynamically rather
daf0f0ba 13518 than hardcoding grub_modules_init.h.
13519
13520 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
13521 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
13522 grub_probe_init.[ch] and grub_setup_init.[ch].
13523
13524 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
13525 grub_modules_init.h with grub_emu_init.h.
13526 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
13527 grub_probe_init.[ch] files.
13528 * conf/i386-efi.rmk: Likewise.
13529 * conf/i386-pc.rmk: Likewise.
13530 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
13531 grub_setup_init.[ch] files.
13532
13533 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
13534 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
13535 to initialize modules rather than a list of hardcoded functions.
13536 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
13537 grub_init_all() to initialize modules rather than a list of hardcoded
13538 functions.
13539
54cdc1cc 135402007-07-22 Robert Millan <rmh@aybabtu.com>
13541
13542 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
13543 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
13544
ad0686cc 135452007-07-22 Robert Millan <rmh@aybabtu.com>
13546
13547 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
13548 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
13549 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
13550 flag when running on SmartFirmware.
13551 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
13552 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
13553 was set.
13554
13555 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
13556 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
13557 rather than decreasing it.
13558
13559 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
13560 there's not enough space to do it, fail in the same way as when it
13561 can't be done because there are no partitions.
13562
13563 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
13564 when nvsetenv failed.
13565
969c02ec 135662007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13567
13568 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
13569 because this rule is automatically generated.
13570 (grub-mkrescue): Removed for the same reason as above.
13571
5a79f472 135722007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13573
13574 Migrate to GNU General Public License Version 3.
f19dbdb7 13575
5a79f472 13576 * COPYING: Replaced with the plain text version of GPLv3.
13577
13578 * config.guess: Updated from gnulib.
13579 * config.sub: Likewise.
13580
13581 * geninit.sh: Output a GPLv3 copyright notice.
13582 * geninitheader.sh: Likewise.
13583 * genmodsrc.sh: Likewise.
13584 * gensymlist.sh.in: Likewise.
13585
13586 * boot/i386/pc/boot.S: Upgraded to GPLv3.
13587 * boot/i386/pc/diskboot.S: Likewise.
13588 * boot/i386/pc/pxeboot.S: Likewise.
13589 * commands/blocklist.c: Likewise.
13590 * commands/boot.c: Likewise.
13591 * commands/cat.c: Likewise.
13592 * commands/cmp.c: Likewise.
13593 * commands/configfile.c: Likewise.
13594 * commands/echo.c: Likewise.
13595 * commands/help.c: Likewise.
13596 * commands/ls.c: Likewise.
13597 * commands/search.c: Likewise.
13598 * commands/terminal.c: Likewise.
13599 * commands/test.c: Likewise.
13600 * commands/videotest.c: Likewise.
13601 * commands/i386/cpuid.c: Likewise.
13602 * commands/i386/pc/halt.c: Likewise.
13603 * commands/i386/pc/play.c: Likewise.
13604 * commands/i386/pc/reboot.c: Likewise.
13605 * commands/i386/pc/vbeinfo.c: Likewise.
13606 * commands/i386/pc/vbetest.c: Likewise.
13607 * commands/ieee1275/halt.c: Likewise.
13608 * commands/ieee1275/reboot.c: Likewise.
13609 * commands/ieee1275/suspend.c: Likewise.
13610 * disk/loopback.c: Likewise.
13611 * disk/lvm.c: Likewise.
13612 * disk/raid.c: Likewise.
13613 * disk/efi/efidisk.c: Likewise.
13614 * disk/i386/pc/biosdisk.c: Likewise.
13615 * disk/ieee1275/ofdisk.c: Likewise.
13616 * font/manager.c: Likewise.
13617 * fs/affs.c: Likewise.
13618 * fs/ext2.c: Likewise.
13619 * fs/fat.c: Likewise.
13620 * fs/fshelp.c: Likewise.
13621 * fs/hfs.c: Likewise.
13622 * fs/hfsplus.c: Likewise.
13623 * fs/iso9660.c: Likewise.
13624 * fs/jfs.c: Likewise.
13625 * fs/minix.c: Likewise.
13626 * fs/sfs.c: Likewise.
13627 * fs/ufs.c: Likewise.
13628 * fs/xfs.c: Likewise.
13629 * hello/hello.c: Likewise.
13630 * include/grub/acorn_filecore.h: Likewise.
13631 * include/grub/arg.h: Likewise.
13632 * include/grub/bitmap.h: Likewise.
13633 * include/grub/boot.h: Likewise.
13634 * include/grub/cache.h: Likewise.
13635 * include/grub/device.h: Likewise.
13636 * include/grub/disk.h: Likewise.
13637 * include/grub/dl.h: Likewise.
13638 * include/grub/elfload.h: Likewise.
13639 * include/grub/env.h: Likewise.
13640 * include/grub/err.h: Likewise.
13641 * include/grub/file.h: Likewise.
13642 * include/grub/font.h: Likewise.
13643 * include/grub/fs.h: Likewise.
13644 * include/grub/fshelp.h: Likewise.
13645 * include/grub/gzio.h: Likewise.
13646 * include/grub/hfs.h: Likewise.
13647 * include/grub/kernel.h: Likewise.
13648 * include/grub/loader.h: Likewise.
13649 * include/grub/lvm.h: Likewise.
13650 * include/grub/misc.h: Likewise.
13651 * include/grub/mm.h: Likewise.
13652 * include/grub/net.h: Likewise.
13653 * include/grub/normal.h: Likewise.
13654 * include/grub/parser.h: Likewise.
13655 * include/grub/partition.h: Likewise.
13656 * include/grub/pc_partition.h: Likewise.
13657 * include/grub/raid.h: Likewise.
13658 * include/grub/rescue.h: Likewise.
13659 * include/grub/script.h: Likewise.
13660 * include/grub/setjmp.h: Likewise.
13661 * include/grub/symbol.h: Likewise.
13662 * include/grub/term.h: Likewise.
13663 * include/grub/terminfo.h: Likewise.
13664 * include/grub/tparm.h: Likewise.
13665 * include/grub/types.h: Likewise.
13666 * include/grub/video.h: Likewise.
13667 * include/grub/efi/api.h: Likewise.
13668 * include/grub/efi/chainloader.h: Likewise.
13669 * include/grub/efi/console.h: Likewise.
13670 * include/grub/efi/console_control.h: Likewise.
13671 * include/grub/efi/disk.h: Likewise.
13672 * include/grub/efi/efi.h: Likewise.
13673 * include/grub/efi/pe32.h: Likewise.
13674 * include/grub/efi/time.h: Likewise.
13675 * include/grub/i386/linux.h: Likewise.
13676 * include/grub/i386/setjmp.h: Likewise.
13677 * include/grub/i386/types.h: Likewise.
13678 * include/grub/i386/efi/kernel.h: Likewise.
13679 * include/grub/i386/efi/loader.h: Likewise.
13680 * include/grub/i386/efi/time.h: Likewise.
13681 * include/grub/i386/pc/biosdisk.h: Likewise.
13682 * include/grub/i386/pc/boot.h: Likewise.
13683 * include/grub/i386/pc/chainloader.h: Likewise.
13684 * include/grub/i386/pc/console.h: Likewise.
13685 * include/grub/i386/pc/init.h: Likewise.
13686 * include/grub/i386/pc/kernel.h: Likewise.
13687 * include/grub/i386/pc/loader.h: Likewise.
13688 * include/grub/i386/pc/memory.h: Likewise.
13689 * include/grub/i386/pc/multiboot.h: Likewise.
13690 * include/grub/i386/pc/serial.h: Likewise.
13691 * include/grub/i386/pc/time.h: Likewise.
13692 * include/grub/i386/pc/vbe.h: Likewise.
13693 * include/grub/i386/pc/vbeblit.h: Likewise.
13694 * include/grub/i386/pc/vbefill.h: Likewise.
13695 * include/grub/i386/pc/vbeutil.h: Likewise.
13696 * include/grub/i386/pc/vga.h: Likewise.
13697 * include/grub/ieee1275/ieee1275.h: Likewise.
13698 * include/grub/ieee1275/ofdisk.h: Likewise.
13699 * include/grub/powerpc/libgcc.h: Likewise.
13700 * include/grub/powerpc/setjmp.h: Likewise.
13701 * include/grub/powerpc/types.h: Likewise.
13702 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
13703 * include/grub/powerpc/ieee1275/console.h: Likewise.
13704 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
13705 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
13706 * include/grub/powerpc/ieee1275/loader.h: Likewise.
13707 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
13708 * include/grub/powerpc/ieee1275/time.h: Likewise.
13709 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
13710 * include/grub/sparc64/libgcc.h: Likewise.
13711 * include/grub/sparc64/setjmp.h: Likewise.
13712 * include/grub/sparc64/types.h: Likewise.
13713 * include/grub/sparc64/ieee1275/console.h: Likewise.
13714 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
13715 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
13716 * include/grub/sparc64/ieee1275/time.h: Likewise.
13717 * include/grub/util/biosdisk.h: Likewise.
13718 * include/grub/util/getroot.h: Likewise.
13719 * include/grub/util/lvm.h: Likewise.
13720 * include/grub/util/misc.h: Likewise.
13721 * include/grub/util/raid.h: Likewise.
13722 * include/grub/util/resolve.h: Likewise.
13723 * io/gzio.c: Likewise.
13724 * kern/device.c: Likewise.
13725 * kern/disk.c: Likewise.
13726 * kern/dl.c: Likewise.
13727 * kern/elf.c: Likewise.
13728 * kern/env.c: Likewise.
13729 * kern/err.c: Likewise.
13730 * kern/file.c: Likewise.
13731 * kern/fs.c: Likewise.
13732 * kern/loader.c: Likewise.
13733 * kern/main.c: Likewise.
13734 * kern/misc.c: Likewise.
13735 * kern/mm.c: Likewise.
13736 * kern/parser.c: Likewise.
13737 * kern/partition.c: Likewise.
13738 * kern/rescue.c: Likewise.
13739 * kern/term.c: Likewise.
13740 * kern/efi/efi.c: Likewise.
13741 * kern/efi/init.c: Likewise.
13742 * kern/efi/mm.c: Likewise.
13743 * kern/i386/dl.c: Likewise.
13744 * kern/i386/efi/init.c: Likewise.
13745 * kern/i386/efi/startup.S: Likewise.
13746 * kern/i386/pc/init.c: Likewise.
13747 * kern/i386/pc/lzo1x.S: Likewise.
13748 * kern/i386/pc/startup.S: Likewise.
13749 * kern/ieee1275/ieee1275.c: Likewise.
13750 * kern/powerpc/cache.S: Likewise.
13751 * kern/powerpc/dl.c: Likewise.
13752 * kern/powerpc/ieee1275/cmain.c: Likewise.
13753 * kern/powerpc/ieee1275/crt0.S: Likewise.
13754 * kern/powerpc/ieee1275/init.c: Likewise.
13755 * kern/powerpc/ieee1275/openfw.c: Likewise.
13756 * kern/sparc64/cache.S: Likewise.
13757 * kern/sparc64/dl.c: Likewise.
13758 * kern/sparc64/ieee1275/init.c: Likewise.
13759 * kern/sparc64/ieee1275/openfw.c: Likewise.
13760 * loader/efi/chainloader.c: Likewise.
13761 * loader/efi/chainloader_normal.c: Likewise.
13762 * loader/i386/efi/linux.c: Likewise.
13763 * loader/i386/efi/linux_normal.c: Likewise.
13764 * loader/i386/pc/chainloader.c: Likewise.
13765 * loader/i386/pc/chainloader_normal.c: Likewise.
13766 * loader/i386/pc/linux.c: Likewise.
13767 * loader/i386/pc/linux_normal.c: Likewise.
13768 * loader/i386/pc/multiboot.c: Likewise.
13769 * loader/i386/pc/multiboot_normal.c: Likewise.
13770 * loader/powerpc/ieee1275/linux.c: Likewise.
13771 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
13772 * normal/arg.c: Likewise.
13773 * normal/cmdline.c: Likewise.
13774 * normal/command.c: Likewise.
13775 * normal/completion.c: Likewise.
13776 * normal/execute.c: Likewise.
13777 * normal/function.c: Likewise.
13778 * normal/lexer.c: Likewise.
13779 * normal/main.c: Likewise.
13780 * normal/menu.c: Likewise.
13781 * normal/menu_entry.c: Likewise.
13782 * normal/misc.c: Likewise.
13783 * normal/parser.y: Likewise.
13784 * normal/script.c: Likewise.
13785 * normal/i386/setjmp.S: Likewise.
13786 * normal/powerpc/setjmp.S: Likewise.
13787 * normal/sparc64/setjmp.S: Likewise.
13788 * partmap/acorn.c: Likewise.
13789 * partmap/amiga.c: Likewise.
13790 * partmap/apple.c: Likewise.
13791 * partmap/gpt.c: Likewise.
13792 * partmap/pc.c: Likewise.
13793 * partmap/sun.c: Likewise.
13794 * term/gfxterm.c: Likewise.
13795 * term/terminfo.c: Likewise.
13796 * term/efi/console.c: Likewise.
13797 * term/i386/pc/console.c: Likewise.
13798 * term/i386/pc/serial.c: Likewise.
13799 * term/i386/pc/vesafb.c: Likewise.
13800 * term/i386/pc/vga.c: Likewise.
13801 * term/ieee1275/ofconsole.c: Likewise.
13802 * util/biosdisk.c: Likewise.
13803 * util/console.c: Likewise.
13804 * util/genmoddep.c: Likewise.
13805 * util/getroot.c: Likewise.
13806 * util/grub-emu.c: Likewise.
13807 * util/grub-mkdevicemap.c: Likewise.
13808 * util/grub-probe.c: Likewise.
13809 * util/lvm.c: Likewise.
13810 * util/misc.c: Likewise.
13811 * util/raid.c: Likewise.
13812 * util/resolve.c: Likewise.
13813 * util/update-grub.in: Likewise.
13814 * util/update-grub_lib.in: Likewise.
13815 * util/grub.d/00_header.in: Likewise.
13816 * util/grub.d/10_hurd.in: Likewise.
13817 * util/grub.d/10_linux.in: Likewise.
13818 * util/i386/efi/grub-install.in: Likewise.
13819 * util/i386/efi/grub-mkimage.c: Likewise.
13820 * util/i386/pc/grub-install.in: Likewise.
13821 * util/i386/pc/grub-mkimage.c: Likewise.
13822 * util/i386/pc/grub-mkrescue.in: Likewise.
13823 * util/i386/pc/grub-setup.c: Likewise.
13824 * util/i386/pc/misc.c: Likewise.
13825 * util/powerpc/ieee1275/grub-install.in: Likewise.
13826 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
13827 * util/powerpc/ieee1275/misc.c: Likewise.
13828 * video/bitmap.c: Likewise.
13829 * video/video.c: Likewise.
13830 * video/i386/pc/vbe.c: Likewise.
13831 * video/i386/pc/vbeblit.c: Likewise.
13832 * video/i386/pc/vbefill.c: Likewise.
13833 * video/i386/pc/vbeutil.c: Likewise.
13834 * video/readers/tga.c: Likewise.
13835
3572d015 138362007-07-02 Robert Millan <rmh@aybabtu.com>
13837
13838 * conf/i386-efi.rmk: Replace obsolete reference to
13839 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
13840 with util/getroot.c.
13841 * conf/powerpc-ieee1275.rmk: Likewise.
13842 * conf/sparc64-ieee1275.rmk: Likewise.
13843
13844 * util/grub-emu.c (main): Fix unchecked pointer handling.
13845
2c2a681b 138462007-07-02 Robert Millan <rmh@aybabtu.com>
13847
13848 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
13849 invocation to fail, in order to support partition-less media.
13850
13851 * util/i386/pc/grub-install.in: Likewise.
13852
13853 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
13854 which fs or partmap modules are needed (akin to its sister scripts).
13855
13856 Also use grub-probe to get rid of unportable /proc/mounts check.
13857
13858 Print the same informational message that the other scripts do, before
fe6b695a 13859 exiting.
2c2a681b 13860
6193defe 138612007-06-23 Robert Millan <rmh@aybabtu.com>
13862
fe6b695a 13863 * util/update-grub_lib.in (font_path): New function. Determine whether
6193defe 13864 a font file can be found and, if so, echo the GRUB path to it.
13865
13866 * util/update-grub.in: Handle multiple terminals depending on user
13867 input, platform availability and font file presence. Propagate
13868 variables of our findings to /etc/grub.d/ children.
13869
13870 * util/grub.d/00_header.in: Handle multiple terminals, based on
13871 environment setup by update-grub.
13872
eface1dc 138732007-06-23 Robert Millan <rmh@aybabtu.com>
13874
ba50d28f 13875 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
eface1dc 13876
bf697e28 138772007-06-21 Robert Millan <rmh@aybabtu.com>
13878
13879 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
13880 indicate end of data section in kernel image.
13881 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
13882 GRUB_KERNEL_MACHINE_DATA_END.
13883
13884 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
13885 space for it.
13886 * kern/i386/efi/startup.S: Likewise.
13887
13888 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
13889 during image generation. Implement --prefix option to override this
13890 patch.
13891 * util/i386/efi/grub-mkimage.c: Likewise.
13892
13893 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
13894 code to make path relative to its root into a separate function.
13895
13896 * util/i386/pc/grub-install.in: Use newly provided
13897 make_system_path_relative_to_its_root() to convert ${grubdir}, then
13898 pass the result to grub-install --prefix.
13899
baa574b4 139002007-06-13 Robert Millan <rmh@aybabtu.com>
13901
13902 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
13903 DEFAULT_DEVICE_MAP.
13904 * util/grub-emu.c: Use above definitions from misc.h instead of
13905 defining them.
13906 * util/grub-mkdevicemap.c: Likewise.
13907 * util/i386/pc/grub-setup.c: Likewise.
13908 * util/grub-probe.c: Likewise.
13909 (probe): Abort with grub_util_error() when either
13910 grub_guess_root_device or grub_util_get_grub_dev fails.
13911
0215dcbf 139122007-06-12 Robert Millan <rmh@aybabtu.com>
13913
13914 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
13915 "pager" assignment.
13916 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
13917 "pcdata".
13918 * util/grub-probe.c (probe): Likewise for "drive_name".
13919
8af2ab7b 139202007-06-11 Robert Millan <rmh@aybabtu.com>
13921
13922 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
13923 not just the cdrom one.
13924
59d31694 139252007-06-11 Robert Millan <rmh@aybabtu.com>
13926
13927 * util/i386/pc/grub-mkrescue.in: Add "set -e".
13928 Add --pkglibdir=DIR option to override pkglibdir.
13929 Mention --image-type=TYPE in help output.
13930 Fix --grub-mkimage (it was a no-op).
fe6b695a 13931 Abort gracefully when no parameter is given.
59d31694 13932
7ee367e4 139332007-06-11 Robert Millan <rmh@aybabtu.com>
13934
13935 * util/i386/pc/grub-mkrescue.in: New file.
13936 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
13937 * Makefile.in: Handle bin_SCRIPTS.
13938
29b0ed46 139392007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
13940
13941 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
13942 list of video modes.
13943
c0f90770 139442007-06-06 Robert Millan <rmh@aybabtu.com>
13945
13946 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
13947 file doesn't exist, or if it is in a filesystem grub can't read.
13948
13949 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
13950 not abort if GRUB_DRIVE could not be defined. Rearrange generated
13951 header comment to fit in 80 columns when the variables are resolved.
13952
13953 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
13954 could be identified by update-grub. Remove redundant check for
fe6b695a 13955 unifont.pff existence (since convert_system_path_to_grub_path now
c0f90770 13956 handles that).
13957
fb36dc26 139582007-06-04 Robert Millan <rmh@aybabtu.com>
13959
13960 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
13961
13962 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
13963
13964 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
13965
0c68c93e 139662007-06-04 Robert Millan <rmh@aybabtu.com>
13967
13968 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
13969
13970 * include/grub/partition.h: Declare grub_apple_partition_map_init and
13971 grub_apple_partition_map_fini.
13972
13973 * util/biosdisk.c
13974 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
13975 to access >2 TiB disks).
13976
13977 Print disk->total_sectors with %llu instead of %lu, since this
13978 variable is always 64-bit (prevents wrong disk size from being displayed
13979 on either >2 TiB disk or big-endian CPU).
13980
13981 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
13982 into a generic case that supports all (sane) partition maps.
13983
13984 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
13985 breaks big-endian.
13986
13987 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
13988 and grub_apple_partition_map_fini() after that.
13989
0f23eb74 139902007-06-01 Robert Millan <rmh@aybabtu.com>
13991
13992 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
13993
13994 * util/grub.d/00_header.in: Only enable gfxterm when
13995 convert_system_path_to_grub_path() succeeds.
13996
42c71976 139972007-05-20 Robert Millan <rmh@aybabtu.com>
13998
13999 * util/update-grub_lib.in: New file.
14000 * DISTLIST: Add update-grub_lib.in.
14001 * conf/common.rmk: Generate update-grub_lib and install it in
14002 $(lib_DATA).
14003 * Makefile.in: Add install routine for $(lib_DATA).
14004
14005 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
14006 function provided by update-grub_lib to support arbitrary paths of
14007 unifont.pff.
14008 * util/update-grub.in: Use convert_system_path_to_grub_path() to
14009 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
14010
5beb2291 140112007-05-19 Robert Millan <rmh@aybabtu.com>
14012
14013 * commands/i386/cpuid.c: New module.
14014 * DISTLIST: Add it.
14015 * conf/i386-efi.rmk: Enable cpuid.mod.
14016 * conf/i386-pc.rmk: Likewise.
14017
7262eca1 140182007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14019
14020 * kern/disk.c (grub_disk_read): Check return value of
14021 grub_realloc().
14022
260ba823 140232007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14024
14025 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
14026 arrays.
14027 * disk/raid.c (grub_raid_open): Likewise.
14028
1ecb6cf2 140292007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14030
14031 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
14032 stack instead of on the heap.
14033
14034 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
14035 before doing a read on it.
14036
14037 * configure.ac: Only use -fno-stack-protector for the target
14038 environment.
f19dbdb7 14039
21c8cbb1 140402007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14041
14042 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
14043 __attribute_ ((unused)) to mode_type argument.
14044
14045 * util/getroot.c (grub_guess_root_device): Fix #endif.
f19dbdb7 14046
21c8cbb1 14047 * kern/misc.c (memcmp): Fix prototype.
14048
14049 * include/grub/partition.h [GRUB_UTIL]
14050 (grub_gpt_partition_map_init): Add prototype.
14051 (grub_gpt_partition_map_fini): Likewise.
14052
14053 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
14054 at the right place.
14055
14056 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
14057 (grub_fat_read_data): Likewise.
14058 (grub_fat_find_dir): Likewise.
14059
14060 * font/manager.c (find_glyph): Make table a const.
14061 (grub_font_get_glyph): Remove bitmap from if statement.
f19dbdb7 14062
849d55d3 140632007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
14064
14065 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
14066 code, first search for device in /dev/mapper, then in /dev.
14067 (grub_util_get_grub_dev): New function.
14068 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
14069 prototype.
14070 * util/grub-probe.c (probe): Remove check for RAID, call
14071 grub_util_get_grub_dev() instead of
14072 grub_util_biosdisk_get_grub_dev().
14073 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
14074 grub_util_biosdisk_get_grub_dev().
14075 * util/i386/pc/grub-setup.c (main): Likewise.
14076
8fff7c2f 140772007-05-16 Robert Millan <rmh@aybabtu.com>
14078
14079 * DISTLIST: Update for the latest changes.
14080 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
14081 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
14082 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
14083 grub/util/biosdisk.h.
14084 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
14085 grub/util/biosdisk.h.
14086
48e12b52 140872007-05-16 Robert Millan <rmh@aybabtu.com>
14088
14089 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
14090
46b9d128 140912007-05-16 Robert Millan <rmh@aybabtu.com>
14092
14093 * util/i386/efi/grub-install.in: New.
14094 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
14095 newly added grub-install.
14096 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
14097 include.
14098 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
14099 grub/util/biosdisk.h.
14100 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
14101 grub/util/biosdisk.h.
14102
2d1a40a9 141032007-05-16 Robert Millan <rmh@aybabtu.com>
14104
14105 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
14106 * include/grub/util/biosdisk.h: ... here.
14107 * util/i386/pc/biosdisk.c: Moved to ...
14108 * util/biosdisk.c: ... here.
14109 * util/i386/pc/getroot.c: Moved to ...
14110 * util/getroot.c: ... here.
14111 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
14112 * util/grub-mkdevicemap.c: ... here.
14113 * util/i386/pc/grub-probe.c: Moved to ...
14114 * util/grub-probe.c: ... here.
14115
9e26e3bc 141162007-05-15 Robert Millan <rmh@aybabtu.com>
14117
14118 * util/update-grub.in: Remove duplicated line in grub.cfg header
14119 message.
14120
57f96397 141212007-05-13 Robert Millan <rmh@aybabtu.com>
14122
14123 * util/update-grub.in: Fix a few assumptions about the devices holding
14124 /, /boot and /boot/grub being the same.
14125 * util/grub.d/00_header.in: Likewise.
14126 * util/grub.d/10_hurd.in: Likewise.
14127 * util/grub.d/10_linux.in: Likewise.
14128
14129 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
14130 patterns. Use that to define the `.old' suffix as older than `'.
14131
14132 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
14133
14134 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
14135 the grub.cfg header message.
14136
2e610d62 141372007-05-11 Robert Millan <rmh@aybabtu.com>
14138
14139 * util/update-grub.in: Create device.map if it doesn't already exist,
14140 before attempting to run grub-probe.
14141 Check for grub-probe and grub-mkdevicemap with the same code
14142 grub-install is using.
14143 Remove test mode.
14144
3f6a10ef 141452007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
14146
14147 * Makefile.in: Add the datarootdir autoconf variable.
14148
02e7b75e 141492007-05-09 Robert Millan <rmh@aybabtu.com>
14150
14151 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
f19dbdb7 14152 fail gracefully if dev->disk->partition == NULL.
02e7b75e 14153
75f396cc 141542007-05-07 Robert Millan <rmh@aybabtu.com>
14155
14156 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
14157 determine partition map module.
14158 * util/i386/pc/grub-install.in: Use this feature to decide which
14159 partition module to load, instead of hardcoding pc and gpt.
14160
da65cb36 141612007-05-07 Robert Millan <rmh@aybabtu.com>
14162
14163 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
14164 source directory differs from build directory.
14165
b57d6a91 141662007-05-05 Robert Millan <rmh@aybabtu.com>
14167
14168 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
14169 initialisation.
14170
509d00f1 141712007-05-05 Robert Millan <rmh@aybabtu.com>
14172
14173 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
14174
c48f23ef 141752007-05-05 Robert Millan <rmh@aybabtu.com>
14176
14177 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
14178 command-line arguments via ${GRUB_CMDLINE_LINUX}.
14179
20b97658 141802007-05-05 Robert Millan <rmh@aybabtu.com>
14181
14182 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
14183 (grub_probe_SOURCES): Likewise.
14184 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
14185 GPT and initialize dos_part and bsd_part accordingly.
14186 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
14187 install_bsd_part.
14188 (main): Activate gpt module for use during partition identification,
14189 and deactivate it afterwards.
14190 * util/i386/pc/grub-install.in: Add gpt module to core.img.
14191 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
14192 partition identification, and deactivate it afterwards.
14193
99123174 141942007-05-05 Robert Millan <rmh@aybabtu.com>
14195
14196 * term/i386/pc/console.c (grub_console_fini): Call
14197 grub_term_set_current() before grub_term_unregister().
14198
ebd97f6e 141992007-05-04 Robert Millan <rmh@aybabtu.com>
14200
14201 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
14202 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
14203 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
14204 and update-grub_DATA.
14205 * conf/common.rmk: Build and install update-grub components.
14206 * conf/common.mk: Regenerate.
14207 * util/update-grub.in: New. Core of update-grub.
14208 * util/grub.d/00_header.in: New. Generates grub.cfg header.
14209 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
14210 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
14211 * util/grub.d/README: New. Document grub.d directory layout.
14212
b06a264d 142132007-05-01 Robert Millan <rmh@aybabtu.com>
14214
14215 * util/grub-emu.c: Move initialization functions
14216 grub_util_biosdisk_init() and grub_init_all() before
14217 grub_util_biosdisk_get_grub_dev(), which relies on them.
14218
41f0050e 142192007-04-19 Robert Millan <rmh@aybabtu.com>
14220
14221 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
14222 it is used later.
14223
04582bb3 142242007-04-18 Jerone Young <jerone@gmail.com>
14225
f19dbdb7 14226 * kernel/elf.c: Add missing parenthesis for conditional statement
04582bb3 14227 stanza.
14228
08db4632 142292007-04-10 Jerone Young <jerone@gmail.com>
49892fdf 14230
08db4632 14231 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
14232 continue on and look for device node with real device name.
14233
801b76be 142342007-04-10 Jerone Young <jerone@gmail.com>
f19dbdb7 14235
fe6b695a 14236 * configure.ac: Add argument for autoconf to use transformation
1d543c3e 14237 ability.
14238 * Makefile.in: Add autoconf package transformation code.
14239 * util/i386/pc/grub-install.in: Likewise.
14240 * util/powerpc/ieee1275/grub-install.in: Likewise.
14241
6795c4e1 142422007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
14243
14244 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
14245 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
14246 (EXT2_REVISION): Likewise.
14247 (EXT2_INODE_SIZE): Likewise.
14248 (struct grub_ext2_block_group): Added a missing member
14249 "used_dirs".
14250 (grub_ext2_read_inode): Divide by the inode size in a superblock
14251 instead of 128 to obtain INODES_PER_BLOCK.
14252 Use the macro EXT2_INODE_SIZE instead of directly using
14253 SBLOCK->INODE_SIZE.
14254
d70af616 142552007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
14256
14257 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
14258 superblock instead of the structure size to compute an
14259 offset. This fixes the problem that GRUB could not read a
14260 filesystem when inode size is different from 128-byte.
14261
3b801603 142622007-03-05 Marco Gerards <marco@gnu.org>
14263
14264 * normal/main.c (read_config_file): When "menu" is not set, create
14265 an initial context.
14266
4785bfe4 142672007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14268
14269 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
14270 (HEAP_LIMIT): New macro.
14271 (grub_claim_heap): Claim memory up to `heaplimit'.
14272
a0cbb023 142732007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14274
14275 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
14276 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
14277 (_start): Likewise.
14278 (grub_arch_modules_addr): Return address after `_end'.
14279 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
14280 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
14281 (add_segments): Calculate `_end' from phdr size and location.
14282 (ALIGN_UP): Moved to ...
14283 * include/grub/misc.h: here.
14284 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
14285 New macro.
14286 (GRUB_IEEE1275_MODULE_BASE): Removed.
14287
fd7d8eba 142882007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14289
14290 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
14291 loop boundary.
14292
9b09e6fc 142932007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14294
14295 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
14296 All users updated.
14297 (grub_elf64_load_hook_t): Likewise.
14298 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
14299 debug output.
14300
3ce27299 143012007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14302
14303 * kern/mm.c: Update copyright.
14304 (grub_mm_debug): Correct syntax error.
14305 (grub_mm_dump_free): New function.
14306 (grub_debug_free): Call `grub_free'.
14307 * include/grub/mm.h: Update copyright.
14308 (grub_mm_dump_free): Add declaration.
14309
077d5fee 143102007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14311
14312 * include/grub/ieee1275/ieee1275.h: Update copyright.
14313 * kern/powerpc/ieee1275/init.c: Likewise.
14314 * kern/powerpc/ieee1275/openfw.c: Likewise.
14315
14316 * loader/powerpc/ieee1275/linux.c: Likewise.
14317 * include/grub/elfload.h: Likewise.
14318 * kern/elf.c: Likewise.
14319 (grub_elf32_load): Pass `base' and `size' parameters. Update all
14320 callers.
14321 (grub_elf64_load): Likewise.
14322 (grub_elf32_load_segment): Move to a nested function.
14323 (grub_elf64_load_segment): Likewise.
14324
dc946850 143252007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14326
14327 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
14328 prototype.
14329 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
14330 (grub_heap_len): Likewise.
14331 (HEAP_SIZE): New macro.
14332 (grub_claim_heap): New function.
14333 (grub_machine_init): Don't claim heap directly. Call
14334 `grub_claim_heap'.
14335 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
14336 (grub_available_iterate): New function.
14337
baa2a121 143382007-02-03 Thomas Schwinge <tschwinge@gnu.org>
14339
14340 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
14341 * configure.ac: Use it for testing the HOST and TARGET compilers.
14342
4fe9862e 143432006-12-13 Thomas Schwinge <tschwinge@gnu.org>
14344
14345 * Makefile.in (enable_grub_emu): New variable.
14346 * configure.ac (--enable-grub-emu): New option.
14347 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
14348 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
14349 * conf/i386-pc.rmk: Likewise.
14350 * conf/powerpc-ieee1275.rmk: Likewise.
14351 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
14352
a8aa5762 143532006-12-12 Marco Gerards <marco@gnu.org>
14354
14355 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
14356
14357 * kern/env.c (grub_env_unset): Don't free the member `value' when
14358 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
14359 pointer.
14360
14361 * normal/main.c (current_menu): Removed.
14362 (free_menu): Unset the `menu' environment variable.
14363 (grub_normal_menu_addentry): Make use of the environment variable
14364 `menu', instead of using the global `current_menu'. Allocate
14365 memory for the sourcecode of this entry.
14366 (read_config_file): New argument `nested', changed all callers.
14367 Only in the case of a new context, initialize a new menu. Set the
14368 `menu' environment variable.
14369 (grub_normal_execute): Don't set and unset the environment
14370 variable `menu' here anymore. Only free the menu when leaving the
14371 context.
14372
14373 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
14374 leak.
14375
957b3a3e 143762006-12-11 Marco Gerards <marco@gnu.org>
14377
14378 * normal/menu_entry.c (run): Fix off by one bug so the last line
14379 is executed. Move the loader check to outside the loop.
14380
ef875714 143812006-12-08 Hollis Blanchard <hollis@penguinppc.org>
14382
14383 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
14384
4e739985 143852006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
14386
14387 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
14388 the number of sectors. Reported by Andrey Shuvikov
14389 <mr_hyro@yahoo.com>.
f19dbdb7 14390
790707f2 143912006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
14392
14393 * kern/disk.c (grub_disk_read): When there is a read error, always
14394 try to read only the necessary data.
f19dbdb7 14395
790707f2 14396 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
14397 disk/raid.c.
14398 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
14399 prototype.
14400 [GRUB_UTIL] (grub_raid_fini): Likewise.
14401 [GRUB_UTIL] (grub_lvm_init): Likewise.
f19dbdb7 14402 [GRUB_UTIL] (grub_lvm_fini): Likewise.
790707f2 14403 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
14404 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
14405 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
14406 and grub_raid_fini().
f19dbdb7 14407
03e58196 144082006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
14409
14410 * include/grub/types.h (__unused): Rename to UNUSED.
14411 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
14412 (grub_elf64_size): Likewise.
f19dbdb7 14413
ae4f23bf 144142006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14415
14416 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
14417 grub_error_push and grub_error_pop in the error-handling path.
14418 (grub_elf32_load_segment): Only call grub_file_read with non-zero
14419 length.
14420
2166cc83 144212006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14422
14423 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
14424 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
14425 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
14426 (kernel_elf_SOURCES): Likewise.
14427 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
14428 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
14429 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14430 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14431 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
14432 (elf_mod_SOURCES): New variable.
14433 (elf_mod_CFLAGS): Likewise.
14434 (elf_mod_LDFLAGS): Likewise.
14435 * include/grub/types.h (__unused): New macro.
14436 * include/grub/elfload.h: New file.
14437 * kern/elf.c: Likewise.
14438 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
14439 (ELF32_LOADMASK): New macro.
14440 (ELF64_LOADMASK): Likewise.
14441 (vmlinux): Removed.
14442 (grub_linux_load32): New function.
14443 (grub_linux_load64): Likewise.
14444 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
14445 Use grub_elf_t instead of grub_file_t.
14446
a09d5aa5 144472006-11-02 Hollis Blanchard <hollis@penguinppc.org>
14448
14449 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
14450 `catch_result' to struct set_color_args.
14451
d976fc51 144522006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
14453
14454 * normal/menu.c: Include grub/script.h.
14455 * normal/menu_entry.c: Likewise.
14456 * include/grub/normal.h: Do not include grub/script.h.
14457
67507549 144582006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14459
14460 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
14461
69203a99 144622006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14463
14464 * kern/disk.c (grub_disk_open): Print debug messages when opening a
14465 disk.
14466 (grub_disk_close): Print debug messages when closing a disk.
14467 (grub_disk_read): Print debug messages when disk read fails.
14468 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
14469 filesystem type.
14470 * kern/partition.c: Include misc.h.
14471 (grub_partition_iterate): Print debug messages when detecting
14472 partition type.
14473
e2b8278c 144742006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14475
14476 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
14477 is negative.
14478 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
14479
97b2f2ff 144802006-10-26 Hollis Blanchard <hollis@penguinppc.org>
14481
14482 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
14483 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
14484
6555d655 144852006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
14486
14487 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
14488 instead of sizeof(lv). Patch by Michael Guntsche.
14489
4d42b77f 144902006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
14491
14492 * disk/lvm.c: Rename VGS to VG_LIST.
14493 (grub_lvm_iterate): Change VGS->LV to VG-LV.
14494 (grub_lvm_open): Likewise.
14495 Thanks to Michael Guntsche for finding this bug.
14496
5d74d927 144972006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14498
14499 * configure.ac (AC_INIT): Bumped to 1.95.
14500
a1bb27e4 145012006-10-14 Robert Millan <rmh@aybabtu.com>
14502
14503 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
14504 with "/dev/.static/dev/md".
14505
e0994b8b 145062006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14507
14508 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
14509 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
14510 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
14511 DRIVE_NAME are always freed.
14512
14513 * util/i386/pc/biosdisk.c (make_device_name): Add one into
14514 DOS_PART, as a DOS partition is counted from one instead of zero
14515 now. Reported by Robert Millan.
14516
ddd5cee9 145172006-10-14 Robert Millan <rmh@aybabtu.com>
14518
14519 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
14520 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
14521 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
14522 string returned by grub_guess_root_device.
14523 * util/i386/pc/grub-setup.c: Likewise.
14524 * util/i386/pc/grub-probefs.c: Likewise.
14525
14526 * util/i386/pc/grub-probefs.c: Rename to ...
14527 * util/i386/pc/grub-probe.c: ... this.
14528 * DISTLIST: Remove grub-probefs, add grub-probe.
14529 * conf/i386-efi.rmk: Likewise.
14530 * conf/i386-pc.rmk: Likewise.
14531 * util/i386/pc/grub-install.in: Likewise.
14532
14533 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
14534 choose which information we want to print.
14535
2b002173 145362006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14537
14538 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
14539 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
14540 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
14541 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
14542 video/readers/tga.c and video/i386/pc/vbeutil.c.
14543
145442006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
14545
14546 Added support for RAID and LVM.
f19dbdb7 14547
2b002173 14548 * disk/lvm.c: New file.
14549 * disk/raid.c: Likewise.
14550 * include/grub/lvm.h: Likewise.
f19dbdb7 14551 * include/grub/raid.h: Likewise.
2b002173 14552 * include/grub/util/lvm.h: Likewise.
14553 * include/grub/util/raid.h: Likewise.
14554 * util/lvm.c: Likewise.
14555 * util/raid.c: Likewise.
14556
14557 * include/grub/disk.h (grub_disk_dev_id): Add
14558 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
14559 (grub_disk_get_size): New prototype.
14560 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
14561 returns a partition.
14562 (grub_disk_get_size): New function.
f19dbdb7 14563
2b002173 14564 * kern/i386/pc/init.c (make_install_device): Copy the prefix
14565 verbatim if grub_install_dos_part is -2.
14566
14567 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
14568 and LVM devices.
14569
14570 * util/i386/pc/grub-setup.c (setup): New argument
14571 MUST_EMBED. Force embedding of GRUB when the argument is
14572 true. Close FILE before returning.
14573 (main): Add support for RAID and LVM.
f19dbdb7 14574
2b002173 14575 * conf/common.rmk: Add RAID and LVM modules.
14576 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
14577 util/lvm.c.
14578 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
14579
14580 * kern/misc.c (grub_strstr): New function.
14581 * include/grub/misc.h (grub_strstr): New prototype.
14582
050548d0 145832006-10-10 Tristan Gingold <tristan.gingold@bull.net>
14584
14585 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
14586
da849d2d 145872006-10-05 Tristan Gingold <tristan.gingold@bull.net>
14588
14589 * kern/misc.c (grub_strtoull): Guess the base only if not
14590 specified.
14591
97b2f2ff 145922006-10-01 Hollis Blanchard <hollis@penguinppc.org>
4f0acd39 14593
14594 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
14595 PowerMac support.
14596
97b2f2ff 145972006-10-01 Hollis Blanchard <hollis@penguinppc.org>
fba51f48 14598
14599 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
14600
14601 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
14602 Remove `flags' argument. All callers changed.
14603 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
14604 (IEEE1275_IHANDLE_INVALID): New variable.
14605 (IEEE1275_CELL_INVALID): New variable.
14606 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
14607 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
14608 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
14609 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
14610 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
14611 codes from Open Firmware. All callers updated.
14612 (grub_ieee1275_next_property): Directly return Open Firmware return
14613 code.
14614 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
14615 Standardize error checking from `grub_ieee1275_get_property'.
14616 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
14617 `devalias' to `aliases'. Correct comments. Consolidate error paths.
14618
97b2f2ff 146192006-10-01 Hollis Blanchard <hollis@penguinppc.org>
cc6d3df3 14620
14621 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
14622 `instance_to_package_args' to `instance_to_path_args'.
14623
14624 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
14625 `grub_ieee1275_chosen'.
14626
14627 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
14628 `grub_ieee1275_interpret'.
14629
97b2f2ff 146302006-09-25 Hollis Blanchard <hollis@penguinppc.org>
02bb8acc 14631
14632 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
14633
97b2f2ff 146342006-09-25 Hollis Blanchard <hollis@penguinppc.org>
663b72f0 14635
14636 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
14637 (__cmpdi): Likewise.
14638
14639 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
14640 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
14641 `grub_ssize_t'.
14642
02bb8acc 14643 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
663b72f0 14644
14645 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
14646 to type `grub_ssize_t'.
14647 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
14648
7f9a8531 146492006-09-22 Marco Gerards <marco@gnu.org>
14650
14651 * normal/script.c (grub_script_create_cmdmenu): Skip leading
14652 newlines.
14653
b5ef1102 146542006-09-22 Marco Gerards <marco@gnu.org>
14655
14656 * commands/echo.c: New file.
14657
14658 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
14659
14660 * conf/common.rmk (echo_mod_SOURCES): New variable.
14661 (echo_mod_CFLAGS): Likewise.
14662 (echo_mod_LDFLAGS): Likewise.
14663
2cff3677 146642006-09-22 Marco Gerards <marco@gnu.org>
14665
14666 * normal/main.c (get_line): Malloc memory instead of using
14667 preallocated memory. Removed the arguments `cmdline' and
14668 `max_len'. Updated all callers.
14669
6ba4688b 146702006-09-22 Marco Gerards <marco@gnu.org>
14671
14672 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
14673 (normal_mod_DEPENDENCIES): Likewise.
14674
14675 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
14676 (normal_mod_DEPENDENCIES): Likewise.
14677
14678 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
14679
e02ac02c 146802006-09-22 Johan Rydberg <jrydberg@gnu.org>
14681
14682 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
14683 programs.
14684 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
14685 (normal_mod_DEPENDENCIES): Likewise.
14686 * conf/i386-pc.mk: Regenerate.
14687 * conf/i386-efi.mk: Likewise
14688 * conf/common.mk: Likewise.
14689 * conf/powerpc-ieee1275.mk: Likewise.
14690 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 14691
8d252e44 146922006-09-22 Robert Millan <rmh@aybabtu.com>
14693
14694 Sync with i386 version.
14695 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
14696 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
14697
209bf7ac 146982006-09-21 Robert Millan <rmh@aybabtu.com>
14699
14700 Import from GRUB Legacy (lib/device.c):
14701 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
14702 (init_device_map) [__linux__]: Add support for I2O devices.
14703
6b146090 147042006-09-14 Marco Gerards <marco@gnu.org>
14705
14706 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
14707 `-melf_i386'.
14708
e38600a8 147092006-09-14 Robert Millan <rmh@aybabtu.com>
2952da5d 14710
14711 * util/i386/pc/grub-install.in: Skip menu.lst when removing
14712 /boot/grub/*.lst.
78fa1790 14713
2952da5d 14714 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
6b146090 14715
2952da5d 14716 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
14717 before adding it to device.map.
14718
01b82a64 147192006-08-15 Johan Rydberg <jrydberg@gnu.org>
14720
fe6b695a 14721 * genmk.rb: Let GCC generate dependencies the first time it
01b82a64 14722 compiles a file; using the -MD option.
14723 * conf/common.mk: Regenerate.
14724 * conf/i386-pc.mk: Likewise.
14725 * conf/i386-efi.mk: Likewise.
14726 * conf/powerpc-ieee1275.mk: Likewise.
14727 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 14728
1064790d 147292006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
14730
14731 Move the prototypes of grub_setjmp and grub_longjmp to
14732 cpu/setjmp.h, so that each architecture may specify different
14733 attributes.
f19dbdb7 14734
1064790d 14735 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
14736 (grub_longjmp): Likewise.
14737 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
14738 (grub_longjmp): Likewise.
14739 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
14740 (grub_longjmp): Likewise.
14741
14742 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
14743 [!GRUB_UTIL] (grub_longjmp): Removed.
14744
29dda3ed 147452006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
14746
14747 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
14748 "color!" method does not return any value.
14749
ad2a06ed 147502006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
14751
14752 * include/grub/bitmap.h: New file.
14753
14754 * include/grub/i386/pc/vbeutil.h: Likewise.
14755
14756 * video/bitmap.c: Likewise.
14757
14758 * video/readers/tga.c: Likewise.
14759
14760 * video/i386/pc/vbeutil.c: Likewise.
14761
14762 * commands/videotest.c: Code cleanup and updated to reflect to new
14763 video API.
14764
14765 * term/gfxterm.c: Likewise.
14766
14767 * video/video.c: Likewise.
14768
14769 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
14770 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
14771 (bitmap_mod_SOURCES): New entry.
14772 (bitmap_mod_CFLAGS): Likewise.
14773 (bitmap_mod_LDFLAGS): Likewise.
14774 (tga_mod_SOURCES): Likewise.
14775 (tga_mod_CFLAGS): Likewise.
14776 (tga_mod_LDFLAGS): Likewise.
14777
14778 * include/grub/video.h (grub_video_blit_operators): New enum type.
14779 (grub_video_render_target): Changed as forward declaration and moved
14780 actual definition to be video driver specific.
14781 (grub_video_adapter.blit_bitmap): Added blitting operator.
14782 (grub_video_adapter.blit_render_target): Likewise.
14783 (grub_video_blit_bitmap): Likewise.
14784 (grub_video_blit_render_target): Likewise.
14785
14786 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
14787 driver specific render target definition.
14788 (grub_video_vbe_map_rgba): Added driver internal helper.
14789 (grub_video_vbe_unmap_color): Updated to use
14790 grub_video_i386_vbeblit_info.
14791 (grub_video_vbe_get_video_ptr): Likewise.
14792
14793 * include/grub/i386/pc/vbeblit.h
14794 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
14795 grub_video_i386_vbeblit_info.
14796 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
14797 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
14798 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
14799 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
14800 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
14801 (grub_video_i386_vbeblit_index_index): Likewise.
14802 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
14803 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
14804 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
14805 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
14806 operator.
14807 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
14808 operator.
14809
14810 * video/i386/pc/vbeblit.c: Updated to reflect changes on
14811 include/grub/i386/pc/vbeblit.h.
14812
14813 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
14814 Updated to use grub_video_i386_vbeblit_info.
14815 (grub_video_i386_vbefill_R8G8B8): Likewise.
14816 (grub_video_i386_vbefill_index): Likewise.
14817 (grub_video_i386_vbefill): Added generic filler.
14818
14819 * video/i386/pc/vbefill.c: Updated to reflect changes on
14820 include/grub/i386/pc/vbefill.h.
14821
14822 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
14823 grub_video_i386_vbeblit_info.
14824 (grub_video_vbe_unmap_color): Likewise.
14825 (grub_video_vbe_blit_glyph): Likewise.
14826 (grub_video_vbe_scroll): Likewise.
14827 (grub_video_vbe_draw_pixel): Removed function.
14828 (grub_video_vbe_get_pixel): Likewise.
14829 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
14830 updated code to use it.
14831 (common_blitter): Added common blitter for render target and bitmap.
14832 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
14833 (grub_video_vbe_blit_render_target): Likewise.
14834
bc8c036d 148352006-07-30 Johan Rydberg <jrydberg@gnu.org>
14836
14837 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
14838 is in text mode if there is no console control protocol instance
14839 available.
14840
684a8eff 148412006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
14842
14843 * include/grub/video.h: Code cleanup.
14844
14845 * include/grub/i386/pc/vbe.h: Likewise.
14846
14847 * video/i386/pc/vbe.c: Likewise.
14848
14849 * video/i386/pc/vbeblit.c: Likewise.
14850
14851 * video/i386/pc/vbefill.c: Likewise.
14852
14853 * video/video.c: Likewise. Also added more comments.
14854
5915059b 148552006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
14856
14857 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
14858 (struct grub_biosdisk_dap): Likewise.
14859
14860 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
14861 linkage settings for all functions.
14862
90ce5d56 148632006-07-12 Marco Gerards <marco@gnu.org>
14864
14865 * configure.ac (--enable-mm-debug): Fix typo.
14866
14867 * genkernsyms.sh.in: Use proper quoting for `CC'.
14868
43e7f879 148692006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
14870
14871 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
14872 (normal_mod_ASFLAGS): Remove "-m32".
14873
4889bdec 148742006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
14875
14876 * util/misc.c: Include config.h.
14877 [!HAVE_MEMALIGN]: Do not include malloc.h.
14878 (grub_memalign): Use posix_memalign, if present. Then, use
14879 memalign, if present. Otherwise, emit an error.
14880
14881 * util/grub-emu.c: Do not include malloc.h.
14882
14883 * include/grub/util/misc.h: Include unistd.h. This is required for
14884 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
14885 D. Eades III <hde@foobar-qux.org>.
14886
14887 * configure.ac (AC_GNU_SOURCE): Added.
14888 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
14889 type.
14890
fd39d4da 148912006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
14892
14893 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
14894 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
14895
b786f3b5 148962006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
14897
14898 * include/grub/types.h (grub_host_addr_t): Rename to
14899 grub_target_addr_t.
14900 (grub_host_off_t): Rename to grub_target_off_t.
14901 (grub_host_size_t): Rename to grub_target_size_t.
14902 (grub_host_ssize_t): Rename to grub_target_ssize_t.
14903 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
14904
14905 * include/grub/kernel.h (struct grub_module_header): Change type
14906 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
14907 (grub_module_info): Likewise.
f19dbdb7 14908
051988bb 149092006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
14910
14911 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
14912 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
14913 Velazquez <jesus.velazquez@gmail.com>.
14914
deae281b 149152006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
14916
14917 Count partitions from 1 instead of 0 in the string representation
14918 of partitions. Still use 0-based internally.
f19dbdb7 14919
deae281b 14920 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
14921 (sun_partition_map_iterate): Use grub_partition_t instead of
14922 struct grub_partition *. Cast DESC->START_CYLINDER to
14923 grub_uint64_t after converting the endian.
14924 (sun_partition_map_probe): Subtract 1 for PARTNUM.
14925 (sun_partition_map_get_name): Add 1 to P->INDEX.
14926
14927 * partmap/pc.c (grub_partition_parse): Subtract 1 for
14928 PCDATA->DOS_PART.
14929 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
14930
14931 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
14932 zero instead of one.
14933 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
14934 (gpt_partition_map_get_name): Add 1 into P->INDEX.
14935
14936 * partmap/apple.c (apple_partition_map_iterate): Change the type
14937 of POS to unsigned.
14938 (apple_partition_map_probe): Subtract 1 for PARTNUM.
14939 (apple_partition_map_get_name): Add 1 into P->INDEX.
14940
14941 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
14942 of POS to unsigned.
14943 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
14944 calculate the offset of a partition.
14945 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
14946 (amiga_partition_map_get_name): Add 1 into P->INDEX.
14947
14948 * partmap/acorn.c (acorn_partition_map_find): Change the type of
14949 SECTOR to grub_disk_addr_t.
14950 (acorn_partition_map_iterate): Likewise.
14951 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
14952 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
14953 top.
14954 (acorn_partition_map_get_name): Add 1 into P->INDEX.
14955
14956 * kern/i386/pc/init.c (make_install_device): Add 1 into
14957 GRUB_INSTALL_DOS_PART.
14958
14959 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
14960 conditional.
14961
524a1e6a 149622006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
14963
14964 Clean up the code to support 64-bit addressing in disks and
14965 files. This change is not enough for filesystems yet.
f19dbdb7 14966
524a1e6a 14967 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
14968 type of "start" to grub_uint64_t.
14969 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
14970 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
14971 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
14972 convert addresses.
14973
14974 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
14975 to grub_disk_addr_t.
14976
14977 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
14978 string.
14979
14980 * partmap/pc.c (pc_partition_map_iterate): Likewise.
14981
14982 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
14983 to char *.
14984
14985 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
14986
14987 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
14988
14989 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
14990
14991 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
14992 to grub_off_t, to detect an error from grub_file_seek.
14993 (grub_multiboot_load_elf32): Likewise.
14994
14995 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
14996 maximum unsigned long value when an overflow is detected.
14997 (grub_strtoull): New function.
14998 (grub_divmod64): Likewise.
14999 (grub_lltoa): use grub_divmod64.
15000
15001 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
15002 grub_disk_addr_t.
15003 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
15004 the pointer to next character. Use grub_strtoull instead of
15005 grub_strtoul.
15006 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
15007 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
15008 respectively.
15009
fe6b695a 15010 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
524a1e6a 15011 return value is signed.
15012 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
15013 test if OFFSET is less than zero, as OFFSET is unsigned now.
15014
15015 * kern/disk.c (struct grub_disk_cache): Change the type of
15016 "sector" to grub_disk_addr_t.
15017 (grub_disk_cache_get_index): Change the type of SECTOR to
15018 grub_disk_addr_t. Calculate the hash with SECTOR casted to
15019 unsigned after shifting.
15020 (grub_disk_cache_invalidate): Change the type of SECTOR to
15021 grub_disk_addr_t.
15022 (grub_disk_cache_unlock): Likewise.
15023 (grub_disk_cache_store): Likewise.
15024 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
15025 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
15026 grub_disk_addr_t and grub_uint64_t, respectively.
15027 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
15028 body, as the value of OFFSET is tweaked by
15029 grub_disk_check_range. Change the types of START_SECTOR, LEN and
15030 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
15031 respectively.
15032 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
15033 body, as the value of OFFSET is tweaked by
15034 grub_disk_check_range. Change the types of LEN and N to
15035 grub_size_t.
15036
15037 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
15038 and "saved_offset" to grub_off_t.
15039 (test_header): Cast BUF to char *.
15040 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
15041 to char *.
15042 (grub_gzio_read): Change the types of OFFSET and SIZE to
15043 grub_off_t and grub_size_t, respectively.
15044
15045 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
15046 Removed.
15047 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
15048 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
15049 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
15050 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
15051 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
15052
15053 * include/grub/types.h (grub_off_t): Unconditionally set to
15054 grub_uint64_t.
15055 (grub_disk_addr_t): Changed to grub_uint64_t.
15056
15057 * include/grub/partition.h (struct grub_partition): Change the
15058 types of "start", "len" and "offset" to grub_disk_addr_t,
15059 grub_uint64_t and grub_disk_addr_t, respectively.
15060 (grub_partition_get_start): Return grub_disk_addr_t.
15061 (grub_partition_get_len): Return grub_uint64_t.
15062
15063 * include/grub/misc.h (grub_strtoull): New prototype.
15064 (grub_divmod64): Likewise.
15065
15066 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
15067 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
15068 grub_off_t, respectively.
15069 All callers and references changed.
15070
15071 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
15072 grub_size_t in "read".
15073 All callers and references changed.
15074
15075 * include/grub/file.h (struct grub_file): Change the types of
15076 "offset" and "size" to grub_off_t and grub_off_t,
15077 respectively. Change the type of SECTOR to grub_disk_addr_t in
15078 "read_hook".
15079 (grub_file_read): Change the type of LEN to grub_size_t.
15080 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
15081 grub_off_t.
15082 (grub_file_size): Return grub_off_t.
15083 (grub_file_tell): Likewise.
15084 All callers and references changed.
15085
15086 * include/grub/disk.h (struct grub_disk_dev): Change the types of
15087 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
15088 "write".
15089 (struct grub_disk): Change the type of "total_sectors" to
15090 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
f19dbdb7 15091 "read_hook".
524a1e6a 15092 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
15093 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
15094 (grub_disk_write): Likewise.
15095 All callers and references changed.
15096
15097 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
15098 char * for grub_strncmp to silence gcc.
15099 (grub_iso9660_mount): Likewise.
15100 (grub_iso9660_mount): Likewise.
15101 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
15102 return statement.
15103 (grub_iso9660_iterate_dir): Likewise.
15104 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
15105
15106 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
15107 LEN to grub_disk_addr_t and grub_size_t, respectively.
15108
15109 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
15110
15111 * fs/jfs.c (grub_jfs_read_file): Likewise.
15112
15113 * fs/minix.c (grub_jfs_read_file): Likewise.
15114
15115 * fs/sfs.c (grub_jfs_read_file): Likewise.
15116
15117 * fs/ufs.c (grub_jfs_read_file): Likewise.
15118
15119 * fs/xfs.c (grub_jfs_read_file): Likewise.
15120
15121 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
15122 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
15123 respectively.
15124
15125 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
15126 BLKNR to -1 instead of returning GRUB_ERRNO.
15127 (grub_ext2_read_file): Change the types of SECTOR and
15128 LEN to grub_disk_addr_t and grub_size_t, respectively.
15129
15130 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
15131 LEN to grub_disk_addr_t and grub_size_t, respectively.
15132
15133 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
15134 grub_file_read.
15135
15136 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
15137 string. Do not cast SECTOR explicitly.
15138
15139 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
15140 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
15141 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
15142 grub_disk_addr_t and grub_size_t, respectively. If the sector is
15143 over 2TB and LBA mode is not supported, raise an error.
15144 (get_safe_sectors): New function.
15145 (grub_biosdisk_read): Use get_safe_sectors.
15146 (grub_biosdisk_write): Likewise.
15147
15148 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
15149 (grub_efidisk_write): Likewise.
15150
15151 * disk/loopback.c (delete_loopback): Cosmetic changes.
15152 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
15153 correctly.
15154 (grub_loopback_open): Likewise.
15155 (grub_loopback_read): Likewise. Also, change the type of POS to
15156 grub_off_t, and fix the usage of grub_memset.
15157
15158 * commands/i386/pc/play.c: Include grub/machine/time.h.
15159
15160 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
15161 print FILE->SIZE.
15162
15163 * commands/configfile.c: Include grub/env.h.
15164
15165 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
15166 GRUB_ERRNO directly instead. Change the type of POS to
15167 grub_off_t. Follow the coding standard.
15168
15169 * commands/blocklist.c: Include grub/partition.h.
15170 (grub_cmd_blocklist): Return an error if the underlying device is
15171 not a disk. Take the starting sector of a partition into account,
15172 if a partition is used.
15173
15174 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
15175 a length field.
15176 (lba_mode): Support 64-bit addresses.
15177 (chs_mode): Likewise.
15178 (copy_buffer): Adapted to the new offsets of a length field and a
15179 segment field.
15180 (blocklist_default_start): Allocate 64-bit space.
15181
15182 * boot/i386/pc/boot.S (force_lba): Removed.
15183 (boot_drive): Moved to under KERNEL_SECTOR.
fe987087 15184 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
524a1e6a 15185 space.
15186 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
15187 is useless.
15188 (lba_mode): Refactored to support a 64-bit address. More size
15189 optimization.
15190 (setup_sectors): Likewise.
15191
53af98ad 151922006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15193
15194 * DISTLIST: Added include/grub/i386/linux.h. Removed
15195 include/grub/i386/pc/linux.h
15196
15197 * configure.ac (AC_INIT): Bumped to 1.94.
15198
15199 * config.guess: Updated from gnulib.
15200 * config.sub: Likewise.
15201 * install-sh: Likewise.
15202 * mkinstalldirs: Likewise.
15203
b4c1940a 152042006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15205
15206 * conf/common.rmk (grub_modules_init.lst): Depended on
15207 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
15208 MODSRCFILES.
15209
15210 * genmk.rb (PModule::rule): Reverted the previous change.
15211
cfca1cfd 152122006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15213
15214 * conf/common.rmk (grub_modules_init.lst): Depends on
15215 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
15216 that the target does not exist before producing.
15217 (grub_modules_init.h): Remove the target before generating.
15218 (grub_emu_init.c): Likewise.
15219
15220 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
15221
aa6d7826 152222006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
15223
15224 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
15225 for the target-specific tests. Make sure that we also have the
15226 up-to-date target variables for those tests.
15227
26c607b9 152282006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15229
15230 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
15231 (PModule::rule): Likewise.
15232
0162321a 152332006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15234
15235 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
15236 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
15237 target-specific flags should be prefixed.
15238 (PModule::rule): Likewise.
15239
6c826348 152402006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
15241
15242 * configure.ac (CMP): Check if cmp is available explicitly.
15243
b977bf01 152442006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
15245
15246 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
15247 (target_cpu): New variable.
15248 (pkglibdir): Use target_cpu instead of host_cpu.
f19dbdb7 15249
b977bf01 15250 * util/i386/pc/grub-install.in (host_cpu): Removed.
15251 (target_cpu): New variable.
15252 (pkglibdir): Use target_cpu instead of host_cpu.
15253
15254 * util/genmoddep.c: Removed.
f19dbdb7 15255
b977bf01 15256 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
15257 instead of GRUB_HOST_SIZEOF_VOID_P.
15258 * kern/dl.c: Likewise.
15259
15260 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
15261 ...
15262 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15263 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15264 (GRUB_TARGET_SIZEOF_LONG): ... this.
15265 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15266 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15267 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15268 to ...
15269 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15270 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15271 (GRUB_TARGET_SIZEOF_LONG): ... this.
15272 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15273 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15274 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15275 to ...
15276 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15277 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15278 (GRUB_TARGET_SIZEOF_LONG): ... this.
15279 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15280 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15281
15282 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
15283 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
15284 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
15285 instead of GRUB_HOST_SIZEOF_LONG.
15286 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
15287 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
15288 GRUB_CPU_WORDS_BIGENDIAN.
15289 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
15290 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
15291 grub_host_ssize_t.
15292
15293 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
15294 (genmoddep_SOURCES): Likewise.
15295 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
15296 (genmoddep_SOURCES): Likewise.
15297 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
15298 (genmoddep_SOURCES): Likewise.
15299 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
15300 Likewise.
15301 (genmoddep_SOURCES): Likewise.
15302
15303 * genmoddep.awk: New file.
15304
15305 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
15306 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
15307 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
15308 (PModule::rule): Likewise.
15309 (Program::rule): Likewise.
15310 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
15311 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
15312 respectively.
15313
15314 * configure.ac: Rewritten intensively to use host and target
15315 instead of build and host, respectively.
15316
15317 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
15318 (host_cpu): Removed.
15319 (target_cpu): New variable.
15320 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
15321 (BUILD_CC): Removed.
15322 (BUILD_CFLAGS): Likewise.
15323 (BUILD_CPPFLAGS): Likewise.
15324 (TARGET_CC): New variable.
15325 (TARGET_CFLAGS): Likewise.
15326 (TARGET_CPPFLAGS): Likewise.
15327 (TARGET_LDFLAGS): Likewise.
15328 (AWK): Likewise.
15329 (include): Use target_cpu instead of host_cpu.
15330 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
f19dbdb7 15331
b977bf01 15332 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
15333
f09771a1 153342006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
15335
15336 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
15337 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
15338 field 'false' to 'exec_on_false'.
15339 (grub_script_create_cmdif): Renamed argument names to reflect above
15340 changes.
15341
15342 * normal/execute.c (grub_script_execute_cmdif): Likewise.
15343
15344 * normal/script.c (grub_script_create_cmdif): Likewise.
15345
118f4fb3 153462006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
15347
15348 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
15349 top.
15350 (grub_hfsplus_btree_recptr): Likewise.
15351 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
15352 FILEBLOCK both to pass a block number and store next block
15353 number.
15354 (grub_hfsplus_read_block): Rewritten heavily to support an extent
15355 overflow file correctly. Specify errors appropriately, because
15356 fshelp expects that GRUB_ERRNO is set when fails. Reuse
15357 grub_hfsplus_btree_recptr to get the pointer to a found key.
15358 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
15359 is found.
15360
15361 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
15362 linux.mod.
15363 (_linux_mod_SOURCES): New variable.
15364 (_linux_mod_CFLAGS): Likewise.
15365 (_linux_mod_LDFLAGS): Likewise.
15366 (linux_mod_SOURCES): Likewise.
15367 (linux_mod_CFLAGS): Likewise.
15368 (linux_mod_LDFLAGS): Likewise.
15369
15370 * DISTLIST: Added loader/i386/efi/linux.c,
15371 loader/i386/efi/linux_normal.c and
15372 include/grub/i386/efi/loader.h.
15373
15374 * loader/i386/efi/linux.c: New file.
15375 * loader/i386/efi/linux_normal.c: Likewise.
15376 * include/grub/i386/efi/loader.h: Likewise.
15377
89a7d726 153782006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
15379
15380 * commands/blocklist.c: New file.
15381
15382 * DISTLIST: Added commands/blocklist.c.
15383
15384 * term/efi/console.c (grub_console_highlight_color): Use a lighter
43b553ad 15385 color for the background, and a darker color for the foreground.
89a7d726 15386 (grub_console_checkkey): Return READ_KEY.
15387 (grub_console_cls): Set the background to
15388 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
15389
15390 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
15391
15392 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
15393 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
15394
15395 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
15396 prototype.
15397
15398 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
15399 BG. The spec is wrong again.
15400
15401 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
15402 prototype.
15403 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
15404
15405 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
15406 commands/blocklist.c.
15407 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
f19dbdb7 15408
89a7d726 15409 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
15410 (blocklist_mod_SOURCES): New variable.
15411 (blocklist_mod_CFLAGS): Likewise.
15412 (blocklist_mod_LDFLAGS): Likewise.
15413
75c8f258 154142006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
15415
15416 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
15417 duplication.
15418 (lba_mode): Use %eax more intensively to reduce the code size.
15419
da2eb181 154202006-05-20 Marco Gerards <marco@gnu.org>
15421
15422 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
15423
15424 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
15425 for `menuentry'.
15426 (script): Accept leading newlines.
15427 (newlines): New rule to describe 0 or more newlines.
15428 (commands): Accept `command' with trailing newline. Fixed the
15429 order in which arguments were passed to `grub_script_add_cmd'.
15430 Accept commands separated by newlines.
15431 (function): Changed to accept newlines.
15432 (menuentry) Rewritten.
15433
15434 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
15435 front of the list, instead of to the end.
15436
577b4050 154372006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
15438
15439 * util/i386/pc/grub-install.in (bindir): New variable.
15440 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
15441 Shaver <lbgwjl@gmail.com>.
15442
0d6e1189 154432006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
15444
15445 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
15446 grub/machine/linux.h
15447 * loader/i386/pc/linux.c: Likewise.
15448
15449 * include/grub/i386/pc/linux.h: Moved to ...
15450 * include/grub/i386/linux.h: ... here.
15451
15452 * include/grub/i386/linux.h (struct linux_kernel_params): New
15453 struct.
f19dbdb7 15454
31b86e9f 154552006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
15456
15457 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
15458 checking.
15459 (grub_video_vbe_blit_glyph): Likewise.
15460 (grub_video_vbe_blit_bitmap): Likewise.
15461 (grub_video_vbe_blit_render_target): Likewise.
15462
83b984de 154632006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
15464
15465 * configure.ac (--with-platform): Properly quote the square
15466 brackets.
15467
5f0413bd 154682006-05-08 Marco Gerards <marco@gnu.org>
15469
15470 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
15471 this...
15472 (kernel_elf_HEADERS): ...to this. Updated all users.
15473 (grubof_symlist.c): Renamed from this...
15474 (kernel_elf_symlist.c): ...to this. Updated all users.
15475 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15476 (grubof_SOURCES): Renamed from this...
15477 (kernel_elf_SOURCES): ...to this.
15478 (grubof_HEADERS): Renamed from this...
15479 (kernel_elf_HEADERS): ...to this.
15480 (grubof_CFLAGS): Renamed from this...
15481 (kernel_elf_CFLAGS): ...to this.
15482 (grubof_ASFLAGS): Renamed from this...
15483 (kernel_elf_ASFLAGS): ...to this.
15484 (grubof_LDFLAGS): Renamed from this...
15485 (kernel_elf_LDFLAGS): ...to this.
15486
15487 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
15488 this...
15489 (kernel_elf_HEADERS): ...to this. Updated all users.
15490 (grubof_symlist.c): Renamed from this...
15491 (kernel_elf_symlist.c): ...to this. Updated all users.
15492 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15493 (grubof_SOURCES): Renamed from this...
15494 (kernel_elf_SOURCES): ...to this.
15495 (grubof_HEADERS): Renamed from this...
15496 (kernel_elf_HEADERS): ...to this.
15497 (grubof_CFLAGS): Renamed from this...
15498 (kernel_elf_CFLAGS): ...to this.
15499 (grubof_ASFLAGS): Renamed from this...
15500 (kernel_elf_ASFLAGS): ...to this.
15501 (grubof_LDFLAGS): Renamed from this...
15502 (kernel_elf_LDFLAGS): ...to this.
15503
15504 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
15505 `kernel.elf' instead of `grubof'.
15506
05568c2e 155072006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
15508
15509 Add --with-platform to configure. Use pkglibdir instead of
15510 pkgdatadir. This is reported by Roger Leigh.
15511
15512 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
15513 (host_vendor): Likewise.
15514 (host_os): Likewise.
15515 (pkgdatadir): Likewise.
15516 (platform): New variable.
15517 (pkglibdir): Likewise.
15518 Use PKGLIBDIR instead of PKGDATADIR.
f19dbdb7 15519
05568c2e 15520 * util/i386/pc/grub-install.in (datadir): Removed.
15521 (host_vendor): Likewise.
15522 (host_os): Likewise.
15523 (pkgdatadir): Likewise.
15524 (platform): New variable.
15525 (pkglibdir): Likewise.
15526 Use PKGLIBDIR instead of PKGDATADIR.
15527
15528 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
15529 instead of GRUB_DATADIR.
15530 (main): Likewise.
15531 * util/i386/pc/grub-mkimage.c (usage): Likewise.
15532 (main): Likewise.
15533 * util/i386/efi/grub-mkimage.c (usage): Likewise.
15534 (main): Likewise.
15535
15536 * configure.ac (--with-platform): New option.
15537 Use PLATFORM instead of HOST_VENDOR to specify a platform.
15538
15539 * Makefile.in: Include a makefile based on PLATFORM instead of
15540 HOST_VENDOR.
15541 (pkgdatadir): Not appended by the machine type.
15542 (pkglibdir): Appended by the machine type.
15543 (host_vendor): Removed.
15544 (platform): New variable.
15545 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
15546 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
15547 (uninstall): Likewise.
15548
4e93851c 155492006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
15550
15551 Use the environment context in the menu. Remove the commands
15552 "default" and "timeout", and use variables instead.
f19dbdb7 15553
4e93851c 15554 * normal/menu.c: Include grub/env.h.
15555 (print_entry): Cast TITLE to silence gcc.
15556 (get_timeout): New function.
15557 (set_timeout): Likewise.
15558 (get_entry_number): Likewise.
15559 (run_menu): Use a default entry, a fallback entry and a timeout
15560 in the environment variables "default", "fallback" and
15561 "timeout". Also, tweak the default entry if it is not within the
15562 current menu entries.
15563 (grub_menu_run): Use a fallback entry in the environment variable
15564 "fallback".
15565
15566 * normal/main.c (read_config_file): Do not initialize
15567 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
15568 NEWMENU->TIMEOUT.
15569 (grub_normal_execute): Use a data slot to store the menu.
15570
15571 * include/grub/normal.h (struct grub_menu): Removed default_entry,
15572 fallback_entry and timeout.
15573 (struct grub_menu_list): Removed.
15574 (grub_menu_list_t): Likewise.
15575 (struct grub_context): Likewise.
15576 (grub_context_t): Likewise.
15577 (grub_context_get): Likewise.
15578 (grub_context_get_current_menu): Likewise.
15579 (grub_context_push_menu): Likewise.
15580 (grub_context_pop_menu): Likewise.
15581 (grub_default_init): Likewise.
15582 (grub_default_fini): Likewise.
15583 (grub_timeout_init): Likewise.
15584 (grub_timeout_fini): Likewise.
15585
15586 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
15587 and timeout.mod.
15588 (normal_mod_SOURCES): Removed normal/context.c.
15589
15590 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
15591 commands/default.c, commands/timeout.c and normal/context.c.
15592 (normal_mod_SOURCES): Removed normal/context.c.
15593
15594 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
15595 commands/timeout.c and normal/context.c.
15596 (normal_mod_SOURCES): Removed normal/context.c.
15597
15598 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
15599 commands/default.c, commands/timeout.c and normal/context.c.
15600 (normal_mod_SOURCES): Removed normal/context.c.
15601
15602 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
15603 timeout.mod.
15604 (default_mod_SOURCES): Removed.
15605 (default_mod_CFLAGS): Likewise.
15606 (default_mod_LDFLAGS): Likewise.
15607 (timeout_mod_SOURCES): Removed.
15608 (timeout_mod_CFLAGS): Likewise.
15609 (timeout_mod_LDFLAGS): Likewise.
15610
15611 * DISTLIST: Removed commands/default.c, commands/timeout.c and
15612 normal/context.c.
15613
15614 * commands/default.c: Removed.
15615 * commands/timeout.c: Likewise.
15616 * normal/context.c: Likewise.
15617
1eb9cc1d 156182006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
15619
15620 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
15621
385bd9c1 156222006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
15623
15624 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
15625 "next" to "prev" for readability.
15626 (struct grub_env_sorted_var): New struct.
15627 (grub_env_context): Renamed to ...
15628 (initial_context): ... this.
15629 (grub_env_var_context): Renamed to ...
15630 (current_context): ... this.
15631 (grub_env_find): Look only at CURRENT_CONTEXT.
15632 (grub_env_context_open): Rewritten to copy exported variables from
15633 previous context.
15634 (grub_env_context_close): Rewritten according to the new
15635 scheme. Also, add an assertion to prevent the initial context from
15636 removed.
15637 (grub_env_insert): Removed the code for the sorted list.
15638 (grub_env_remove): Likewise.
15639 (grub_env_export): Simply mark the variable with
15640 GRUB_ENV_VAR_GLOBAL.
15641 (grub_env_set): A cosmetic change for naming consistency.
15642 (grub_env_get): Likewise.
15643 (grub_env_unset): Likewise.
15644 (grub_env_iterate): Rewritten to sort variables within this
15645 function.
15646 (grub_register_variable_hook): Fixed for naming consistency. Call
15647 grub_env_find again, only if NAME is not found at the first time.
15648 (mangle_data_slot_name): New function.
15649 (grub_env_set_data_slot): Likewise.
15650 (grub_env_get_data_slot): Likewise.
15651 (grub_env_unset_data_slot): Likewise.
15652
15653 * include/grub/env.h (grub_env_var_type): New enum.
15654 (GRUB_ENV_VAR_LOCAL): New constant.
15655 (GRUB_ENV_VAR_GLOBAL): Likewise.
15656 (GRUB_ENV_VAR_DATA): Likewise.
15657 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
15658 "type".
15659 (grub_env_set): Replace VAR with NAME for consistency.
15660 (grub_register_variable_hook): Likewise.
15661 (grub_env_export): Specify the name of the argument.
15662 (grub_env_set_data_slot): New prototype.
15663 (grub_env_get_data_slot): Likewise.
15664 (grub_env_unset_data_slot): Likewise.
15665
7f362539 156662006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
15667
15668 Extend the loader so that GRUB can accept a loader which comes
15669 back to GRUB when a loaded image exits. Also, this change adds
15670 support for a chainloader on EFI.
f19dbdb7 15671
7f362539 15672 * term/efi/console.c: Include grub/misc.h.
15673 (grub_console_checkkey): Display a scan code on the top for
15674 debugging. This will be removed once the EFI port gets stable.
15675 Correct the scan code mapping.
15676
15677 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
15678 allocate memory from larger regions, in order to reduce the number
15679 of allocated regions. Otherwise, the MacOSX loader panics.
15680 (filter_memory_map): Avoid less than 1MB for compatibility with
15681 other loaders.
15682 (add_memory_regions): Allocate from the tail of a region, if
15683 possible, to avoid allocating a region near to 1MB, for the MacOSX
15684 loader.
15685
15686 * kern/efi/init.c (grub_efi_set_prefix): Specify
15687 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
15688
15689 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
15690 argument IMAGE_HANDLE and specify it to get a loaded image.
15691 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
15692 grub_efi_get_loaded_image.
fe6b695a 15693 (grub_efi_get_filename): Divide the length by the size of
7f362539 15694 grub_efi_char16_t.
15695 (grub_efi_get_device_path): New function.
15696 (grub_efi_print_device_path): Print End Device Path nodes. Divide
15697 the length by the size of grub_efi_char16_t for a file path device
15698 path node.
15699
15700 * kern/loader.c (grub_loader_noreturn): New variable.
15701 (grub_loader_set): Accept a new argument NORETURN. Set
15702 GRUB_LOADER_NORETURN to NORETURN.
15703 All callers changed.
15704 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
15705 grub_machine_fini.
15706
15707 * include/grub/efi/efi.h (grub_efi_get_device_path): New
15708 prototype.
15709 (grub_efi_get_loaded_image): Take an argument to specify an image
15710 handle.
15711
15712 * include/grub/loader.h (grub_loader_set): Added one more argument
15713 NORETURN.
15714
15715 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
15716 instead of grub_efi_open_protocol.
15717 (grub_efidisk_get_device_name): Likewise.
15718 (grub_efidisk_close): Print a newline.
15719 (grub_efidisk_get_device_handle): Fixed to use
15720 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
15721 GRUB_EFI_DEVICE_PATH_TYPE.
15722
15723 * disk/efi/efidisk.c (device_path_guid): Moved to ...
15724 * kern/efi/efi.c (device_path_guid): ... here.
15725
15726 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
15727 chain.mod.
15728 (kernel_mod_HEADERS): Added efi/disk.h.
15729 (_chain_mod_SOURCES): New variable.
15730 (_chain_mod_CFLAGS): Likewise.
15731 (_chain_mod_LDFLAGS): Likewise.
15732 (chain_mod_SOURCES): Likewise.
15733 (chain_mod_CFLAGS): Likewise.
15734 (chain_mod_LDFLAGS): Likewise.
15735
15736 * DISTLIST: Added include/grub/efi/chainloader.h,
15737 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
15738
15739 * include/grub/efi/chainloader.h: New file.
15740 * loader/efi/chainloader.c: Likewise.
15741 * loader/efi/chainloader_normal.c: Likewise.
15742
c0111d6e 157432006-04-30 Marco Gerards <marco@gnu.org>
15744
15745 * commands/configfile.c (grub_cmd_source): New function.
15746 (GRUB_MOD_INIT): Register the commands `source' and `.'.
15747 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
15748
df5341da 157492006-04-30 Marco Gerards <marco@gnu.org>
15750
15751 * normal/execute.c (grub_script_execute_cmd): Change the return
15752 type to `grub_err_t'. Correctly return the error.
15753 (grub_script_execute_cmdline): In case a command line is not a
15754 command or a function, try to interpret it as an assignment.
15755
f85934bd 157562006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
15757
15758 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
15759 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
15760 skip a node whose name is obviously invalid as UTF-16,
15761 i.e. contains a NUL character. Stop the iteration when the last
15762 directory entry is found. Instead of using the return value of
15763 grub_hfsplus_btree_iterate_node, store the value in RET and use
15764 it, because the iterator can be stopped by the last directory
15765 entry.
15766
8f8a2cf8 157672006-04-30 Marco Gerards <marco@gnu.org>
15768
15769 * include/grub/env.h (grub_env_export): New prototype. Reported
15770 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
15771
a27e84ce 157722006-04-30 Marco Gerards <marco@gnu.org>
15773
15774 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
15775 size of the extents in a catalog file record.
15776
eaef0553 157772006-04-29 Marco Gerards <marco@gnu.org>
15778
15779 * commands/configfile.c (grub_cmd_configfile): Execute the
15780 configfile within its own context.
15781
15782 * include/grub/env.h (grub_env_context_open): New prototype.
15783 (grub_env_context_close): Likewise.
15784
15785 * kern/env.c (grub_env): Removed.
15786 (grub_env_sorted): Likewise.
15787 (grub_env_context): New variable.
15788 (grub_env_var_context): Likewise.
15789 (grub_env_find): Search both the active context and the global
15790 context.
15791 (grub_env_context_open): New function.
15792 (grub_env_context_close): Likewise.
15793 (grub_env_insert): Likewise.
15794 (grub_env_remove): Likewise.
15795 (grub_env_export): Likewise.
15796 (grub_env_set): Changed to use helper functions to avoid code
15797 duplication.
15798 (grub_env_iterate): Rewritten so both the current context and the
15799 global context are being used.
15800
15801 * normal/command.c (export_command): New function.
15802 (grub_command_init): Register the `export' function.
15803
7b455f4d 158042006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
15805
15806 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
15807 explicitly to suppress gcc's warnings.
15808 * fs/fat.c (grub_fat_find_dir): Likewise.
15809 (grub_fat_label): Likewise.
15810 * fs/xfs.c (grub_xfs_read_inode): Likewise.
15811 (grub_xfs_mount): Likewise.
15812 (grub_xfs_label): Likewise.
15813 * fs/affs.c (grub_affs_mount): Likewise.
15814 (grub_affs_label): Likewise.
15815 (grub_affs_iterate_dir): Likewise.
15816 * fs/sfs.c (grub_sfs_mount): Likewise.
15817 (grub_sfs_iterate_dir): Likewise.
15818 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
15819 * fs/hfs.c (grub_hfs_mount): Likewise.
15820 (grub_hfs_cmp_catkeys): Likewise.
15821 (grub_hfs_find_dir): Likewise.
15822 (grub_hfs_dir): Likewise.
15823 (grub_hfs_label): Likewise.
15824 * fs/jfs.c (grub_jfs_mount): Likewise.
15825 (grub_jfs_opendir): Likewise.
15826 (grub_jfs_getent): Likewise.
15827 (grub_jfs_lookup_symlink): Likewise.
15828 (grub_jfs_label): Likewise.
15829 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
15830 (grub_hfsplus_iterate_dir): Likewise.
15831 (grub_hfsplus_btree_iterate_node): Made static.
15832
15833 * util/grub-emu.c (prefix): New variable.
15834 (grub_machine_set_prefix): New function.
15835 (main): Do not set the environment variable "prefix" here. Only
15836 set PREFIX, which is used later by grub_machine_set_prefix.
15837
15838 * include/grub/video.h: Do not include grub/symbol.h.
15839 (grub_video_register): Not exported. This symbol is not defined in
15840 the kernel.
15841 (grub_video_unregister): Likewise.
15842 (grub_video_iterate): Likewise.
15843 (grub_video_setup): Likewise.
15844 (grub_video_restore): Likewise.
15845 (grub_video_get_info): Likewise.
15846 (grub_video_get_blit_format): Likewise.
15847 (grub_video_set_palette): Likewise.
15848 (grub_video_get_palette): Likewise.
15849 (grub_video_set_viewport): Likewise.
15850 (grub_video_get_viewport): Likewise.
15851 (grub_video_map_color): Likewise.
15852 (grub_video_map_rgb): Likewise.
15853 (grub_video_map_rgba): Likewise.
15854 (grub_video_fill_rect): Likewise.
15855 (grub_video_blit_glyph): Likewise.
15856 (grub_video_blit_bitmap): Likewise.
15857 (grub_video_blit_render_target): Likewise.
15858 (grub_video_scroll): Likewise.
15859 (grub_video_swap_buffers): Likewise.
15860 (grub_video_create_render_target): Likewise.
15861 (grub_video_delete_render_target): Likewise.
15862 (grub_video_set_active_render_target): Likewise.
15863
15864 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
15865 Undefined.
15866 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
15867
15868 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
15869 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
15870 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
15871 instead of $(srcdir)/genkernsyms.sh.
15872
15873 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
15874 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
15875 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
15876 instead of $(srcdir)/genkernsyms.sh.
15877
15878 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
15879 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
15880 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
15881 instead of $(srcdir)/genkernsyms.sh.
15882
15883 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
15884 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
15885 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
15886 instead of $(srcdir)/genkernsyms.sh.
15887
15888 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
15889 genkernsyms.sh.
15890
15891 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
15892 genkernsyms.sh.
15893 (gensymlist.sh): New target.
15894 (genkernsyms.sh): Likewise.
15895
15896 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
15897 genkernsyms.sh.in and gensymlist.sh.in.
15898
15899 * genkernsyms.sh: Removed.
15900 * gensymlist.sh: Likewise.
f19dbdb7 15901
7b455f4d 15902 * genkernsyms.sh.in: New file.
15903 * gensymlist.sh.in: Likewise.
15904
1885bb27 159052006-04-25 Hollis Blanchard <hollis@penguinppc.org>
15906
15907 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
15908 clobber "prefix", since we may have already set it manually.
15909
71538dff 159102006-04-25 Hollis Blanchard <hollis@penguinppc.org>
15911
15912 * kern/misc.c (abort): New alias for grub_abort.
15913
2965c7cc 159142006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
15915
15916 A new machine-specific function "grub_machine_set_prefix" is
15917 defined. This is called after loading modules, so that a prefix
15918 initialization can use modules. Also, this change adds an
15919 intensive debugging feature for the memory manager via the
15920 configure option "--enable-mm-debug".
f19dbdb7 15921
2965c7cc 15922 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
15923 PART.LEN.
15924
15925 * kern/sparc64/ieee1275/init.c (abort): Removed.
15926 (grub_stop): Likewise.
15927 (grub_exit): New function.
15928 (grub_set_prefix): Renamed to ...
15929 (grub_machine_set_prefix): ... this.
15930 (grub_machine_init): Do not call grub_set_prefix.
15931
15932 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
15933 (grub_machine_set_prefix): ... this.
15934 (grub_machine_init): Do not call grub_set_prefix.
15935
15936 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
15937 (grub_machine_init): Do not set the prefix here.
15938
15939 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
15940
15941 * kern/efi/init.c: Include grub/mm.h.
15942 (grub_efi_set_prefix): New function.
15943
15944 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
15945 (grub_efi_get_filename): New function.
15946 (grub_print_device_path): Renamed to ...
15947 (grub_efi_print_device_path): ... this.
15948
15949 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
15950 [MM_DEBUG] (grub_realloc): Likewise.
15951 [MM_DEBUG] (grub_free): Likewise.
15952 [MM_DEBUG] (grub_memalign): Likewise.
15953 [MM_DEBUG] (grub_mm_debug): New variable.
15954 [MM_DEBUG] (grub_debug_malloc): New function.
15955 [MM_DEBUG] (grub_debug_free): New function.
15956 [MM_DEBUG] (grub_debug_realloc): New function.
15957 [MM_DEBUG] (grub_debug_memalign): New function.
15958
15959 * kern/misc.c (grub_abort): Print a newline to distinguish
15960 the message.
15961
15962 * kern/main.c (grub_main): Call grub_machine_set_prefix and
15963 grub_set_root_dev after loading modules. This is necessary when
15964 setting a prefix depends on modules.
15965
15966 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
15967 (grub_efi_print_device_path): ... this.
15968 (grub_efi_get_filename): New prototype.
15969 (grub_efi_set_prefix): Likewise.
15970
15971 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
15972 and grub/disk.h.
15973 (grub_efidisk_get_device_handle): New prototype.
15974 (grub_efidisk_get_device_name): Likewise.
15975
15976 * include/grub/mm.h: Include config.h.
15977 (MM_DEBUG): Removed.
15978 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
15979 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
15980 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
15981 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
15982 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
15983 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
15984 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
15985 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
15986 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
15987
15988 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
15989
15990 * disk/efi/efidisk.c: Include grub/partition.h.
15991 (iterate_child_devices): New function.
15992 (add_device): First, compare only last device path nodes, so that
15993 devices are sorted by the types.
15994 (grub_efidisk_get_device_handle): New function.
15995 (grub_efidisk_get_device_name): Likewise.
15996
15997 * configure.ac (--enable-mm-debug): New option to enable the
15998 memory manager debugging feature. This makes the binary much
15999 bigger, so is disabled by default.
16000
9cacaa17 160012006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
16002
16003 Use grub_abort instead of grub_stop, and grub_exit must be
16004 define in each architecture now. Also, this change adds support
16005 for EFI disks.
f19dbdb7 16006
9cacaa17 16007 * util/i386/pc/grub-probefs.c: Include grub/term.h.
16008 (grub_getkey): New function.
16009 (grub_term_get_current): Likewise.
16010
16011 * util/i386/pc/grub-setup.c: Include grub/term.h.
16012 (grub_getkey): New function.
16013 (grub_term_get_current): Likewise.
16014
16015 * util/misc.c (grub_stop): Renamed to ...
16016 (grub_exit): ... this.
16017
16018 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
16019 (grub_exit): ... this.
16020 (grub_machine_init): Use grub_abort instead of abort.
16021 (grub_stop): Removed.
16022
16023 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
16024 abort.
16025
16026 * kern/i386/pc/startup.S (grub_exit): New function.
16027 (cold_reboot): New label.
16028
16029 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
16030 (grub_efi_init): Call grub_efidisk_init.
16031 (grub_efi_fini): Call grub_efidisk_fini.
16032
16033 * kern/efi/efi.c: Include grub/mm.h.
16034 (grub_efi_console_control_guid): Renamed to ...
16035 (console_control_guid): ... this.
16036 (grub_efi_loaded_image_guid): Renamed to ...
16037 (loaded_image_guid): ... this.
16038 (grub_efi_locate_handle): New function.
16039 (grub_efi_open_protocol): Likewise.
16040 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
16041 GRUB_EFI_CONSOLE_CONTROL_GUID.
16042 (grub_efi_exit): Removed.
16043 (grub_stop): Likewise.
16044 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
16045 (grub_exit): New function.
16046 (grub_print_device_path): Likewise.
16047
16048 * kern/rescue.c (grub_rescue_cmd_exit): New function.
16049 (grub_enter_rescue_mode): Register "exit".
16050
16051 * kern/misc.c (grub_real_dprintf): A cosmetic change.
16052 (grub_abort): New function.
16053
16054 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
16055
16056 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
16057
16058 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
16059
16060 * include/grub/efi/efi.h (grub_efi_exit): Removed.
16061 (grub_print_device_path): New prototype.
16062 (grub_efi_locate_handle): Likewise.
16063 (grub_efi_open_protocol): Likewise.
16064
16065 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
16066 * disk/efi/efidisk.c: Likewise.
16067
16068 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
16069
16070 * include/grub/efi/console_control.h
16071 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
16072
16073 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
16074 last 8 bytes as an array.
16075 (GRUB_EFI_DISK_IO_GUID): New macro.
16076 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
16077 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
16078 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
16079 grub_uint8_t.
16080 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
16081 (struct grub_efi_device_path): Rename the member "sub_type" to
16082 "subtype".
16083 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
16084 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
16085 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
16086 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
16087 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
16088 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
16089 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
16090 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
16091 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
16092 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
16093 (struct grub_efi_pci_device_path): New structure.
16094 (grub_efi_pci_device_path_t): New type.
16095 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
16096 (struct grub_efi_pccard_device_path): New structure.
16097 (grub_efi_pccard_device_path_t): New type.
16098 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
16099 (struct grub_efi_memory_mapped_device_path): New structure.
16100 (grub_efi_memory_mapped_device_path_t): New type.
16101 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
16102 (struct grub_efi_vendor_device_path): New structure.
16103 (grub_efi_vendor_device_path_t): New type.
16104 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
16105 (struct grub_efi_controller_device_path): New structure.
16106 (grub_efi_controller_device_path_t): New type.
16107 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
16108 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
16109 (struct grub_efi_acpi_device_path): New structure.
16110 (grub_efi_acpi_device_path_t): New type.
16111 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
16112 (struct grub_efi_expanded_acpi_device_path): New structure.
16113 (grub_efi_expanded_acpi_device_path_t): New type.
16114 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
16115 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
16116 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
16117 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
16118 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
16119 (struct grub_efi_atapi_device_path): New structure.
16120 (grub_efi_atapi_device_path_t): New type.
16121 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
16122 (struct grub_efi_fibre_channel_device_path): New structure.
16123 (grub_efi_fibre_channel_device_path_t): New type.
16124 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
16125 (struct grub_efi_1394_device_path): New structure.
16126 (grub_efi_1394_device_path_t): New type.
16127 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
16128 (struct grub_efi_usb_device_path): New structure.
16129 (grub_efi_usb_device_path_t): New type.
16130 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
16131 (struct grub_efi_usb_class_device_path): New structure.
16132 (grub_efi_usb_class_device_path_t): New type.
16133 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
16134 (struct grub_efi_i2o_device_path): New structure.
16135 (grub_efi_i2o_device_path_t): New type.
16136 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
16137 (struct grub_efi_mac_address_device_path): New structure.
16138 (grub_efi_mac_address_device_path_t): New type.
16139 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
16140 (struct grub_efi_ipv4_device_path): New structure.
16141 (grub_efi_ipv4_device_path_t): New type.
16142 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
16143 (struct grub_efi_ipv6_device_path): New structure.
16144 (grub_efi_ipv6_device_path_t): New type.
16145 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
16146 (struct grub_efi_infiniband_device_path): New structure.
16147 (grub_efi_infiniband_device_path_t): New type.
16148 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
16149 (struct grub_efi_uart_device_path): New structure.
16150 (grub_efi_uart_device_path_t): New type.
16151 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
16152 (struct grub_efi_vendor_messaging_device_path): New structure.
16153 (grub_efi_vendor_messaging_device_path_t): New type.
16154 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
16155 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
16156 (struct grub_efi_hard_drive_device_path): New structure.
16157 (grub_efi_hard_drive_device_path_t): New type.
16158 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
16159 (struct grub_efi_cdrom_device_path): New structure.
16160 (grub_efi_cdrom_device_path_t): New type.
16161 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
16162 (struct grub_efi_vendor_media_device_path): New structure.
16163 (grub_efi_vendor_media_device_path_t): New type.
16164 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
16165 (struct grub_efi_file_path_device_path): New structure.
16166 (grub_efi_file_path_device_path_t): New type.
16167 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
16168 (struct grub_efi_protocol_device_path): New structure.
16169 (grub_efi_protocol_device_path_t): New type.
16170 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
16171 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
16172 (struct grub_efi_bios_device_path): New structure.
16173 (grub_efi_bios_device_path_t): New type.
16174 (struct grub_efi_disk_io): New structure.
16175 (grub_efi_disk_io_t): New type.
16176 (struct grub_efi_block_io_media): New structure.
16177 (grub_efi_block_io_media_t): New type.
16178 (struct grub_efi_block_io): New structure.
16179 (grub_efi_block_io_t): New type.
16180
16181 * include/grub/misc.h (grub_stop): Removed.
16182 (grub_exit): New prototype.
16183 (grub_abort): Likewise.
16184
16185 * include/grub/disk.h (enum grub_disk_dev_id): Added
16186 GRUB_DISK_DEVICE_EFIDISK_ID.
16187
16188 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
16189 disk/efi/efidisk.c.
16190 (kernel_syms.lst): Remove the target if an error occurs.
16191
49986a9f 161922006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
16193
16194 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
16195 as it was simply too buggy.
16196
970d3b8a 161972006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
16198
16199 * kern/misc.c (grub_lltoa): New function.
16200 (grub_vsprintf): Added support for the long long suffix,
16201 i.e. "ll".
16202
ff04ec24 162032006-04-20 Hollis Blanchard <hollis@penguinppc.org>
16204
16205 * Makefile.in (LDFLAGS): Add variable.
16206 (LD): Remove variable.
16207 * configure.ac: Add -m32 to LDFLAGS.
16208 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
16209 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
16210 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
16211 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
16212 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
16213 variables.
16214 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
16215 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
16216 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
16217
37e5e1a4 162182006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
16219
16220 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
16221 length for unknown glyph.
16222
c352d8dd 162232006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
16224
2eab1c0d 16225 Add support for pre-loaded modules into the EFI port.
f19dbdb7 16226
2eab1c0d 16227 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
16228 completely. Accept one more argument DIR. The caller has changed.
16229
16230 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
16231
16232 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
16233 (grub_efi_loaded_image_guid): New variable.
16234 (grub_efi_get_loaded_image): New function.
16235 (grub_arch_modules_addr): Likewise.
16236
16237 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
16238 prototype.
16239
16240 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
16241 (struct grub_efi_loaded_image): New structure.
16242 (grub_efi_loaded_image_t): New type.
16243
162442006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 16245
c352d8dd 16246 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
16247 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
16248 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
16249
6d01d6b4 162502006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
16251
16252 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
16253
976a4ea0 162542006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
16255
16256 * DISTLIST: Added include/grub/efi/console.h,
16257 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
16258 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16259
16260 * include/grub/efi/console.h: New file.
16261 * include/grub/efi/time.h: Likewise.
16262 * include/grub/i386/efi/kernel.h: Likewise.
16263 * kern/efi/init.c: Likewise.
16264 * kern/efi/mm.c: Likewise.
16265 * term/efi/console.c: Likewise.
f19dbdb7 16266
976a4ea0 16267 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
16268 (grub_stop): Removed.
16269 (grub_get_rtc): Likewise.
16270 (grub_machine_init): Simply call grub_efi_init.
16271 (grub_machine_fini): Call grub_efi_fini.
16272
16273 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
16274 (grub_efi_output_string): Removed.
16275 (grub_efi_stall): New function.
16276 (grub_stop): Likewise.
16277 (grub_get_rtc): Likewise.
16278
16279 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
16280 (grub_efi_stall): New prototype.
16281 (grub_efi_allocate_pages): Likewise.
16282 (grub_efi_free_pages): Likewise.
16283 (grub_efi_get_memory_map): Likewise.
16284 (grub_efi_mm_init): Likewise.
16285 (grub_efi_mm_fini): Likewise.
16286 (grub_efi_init): Likewise.
16287 (grub_efi_fini): Likewise.
16288
16289 * include/grub/i386/efi/time.h: Do not include
16290 grub/symbol.h. Include grub/efi/time.h.
16291 (GRUB_TICKS_PER_SECOND): Removed.
16292 (grub_get_rtc): Likewise.
16293
16294 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
16295 Added padding. The EFI spec is buggy.
16296 (GRUB_EFI_BLACK): New macro.
16297 (GRUB_EFI_BLUE): Likewise.
16298 (GRUB_EFI_GREEN): Likewise.
16299 (GRUB_EFI_CYAN): Likewise.
16300 (GRUB_EFI_RED): Likewise.
16301 (GRUB_EFI_MAGENTA): Likewise.
16302 (GRUB_EFI_BROWN): Likewise.
16303 (GRUB_EFI_LIGHTGRAY): Likewise.
16304 (GRUB_EFI_BRIGHT): Likewise.
16305 (GRUB_EFI_DARKGRAY): Likewise.
16306 (GRUB_EFI_LIGHTBLUE): Likewise.
16307 (GRUB_EFI_LIGHTGREEN): Likewise.
16308 (GRUB_EFI_LIGHTCYAN): Likewise.
16309 (GRUB_EFI_LIGHTRED): Likewise.
16310 (GRUB_EFI_LIGHTMAGENTA): Likewise.
16311 (GRUB_EFI_YELLOW): Likewise.
16312 (GRUB_EFI_WHITE): Likewise.
16313 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
16314 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
16315 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
16316 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
16317 (GRUB_EFI_BACKGROUND_RED): Likewise.
16318 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
16319 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
16320 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
16321 (GRUB_EFI_TEXT_ATTR): Likewise.
16322
16323 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
16324 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16325 (kernel_mod_HEADERS): Added efi/time.h.
16326
83709125 163272006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
16328
16329 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
16330 include/grub/efi/api.h, include/grub/efi/console_control.h,
16331 include/grub/efi/efi.h, include/grub/efi/pe32.h,
16332 include/grub/i386/efi/time.h, kern/efi/efi.c,
16333 kern/i386/efi/init.c, kern/i386/efi/startup.S,
16334 and util/i386/efi/grub-mkimage.c.
16335
16336 * Makefile.in (RMKFILES): Added i386-efi.rmk.
16337
16338 * genmk.rb (PModule#rule): Do not export symbols if
16339 #{prefix}_EXPORTS is set to "no".
16340
16341 * conf/i386-efi.mk: New file.
16342 * conf/i386-efi.rmk: Likewise.
16343 * include/grub/efi/api.h: Likewise.
16344 * include/grub/efi/console_control.h: Likewise.
16345 * include/grub/efi/efi.h: Likewise.
16346 * include/grub/efi/pe32.h: Likewise.
16347 * include/grub/i386/efi/time.h: Likewise.
16348 * kern/efi/efi.c: Likewise.
16349 * kern/i386/efi/init.c: Likewise.
16350 * kern/i386/efi/startup.S: Likewise.
16351 * util/i386/efi/grub-mkimage.c: Likewise.
16352
163532006-04-17 Marco Gerards <marco@gnu.org>
bfa2bd9e 16354
16355 * include/grub/script.h: Include <grub/parser.h> and
16356 "grub_script.tab.h".
16357 (struct grub_lexer_param): New struct.
16358 (struct grub_parser_param): Likewise.
16359 (grub_script_create_arglist): Pass the state in an argument.
16360 (grub_script_add_arglist): Likewise.
16361 (grub_script_create_cmdline): Likewise.
16362 (grub_script_create_cmdblock): Likewise.
16363 (grub_script_create_cmdif): Likewise.
16364 (grub_script_create_cmdmenu): Likewise.
16365 (grub_script_add_cmd): Likewise.
16366 (grub_script_arg_add): Likewise.
16367 (grub_script_lexer_ref): Likewise.
16368 (grub_script_lexer_deref): Likewise.
16369 (grub_script_lexer_record_start): Likewise.
16370 (grub_script_lexer_record_stop): Likewise.
16371 (grub_script_mem_record): Likewise.
16372 (grub_script_mem_record_stop): Likewise.
16373 (grub_script_malloc): Likewise.
16374 (grub_script_yylex): Likewise.
16375 (grub_script_yyparse): Likewise.
16376 (grub_script_yyerror): Likewise.
16377 (grub_script_yylex): Likewise.
16378 (grub_script_lexer_init): Return the state.
16379
16380 * normal/lexer.c (grub_script_lexer_state): Removed variable.
16381 (grub_script_lexer_done): Likewise.
16382 (grub_script_lexer_getline): Likewise.
16383 (grub_script_lexer_refs): Likewise.
16384 (script): Likewise.
16385 (newscript): Likewise.
16386 (record): Likewise.
16387 (recording): Likewise.
16388 (recordpos): Likewise.
16389 (recordlen): Likewise.
16390 (grub_script_lexer_init): Return the state instead of setting
16391 global variables.
16392 (grub_script_lexer_ref): Use the newly added argument for state
16393 instead of globals.
16394 (grub_script_lexer_deref): Likewise.
16395 (grub_script_lexer_record_start): Likewise.
16396 (grub_script_lexer_record_stop): Likewise.
16397 (recordchar): Likewise.
16398 (nextchar): Likewise.
16399 (grub_script_yylex2): Likewise.
16400 (grub_script_yylex): Likewise.
16401 (grub_script_yyerror): Likewise.
16402
16403 * normal/parser.y (func_mem): Removed variable.
16404 (menu_entry): Likewise.
16405 (err): Likewise.
16406 (%lex-param): New parser option.
16407 (%parse-param): Likewise.
16408 (script): Always return the AST.
16409 (argument): Pass the state around.
16410 (arguments): Likewise.
16411 (grubcmd): Likewise.
16412 (commands): Likewise.
16413 (function): Likewise.
16414 (menuentry): Likewise.
16415 (if_statement): Likewise.
16416 (if): Likewise.
16417
16418 * normal/script.c (grub_script_memused): Removed variable.
16419 (grub_script_parsed): Likewise.
16420 (grub_script_malloc): Added a state argument. Use that instead of
16421 global variables.
16422 (grub_script_mem_record): Likewise.
16423 (grub_script_mem_record_stop): Likewise.
16424 (grub_script_arg_add): Likewise.
16425 (grub_script_add_arglist): Likewise.
16426 (grub_script_create_cmdline): Likewise.
16427 (grub_script_create_cmdif): Likewise.
16428 (grub_script_create_cmdmenu): Likewise.
16429 (grub_script_add_cmd): Likewise.
16430 (grub_script_parse): Setup the state before calling the parser.
f19dbdb7 16431
e2a8c904 164322006-04-16 Marco Gerards <marco@gnu.org>
6de2ee99 16433
16434 * normal/command.c (grub_command_init): Remove the title command.
16435
16436 * normal/lexer.c (grub_script_yylex): Renamed from this...
16437 (grub_script_yylex2): ... to this.
16438 (grub_script_yylex): New function. Temporary
16439 introduced to filter some tokens.
16440 (grub_script_yyerror): Print a newline.
16441
16442 * normal/main.c (read_config_file): Output information about the
16443 lines that contain errors. Wait for a key after all lines have
16444 been processed. Don't return an empty menu.
16445
16446 * normal/parser.y (func_mem): Don't initialize.
16447 (menu_entry): Likewise.
16448 (err): New variable.
16449 (script): Don't return anything when an error was encountered.
16450 (ws, returns): Removed rules.
16451 (argument): Disabled concatenated variable support.
16452 (arguments): Remove explicit separators.
16453 (grubcmd): Likewise.
16454 (function): Likewise.
16455 (menuentry): Likewise.
16456 (if): Likewise.
16457 (commands): Likewise. Add error handling.
16458
16459 * normal/script.c (grub_script_create_cmdline): If
16460 `grub_script_parsed' is 0, assume the parser encountered an error.
16461
c9a86192 164622006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
16463
16464 * configure.ac: Add support for EFI. Fix the typo
16465 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
16466
70f3b243 164672006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16468
16469 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
16470 foreign multibyte characters should be shown correctly.
16471
65f201ad 164722006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16473
16474 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
16475 calculation.
16476 (read_config_file): Made it to close file before returning.
16477
b4b93674 164782006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
16479
16480 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
16481 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
16482 video/i386/pc/vbefill.c.
16483
16484 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
16485 video/i386/pc/vbefill.c.
16486
16487 * include/grub/video.h (grub_video_blit_format): New enum.
16488 (grub_video_mode_info): Added new member blit_format.
16489 (grub_video_get_blit_format): New function prototype.
16490
16491 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
16492 function prototype.
16493 (grub_video_vbe_map_rgb): Likewise.
16494 (grub_video_vbe_unmap_color): Likewise.
16495
16496 * include/grub/i386/pc/vbeblit.h: New file.
16497
16498 * include/grub/i386/pc/vbefill.h: New file.
16499
16500 * video/video.c (grub_video_get_blit_format): New function.
16501 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
16502 (grub_video_vbe_map_rgb): Likewise.
16503 (grub_video_vbe_unmap_color): Likewise.
16504
16505 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
16506 optimized fills.
16507 (grub_video_vbe_blit_render_target): Changed to use more optimized
16508 blits.
16509 (grub_video_vbe_setup): Added detection for optimized settings.
16510 (grub_video_vbe_create_render_target): Likewise.
16511
16512 * video/i386/pc/vbeblit.c: New file.
16513
16514 * video/i386/pc/vbefill.c: New file.
16515
c2379b9c 165162006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
16517
16518 * font/manager.c (grub_font_get_glyph): Removed font fixup from
16519 here...
16520
16521 * util/unifont2pff.rb: ... and moved it to here. Improved argument
16522 parsing to support both hex and dec ranges. If filename was missing
16523 show usage information.
16524
bd0d7896 165252006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
16526
16527 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
16528 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
16529
16530 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
16531 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
16532 (video_mod_SOURCES): Added.
16533 (video_mod_CFLAGS): Likewise.
16534 (video_mod_LDFLAGS): Likewise.
16535 (gfxterm_mod_SOURCES): Likewise.
16536 (gfxterm_mod_CFLAGS): Likewise.
16537 (gfxterm_mod_LDFLAGS): Likewise.
16538 (videotest_mod_SOURCES): Likewise.
16539 (videotest_mod_CFLAGS): Likewise.
16540 (videotest_mod_LDFLAGS): Likewise.
16541 (vesafb_mod_SOURCES): Removed.
16542 (vesafb_mod_CFLAGS): Likewise.
16543 (vesafb_mod_LDFLAGS): Likewise.
16544 (vga_mod_SOURCES): Likewise.
16545 (vga_mod_CFLAGS): Likewise.
16546 (vga_mod_LDFLAGS): Likewise.
16547
16548 * commands/videotest.c: New file.
16549
16550 * font/manager.c (fill_with_default_glyph): Modified to use
16551 grub_font_glyph.
16552 (grub_font_get_glyph): Likewise.
16553 (fontmanager): Renamed from this...
16554 (font_manager): ... to this.
16555
16556 * include/grub/font.h (grub_font_glyph): Added new structure.
16557 (grub_font_get_glyph): Modified to use grub_font_glyph.
16558
16559 * include/grub/misc.h (grub_abs): Added as inline function.
16560
16561 * include/grub/video.h: New file.
16562
16563 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
16564 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
16565 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
16566 (grub_vbe_get_controller_info): Renamed from this...
16567 (grub_vbe_bios_get_controller_info): ... to this.
16568 (grub_vbe_get_mode_info): Renamed from this...
16569 (grub_vbe_bios_get_mode_info): ... to this.
16570 (grub_vbe_set_mode): Renamed from this...
16571 (grub_vbe_bios_set_mode): ... to this.
16572 (grub_vbe_get_mode): Renamed from this...
16573 (grub_vbe_bios_get_mode): ... to this.
16574 (grub_vbe_set_memory_window): Renamed from this...
16575 (grub_vbe_bios_set_memory_window): ... to this.
16576 (grub_vbe_get_memory_window): Renamed from this...
16577 (grub_vbe_bios_get_memory_window): ... to this.
16578 (grub_vbe_set_scanline_length): Renamed from this...
16579 (grub_vbe_set_scanline_length): ... to this.
16580 (grub_vbe_get_scanline_length): Renamed from this...
16581 (grub_vbe_bios_get_scanline_length): ... to this.
16582 (grub_vbe_set_display_start): Renamed from this...
16583 (grub_vbe_bios_set_display_start): ... to this.
16584 (grub_vbe_get_display_start): Renamed from this...
16585 (grub_vbe_bios_get_display_start): ... to this.
16586 (grub_vbe_set_palette_data): Renamed from this...
16587 (grub_vbe_bios_set_palette_data): ... to this.
16588 (grub_vbe_set_pixel_rgb): Removed.
16589 (grub_vbe_set_pixel_index): Likewise.
16590
16591 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
16592 from this...
16593 (grub_vbe_bios_get_controller_info): ... to this.
16594 (grub_vbe_get_mode_info): Renamed from this...
16595 (grub_vbe_bios_get_mode_info): ... to this.
16596 (grub_vbe_set_mode): Renamed from this...
16597 (grub_vbe_bios_set_mode): ... to this.
16598 (grub_vbe_get_mode): Renamed from this...
16599 (grub_vbe_bios_get_mode): ... to this.
16600 (grub_vbe_set_memory_window): Renamed from this...
16601 (grub_vbe_bios_set_memory_window): ... to this.
16602 (grub_vbe_get_memory_window): Renamed from this...
16603 (grub_vbe_bios_get_memory_window): ... to this.
16604 (grub_vbe_set_scanline_length): Renamed from this...
16605 (grub_vbe_set_scanline_length): ... to this.
16606 (grub_vbe_get_scanline_length): Renamed from this...
16607 (grub_vbe_bios_get_scanline_length): ... to this.
16608 (grub_vbe_set_display_start): Renamed from this...
16609 (grub_vbe_bios_set_display_start): ... to this.
16610 (grub_vbe_get_display_start): Renamed from this...
16611 (grub_vbe_bios_get_display_start): ... to this.
16612 (grub_vbe_set_palette_data): Renamed from this...
16613 (grub_vbe_bios_set_palette_data): ... to this.
16614 (grub_vbe_bios_get_controller_info): Fixed problem with registers
16615 getting corrupted after calling it. Added more pushes and pops.
16616 (grub_vbe_bios_set_mode): Likewise.
16617 (grub_vbe_bios_get_mode): Likewise.
16618 (grub_vbe_bios_get_memory_window): Likewise.
16619 (grub_vbe_bios_set_scanline_length): Likewise.
16620 (grub_vbe_bios_get_scanline_length): Likewise.
16621 (grub_vbe_bios_get_display_start): Likewise.
16622 (grub_vbe_bios_set_palette_data): Likewise.
16623
16624 * normal/cmdline.c (cl_set_pos): Refresh the screen.
16625 (cl_insert): Likewise.
16626 (cl_delete): Likewise.
16627
16628 * term/gfxterm.c: New file.
16629
16630 * term/i386/pc/vesafb.c: Removed file.
16631
16632 * video/video.c: New file.
16633
16634 * video/i386/pc/vbe.c (real2pm): Added new function.
16635 (grub_video_vbe_draw_pixel): Likewise.
16636 (grub_video_vbe_get_video_ptr): Likewise.
16637 (grub_video_vbe_get_pixel): Likewise
16638 (grub_video_vbe_init): Likewise.
16639 (grub_video_vbe_fini): Likewise.
16640 (grub_video_vbe_setup): Likewise.
16641 (grub_video_vbe_get_info): Likewise.
16642 (grub_video_vbe_set_palette): Likewise.
16643 (grub_video_vbe_get_palette): Likewise.
16644 (grub_video_vbe_set_viewport): Likewise.
16645 (grub_video_vbe_get_viewport): Likewise.
16646 (grub_video_vbe_map_color): Likewise.
16647 (grub_video_vbe_map_rgb): Likewise.
16648 (grub_video_vbe_map_rgba): Likewise.
16649 (grub_video_vbe_unmap_color): Likewise.
16650 (grub_video_vbe_fill_rect): Likewise.
16651 (grub_video_vbe_blit_glyph): Likewise.
16652 (grub_video_vbe_blit_bitmap): Likewise.
16653 (grub_video_vbe_blit_render_target): Likewise.
16654 (grub_video_vbe_scroll): Likewise.
16655 (grub_video_vbe_swap_buffers): Likewise.
16656 (grub_video_vbe_create_render_target): Likewise.
16657 (grub_video_vbe_delete_render_target): Likewise.
16658 (grub_video_vbe_set_active_render_target): Likewise.
16659 (grub_vbe_set_pixel_rgb): Remove function.
16660 (grub_vbe_set_pixel_index): Likewise.
16661 (index_color_mode): Remove static variable.
16662 (active_mode): Likewise.
16663 (framebuffer): Likewise.
16664 (bytes_per_scan_line): Likewise.
16665 (grub_video_vbe_adapter): Added new static variable.
16666 (framebuffer): Likewise.
16667 (render_target): Likewise.
16668 (initial_mode): Likewise.
16669 (mode_in_use): Likewise.
16670 (mode_list): Likewise.
16671
5f97350b 166722006-03-10 Marco Gerards <marco@gnu.org>
16673
16674 * configure.ac (AC_INIT): Bumped to 1.93.
16675
16676 * DISTLIST: Added `include/grub/hfs.h'.
16677
a3c5c6f8 166782006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
16679
16680 * boot/i386/pc/boot.S (general_error): Before looping, try INT
16681 18H, which might help the BIOS falling back to next boot media.
16682
6de53d26 166832006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
16684
16685 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
16686 Poe Chen <poe.poechen@gmail.com>.
16687
77c4a393 166882006-01-17 Marco Gerards <marco@gnu.org>
16689
16690 * include/grub/normal.h: Include <grub/script.h>.
16691 (grub_command_list): Removed struct.
16692 (grub_command_list_t): Removed type.
16693 (grub_menu_entry): Remove members `num' and `command_list'. Add
16694 members `commands' and `sourcecode'.
16695 * include/grub/script.h: Add inclusion guards.
16696 (grub_script_cmd_menuentry): New struct.
16697 (grub_script_execute_menuentry): New prototype.
16698 (grub_script_lexer_record_start): Likewise.
16699 (grub_script_lexer_record_stop): Likewise.
16700 * normal/execute.c (grub_script_execute_menuentry): New function.
16701 * normal/lexer.c (record, recording, recordpos, recordlen): New
16702 variables.
16703 (grub_script_lexer_record_start): New function.
16704 (grub_script_lexer_record_stop): Likewise.
16705 (recordchar): Likewise.
16706 (nextchar): Likewise.
16707 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
16708 2048 as the buffer size. Add the tokens `menuentry' and `@'.
16709 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
16710 (current_menu): New variable.
16711 (free_menu): Mainly rewritten.
16712 (grub_normal_menu_addentry): New function.
16713 (read_config_file): Rewritten.
16714 * normal/menu.c (run_menu_entry): Mainly rewritten.
fe987087 16715 * normal/menu_entry.c (make_screen): Rewritten the code to insert
77c4a393 16716 the menu entry.
16717 (run): Mainly rewritten.
16718 * normal/parser.y (menu_entry): New variable.
16719 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
16720 (menuentry): New rule.
16721 (command): Add `menuentry'.
16722 (if_statement): Allow additional returns before `fi'.
16723 * normal/script.c (grub_script_create_cmdmenu): New function.
16724
144f1f98 167252006-01-03 Marco Gerards <marco@gnu.org>
16726
16727 * INSTALL: GNU Bison is required.
16728 * configure.ac: Rewritten the test to detect Bison.
16729 * Makefile.in (YACC): New variable. Reported by Xun Sun
16730 <xun.sun.cn@gmail.com>.
16731
af4b2d89 167322006-01-03 Marco Gerards <marco@gnu.org>
16733
16734 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
16735 the HFS+ filesystem to filesystem blocks.
16736 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
16737 GCC warning is silenced.
16738
15643b71 167392006-01-03 Marco Gerards <marco@gnu.org>
16740
16741 * partmap/apple.c (apple_partition_map_iterate): Convert the data
16742 read from disk from big endian to host byte order.
16743
00905879 167442006-01-03 Hollis Blanchard <hollis@penguinppc.org>
16745
16746 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
16747 documentation.
16748 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
16749 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
16750 embedded HFS+ filesystem.
16751 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
16752 (grub_hfs_sblock): Move from here...
16753 * include/grub/hfs.h: To here... New file.
16754 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
16755 documentation.
16756 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
16757 New macros.
16758 (grub_hfsplus_volheader): Change type of member `magic' to
16759 `grub_uint16_t'.
16760 (grub_hfsplus_data): Add new member `embedded_offset'.
16761 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
16762 returned block.
16763 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
16764 Calculate the offset.
16765
8899bc3e 167662005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
16767
16768 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
16769 Removed.
16770 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
16771
ae8c0277 167722005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
16773
16774 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
16775 ENV->NAME is NULL after allocating ENV->VALUE.
16776
07084456 167772005-12-25 Marco Gerards <marco@gnu.org>
16778
16779 * kern/env.c (grub_env_set): Rewritten the error handling code.
16780
4750f5f1 167812005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
16782
16783 * geninit.sh: Made more robust, and more portable.
16784
50214199 167852005-12-25 Marco Gerards <marco@gnu.org>
16786
16787 Add support for Apple HFS+ filesystems.
f19dbdb7 16788
50214199 16789 * fs/hfsplus.c: New file.
16790
16791 * DISTLIST: Added `fs/hfsplus.c'.
16792
16793 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
16794 (hfsplus_mod_SOURCES): New variable.
16795 (hfsplus_mod_CFLAGS): Likewise.
16796 (hfsplus_mod_LDFLAGS): Likewise.
16797 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
16798 (grub_setup_SOURCES): Likewise.
16799 (grub_mkdevicemap_SOURCES): Likewise.
16800 (grub_emu_SOURCES): Likewise.
16801 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
16802
16803 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
16804
16805 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
16806
befaed6c 168072005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
16808
16809 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
16810 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
16811 include/grub/parser.h, include/grub/script.h, kern/parser.c,
16812 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
16813 normal/lexer.c, normal/parser.y, normal/script.c, and
16814 partmap/gpt.c.
16815 Removed kern/sparc64/cache.c.
16816
16817 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
16818 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
16819 grub_emu_init.c.
16820
16821 * configure.ac (AC_INIT): Bumped to 1.92.
16822
6a124103 168232005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
16824
16825 * kern/err.c (grub_error_push): Added new function to support error
16826 stacks.
16827 (grub_error_pop): Likewise.
16828 (grub_error_stack_items): New local variable to support error stacks.
16829 (grub_error_stack_pos): Likewise.
16830 (grub_error_stack_assert): Likewise.
16831 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
16832 stack depth.
16833 (grub_print_error): Added support to print errors from error stack.
16834
16835 * include/grub/err.h (grub_error_push): Added function prototype.
16836 (grub_error_pop): Likewise.
16837
be973c1b 168382005-12-09 Hollis Blanchard <hollis@penguinppc.org>
16839
16840 * configure.ac: Accept `powerpc64' as host_cpu.
16841 (amd64): Rename to `biarch32'.
16842
16843 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
16844 non-cacheline-aligned addresses.
16845
16846 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
16847 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
16848 if `size' is non-zero.
16849
b04216ab 168502005-12-03 Marco Gerards <mgerards@xs4all.nl>
16851
16852 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
16853 and `cd' to make sure the filename is not prefixed with a
16854 directory name.
16855 (pkgdata_MODULES): Add `gpt.mod'.
16856 (gpt_mod_SOURCES): New variable.
16857 (gpt_mod_CFLAGS): Likewise.
16858 (gpt_mod_LDFLAGS): Likewise.
16859
16860 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
16861
16862 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
16863 New macro.
16864
16865 * partmap/gpt.c: New file.
16866
16867 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
16868 GPT partition map is detected.
16869
41730ed9 168702005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
16871
16872 * commands/i386/pc/play.c: New file.
16873 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
16874 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
16875 macros.
f19dbdb7 16876
95dc3643 168772005-11-27 Marco Gerards <mgerards@xs4all.nl>
16878
16879 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
16880 ((unused))' to silence gcc warning.
16881
1569ec51 168822005-11-26 Hollis Blanchard <hollis@penguinppc.org>
16883
16884 * configure.ac: Correct `AC_PROG_YACC' test.
16885
9abde152 168862005-11-22 Hollis Blanchard <hollis@penguinppc.org>
16887
16888 * util/powerpc/ieee1275/grub-install.in: Run the mount point
16889 check before installing files.
16890
44b83271 168912005-11-22 Mike Small <smallm@panix.com>
16892
16893 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
16894 number regex so multidigit numbers are recognized correctly.
16895
168962005-11-22 Mike Small <smallm@panix.com>
16897
16898 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
16899 debugging message before attempting to claim memory.
16900 (grub_rescue_cmd_initrd): Add a claim debugging message and try
16901 multiple addresses in case of failure.
16902
9c12956b 169032005-11-22 Hollis Blanchard <hollis@penguinppc.org>
16904
16905 * term/tparm.c (get_space): Remove empty `if' statement.
16906
16907 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
16908
16909 * kern/parser.c (check_varstate): Rename `state' to 's'.
16910
aeaf81d9 169112005-11-22 Hollis Blanchard <hollis@penguinppc.org>
16912
16913 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
16914 variable definitions to the beginning of each function. Sort stack
16915 variables by size.
16916 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
16917 `buf' argument to `char *'.
16918
79bbb63f 169192005-11-22 Hollis Blanchard <hollis@penguinppc.org>
16920
16921 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
16922 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 16923 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
79bbb63f 16924 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
16925 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
16926 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
16927 configfile.mod, search.mod, gzio.mod and test.mod.
16928 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
16929 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
16930 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
16931 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
16932 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
16933 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
16934 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
16935 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
16936 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
16937 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
16938 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
16939 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
16940 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
16941 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
16942 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
16943 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
16944 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
16945 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
16946 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
16947 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
16948 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
16949 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
16950 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
16951
16952 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
16953 `grep --include'.
16954 (pkgdata_MODULES): Add test.mod.
16955
233b1628 169562005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
16957
16958 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
16959 appending to variables with "+=".
16960 (PModule): Use full pathname to generate *.lst filenames.
16961
16962 * Makefile.in: Fixed list rules moved from genmk.rb.
16963 (.DELETE_ON_ERROR): New special target.
16964 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
16965
16966 * conf/i386-pc.rmk: Include conf/common.mk.
16967 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 16968 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
233b1628 16969 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
16970 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
16971 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
16972 configfile.mod, search.mod, gzio.mod and test.mod.
16973 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
16974 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
16975 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
16976 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
16977 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
16978 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
16979 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
16980 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
16981 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
16982 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
16983 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
16984 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
16985 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
16986 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
16987 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
16988 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
16989 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
16990 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
16991 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
16992 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
16993 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
16994 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
16995 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
16996 here...
16997 * conf/common.rmk: ... to here. New file.
16998
16999 * conf/common.mk: New file.
17000
16f820c8 170012005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
17002
17003 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
17004 (grub_script.tab.c): ... here.
17005
17006 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
17007 (grub_script.tab.c): ... here.
17008
17009 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
17010 (grub_script.tab.c): ... here.
17011
17012 * normal/command.c (grub_command_find): Fixed a memory leak of
17013 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
17014
63ba1554 170152005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17016
17017 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
17018 "@" which marks the start of a comment on ARM.
17019 (VARIABLE): Likewise.
17020
7f67dc13 170212005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17022
79bbb63f 17023 Add support for Linux/ADFS partition tables.
7f67dc13 17024
17025 * partmap/acorn.c: New file.
17026
17027 * include/grub/acorn_filecore.h: Likewise.
17028
17029 * DISTLIST: Added `partmap/acorn.c' and
17030 `include/grub/acorn_filecore.h'.
f19dbdb7 17031
7f67dc13 17032 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17033 `partmap/acorn.c'.
17034 (pkgdata_MODULES): Add `acorn.mod'.
17035 (acorn_mod_SOURCES): New variable.
17036 (acorn_mod_CFLAGS): Likewise.
17037
17038 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17039 `partmap/acorn.c'.
17040 (pkgdata_MODULES): Add `acorn.mod'.
17041 (acorn_mod_SOURCES): New variable.
17042 (acorn_mod_CFLAGS): Likewise.
17043
17044 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
17045 (pkgdata_MODULES): Add `acorn.mod'.
17046 (acorn_mod_SOURCES): New variable.
17047 (acorn_mod_CFLAGS): Likewise.
17048 (acorn_mod_LDFLAGS): Likewise.
17049
17050 * include/types.h (grub_disk_addr_t): New typedef.
17051
6d099807 170522005-11-13 Marco Gerards <mgerards@xs4all.nl>
17053
17054 * geninit.sh: New file.
17055
17056 * geninitheader.sh: Likewise.
17057
17058 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
17059 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
17060 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
17061 * commands/configfile.c (grub_configfile_init)
17062 (grub_configfile_fini): Likewise.
17063 * commands/default.c (grub_default_init, grub_default_fini):
17064 Likewise.
17065 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
17066 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
17067 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
17068 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
17069 Likewise.
17070 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
17071 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
17072 Likewise.
17073 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
fe6b695a 17074 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
6d099807 17075 Likewise.
17076 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
17077 Likewise.
fe6b695a 17078 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
6d099807 17079 Likewise.
17080 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
17081 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
17082 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
17083 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
17084 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
17085 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
17086 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
17087 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
17088 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
17089 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
17090 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
17091 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
17092 * partmap/amiga.c (grub_amiga_partition_map_init)
17093 (grub_amiga_partition_map_fini): Likewise.
17094 * partmap/apple.c (grub_apple_partition_map_init)
17095 (grub_apple_partition_map_fini): Likewise.
17096 * partmap/pc.c (grub_pc_partition_map_init)
17097 (grub_pc_partition_map_fini): Likewise.
17098 * partmap/sun.c (grub_sun_partition_map_init,
17099 grub_sun_partition_map_fini): Likewise.
17100 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
17101 Likewise.
17102
17103 * util/grub-emu.c: Include <grub_modules_init.h>.
17104 (main): Don't initialize and de-initialize any modules directly,
17105 use `grub_init_all' and `grub_fini_all' instead.
17106
17107 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
17108 `grub_vesafb_mod_init'.
17109 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
17110 all users.
17111 * term/i386/pc/vga.c (grub_vga_init): Renamed to
17112 `grub_vga_mod_init'. Updated all users.
17113 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
f19dbdb7 17114
6d099807 17115 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
17116 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
17117 rules.
17118
17119 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
17120 Generate a function to initialize the module in utilities.
17121 Updated all callers.
17122 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
17123 initialize the module in utilities. Updated all callers.
17124
9046bcf0 171252005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17126
17127 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
17128 escape sequence and a literal ^L to clear the screen.
17129
17130 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
17131 when returning from Open Firmware.
17132
d13ea639 171332005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17134
17135 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
17136 (grub_ofconsole_height): Likewise.
17137 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
17138 manually insert a '\n'.
17139 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
17140 `grub_ofconsole_height'. Return early if these are already set.
17141
a8fcf206 171422005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
17143
17144 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17145 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
17146 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
17147 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
17148 and `normal/script.c'.
17149 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17150 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17151 (test_mod_SOURCES): New variable.
17152 (test_mod_CFLAGS): Likewise.
17153 (test_mod_LDFLAGS): Likewise.
17154 (pkgdata_MODULES): Add `test.mod'.
17155 (grub_script.tab.c): New rule.
17156 (grub_script.tab.h): Likewise.
17157
b6b32745 171582005-11-07 Marco Gerards <mgerards@xs4all.nl>
17159
17160 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17161 `commands/test.c', `normal/execute.c', `normal/lexer.c',
17162 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17163 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17164 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17165 (test_mod_SOURCES): New variable.
17166 (test_mod_CFLAGS): Likewise.
17167 (pkgdata_MODULES): Add `test.mod'.
17168 (grub_script.tab.c): New rule.
17169 (grub_script.tab.h): Likewise.
17170
daac212a 171712005-11-06 Marco Gerards <mgerards@xs4all.nl>
17172
17173 Add initial scripting support.
17174
17175 * commands/test.c: New file.
17176 * include/grub/script.h: Likewise.
17177 * normal/execute.c: Likewise.
17178 * normal/function.c: Likewise.
17179 * normal/lexer.c: Likewise.
17180 * normal/parser.y: Likewise.
17181 * normal/script.c: Likewise.
17182
17183 * configure.ac: Add `AC_PROG_YACC' test.
f19dbdb7 17184
daac212a 17185 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
17186 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
17187 `normal/function.c' and `normal/script.c'.
17188 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17189 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
b6b32745 17190 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
17191 variables.
daac212a 17192 (pkgdata_MODULES): Add `test.mod'.
17193 (grub_script.tab.c): New rule.
17194 (grub_script.tab.h): Likewise.
17195
17196 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
17197
17198 * include/grub/normal.h (grub_test_init): New prototype.
17199 (grub_test_fini): Likewise.
f19dbdb7 17200
daac212a 17201 * normal/command.c: Include <grub/script.h>.
17202 (grub_command_execute): Rewritten.
f19dbdb7 17203
daac212a 17204 * util/grub-emu.c (main): Call `grub_test_init' and
17205 `grub_test_fini'.
17206
77500b2b 172072005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17208
17209 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
17210 to 0.
17211 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
17212 there are no pending characters.
17213
e45deb9e 172142005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17215
17216 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
17217 `grub_strndup' to drop device arguments. Replace unnecessary
17218 `grub_strndup' with `grub_strdup'.
17219
4ce32619 172202005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17221
17222 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
17223 `debug' environment variable has been set.
17224
172252005-11-02 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 17226
4ce32619 17227 * Makefile.in (install-local): Use $(DATA).
17228 (uninstall): Likewise.
17229 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
17230 (sbin_UTILITIES): ... to here.
17231 (sbin_SCRIPTS): New variable.
17232 (grub_install_SOURCES): New variable.
17233 * util/powerpc/ieee1275/grub-install.in: New file.
17234 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
17235 variable.
17236 (add_segments): Call `grub_util_get_path'.
17237
25fe6f03 172382005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
17239
17240 From Timothy Baldwin:
17241 * commands/ls.c (grub_ls_list_files): Close FILE with
17242 grub_file_close.
17243 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
17244
04ccf3ec 172452005-10-24 Marco Gerards <mgerards@xs4all.nl>
17246
17247 * include/grub/parser.h: New file.
17248
17249 * kern/parser.c: Likewise.
17250
17251 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
17252 (grub_setup_SOURCES): Likewise.
17253 (grub_probefs_SOURCES): Likewise.
17254 (grub_emu_SOURCES): Likewise.
17255 (kernel_img_HEADERS): Add `parser.h'.
17256
17257 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17258 (grub_emu_SOURCES): Add `kern/parser.c'.
17259 (grubof_SOURCES): Likewise.
17260
17261 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17262 (grubof_SOURCES): Add `kern/parser.c'.
17263
17264 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
17265
17266 * kern/misc.c (grub_split_cmdline): Removed function.
17267
17268 * kern/rescue.c: Include <grub/parser.h>.
17269 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
17270 of `grub_split_cmdline'.
17271
17272 * normal/command.c: Include <grub/parser.h>.
17273 (grub_command_execute): Use `grub_parser_split_cmdline' instead
17274 of `grub_split_cmdline'.
17275
17276 * normal/completion.c: Include <grub/parser.h>.
17277 (cmdline_state): New variable.
17278 (iterate_dir): End the filename with a quote depending on the
17279 command line state.
17280 (get_state): new function.
17281 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
17282 split the arguments and determine the current argument. When the
17283 argument string is not quoted, escape all spaces.
17284
6d8f4b0e 172852005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17286
17287 * normal/sparc64/setjmp.S: New file.
17288
15cf03ed 172892005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17290
17291 * include/grub/sparc64/libgcc.h: New file.
17292 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
17293 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
17294 normal/sparc64/setjmp.c.
17295
03e8661a 172962005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17297
17298 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
17299 * kern/sparc64/cache.S: New file.
17300 * kern/sparc64/cache.c: Removed.
17301 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
17302 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
17303 -mtune=ultrasparc.
17304 (COMMON_LDFLAGS): Add -melf64_sparc.
17305 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
17306 (grubof_SOURCES): Use cache.S instead of cache.c.
17307 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
17308 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
17309 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
17310 commented though.
17311 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
17312 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
17313 (linux_mod_CFLAGS): Commented out.
17314 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
17315 out because module isn't built.
17316 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
17317 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
17318 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
17319 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
17320 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
17321 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17322 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17323 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
17324 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
17325 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
17326 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17327 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17328 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
17329 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
17330
34eeec8a 173312005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
17332
17333 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
17334 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
17335 longer, because HFS should not be used on PC.
17336
708367a3 173372005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17338
17339 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
17340 consistently within the loop.
17341
6fa1251a 173422005-10-15 Marco Gerards <mgerards@xs4all.nl>
17343
17344 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
17345 directory can not be read.
17346
4801580b 173472005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17348
17349 * configure.ac (AC_INIT): Increase the version number to 1.91.
17350
17351 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
17352 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
17353 term/i386/pc/serial.c.
17354
219ad426 173552005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17356
17357 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
17358 file size must be permitted.
17359
17360 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
17361 between %ah and %al.
17362
688e5699 173632005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17364
17365 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
17366 grub_uint64_t.
17367 Call the hook with a NUL-terminated filename.
17368 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
17369 grub_cpu_to_be32.
17370
17371 * kern/term.c (cursor_state): New variable.
17372 (grub_term_set_current): Reset the cursor state on a new
17373 terminal.
17374 (grub_setcursor): Rewritten to use CURSOR_STATE.
17375 (grub_getcursor): New function.
17376
17377 * include/grub/term.h (grub_getcursor): New prototype.
17378
17379 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
17380 integers on ARM. Reported by Timothy Baldwin
17381 <T.E.Baldwin99@members.leeds.ac.uk>.
17382
bb34586c 173832005-10-11 Marco Gerards <mgerards@xs4all.nl>
17384
17385 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
17386 allocated.
17387 (grub_sfs_dir): Likewise.
17388
9a909877 173892005-10-09 Marco Gerards <mgerards@xs4all.nl>
17390
17391 Add support for the SFS filesystem.
17392
17393 * fs/sfs.c: New file.
17394
17395 * DISTLIST: Added `fs/sfs.c'.
17396
17397 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
17398 (grub_probefs_SOURCES): Likewise.
17399 (grub_emu_SOURCES): Likewise.
17400 (pkgdata_MODULES): Add `sfs.mod'.
17401 (sfs_mod_SOURCES): New variable.
17402 (sfs_mod_CFLAGS): Likewise.
17403 (sfs_mod_LDFLAGS): Likewise.
17404
17405 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
17406 (pkgdata_MODULES): Add `sfs.mod'.
17407 (sfs_mod_SOURCES): New variable.
17408 (sfs_mod_CFLAGS): Likewise.
17409
17410 * util/grub-emu.c (main): Call `grub_sfs_init' and
17411 `grub_sfs_fini'.
17412
17413 * include/grub/fs.h (grub_sfs_init): New prototype.
17414 (grub_sfs_fini): Likewise.
17415
57bdbde3 174162005-10-07 Marco Gerards <mgerards@xs4all.nl>
17417
17418 Add support for the AFFS filesystem.
17419
17420 * fs/affs.c: New file.
17421
17422 * DISTLIST: Added `fs/affs.c'.
17423
17424 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
17425 (grub_probefs_SOURCES): Likewise.
17426 (grub_emu_SOURCES): Likewise.
17427 (pkgdata_MODULES): Add `affs.mod'.
17428 (affs_mod_SOURCES): New variable.
17429 (affs_mod_CFLAGS): Likewise.
17430 (affs_mod_LDFLAGS): Likewise.
17431
17432 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
17433 (pkgdata_MODULES): Add `affs.mod'.
17434 (affs_mod_SOURCES): New variable.
17435 (affs_mod_CFLAGS): Likewise.
17436
17437 * util/grub-emu.c (main): Call `grub_affs_init' and
17438 `grub_affs_fini'.
17439
17440 * include/grub/fs.h (grub_affs_init): New prototype.
17441 (grub_affs_fini): Likewise.
17442
047b67e0 174432005-10-01 Marco Gerards <mgerards@xs4all.nl>
17444
17445 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
17446
59b8208a 174472005-10-01 Marco Gerards <mgerards@xs4all.nl>
17448
17449 * configure.ac: Accept `x86_64' as host_cpu. In that case add
17450 `-m32' to CFLAGS.
17451
17452 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
17453 linking.
f19dbdb7 17454
59b8208a 17455 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
17456 (COMMON_LDFLAGS): New variable.
17457 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
17458 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
17459 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
17460 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
17461 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
17462 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
17463 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
17464 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
17465 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
17466 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
17467 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17468 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17469 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
17470 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
17471 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
17472 variables.
17473 (normal_mod_ASFLAGS): Add `-m32'.
17474
17475 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
17476 (grub_host_size_t, grub_host_ssize_t): New types.
17477 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
fe6b695a 17478 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
59b8208a 17479 `GRUB_HOST_SIZEOF_VOID_P'.
17480
17481 * include/grub/kernel.h (struct grub_module_header): Type of
17482 member offset changed to `grub_host_off_t'. Type of member size
17483 changed to `grub_host_size_t'.
17484 (struct grub_module_info): Type of member offset changed to
17485 `grub_host_off_t'. Type of member size changed to
17486 `grub_host_size_t'.
17487
b4093103 174882005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
17489
17490 Make GRUB's kernel compliant to Multiboot Specification.
f19dbdb7 17491
b4093103 17492 * kern/i386/pc/startup.S (multiboot_header): New label.
17493 (multiboot_entry): Likewise.
17494 (multiboot_trampoline): Likewise.
17495
17496 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
17497 Increased to 0x4A0.
17498
17499 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
17500 put parentheses after a question mark.
17501 [!GRUB_UTIL] (my_mod): New variable.
17502
17503 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
17504
b2499b29 175052005-09-28 Marco Gerards <mgerards@xs4all.nl>
17506
17507 Adds support for the XFS filesystem. Btrees are not supported
17508 yet.
17509
17510 * fs/xfs.c: New file.
17511
17512 * DISTLIST: Added `fs/xfs.c'.
17513
17514 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
17515 (grub_probefs_SOURCES): Likewise.
17516 (grub_emu_SOURCES): Likewise.
17517 (pkgdata_MODULES): Add `xfs.mod'.
17518 (xfs_mod_SOURCES): New variable.
17519 (xfs_mod_CFLAGS): Likewise.
17520
17521 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
17522 (pkgdata_MODULES): Add `xfs.mod'.
17523 (xfs_mod_SOURCES): New variable.
17524 (xfs_mod_CFLAGS): Likewise.
17525
17526 * util/grub-emu.c (main): Call `grub_xfs_init' and
17527 `grub_xfs_fini'.
17528
17529 * include/grub/fs.h (grub_xfs_init): New prototype.
17530 (grub_xfs_fini): Likewise.
17531
f19dbdb7 17532
83d37a62 175332005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
17534
17535 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
17536 color modes, allow greater than 16 colors to be configured as
17537 a default palette.
17538
47d2d65e 175392005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
17540
17541 * normal/completion.c (complete_arguments): Add the qualifier
17542 const into OPTIONS.
17543
17544 From Omniflux <omniflux+lists@omniflux.com>:
17545 * include/grub/terminfo.h: New file.
17546 * include/grub/tparm.h: Likewise.
17547 * include/grub/i386/pc/serial.h: Likewise.
17548 * term/terminfo.c: Likewise.
17549 * term/tparm.c: Likewise.
17550 * term/i386/pc/serial.c: Likewise.
17551 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
17552 serial.mod.
17553 (terminfo_mod_SOURCES): New variable.
17554 (terminfo_mod_CFLAGS): Likewise.
17555 (serial_mod_SOURCES): Likewise.
17556 (serial_mod_CFLAGS): Likewise.
17557
48b671ff 175582005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
17559
17560 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
17561 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
17562 and kern/powerpc/ieee1275/cmain.c, respectively.
17563
17564 * boot/powerpc/ieee1275/crt0.S: Moved to ...
17565 * kern/powerpc/ieee1275/crt0.S: ... here.
17566
17567 * boot/powerpc/ieee1275/cmain.c: Moved to ...
17568 * kern/powerpc/ieee1275/cmain.c: ... here.
f19dbdb7 17569
48b671ff 17570 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
17571 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
17572 instead of boot/powerpc/ieee1275/crt0.S and
17573 boot/powerpc/ieee1275/cmain.c, respectively.
17574
17575 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
17576 sectors. It was not used anyway.
17577
09fc77a7 175782005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17579
17580 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
17581 `unused parameter' warning.
17582
003789c7 175832005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17584
17585 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
17586 function.
17587 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
17588 getcharwidth.
17589
67f44c86 175902005-08-28 Marco Gerards <metgerards@student.han.nl>
17591
17592 * include/grub/normal.h (enum grub_completion_type): Added
17593 `GRUB_COMPLETION_TYPE_ARGUMENT'.
17594
17595 * normal/cmdline.c (print_completion): Handle
17596 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
17597 * normal/menu_entry.c (store_completion): Likewise.
17598
17599 * normal/completion.c (complete_arguments): New function.
17600 (grub_normal_do_completion): Call `complete_arguments' when the
17601 current words start with a dash.
17602
0b5abe02 176032005-08-27 Marco Gerards <metgerards@student.han.nl>
17604
17605 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
17606 `gzio.mod' instead of `io.mod').
17607
d9864ee1 176082005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
17609
17610 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
17611 (DISTDIRS): Added io and video.
17612 Rewrite the search routine to make an output consistently.
17613
17614 * DISTLIST: Added conf/sparc64-ieee1275.mk,
17615 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
17616 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
17617 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
17618 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
17619 util/powerpc/ieee1275/misc.c.
f19dbdb7 17620
d9864ee1 17621 * include/grub/gzio.h: New file.
17622 * io/gzio.c: Likewise.
f19dbdb7 17623
d9864ee1 17624 * kern/file.c (grub_file_close): Call grub_device_close only if
17625 FILE->DEVICE is not NULL.
17626
17627 * include/grub/mm.h [!NULL] (NULL): New macro.
17628
17629 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
17630
17631 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
17632 (pkgdata_MODULES): Added gzio.mod.
17633 (gzio_mod_SOURCES): New variable.
17634 (gzio_mod_CFLAGS): Likewise.
17635
17636 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
17637 (pkgdata_MODULES): Added gzio.mod.
17638 (gzio_mod_SOURCES): New variable.
17639 (gzio_mod_CFLAGS): Likewise.
17640
17641 * commands/cat.c: Include grub/gzio.h.
17642 (grub_cmd_cat): Use grub_gzfile_open instead of
17643 grub_file_open.
f19dbdb7 17644
d9864ee1 17645 * commands/cmp.c: Include grub/gzio.h.
17646 (grub_cmd_cmp): Use grub_gzfile_open instead of
17647 grub_file_open.
17648
17649 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
17650 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
17651 grub_file_open.
17652 (grub_rescue_cmd_module): Likewise.
17653
fa46f4b5 176542005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
17655
17656 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
17657 kern/sparc64/ieee1275/init.c because it contains _start.
17658 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
17659
e9211b5d 176602005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
17661
17662 * configure.ac: Add support for sparc64 host with ieee1275
17663 firmware.
17664 * configure: Generated from configure.ac.
17665 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
17666 instead of int.
17667 (grub_ofdisk_read): Likewise.
17668 (grub_ofdisk_open): Use %p to print pointer values, and cast the
17669 pointers as (void *) to remove a warning.
17670 (grub_ofdisk_close): Likewise.
17671 (grub_ofdisk_read): Likewise.
17672 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
17673 returns, so make it return void to remove a warning.
17674 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
17675 Corresponding prototype change.
17676 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
17677 values, and cast the pointers as (void *) to remove a warning.
17678 (grub_mm_dump): Likewise.
17679 * conf/sparc64-ieee1275.mk: New file.
17680 * conf/sparc64-ieee1275.rmk: Likewise.
17681 * include/grub/sparc64/setjmp.h: Likewise.
17682 * include/grub/sparc64/types.h: Likewise.
17683 * include/grub/sparc64/ieee1275/console.h: Likewise.
17684 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
17685 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
17686 * include/grub/sparc64/ieee1275/time.h: Likewise.
17687 * kern/sparc64/cache.c: Likewise.
17688 * kern/sparc64/dl.c: Likewise.
17689 * kern/sparc64/ieee1275/init.c: Likewise.
17690 * kern/sparc64/ieee1275/openfw.c: Likewise.
17691
385c6a92 176922005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
17693
17694 * util/console.c (grub_ncurses_putchar): If C is greater than
17695 0x7f, set C to a question mark.
17696 (grub_ncurses_getcharwidth): New function.
17697 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
17698 getcharwidth.
17699
17700 * normal/menu.c (print_entry): Made aware of Unicode. First,
17701 convert TITLE to UCS-4, and predict the cursor position by
17702 grub_getcharwidth.
17703
17704 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
17705 const to SRC.
17706 * kern/misc.c (grub_utf16_to_utf8): Likewise.
17707
16ccb8b1 177082005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17709
17710 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
17711 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
17712 grub_strcat.
17713
17714 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
17715 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
17716 grub_strcpy and grub_strlen. Take it into account that a space
17717 character is inserted as a delimiter.
17718
6a85ce79 177192005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17720
17721 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
fe6b695a 17722 invalid magic in the error.
6a85ce79 17723
17724 * commands/search.c: New file.
f19dbdb7 17725
6a85ce79 17726 * util/grub-emu.c (main): Call grub_search_init and
17727 grub_search_fini.
17728
17729 * kern/rescue.c (grub_rescue_print_disks): Removed.
17730 (grub_rescue_print_devices): New function.
17731 (grub_rescue_cmd_ls): Use grub_device_iterate with
17732 grub_rescue_print_devices instead of grub_disk_dev_iterate with
17733 grub_rescue_print_disks.
17734
17735 * kern/partition.c (grub_partition_iterate): Return the result of
17736 PARTMAP->ITERATE instead of GRUB_ERRNO.
17737
17738 * kern/device.c: Include grub/partition.h.
17739 (grub_device_iterate): New function.
17740
17741 * include/grub/partition.h (grub_partition_iterate): Return int
17742 instead of grub_err_t.
17743
17744 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
17745 prototype.
17746 [GRUB_UTIL] (grub_search_fini): Likewise.
17747
17748 * include/grub/device.h (grub_device_iterate): New prototype.
17749
17750 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
17751 commands/search.c.
17752 (pkgdata_MODULES): Added search.mod.
17753 (search_mod_SOURCES): New variable.
17754 (search_mod_CFLAGS): Likewise.
17755
17756 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
17757 (pkgdata_MODULES): Added search.mod.
17758 (search_mod_SOURCES): New variable.
17759 (search_mod_CFLAGS): Likewise.
17760
17761 * commands/ls.c (grub_ls_list_disks): Renamed to ...
17762 (grub_ls_list_devices): ... this, and use grub_device_iterate.
17763 All callers changed.
17764
17765 * DISTLIST: Added commands/search.c.
17766
ef095434 177672005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17768
17769 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
17770 conversion.
17771 (grub_getcharwidth): New function.
17772
17773 * kern/misc.c (grub_utf8_to_ucs4): New function.
17774
17775 * include/grub/term.h (struct grub_term): Added a new member
17776 "getcharwidth".
17777 (grub_getcharwidth): New prototype.
17778
17779 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
17780
17781 * term/i386/pc/console.c (map_char): New function. Segregated from
17782 grub_console_putchar.
17783 (grub_console_putchar): Use map_char.
17784 (grub_console_getcharwidth): New function.
17785 (grub_console_term): Specified grub_console_getcharwidth as
17786 getcharwidth.
17787
17788 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
17789 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
17790
17791 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
17792 GRUB_ERRNO.
17793 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
17794 on grub_strtoul completely.
17795 (write_char): Declare local variables in the beginning of the
17796 function.
17797 (grub_vesafb_getcharwidth): New function.
17798 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
17799 getcharwidth.
17800
1f0a95e4 178012005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
17802
17803 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
17804 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
17805 commands/i386/pc/vbetest.c.
17806
17807 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
17808 call grub_vbe_get_controller_info again, because the returned
17809 information is volatile.
17810 (grub_vbe_set_video_mode): Mostly rewritten.
17811 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
17812 grub_vbe_status_t correctly.
17813 (grub_vbe_get_video_mode_info): Likewise.
17814 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
17815 several if statements.
17816
17817 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
17818 * commands/i386/pc/vbeinfo.c: ... this.
17819
17820 * commands/i386/pc/vbe_test.c: Renamed to ...
17821 * commands/i386/pc/vbetest.c: ... this.
17822
17823 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
17824 ...
17825 (grub_cmd_vbeinfo): ... this. Save video modes before
17826 iterating. Skip a video mode, if it is not available, not enough
17827 information is given or it is monochrome. Show the memory
17828 model. Leave the interpretation of MODEVAR to grub_strtoul
17829 completely.
17830 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
17831 (GRUB_MOD_FINI): Likewise.
17832
17833 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
17834 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
17835 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
17836 duplicated grub_env_get. Leave the interpretation of MODEVAR to
17837 grub_strtoul completely.
17838 (real2pm): Removed.
17839 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
17840 (GRUB_MOD_FINI): Likewise.
17841
17842 * normal/misc.c: Include grub/mm.h.
17843
17844 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
17845 vbe_list_modes with vbetest.mod and vbeinfo.mod.
17846 (vbe_list_modes_mod_SOURCES): Removed.
17847 (vbe_list_modes_mod_CFLAGS): Likewise.
17848 (vbe_test_mod_SOURCES): Likewise.
17849 (vbe_test_mod_CFLAGS): Likewise.
17850 (vbeinfo_mod_SOURCES): New variable.
17851 (vbeinfo_mod_CFLAGS): Likewise.
17852 (vbetest_mod_SOURCES): Likewise.
17853 (vbetest_mod_CFLAGS): Likewise.
17854
992ffbbe 178552005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
17856
17857 * normal/misc.c: New file.
17858
17859 * DISTLIST: Added normal/misc.c.
f19dbdb7 17860
992ffbbe 17861 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
17862 DISK to HOOK. Call HOOK with DISK.
17863 * partmap/apple.c (apple_partition_map_iterate): Likewise.
17864 * partmap/pc.c (pc_partition_map_iterate): Likewise.
17865 * partmap/sun.c (sun_partition_map_iterate): Likewise.
17866
17867 * normal/menu_entry.c (struct screen): Added a new member
17868 "completion_shown".
17869 (completion_buffer): New global variable.
17870 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
17871 (store_completion): New function.
17872 (complete): Likewise.
17873 (clear_completions): Likewise.
17874 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
17875 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
17876 a tab, call complete.
17877
17878 * normal/completion.c (disk_dev): Removed.
17879 (print_simple_completion): Likewise.
17880 (print_partition_completion): Likewise.
17881 (print_func): New global variable.
17882 (add_completion): Do not take the arguments WHAT or PRINT any
17883 longer. Added a new argument TYPE. Instead of printing directly,
17884 call PRINT_FUNC if not NULL.
17885 All callers changed.
17886 (complete_device): Use a local variable DEV instead of
17887 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
17888 (grub_normal_do_completion): Take a new argument HOOK. Do not
17889 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
17890 empty string, return NULL instead.
17891 All callers changed.
17892
17893 * normal/cmdline.c (print_completion): New function.
17894
17895 * kern/partition.c (grub_partition_iterate): Add an argument DISK
17896 to HOOK.
17897 All callers changed.
17898
17899 * kern/disk.c (grub_print_partinfo): Removed.
17900
17901 * include/grub/partition.h (struct grub_partition_map): Add a new
17902 argument DISK into HOOK of ITERATE.
17903 (grub_partition_iterate): Add a new argument DISK to HOOK.
17904
17905 * include/grub/normal.h (enum grub_completion_type): New enum.
17906 (grub_completion_type_t): New type.
17907 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
17908 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
17909 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
17910 (GRUB_COMPLETION_TYPE_FILE): Likewise.
17911 (grub_normal_do_completion): Added a new argument HOOK.
17912 (grub_normal_print_device_info): New prototype.
17913
17914 * include/grub/disk.h (grub_print_partinfo): Removed.
17915
17916 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
17917 (normal_mod_SOURCES): Likewise.
17918 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
17919 (normal_mod_SOURCES): Likewise.
17920
17921 * commands/ls.c (grub_ls_list_disks): Use
17922 grub_normal_print_device_info instead of grub_print_partinfo. Free
17923 PNAME.
17924 (grub_ls_list_files): Use grub_normal_print_device_info instead of
17925 duplicating the code.
17926
0bd41162 179272005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
17928
17929 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
f19dbdb7 17930 follow GCS more precisely.
17931 * commands/i386/pc/vbe_test.c: Likewise.
17932 * include/grub/i386/pc/vbe.h: Likewise.
17933 * term/i386/pc/vesafb.c: Likewise.
17934 * video/i386/pc/vbe.c: Likewise.
0bd41162 17935
6323696a 179362005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
17937
17938 * DISTLIST: Added term/i386/pc/vesafb.c
17939 DISTLIST: Added video/i386/pc/vbe.c
17940 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
17941 DISTLIST: Added commands/i386/pc/vbe_test.c.
17942 * commands/i386/pc/vbe_list_modes.c: New file.
17943 * commands/i386/pc/vbe_test.c: Likewise.
17944 * term/i386/pc/vesafb.c: Likewise.
17945 * video/i386/pc/vbe.c: Likewise.
17946 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
17947 (grub_vbe_probe) Added prototype.
17948 (grub_vbe_set_video_mode) Likewise.
17949 (grub_vbe_get_video_mode) Likewise.
17950 (grub_vbe_get_video_mode_info) Likewise.
17951 (grub_vbe_set_pixel_rgb) Likewise.
17952 (grub_vbe_set_pixel_index) Likewise.
17953 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
17954 (pkgdata_MODULES): Added vesafb.mod.
17955 (pkgdata_MODULES): Added vbe_list_modes.mod.
17956 (pkgdata_MODULES): Added vbe_test.mod.
17957 (vbe_mod_SOURCES): Added.
17958 (vbe_mod_CFLAGS): Likewise.
17959 (vesafb_mod_SOURCES): Likewise.
17960 (vesafb_mod_CFLAGS): Likewise.
17961 (vbe_list_modes_mod_SOURCES): Likewise.
17962 (vbe_list_modes_mod_CFLAGS): Likewise.
17963 (vbe_test_mod_SOURCES): Likewise.
17964 (vbe_test_mod_CFLAGS): Likewise.
17965
0a74e62f 179662005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
17967
0a74e62f 17968 * normal/command.c (grub_command_execute): If INTERACTIVE is
17969 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
17970 CMDLINE. Disable the pager if INTERACTIVE is true.
17971 All callers are changed.
17972
17973 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
17974 before reading a config file.
17975 * normal/main.c (read_config_file): Even if a command is not
17976 found, register it if it is within an entry.
17977
17978 * util/grub-emu.c: Include sys/types.h and unistd.h.
17979 (options): Added --hold.
17980 (struct arguments): Added a new member "hold".
17981 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
17982 missing.
17983 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
17984 cleared by a debugger, if it is not zero.
17985
17986 * include/grub/normal.h (grub_command_execute): Add an argument
17987 INTERACTIVE.
17988
e51f85ae 179892005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
17990
17991 * DISTLIST: Added include/grub/i386/pc/vbe.h.
17992
e9c6f39b 179932005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
17994
17995 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
17996 program with another one, because the old one didn't detect a bug
17997 in gcc-3.4. Always use regparm 2, because the new test is still
17998 not enough for gcc-4.0. Someone must investigate a simple test
17999 case which detects a bug in gcc-4.0.
18000
8de3495c 180012005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
18002
18003 * DISTLIST: Added normal/completion.c.
18004
18005 * normal/completion.c: New file.
f19dbdb7 18006
8de3495c 18007 * term/i386/pc/console.c (grub_console_getwh): New function.
18008 (grub_console_term): Assign grub_console_getwh to getwh.
18009
18010 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
18011 function is defined in normal/completion.c as
18012 grub_normal_do_completion.
18013 (grub_cmdline_get): Use grub_normal_do_completion instead of
18014 grub_tab_complete.
18015
18016 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
18017 returns non-zero, otherwise return 0.
18018 (grub_partition_iterate): First, probe the partition map. Then,
18019 call ITERATE only for this partition map.
18020
18021 * kern/misc.c (grub_strncmp): Rewritten.
18022
18023 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
18024 returns non-zero. Otherwise return 0.
18025
18026 * include/grub/partition.h (grub_partition_map_iterate): Return
18027 int instead of void.
18028
18029 * include/grub/normal.h (grub_normal_do_completion): New prototype.
18030
18031 * include/grub/misc.h (grub_strncmp): Change the type of N to
18032 grub_size_t.
18033
18034 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
18035 of void.
18036
18037 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
fe6b695a 18038 unsigned explicitly before comparing it with I.
8de3495c 18039
18040 * kern/main.c (grub_env_write_root): Add the attribute unused into
18041 VAR.
18042
18043 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18044 normal/completion.c.
18045 (normal_mod_SOURCES): Likewise.
18046 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
18047 (normal_mod_SOURCES): Likewise.
18048
18049 * normal/command.c (grub_iterate_commands): If ITERATE returns
18050 non-zero, return one immediately.
18051
e85e144b 180522005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
18053
18054 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
18055 * kern/i386/pc/startup.S: Updated Global Descriptor table's
18056 descriptions.
18057 (grub_vbe_get_controller_info): New function.
18058 (grub_vbe_get_mode_info): Likewise.
18059 (grub_vbe_set_mode): Likewise.
18060 (grub_vbe_get_mode): Likewise.
18061 (grub_vbe_set_memory_window): Likewise.
18062 (grub_vbe_get_memory_window): Likewise.
18063 (grub_vbe_set_scanline_length): Likewise.
18064 (grub_vbe_get_scanline_length): Likewise.
18065 (grub_vbe_set_display_start): Likewise.
18066 (grub_vbe_get_display_start): Likewise.
18067 (grub_vbe_set_palette_data): Likewise.
18068 * include/grub/i386/pc/vbe.h: New file.
18069
c46153d2 180702005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18071
18072 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18073 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
18074 * DISTLIST: Likewise.
18075 * kern/ieee1275/of.c: Moved to ...
18076 * kern/ieee1275/ieee1275.c: ... here.
18077
0cb90c45 180782005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18079
18080 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
18081 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
18082 Pass 0 as `end' parameter to grub_strtoul().
18083
a19fb360 180842005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18085
18086 * include/grub/powerpc/ieee1275/console.h: Do not include
18087 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
18088 ifdef.
18089 (grub_console_cur_color): Remove i386-specific prototype.
18090 (grub_console_real_putchar): Likewise.
18091 (grub_console_checkkey): Likewise.
18092 (grub_console_getkey): Likewise.
18093 (grub_console_getxy): Likewise.
18094 (grub_console_gotoxy): Likewise.
18095 (grub_console_cls): Likewise.
18096 (grub_console_setcursor): Likewise.
18097 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
18098 Include <grub/machine/console.h>.
18099 * term/ieee1275/ofconsole.c: Likewise.
18100
4ac9bd04 181012005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
18102
18103 * Makefile.in (LIBLZO): New variable.
18104
18105 * configure.ac: Check for LZO version 2.
18106
18107 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
18108 lzo/lzo1x.h instead of lzo1x.h.
18109
18110 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
18111 of -llzo.
18112
18113 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
18114 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
18115
18116 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
18117 copying the data from PARTITION to P.
18118
f4917dfd 181192005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18120
18121 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
18122 negative, unload the module.
18123
18124 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
18125 map is "pc_partition_map" but not "pc".
18126 (usage): Fix the description. The options are --boot-image and
18127 --core-image but not --boot-file or --core-file.
18128 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
18129 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
18130 DEFAULT_DIRECTORY.
18131
18132 * util/i386/pc/grub-install.in: Do not specify --boot-file or
18133 --core-file. Specify INSTALL_DEVICE as an argument.
18134
18135 * util/console.c: Include config.h.
18136 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
18137 [HAVE_NCURSES_H]: Include ncurses.h.
18138 [HAVE_CURSES_H]: Include curses.h.
18139 [!A_NORMAL] (A_NORMAL): Defined as zero.
18140 [!A_STANDOUT] (A_STANDOUT): Likewise.
18141
18142 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
18143 -lncurses.
18144 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
18145
18146 * configure.ac: Check for curses libraries and headers.
18147
18148 * Makefile.in (LIBCURSES): New variable.
18149
18150 * genmk.rb (Script::rule): Set the executable bits.
18151
18152 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
18153 name of the PC partition map is "pc_partition_map" but not "pc".
18154
0e143073 181552005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18156
18157 * util/i386/pc/grub-install.in (grub_probefs): New variable.
18158 (modules): Likewise.
18159 (usage): Added descriptions for --modules and --grub-probefs.
18160 Handle --modules and --grub-probefs. Save the arguments in MODULES
18161 and GRUB_PROBEFS, respectively.
18162 Auto-detect a filesystem module against GRUBDIR. If the result is
18163 empty and modules are not specified explicitly, abort the
18164 installation. Add the result to MODULES.
18165
18166 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
18167 disk/powerpc/ieee1275/ofdisk.c,
18168 include/grub/powerpc/ieee1275/init.h and
18169 term/powerpc/ieee1275/ofconsole.c.
18170 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
18171 term/ieee1275/ofconsole.c.
18172
18173 * include/grub/powerpc/ieee1275/console.h: Resurrected.
18174
18175 * COPYING: Upgraded to the latest version. Only the address of the
18176 FSF office has changed.
f19dbdb7 18177
efd6e6d5 181782005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18179
18180 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18181 kern/ieee1275.c with kern/ieee1275/of.c.
18182
18183 * kern/ieee1275.c: Moved to ...
18184 * kern/ieee1275/of.c: ... here.
18185
8ceafda2 181862005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
18187
18188 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
fe6b695a 18189 readability.
8ceafda2 18190
18191 * config.guess: Updated to the latest version from gnulib.
18192 * config.sub: Likewise.
18193 * install.sh: Likewise.
18194 * mkinstalldirs: Likewise.
18195
18196 * include/grub/console.h: Removed. This file is arch-specific. Do
18197 not put this in include/grub.
18198
18199 * include/grub/i386/pc/console.h: Resurrected.
18200
18201 * util/console.c: Include grub/machine/console.h instead of
18202 grub/console.h.
18203 * util/grub-emu.c: Likewise.
18204
267f6cd9 182052005-08-04 Marco Gerards <metgerards@student.han.nl>
18206
18207 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
18208 hardcoded value.
f19dbdb7 18209
267f6cd9 18210 From Vincent Pelletier <subdino2004@yahoo.fr>
18211 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
18212 Redefined to use grub_getwh.
18213 (grub_term): New member named getwh.
18214 (grub_getwh): New prototype.
18215 * kern/term.c (grub_getwh): New function.
18216 * term/i386/pc/console.c (grub_console_getwh): New function.
18217 (grub_console_term): New member `getwh'.
18218 * term/i386/pc/vga.c (grub_vga_getwh): New function.
18219 (grub_vga_term): New member `getwh'.
0b5abe02 18220 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
267f6cd9 18221 grub_ssize_t.
18222 (grub_ofconsole_getw): New function.
18223 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
18224 (grub_ofconsole_term): New field named getwh and new initial
18225 value.
18226
3be7266d 182272005-08-03 Hollis Blanchard <hollis@penguinppc.org>
18228
18229 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
18230 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
18231 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
18232 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
18233 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
18234 of <grub/machine/ieee1275.h>.
18235 * commands/ieee1275/reboot.c: Likewise.
18236 * boot/powerpc/ieee1275/ieee1275.c: Move ...
18237 * kern/ieee1275.c: ... to here. All users updated. Change all
18238 parameter structs to use new type `grub_ieee1275_cell_t'.
18239 * term/powerpc/ieee1275/ofconsole.c: Move ...
18240 * term/ieee1275/ofconsole.c: ... to here. All users updated.
18241 * disk/powerpc/ieee1275/ofdisk.c: Move ...
18242 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
18243 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
18244 to return int.
18245 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
18246 Remove unused prototypes. All users updated.
18247 * include/grub/powerpc/ieee1275/console.h: Removed.
18248 * include/grub/powerpc/ieee1275/ieee1275.h: Define
18249 `grub_ieee1275_cell_t'.
18250 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
18251 Cast comparisons with -1 to the correct type.
18252 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
18253 type to match `grub_ieee1275_entry_fn'.
18254
8b5f3938 182552005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
18256
18257 * DISTLIST: Added util/i386/pc/grub-probefs.c.
18258
18259 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
18260 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
18261 partmap/sun.c.
18262 (grub_probefs_SOURCES): New variable.
18263
18264 * util/i386/pc/grub-probefs.c: New file.
18265
18266 * util/i386/pc/grub-setup.c (main): Call
18267 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
18268 grub_hfs_init and grub_jfs_init to initialize the system. Call
18269 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
18270 grub_pc_partition_map_fini to finish the system.
18271
ea409713 182722005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
18273
18274 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
18275 function.
18276 (grub_multiboot_load_elf32): Likewise.
18277 (grub_multiboot_is_elf64): Likewise.
18278 (grub_multiboot_load_elf64): Likewise.
18279 (grub_multiboot_load_elf): Likewise.
18280 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
18281 an ELF32 or ELF64 file.
18282 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
18283
18284 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
18285 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
18286 NULL before calling FS->LABEL.
18287 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
18288 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
18289 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
18290 before calling FS->LABEL.
18291
141a288b 182922005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
18293
18294 * util/i386/pc/grub-install.in (datadir): New variable.
18295 (libdir): Removed.
18296 (pkgdatadir): New variable.
18297 (pkglibdir): Removed.
18298
0d5f8a54 182992005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
18300
18301 * DISTLIST: Added util/i386/pc/grub-install.in.
18302
18303 * util/i386/pc/grub-install.in: New file.
18304
18305 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
18306 (grub_install_SOURCES): Likewise.
18307
18308 * genmk.rb: Added support for scripts.
18309 (Script): New class.
18310 (scripts): New variable.
18311
18312 * Makefile.in (install-local): Install sbin_SCRIPTS by
18313 INSTALL_SCRIPT.
18314 (uninstall): Remove sbin_SCRIPTS.
18315
18316 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
18317 device, try to get a GRUB device by
18318 grub_util_biosdisk_get_grub_dev.
18319 Free DEST_DEV.
18320
18321 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
18322 description for --device-map.
18323
5f968e1e 183242005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18325
18326 Change the semantics of variable hooks. They now return strings
18327 instead of error values.
f19dbdb7 18328
5f968e1e 18329 * util/i386/pc/grub-setup.c: Include grub/env.h.
18330 (setup): Use grub_device_set_root instead of grub_env_set.
18331
18332 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
18333 grub_env_get instead of grub_device_set_root and
18334 grub_device_get_root, respectively.
18335
18336 * kern/main.c (grub_env_write_root): New function.
18337 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
18338 grub_env_set instead of grub_device_set_root.
18339
18340 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
18341 many variables.
18342 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
18343 rather than calling ENV->WRITE_HOOK afterwards.
18344 (grub_env_get): Return the result of ENV->READ_HOOK rather than
18345 passing a pointer of a pointer.
18346 (grub_register_variable_hook): Change the types of "read_hook" and
18347 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
18348 respectively.
18349 Allocate the default empty string on the heap, because this string
18350 may be freed later.
18351
18352 * kern/device.c: Include grub/env.h.
18353 (grub_device_set_root): Removed.
18354 (grub_device_get_root): Likewise.
18355 (grub_device_open): Use grub_env_get instead of
18356 grub_device_get_root.
18357
18358 * include/grub/env.h (grub_env_read_hook_t): New type.
18359 (grub_env_write_hook_t): Likewise.
18360 (grub_env_var): Change the types of "read_hook" and "write_hook"
18361 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
18362 (grub_register_variable_hook): Likewise.
18363
18364 * include/grub/device.h (grub_device_set_root): Removed.
18365 (grub_device_set_root): Likewise.
18366
18367 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
18368 make sure that DIRNAME terminates with '/', so that
18369 grub_fat_find_dir will fail if PATH is not a directory.
18370
18371 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
18372 from DIRNAME.
18373 Use the qualifier auto for print_files and print_files_long.
18374 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
18375 as a regular file.
18376 Put a newline only if there is no error.
18377 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
18378 used.
18379
896f0afd 183802005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18381
18382 * kern/partition.c (grub_partition_probe): Initialize PART to
18383 NULL. Otherwise, when no partition map is registered, this returns
18384 a garbage.
18385
b28b81b2 183862005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
18387
18388 * partmap/apple.c (apple_partition_map_iterate): Check if POS
18389 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
18390 valid.
18391
5f3607e0 183922005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
18393
18394 * commands/ls.c (grub_ls_list_disks): Print the filesystem
18395 information on each device, if it does not have partitions. Print
18396 "Device" instead of "Disk", because this function is not specific
18397 to disk devices.
18398
18399 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
18400 static to ensure that it is put on the memory rather than a
18401 register.
18402
502c87e8 184032005-07-17 Yoshinori Okuji <okuji@enbug.org>
18404
18405 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
18406 (grub_cat_init): Likewise.
18407 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
18408 (options): Likewise.
18409 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
18410 (grub_configfile_init): Likewise.
18411 * font/manager.c (GRUB_MOD_INIT): Likewise.
18412 * commands/help.c (GRUB_MOD_INIT): Likewise.
18413 (grub_help_init): Likewise.
18414 * normal/command.c (grub_command_init): Likewise.
18415 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
18416 * disk/loopback.c (grub_loop_init): Likewise.
18417 (GRUB_MOD_INIT): Likewise.
18418 * commands/ls.c (grub_ls_init): Likewise.
18419 (GRUB_MOD_INIT): Likewise.
18420 (options): Likewise.
18421 * commands/boot.c (grub_boot_init): Likewise.
18422 (GRUB_MOD_INIT): Likewise.
18423 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
18424 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
18425 (GRUB_MOD_INIT): Likewise.
18426 * commands/cmp.c (grub_cmp_init): Likewise.
18427 (GRUB_MOD_INIT): Likewise.
18428
18429 * normal/arg.c: Use <> instead of "" to include header files.
18430 (SHORT_ARG_HELP): New macro.
18431 (SHORT_ARG_USAGE): Likewise.
18432 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
18433 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
18434 descriptions.
18435 (find_short): Check if C is 'h' or 'u' explicitly.
18436 (grub_arg_show_help): Use space characters instead of tabs. Treat
18437 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
18438 are shown with --help and --usage only if they are not used for
18439 the command itself.
18440 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
18441 'h' and 'u'.
18442
18443 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
18444 const into "longarg". Change the type of "shortarg" to int.
18445
f806d18e 184462005-07-17 Yoshinori Okuji <okuji@enbug.org>
18447
18448 * boot/i386/pc/boot.S (boot_drive_check): New label.
18449
18450 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
18451 macro.
18452
18453 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
18454 which do not pass a boot drive correctly. Copied from GRUB Legacy.
18455
e293232b 184562005-07-17 Yoshinori Okuji <okuji@enbug.org>
18457
18458 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
18459 When turning off Gate A20, skip the check and return immediately,
18460 because this is not fatal usually.
18461
ebedfd00 184622005-07-17 Yoshinori Okuji <okuji@enbug.org>
18463
18464 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
18465 be 0x7C00 instead of 0x8000.
18466
18467 * boot/i386/pc/pxeboot.S: Rewritten.
18468
18469 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
18470 EXT_C.
18471 (gate_a20_check_state): Read a byte from 0x108000. Invert the
18472 result.
18473
654fc59f 184742005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
18475
18476 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
18477 robustness. This routine now supports a BIOS call and System
18478 Control Port A to modify the gate A20.
18479
18480 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
18481 Increased to 0x440.
18482
09f9923f 184832005-07-12 Hollis Blanchard <hollis@penguinppc.org>
18484
18485 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
18486 device path and resulting ihandle.
18487 (grub_ofdisk_close): dprintf the ihandle being closed.
18488 (grub_ofdisk_read): dprintf function parameters.
18489 * kern/mm.c (grub_mm_init_region): Likewise.
18490 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
18491 (grub_linux_boot): dprintf the Linux entry point, initrd address and
18492 size, and boot arguments.
18493 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
18494 before loading into memory.
18495 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
18496 before loading into memory.
18497
7ef504d8 184982005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
18499
18500 * kern/mm.c: Added much documentation.
18501 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
18502 8, set to 5 instead of 8.
18503
e0f050c2 185042005-07-10 Yoshinori Okuji <okuji@enbug.org>
18505
18506 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
18507
18508 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
18509 (grub_mkdevicemap_SOURCES): New variable.
18510
18511 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
18512 lib/device.c of GRUB Legacy.
18513
7224189a 185142005-07-10 Yoshinori Okuji <okuji@enbug.org>
18515
18516 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
18517 instead of PATH is NULL.
18518
68c864eb 185192005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
18520
18521 * commands/cmp.c (BUFFER_SIZE): New macro.
18522 (grub_cmd_cmp): Close the right file at the right time. Compare
18523 only data just read. Don't report files of different size as
18524 identical. Dynamically allocate buffers. Move variable
18525 declarations at the beginning of function.
18526
e6f3e614 185272005-07-09 Yoshinori Okuji <okuji@enbug.org>
18528
18529 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
18530 reverse.
18531
f8f1559a 185322004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
18533
18534 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
18535 when backspace is pressed at beginning of line.
18536
39c9d41d 185372005-07-03 Yoshinori Okuji <okuji@enbug.org>
18538
18539 * DISTLIST: Added genfslist.sh.
18540
18541 * normal/main.c (fs_module_list): New variable.
18542 (autoload_fs_module): New function.
18543 (read_fs_list): Likewise.
18544 (grub_normal_execute): Call read_fs_list.
18545
18546 * kern/fs.c (grub_fs_autoload_hook): New variable.
18547 (grub_fs_probe): Added support for auto-loading.
18548
18549 * include/grub/normal.h (struct grub_fs_module_list): New struct.
18550 (grub_fs_module_list_t): New type.
18551
18552 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
18553 (grub_fs_autoload_hook): New prototype.
18554
18555 * genfslist.sh: New file.
f19dbdb7 18556
39c9d41d 18557 * genmk.rb: Added a rule to generate a filesystem list.
18558
121c1d83 185592005-06-30 Marco Gerards <metgerards@student.han.nl>
18560
18561 * configure.ac: Fix the test for cross-compiling.
18562
18563 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
18564 define GRUB_UTIL anymore.
18565
18566 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
18567 so this function works on other systems than just big endian.
18568 (load_modules): Likewise.
18569 (add_segments): Likewise.
18570
e75d76e1 185712005-06-23 Hollis Blanchard <hollis@penguinppc.org>
18572
18573 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
18574 contains `l' modifier, get a long from va_arg().
18575
50b5a0a7 185762005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
18577
18578 * kern/mm.c (grub_free): If the next free block which is being
18579 merged is the first free block, set the first block to the block
18580 being freed.
18581 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
18582
89371b20 185832005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18584
18585 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
18586 `grub_ieee1275_chosen'.
18587
168d6e58 185882005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18589
18590 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
18591 (grub_ieee1275_chosen): New variable.
18592 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
18593 `chosen'.
18594 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
18595 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
18596 Rename first argument to `phandle' for consistency.
18597 (grub_ieee1275_get_property_length): Likewise.
18598 (grub_ieee1275_next_property): Likewise. Change type of first argument
18599 to grub_ieee1275_phandle_t.
18600 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
18601 Move export next to declaration.
18602 (grub_ieee1275_chosen): New variable.
18603 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
18604 Correct cosmetic typo.
18605 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
18606 `grub_ieee1275_chosen'.
18607 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
18608 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
18609 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
18610 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
18611 `grub_ieee1275_chosen'.
18612
ca5baa3f 186132005-05-10 Hollis Blanchard <hollis@penguinppc.org>
18614
18615 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
18616 /chosen/bootargs.
18617 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
18618 /chosen/bootargs as "variable=value" pairs.
18619
708b345f 186202005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
18621
18622 * include/grub/misc.h (grub_dprintf): New macro.
18623 (grub_real_dprintf): New prototype.
18624 (grub_strword): Likewise.
18625 (grub_iswordseparator): Likewise.
18626 * kern/misc.c (grub_real_dprintf): New function.
18627 (grub_strword): Likewise.
18628 (grub_iswordseparator): Likewise.
18629
f4c5e67c 186302005-04-30 Hollis Blanchard <hollis@penguinppc.org>
18631
18632 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
18633 (roundup): Remove macro.
18634 (grub_ieee1275_flags): Make static.
18635 (grub_ieee1275_realmode): Remove.
18636 (grub_ieee1275_test_flag): New function.
18637 (grub_ieee1275_set_flag): Likewise.
18638 (find_options): Rename to `grub_ieee1275_find_options'; update
18639 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
18640 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
18641 (cmain): New prototype.
18642 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
18643 `grub_ieee1275_flags' directly.
18644 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
18645 machine/biosdisk.h.
18646 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
18647 Don't include grub/machine/init.h.
18648 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
18649 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
18650 Remove prototype.
18651 (grub_ieee1275_realmode): Likewise.
18652 (grub_ieee1275_flag): New enum.
18653 (grub_ieee1275_test_flag): New prototype.
18654 (grub_ieee1275_set_flag): New prototype.
18655 * include/grub/powerpc/ieee1275/init.h: Remove file.
18656 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
18657 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
18658 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
18659 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
18660 comment.
18661 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
18662 `grub_ieee1275_test_flag'.
18663 (grub_ieee1275_encode_devname): Likewise.
18664
ed16607e 186652005-04-21 Hollis Blanchard <hollis@penguinppc.org>
18666
18667 * include/grub/powerpc/ieee1275/ieee1275.h
18668 (grub_ieee1275_encode_devname): New prototype.
18669 (grub_ieee1275_get_filename): Likewise.
18670 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
18671 function.
18672 (grub_set_prefix): Likewise.
18673 (grub_machine_init): Call grub_set_prefix.
18674 * kern/powerpc/ieee1275/openfw.c: Fix typos.
18675 (grub_parse_type): New enum.
18676 (grub_ieee1275_get_devargs): New function.
18677 (grub_ieee1275_get_devname): Likewise.
18678 (grub_ieee1275_parse_args): Likewise.
18679 (grub_ieee1275_get_filename): Likewise.
18680 (grub_ieee1275_encode_devname): Likewise.
18681
be369920 186822005-03-30 Marco Gerards <metgerards@student.han.nl>
18683
18684 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
18685 `grub_loader_unset'.
18686
a5ce3a4a 186872005-03-26 Hollis Blanchard <hollis@penguinppc.org>
18688
18689 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
18690 instead of grub_ieee1275_interpret.
18691 (grub_halt_init): New function.
18692 (grub_halt_fini): Likewise.
18693 (GRUB_MOD_INIT): Correct message grammar.
18694 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
18695 instead of grub_ieee1275_interpret.
18696 (grub_reboot_init): New function.
18697 (grub_reboot_fini): Likewise.
18698 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
18699 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
18700 util/i386/pc/misc.c with commands/ieee1275/halt.c,
18701 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
18702 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
18703 function.
18704 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
18705 Add prototype.
18706 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
18707 prototype.
18708 (grub_halt): Likewise.
18709 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
18710 (cmain): Remove __attribute__((unused)).
18711 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
18712 (grub_heap_len): Likewise.
18713 (grub_machine_fini): New function.
18714 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
18715 (grub_halt): Likewise.
18716 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
18717 function.
18718 * util/powerpc/ieee1275/misc.c: New file.
18719
0058f771 187202005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
18721
18722 * DISTLIST: New file.
18723 * gendistlist.sh: Likewise.
f19dbdb7 18724
0058f771 18725 * Makefile.in (COMMON_DISTFILES): Removed.
18726 (BOOT_DISTFILES): Likewise.
18727 (CONF_DISTFILES): Likewise.
18728 (DISK_DISTFILES): Likewise.
18729 (FS_DISTFILES): Likewise.
18730 (INCLUDE_DISTFILES): Likewise.
18731 (KERN_DISTFILES): Likewise.
18732 (LOADER_DISTFILES): Likewise.
18733 (TERM_DISTFILES): Likewise.
18734 (UTIL_DISTFILES): Likewise.
18735 (DISTFILES): Likewise.
18736 (uninstall): Uninstall files in $(pkgdata_DATA).
18737 (DISTLIST): New target.
18738 (distdir): Use the contents of the file DISTLIST to get a list of
18739 distributed files.
18740
46b3b8a5 187412005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
18742
18743 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
18744 descriptor. This is ported from GRUB Legacy.
18745
18746 * gencmdlist.sh: Added an extra semicolon to make it work with
18747 old sed versions. Reported by Robert Bihlmeyer
18748 <robbe@orcus.priv.at>.
18749
5822ff87 187502005-03-08 Yoshinori Okuji <okuji@enbug.org>
18751
18752 Automatic loading of commands is supported.
f19dbdb7 18753
5822ff87 18754 * normal/main.c (read_command_list): New function.
18755 (grub_normal_execute): Call read_command_list.
18756
18757 * normal/command.c (grub_register_command): Return zero or CMD.
18758 Allocate CMD->NAME from the heap.
18759 Initialize CMD->MODULE_NAME to zero.
18760 Find the same name as well. If the same command is found and it is
18761 a dummy command, overwrite members. If it is not a dummy command,
18762 return zero.
18763 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
18764 (grub_command_find): If a dummy command is found, load a module
18765 and retry to find a command only once.
18766
18767 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
18768 make sure that each command is loaded.
18769
18770 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
18771 macro.
18772 (struct grub_command): Remove const from the member `name'.
18773 Add a new member `module_name'.
18774 (grub_register_command): Return grub_command_t.
18775
18776 * commands/help.c (grub_cmd_help): Call grub_command_find to make
18777 sure that each command is loaded.
18778
18779 * genmk.rb (PModule::rule): Specify a module name without the
18780 suffix ".mod" to gencmdlist.sh.
18781
7b1f4b57 187822005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
18783
18784 * gencmdlist.sh: New file.
f19dbdb7 18785
7b1f4b57 18786 * genmk.rb (PModule::rule): Generate a rule for a command list.
18787 Clean command.lst.
18788 Generate command.lst from $(COMMANDFILES).
18789
18790 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
18791 (DATA): Added $(pkgdata_DATA).
18792 (install-local): Install files in $(pkgdata_DATA).
18793
062aaf39 187942005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
18795
18796 * term/i386/pc/vga.c (debug_command): Removed.
18797 (GRUB_MOD_INIT): Do not register the command "debug".
18798
18799 From Hollis Blanchard:
18800 * commands/configfile.c: New file.
18801 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
18802 commands/configfile.c.
18803 (pkgdata_MODULES): Added configfile.mod.
18804 (configfile_mod_SOURCES): New variable.
18805 (configfile_mod_CFLAGS): Likewise.
18806 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18807 commands/configfile.c.
18808 (pkgdata_MODULES): Added configfile.mod.
18809 (configfile_mod_SOURCES): New variable.
18810 (configfile_mod_CFLAGS): Likewise.
18811 * util/grub-emu.c (main): Call grub_configfile_init and
18812 grub_configfile_fini.
18813 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
18814 prototype.
18815 [GRUB_UTIL] (grub_configfile_fini): Likewise.
f19dbdb7 18816
cee01aa6 188172005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
18818
18819 * normal/arg.c (grub_arg_show_help): Do not show the bug report
18820 address.
18821
18822 * commands/help.c (grub_cmd_help): Do not print newlines after
18823 the last command in print_command_help.
18824
93f3a1d8 188252005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
18826
18827 * commands/default.h: New file.
18828 * commands/timeout.h: Likewise.
18829 * normal/context.c: Likewise.
f19dbdb7 18830
93f3a1d8 18831 * util/misc.c: Do not include sys/times.h.
18832 Include sys/time.h and grub/machine/time.h.
18833 (grub_get_rtc): Rewritten with gettimeofday.
18834
18835 * util/grub-emu.c (main): Call grub_default_init and
18836 grub_timeout_init before grub_normal_init, and call
18837 grub_timeout_fini and grub_default_fini after grub_main.
18838
18839 * util/console.c (grub_ncurses_checkkey): Return the read
18840 character or -1.
18841
18842 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
18843 timeouts.
18844
18845 * normal/main.c (read_config_file): Push MENU. If this fails,
18846 print an error and wait for a user input.
18847 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
18848 If a menu is empty or an error occurs, pop MENU.
18849 (grub_normal_execute): Pop and free MENU after grub_menu_run
18850 returns.
18851
18852 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
18853
18854 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
18855 include time.h.
18856 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
18857 without GRUB_UTIL.
18858 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
18859 time.h.
18860 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
18861 without GRUB_UTIL.
18862
18863 * include/grub/normal.h (struct grub_menu_list): New struct.
18864 (grub_menu_list_t): New type.
18865 (struct grub_context): New struct.
18866 (grub_context_t): New type.
18867 (grub_register_command): Got rid of EXPORT_FUNC.
18868 (grub_unregister_command): Likewise.
18869 (grub_context_get): New prototype.
18870 (grub_context_get_current_menu): Likewise.
18871 (grub_context_push_menu): Likewise.
18872 (grub_context_pop_menu): Likewise.
18873 [GRUB_UTIL] (grub_default_init): Likewise.
18874 [GRUB_UTIL] (grub_default_fini): Likewise.
18875 [GRUB_UTIL] (grub_timeout_init): Likewise.
18876 [GRUB_UTIL] (grub_timeout_fini): Likewise.
18877
18878 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
18879 commands/timeout.c and normal/context.c.
18880 (pkgdata_MODULES): Added default.mod and timeout.mod.
18881 (normal_mod_SOURCES): Added normal/context.c.
18882 (default_mod_SOURCES): New variable.
18883 (default_mod_CFLAGS): Likewise.
18884 (timeout_mod_SOURCES): Likewise.
18885 (timeout_mod_CFLAGS): Likewise.
18886 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
18887 conf/i386-pc.rmk.
18888 (pkgdata_MODULES): Added default.mod and timeout.mod.
18889 (normal_mod_SOURCES): Added normal/context.c.
18890 (default_mod_SOURCES): New variable.
18891 (default_mod_CFLAGS): Likewise.
18892 (timeout_mod_SOURCES): Likewise.
18893 (timeout_mod_CFLAGS): Likewise.
18894
18895 * Makefile.in (all-local): Added $(MKFILES).
18896
4ed2e1dd 188972005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
18898
18899 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
18900 (grub_emu_SOURCES): Likewise.
18901 (pkgdata_MODULES): Add `sun.mod'.
18902 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
18903 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
18904 `partmap/sun.c'.
18905 (pkgdata_MODULES): Add `sun.mod'.
18906 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
18907 * include/grub/partition.h (grub_sun_partition_map_init): New
18908 prototype.
18909 (grub_sun_partition_map_fini): Likewise.
18910 * partmap/sun.c: New file.
18911 * util/grub-emu.c (main): Initialize and de-initialize the sun
18912 partitionmap support.
18913
4d4e372e 189142005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
18915
18916 This implements an Emacs-like menu entry editor.
f19dbdb7 18917
4d4e372e 18918 * normal/menu_entry.c: New file.
f19dbdb7 18919
4d4e372e 18920 * util/console.c (grub_ncurses_putchar): Translate some Unicode
18921 characters to ASCII.
18922 (saved_char): New variable.
18923 (grub_ncurses_checkkey): Rewritten completely.
18924 (grub_ncurses_getkey): Likewise.
18925 (grub_ncurses_init): Call raw instead of cbreak.
18926
18927 * normal/menu.c (print_entry): Do not put a space.
18928 (init_page): Renamed to ...
18929 (grub_menu_init_page): ... this. All callers changed.
18930 (edit_menu_entry): Removed.
18931 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
18932
18933 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
18934
18935 * kern/misc.c (grub_vprintf): Call grub_refresh.
18936
18937 * normal/menu.c (DISP_LEFT): Renamed to ...
18938 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
18939 * normal/menu.c (DISP_UP): Renamed to ...
18940 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
18941 * normal/menu.c (DISP_RIGHT): Renamed to ...
18942 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
18943 * normal/menu.c (DISP_DOWN): Renamed to ...
18944 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
18945 * normal/menu.c (DISP_HLINE): Renamed to ...
18946 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
18947 * normal/menu.c (DISP_VLINE): Renamed to ...
18948 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
18949 * normal/menu.c (DISP_UL): Renamed to ...
18950 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
18951 * normal/menu.c (DISP_UR): Renamed to ...
18952 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
18953 * normal/menu.c (DISP_LL): Renamed to ...
18954 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
18955 * normal/menu.c (DISP_LR): Renamed to ...
18956 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
18957 * normal/menu.c (TERM_WIDTH): Renamed to ...
18958 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
18959 * normal/menu.c (TERM_HEIGHT): Renamed to ...
18960 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
18961 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
18962 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
18963 * normal/menu.c (TERM_MARGIN): Renamed to ...
18964 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
18965 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
18966 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
18967 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
18968 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
18969 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
18970 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
18971 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
18972 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
18973 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
18974 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
18975 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
18976 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
18977 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
18978 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
18979 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
18980 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
18981 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
18982 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
18983 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
18984 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
18985 All callers changed.
18986
18987 * include/grub/normal.h: New prototype.
18988
18989 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
18990 normal/menu_entry.c.
18991 (normal_mod_SOURCES): Likewise.
18992 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
18993 (normal_mod_SOURCES): Likewise.
18994
e6b92c8a 189952005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
18996
18997 * include/grub/normal.h (grub_halt_init): New prototype.
18998 (grub_halt_fini): Likewise.
18999 (grub_reboot_init): Likewise.
19000 (grub_reboot_fini): Likewise.
19001
19002 * util/grub-emu.c: Include signal.h.
19003 (main_env): New global variable.
19004 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
19005 catch C-c.
19006 (grub_machine_fini): New function.
19007 (main): Call grub_halt_init and grub_reboot_init before
19008 grub_main, and grub_reboot_fini and grub_halt_fini after it.
19009 Call setjmp with MAIN_ENV to go back afterwards.
19010 Call grub_machine_fini right before return.
19011
19012 * include/grub/util/misc.h: Include setjmp.h.
19013 (main_env): New prototype.
19014
19015 * include/grub/kernel.h (grub_machine_fini): New prototype.
19016 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
19017 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
19018
19019 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
19020 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
19021 * term/i386/pc/console.c (grub_console_fini): Likewise.
f19dbdb7 19022
e6b92c8a 19023 * util/i386/pc/misc.c: New file.
f19dbdb7 19024
e6b92c8a 19025 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19026 util/i386/pc/misc.c, commands/i386/pc/halt.c and
19027 commands/i386/pc/reboot.c.
19028
c642636f 190292005-02-14 Guillem Jover <guillem@hadrons.org>
19030
19031 * include/grub/dl.h (grub_dl_check_header): New prototype.
19032 (grub_arch_dl_check_header): Change return type to grub_err_t,
19033 remove size parameter and export function. Update all callers.
19034 * kern/dl.c (grub_dl_check_header): New function.
19035 (grub_dl_load_core): Use `grub_dl_check_header' instead of
19036 `grub_arch_dl_check_header'. Check ELF type. Check if sections
19037 are inside the core.
19038 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
19039 independent ELF header checks.
19040 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19041 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
19042 `grub_dl_check_header' instead of explicit checks. Check for the
19043 ELF type.
19044 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
19045 `grub_dl_check_header' instead of explicit checks. Remove arch
19046 specific ELF header checks.
19047
e6b92c8a 19048 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
19049 argument SIZE.
19050
5eabe94b 190512005-02-13 Hollis Blanchard <hollis@penguinppc.org>
19052
19053 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
19054 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
19055
1b14a681 190562005-02-12 Hollis Blanchard <hollis@penguinppc.org>
19057
19058 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
f19dbdb7 19059 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
1b14a681 19060 (part_map_iterate): Clear `grub_errno' and return 0 if
f19dbdb7 19061 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
1b14a681 19062 * partmap/amiga.c (amiga_partition_map_iterate): Return
19063 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
19064 * partmap/apple.c (apple_partition_map_iterate): Likewise.
19065
aca108aa 190662005-02-01 Guillem Jover <guillem@hadrons.org>
19067
19068 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
19069 help info.
19070
c9f9c556 190712005-01-31 Marco Gerards <metgerards@student.han.nl>
19072
19073 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
19074 Removed prototype.
19075 (grub_rescue_cmd_linux): New prototype.
19076 (grub_rescue_cmd_initrd): Likewise.
19077 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
19078 `bi_rec'.
19079 (grub_linux_release_mem): Release the memory for the initrd.
19080 (grub_load_linux): Renamed from this...
19081 (grub_rescue_cmd_linux): ...To this. Changed all callers.
19082 Changed `entry' not to be static. Loop over memory regions to
19083 find another one when the default fails.
19084 (grub_rescue_cmd_initrd): New function.
19085 (grub_linux_init): Remove function.
19086 (grub_linux_fini): Likewise.
19087 (GRUB_MOD_INIT): Register `initrd'.
19088 (GRUB_MOD_FINI): Unregister `initrd'.
19089 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
19090 Function removed.
19091 (grub_linux_normal_fini): Likewise.
19092 (GRUB_MOD_INIT): Register `initrd'.
19093 (GRUB_MOD_FINI): Unregister `initrd'.
19094
990cf3aa 190952005-01-31 Marco Gerards <metgerards@student.han.nl>
19096
19097 * commands/help.c: New file.
19098 * normal/arg.c (show_help): Renamed to...
19099 (grub_arg_show_help): ... this.
19100 * commands/i386/pc/halt.c: New file.
19101 * commands/i386/pc/reboot.c: Likewise.
19102 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
19103 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
19104 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
19105 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
19106 variables.
19107 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19108 `commands/help.c'.
19109 (pkgdata_MODULES): Add `help.mod'.
19110 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
19111 * grub/i386/pc/init.h (grub_reboot): New prototype.
19112 (grub_halt): Likewise.
19113 * include/grub/normal.h (grub_arg_show_help): New prototype.
19114 (grub_help_init): Likewise.
19115 (grub_help_fini): Likewise.
19116 * util/grub-emu.c (main): Initialize and deinitialize the help
19117 command.
19118
19119 * normal/cmdline.c (grub_cmdline_get): Doc fix.
19120
19121 * normal/command.c (grub_command_init): Fixed the description of
19122 the `set' and `unset' commands.
19123
191242005-01-31 Marco Gerards <metgerards@student.han.nl>
0f79cdc1 19125
19126 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
19127 function.
19128 * commands/ieee1275/halt.c: New file.
19129 * commands/ieee1275/reboot.c: Likewise.
19130 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
19131 `__attribute__ ((unused))'. Some GCS related fixed.
19132 (grub_suspend_init) [GRUB_UTIL]: Function removed.
19133 (grub_suspend_fini): Likewise.
19134 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
19135 and `halt.mod'.
19136 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
19137 (halt_mod_CFLAGS): New variables.
19138 * include/grub/powerpc/ieee1275/ieee1275.h
19139 (grub_ieee1275_interpret): New prototype.
19140
1ab09cc7 191412005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
19142
19143 * include/grub/misc.h (memmove): New prototype.
19144 (memcpy): Likewise.
19145
8b8cbdb2 191462005-01-22 Hollis Blanchard <hollis@penguinppc.org>
19147
19148 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
19149 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
19150
e3741a27 191512005-01-22 Marco Gerards <metgerards@student.han.nl>
19152
19153 * kern/misc.c (grub_strndup): Function rewritten.
19154
776bd780 191552005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
19156
19157 * normal/menu.c (TERM_WIDTH): Macro redefined.
19158 (TERM_TOP_BORDER_Y): Likewise.
19159 (draw_border): Replaced while-loop by a for-loop. Make the number
19160 of lines consistent with the number of lines displayed in
19161 print_entries. Added a margin below the rectangle.
19162 (print_entry): Make the entry fit in the rectangle.
19163 (print_entries): Display the scroll arrows next to the right
19164 border.
19165
78026bce 191662005-01-21 Marco Gerards <metgerards@student.han.nl>
19167
19168 * fs/minix.c (grub_minix_find_file): Reserve more space for
19169 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
19170 `grub_strncpy' to copy `path' into it.
19171
67bbaf0f 191722005-01-21 Marco Gerards <metgerards@student.han.nl>
19173
19174 Add the loopback device, a device via which files can be accessed
19175 as devices.
f19dbdb7 19176
67bbaf0f 19177 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
19178 (pkgdata_MODULES): Add loopback.mod.
19179 (loopback_mod_SOURCES): New variable.
19180 (loopback_mod_CFLAGS): Likewise.
19181 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19182 `disk/loopback.c'.
19183 (pkgdata_MODULES): Add loopback.mod.
19184 (loopback_mod_SOURCES): New variable.
19185 (loopback_mod_CFLAGS): Likewise.
19186 * disk/loopback.c: new file.
19187 * include/grub/normal.h (grub_loop_init): New prototype.
19188 (grub_loop_fini): New prototype.
19189 * util/grub-emu.c (main): Initialize and de-initialize loopback
19190 support.
19191 * include/grub/disk.h (grub_disk_dev_id): Add
19192 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
19193
6f1c18bd 191942005-01-20 Hollis Blanchard <hollis@penguinppc.org>
19195
19196 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
19197 function.
19198 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
19199 (suspend_mod_SOURCES): New variable.
19200 (suspend_mod_CFLAGS): Likewise.
19201 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
19202 New prototype.
19203 * commands/ieee1275/suspend.c: New file.
19204
b38551da 192052005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
19206
19207 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
f19dbdb7 19208 ((unused))' to `__attribute__ ((used))'.
b38551da 19209 (GRUB_MOD_FINI): Likewise.
19210 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
19211 * genmk.rb (PModule): Assign space to common symbols when linking
19212 modules.
19213
777aff39 192142005-01-20 Marco Gerards <metgerards@student.han.nl>
19215
19216 * include/grub/mm.h (grub_mm_init_region): Change the type of the
19217 `unsigned' arguments to `grub_size_t'.
19218 (grub_malloc): Likewise.
19219 (grub_realloc): Likewise.
19220 (grub_memalign): Likewise.
19221 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
19222 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19223 * util/misc.c (grub_malloc): Likewise.
19224 (grub_realloc): Likewise.
19225 * kern/mm.c (get_header_from_pointer): Change the casts to
19226 `unsigned' into a cast to `grub_size_t'.
19227
19228 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
19229 point to `currnode' when `currnode' is changed.
19230
19231 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
19232 Schottelius <nico-linux@schottelius.org>.
19233
d0ff18e1 192342005-01-09 Hollis Blanchard <hollis@penguinppc.org>
19235
19236 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
19237 (note_path): Remove variable.
19238 (GRUB_IEEE1275_NOTE_NAME): New macro.
19239 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
19240 (grub_ieee1275_note_hdr): New structure.
19241 (grub_ieee1275_note_desc): Likewise.
19242 (grub_ieee1275_note): Likewise.
19243 (load_note): Remove `dir' argument. All callers updated. Remove
19244 `note_img' and `path'. Do not load a file from `note_path'.
19245 Initialize a struct grub_ieee1275_note and write that to `out'.
19246 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
19247
4ca7004c 192482005-01-05 Marco Gerards <metgerards@student.han.nl>
19249
19250 * util/misc.c (grub_util_read_image): Revert last change. It
19251 called `grub_util_read_at', which seeks from the beginning of the
19252 file.
19253
0b412211 192542005-01-04 Hollis Blanchard <hollis@penguinppc.org>
19255
19256 * TODO: Add note about endianness in grub-mkimage.
19257 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
19258 section.
19259 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
19260 (grub_mkimage_SOURCES): New target.
19261 * include/grub/kernel.h (grub_start_addr): Remove variable.
19262 (grub_end_addr): Likewise.
19263 (grub_total_module_size): Likewise.
19264 (grub_kernel_image_size): Likewise.
19265 (GRUB_MODULE_MAGIC): New constant.
19266 (grub_module_info): New structure.
19267 (grub_arch_modules_addr): New prototype.
19268 (grub_get_end_addr): Remove prototype.
19269 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
19270 * include/grub/powerpc/ieee1275/kernel.h: New file.
19271 * include/grub/util/misc.h (grub_util_get_fp_size): New
19272 prototype.
19273 (grub_util_read_at): Likewise.
19274 (grub_util_write_image_at): Likewise.
19275 * kern/main.c (grub_get_end_addr): Remove function.
19276 (grub_load_modules): Call grub_arch_modules_addr instead of using
19277 grub_end_addr. Look for a grub_module_info struct in memory. Use
19278 the grub_module_info fields instead of calling grub_get_end_addr
19279 as loop conditions. Move grub_add_unused_region code here.
19280 (grub_add_unused_region): Remove function.
19281 * kern/i386/pc/init.c: Include grub/cache.h.
19282 (grub_machine_init): Remove call to grub_get_end_addr. Remove
19283 one call to add_mem_region.
19284 (grub_arch_modules_addr): New function.
19285 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
19286 (grub_total_module_size): Likewise.
19287 Include grub/machine/kernel.h.
19288 (grub_arch_modules_addr): New function.
19289 * util/grub-emu.c (grub_end_addr): Remove variable.
19290 (grub_total_module_size): Likewise.
19291 (grub_arch_modules_addr): New function.
19292 * util/misc.c: Include unistd.h.
19293 (grub_util_get_fp_size): New function.
19294 (grub_util_read_at): Likewise.
19295 (grub_util_write_image_at): Likewise.
19296 (grub_util_read_image): Call grub_util_read_at.
19297 (grub_util_write_image): Call grub_util_write_image_at.
19298 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
19299 additional memory in kernel_img for a struct grub_module_info.
19300 Fill in that grub_module_info.
19301 * util/powerpc/ieee1275/grub-mkimage.c: New file.
19302
458786f8 193032005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19304
19305 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
19306 New function.
19307 * include/grub/powerpc/ieee1275/ieee1275.h
19308 (grub_ieee1275_milliseconds): New prototype.
19309 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
19310 Change to 1000.
19311 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
19312 grub_ieee1275_milliseconds.
19313
ac507d1b 193142005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19315
19316 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
19317 variable.
19318 (find_options): New function.
19319 (cmain): Call find_options.
19320 * include/grub/powerpc/ieee1275/ieee1275.h
19321 (grub_ieee1275_realmode): New extern variable.
19322 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
19323 grub_map if grub_ieee1275_realmode is false.
19324
6b8fd1c4 193252004-12-29 Marco Gerards <metgerards@student.han.nl>
19326
19327 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
19328 lines are inserted and make it work like readline. Reported by
19329 Vincent Pelletier <subdino2004@yahoo.fr>.
19330
8514a1e0 193312004-12-28 Marco Gerards <metgerards@student.han.nl>
19332
19333 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
19334
19335 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
19336 `kern/powerpc/cache.S'.
19337
924b6140 193382004-12-27 Marco Gerards <metgerards@student.han.nl>
19339
19340 * genmk.rb: Handle the `Program' class in the main loop. Written
19341 by Johan Rydberg <jrydberg@gnu.org>.
19342 (Program): New class.
19343 (programs): New variable.
19344 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
19345 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
19346 instead of "grub/kernel.h". Include <grub/machine/init.h>.
19347 (help_arch): Function removed.
19348 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
19349 `powerpc/libgcc.h' and `loader.h'.
19350 (pkgdata_PROGRAMS): New variable.
19351 (sbin_UTILITIES): Variable removed.
19352 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
19353 (grubof_SOURCES): Variable re-defined so it only includes the
19354 core functionality.
19355 (grubof_CFLAGS): Remove `-DGRUBOF'.
19356 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
19357 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
19358 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
19359 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
19360 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
19361 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
19362 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
19363 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
19364 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
19365 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
19366 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
19367 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
19368 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
19369 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
19370 (pc_mod_CFLAGS): New variables.
19371 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
19372 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
19373 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
19374 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
19375 Moved from here...
19376 * include/grub/i386/pc/init.h (grub_os_area_addr)
19377 (rub_os_area_size): ... to here.
19378 * include/grub/powerpc/ieee1275/ieee1275.h
19379 (grub_ieee1275_entry_fn): Export symbol.
19380 * include/grub/powerpc/ieee1275/init.h: New file.
19381 * include/grub/powerpc/libgcc.h: Likewise.
19382 * include/grub/cache.h: Likewise.
19383 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
19384 <hollis@penguinppc.org>.
19385 * kern/dl.c: Include <grub/cache.h>.
19386 (grub_dl_flush_cache): New function.
19387 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
19388 for this module.
19389 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
19390 (grub_console_init): Removed prototypes.
19391 (grub_machine_init): Don't initialize the modules anymore.
19392 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
19393 static.
19394 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
19395 Macro undef removed.
19396 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
19397 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
19398 relocation `R_PPC_REL32'. Return an error when the relocation is
19399 unknown.
19400 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
19401 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
19402 * util/misc.c (grub_arch_sync_caches): Likewise.
19403
e4b47e0c 194042004-12-19 Marco Gerards <metgerards@student.han.nl>
19405
19406 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
19407 `symlist.c', add `grubof_symlist.c'.
19408 (symlist.c): Variable removed.
19409 (grubof_HEADERS): Variable added.
19410 (grubof_symlist.c): New target.
19411 (kernel_syms.lst): Use `grubof_HEADERS' instead of
19412 `kernel_img_HEADERS'.
19413 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
19414 * kern/powerpc/dl.c: New file.
19415 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
19416 Function removed.
19417 (grub_arch_dl_relocate_symbols): Likewise.
19418 (grub_register_exported_symbols): Likewise.
19419
4ceb3636 194202004-12-13 Marco Gerards <metgerards@student.han.nl>
19421
19422 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
19423 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
19424 to fail instead. Reported by Vincent Pelletier
19425 <subdino2004@yahoo.fr>.
19426
19427 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
19428 it is not allocated. Reported by Vincent Pelletier
19429 <subdino2004@yahoo.fr>.
19430
19431 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
19432 output so the output looks better.
f19dbdb7 19433
3f1578fe 194342004-12-04 Marco Gerards <metgerards@student.han.nl>
19435
19436 Modulize the partition map support and add support for the amiga
19437 partition map.
f19dbdb7 19438
3f1578fe 19439 * commands/ls.c: Include <grub/partition.h> instead of
19440 <grub/machine/partition.h>.
19441 * kern/disk.c: Likewise.
19442 * kern/rescue.c: Likewise.
19443 * loader/i386/pc/chainloader.c: Likewise.
19444 * normal/cmdline.c: Likewise.
19445 * kern/powerpc/ieee1275/init.c: Likewise.
19446 (grub_machine_init): Call `grub_pc_partition_map_init',
19447 `grub_amiga_partition_map_init' and
19448 `grub_apple_partition_map_init'.
19449 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
19450 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
19451 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
19452 `partition.h' and `pc_partition.h'.
19453 (grub_setup_SOURCES): Remove
19454 `disk/i386/pc/partition.c'. Add `kern/partition.c',
19455 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19456 (grub_emu_SOURCES): Likewise.
19457 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
19458 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
19459 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
19460 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19461 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
19462 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19463 (grubof_SOURCES): Likewise.
19464 * disk/i386/pc/partition.c: File removed.
19465 * disk/powerpc/ieee1275/partition.c: Likewise.
19466 * include/grub/powerpc/ieee1275/partition.h: Likewise.
19467 * include/grub/i386/pc/partition.h: Likewise.
19468 * kern/partition.c: New file.
19469 * partmap/amiga.c: Likewise.
19470 * partmap/apple.c: Likewise.
19471 * partmap/pc.c: Likewise.
19472 * include/grub/partition.h: Likewise..
19473 * include/grub/pc_partition.h: Likewise.
19474 * util/grub-emu.c: Include <grub/partition.h> instead of
19475 <grub/machine/partition.h>.
19476 (main): Call `grub_pc_partition_map_init',
19477 `grub_amiga_partition_map_init' and
19478 `grub_apple_partition_map_init' and deinitialize afterwards.
19479 * util/i386/pc/biosdisk.c: Include `#include
19480 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19481 `<grub/machine/partition.h>'.
19482 * util/i386/pc/grub-setup.c: Likewise.
19483 * util/i386/pc/biosdisk.c: Likewise.
19484 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
19485 partition information in case of a PC partition.
19486 * util/i386/pc/grub-setup.c: Include `#include
19487 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19488 `<grub/machine/partition.h>'.
19489 (setup): Only access the PC specific partition information in case
19490 of a PC partition.
19491
0ef4ced9 194922004-11-17 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 19493
0ef4ced9 19494 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
19495 (grub_longjmp): Likewise.
19496 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
19497 20.
19498 * normal/powerpc/setjmp.S: New file.
19499 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
19500 `normal/powerpc/setjmp.S'.
19501 (grubof_CFLAGS): Add `-DGRUBOF'.
19502 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
19503 [GRUB_UTIL && !GRUBOF].
f19dbdb7 19504
19950e29 195052004-11-16 Marco Gerards <metgerards@student.han.nl>
19506
19507 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
19508 property named `name'. Correctly handle the error returned by
19509 `grub_ieee1275_finddevice' if a device can not be opened.
19510
a2fea427 195112004-11-02 Hollis Blanchard <hollis@penguinppc.org>
19512
19513 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
19514 `actual' for negativity.
19515 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19516 kern/fshelp.c.
19517
41ea0ea3 195182004-11-01 Marco Gerards <metgerards@student.han.nl>
19519
19520 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
19521 (PAGE_OFFSET): New macro.
19522 (CRTC_ADDR_PORT): Likewise.
19523 (CRTC_DATA_PORT): Likewise.
19524 (START_ADDR_HIGH_REGISTER): Likewise.
19525 (START_ADDR_LOW_REGISTER): Likewise.
19526 (GRAPHICS_ADDR_PORT): Likewise.
19527 (GRAPHICS_DATA_PORT): Likewise.
19528 (READ_MAP_REGISTER): Likewise.
19529 (INPUT_STATUS1_REGISTER): Likewise.
19530 (INPUT_STATUS1_VERTR_BIT): Likewise.
19531 (page): New variable.
19532 (wait_vretrace): New function.
19533 (set_read_map): Likewise.
19534 (set_start_address): Likewise.
19535 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
19536 the right page.
19537 (check_vga_mem): Take the page into account.
19538 (write_char): Likewise.
19539 (write_cursor): Likewise.
19540 (scroll_up): Likewise. Copy the page to the page that is not
19541 shown and switch between both pages.
19542 (grub_vga_putchar): Fix off by one error.
19543 (grub_vga_cls): Wait for the vertical retrace. Take the page into
19544 account.
19545
ad0bd20b 195462004-11-01 Marco Gerards <metgerards@student.han.nl>
19547
19548 Add support for iso9660 (including rockridge).
f19dbdb7 19549
ad0bd20b 19550 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19551 (iso9660_mod_SOURCES): New variable.
19552 (iso9660_mod_CFLAGS): Likewise.
19553 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19554 * include/grub/fs.h (grub_iso9660_init): New prototype.
19555 * util/grub-emu.c (main): Call `grub_iso9660_init'.
19556 * fs/iso9660.c: New file.
19557
19558 * include/grub/misc.h (grub_strncat): New prototype.
19559 * kern/misc.c (grub_strncat): New function.
f19dbdb7 19560
ad0bd20b 19561 * fs/hfs.c (grub_hfs_mount): Translate the error
19562 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
19563 * fs/jfs.c (grub_jfs_mount): Likewise.
19564 * fs/ufs.c (grub_ufs_mount): Likewise.
19565
a5477a59 195662004-10-28 Hollis Blanchard <hollis@penguinppc.org>
19567
19568 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
19569 which initialized BAT registers.
19570 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
19571 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19572 Move from here...
19573 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
19574 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19575 ... to here.
19576 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
19577 (grub_mapclaim): Likewise.
19578 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
19579 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
19580 hand.
19581
9304c1f8 195822004-10-19 Hollis Blanchard <hollis@penguinppc.org>
19583
19584 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
19585 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
19586 -ffreestanding and -msoft-float.
19587
86f4ae25 195882004-10-15 Hollis Blanchard <hollis@penguinppc.org>
19589
19590 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
19591 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
19592 set in grub_ieee1275_flags.
19593
38912228 195942004-10-14 Hollis Blanchard <hollis@penguinppc.org>
19595
19596 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
19597 prototype.
19598 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
19599 grub_console_init first.
19600 Change the memory range used for grub_ieee1275_claim and
19601 grub_mm_init_region.
19602 Print an error message if the claim fails.
19603 Include <grub/misc.h>.
19604
d1923dc8 196052004-10-13 Hollis Blanchard <hollis@penguinppc.org>
19606
19607 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
19608 Call grub_children_iterate for device nodes of type `scsi',
19609 `ide', or `ata'.
19610 (grub_ofdisk_open): Remove manual device alias resolution.
19611 Fix memory leak when device cannot be opened.
f19dbdb7 19612 * include/grub/powerpc/ieee1275/ieee1275.h
d1923dc8 19613 (grub_children_iterate): New prototype.
19614 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
19615 New function.
19616 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
19617 Return -1 if args.size was -1.
19618
4512e4f3 196192004-10-11 Hollis Blanchard <hollis@penguinppc.org>
19620
19621 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
19622 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
19623 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
19624 Open Firmware's memory for it; claim memory from _start to _end.
19625 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
19626 (_end): New extern.
19627 (_start): Zero BSS from __bss_start to _end.
19628 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
19629 New extern.
19630 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
19631
4d61feb0 196322004-10-11 Hollis Blanchard <hollis@penguinppc.org>
19633
ad0bd20b 19634 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
19635 -1 if args.base was -1.
4d61feb0 19636
026fa2f9 196372004-10-08 Hollis Blanchard <hollis@penguinppc.org>
19638
19639 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
19640 escape sequence instead of a literal ^L. Also call
19641 grub_ofconsole_gotoxy.
19642
9f2220ef 196432004-10-03 Hollis Blanchard <hollis@penguinppc.org>
19644
19645 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
19646 void * arguments to grub_addr_t. All callers updated. Also make
19647 the `result' argument optional.
19648 (grub_ieee1275_release): change void * arguments to grub_addr_t.
19649 All callers updated.
19650
8a572cd7 196512004-09-22 Hollis Blanchard <hollis@penguinppc.org>
19652
19653 * commands/ls.c (grub_ls_list_files): Use the string following the
19654 initial ')', if present, as the filesystem path.
19655 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
19656
19657 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
19658
18aa81f2 196592004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
19660
19661 Make the source code of the menu interface more readable.
f19dbdb7 19662
18aa81f2 19663 * normal/menu.c: Include grub/mm.h.
19664 (TERM_WIDTH): New macro.
19665 (TERM_HEIGHT): Likewise.
19666 (TERM_INFO_HEIGHT): Likewise.
19667 (TERM_MARGIN): Likewise.
19668 (TERM_SCROLL_WIDTH): Likewise.
19669 (TERM_TOP_BORDER_Y): Likewise.
19670 (TERM_LEFT_BORDER_X): Likewise.
19671 (TERM_BORDER_WIDTH): Likewise.
19672 (TERM_MESSAGE_HEIGHT): Likewise.
19673 (TERM_BORDER_HEIGHT): Likewise.
19674 (TERM_NUM_ENTRIES): Likewise.
19675 (TERM_FIRST_ENTRY_Y): Likewise.
19676 (TERM_ENTRY_WIDTH): Likewise.
19677 (TERM_CURSOR_X): Likewise.
19678 (draw_border): Use macros instead of magic numbers.
19679 (print_entry): Likewise.
19680 (print_entries): Likewise.
19681 (run_menu): Likewise. Also, handle the key 'e'.
19682 (run_menu_entry): Ignore empty command lines.
19683 (print_message): Added a new argument EDIT. If EDIT is true,
19684 print a different message.
19685 (init_page): Likewise.
19686 (edit_menu_entry): New function. Not implemented yet.
19687
b47efe30 196882004-09-17 Marco Gerards <metgerards@student.han.nl>
19689
19690 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
19691 can be loaded from normal mode.
f19dbdb7 19692
b47efe30 19693 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
19694 `multiboot.mod'.
19695 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
19696 (multiboot_mod_CFLAGS): New variables.
19697 * loader/i386/pc/linux_normal.c: New file.
f19dbdb7 19698 * loader/i386/pc/multiboot_normal.c: Likewise.
19699
b47efe30 19700 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
19701 attribute `unused'.
f19dbdb7 19702
b47efe30 19703 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
19704 `fdiro' to read the mode information from instead of `diro'.
19705
19706 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
19707 looking up a symlink.
19708
19709 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
19710 macro.
19711 * normal/command.c (grub_command_execute): Don't parse the
19712 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
19713 flags of the command.
19714
19715 * normal/menu.c (grub_menu_run): Fix typo.
19716
da75ac71 197172004-09-14 Hollis Blanchard <hollis@penguinppc.org>
19718
19719 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
19720
19721 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
19722 `y + 1' instead of `y - 1'.
19723
19724 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
f19dbdb7 19725
062b24c2 197262004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
19727
19728 From Hollis Blanchard <hollis@penguinppc.org>:
19729 * kern/misc.c (memmove): New alias for grub_memmove.
19730 (memcmp): New alias for grub_memcmp.
19731 (memset): New alias for grub_memset.
f19dbdb7 19732 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
062b24c2 19733 Change "int handle" to "grub_ieee1275_phandle_t handle".
f19dbdb7 19734 * include/grub/powerpc/ieee1275/ieee1275.h
062b24c2 19735 (grub_ieee1275_get_property): Likewise.
f19dbdb7 19736
8ddad845 197372004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
19738
19739 Added normal mode command `chainloader' as module chain.mod, which
19740 depends on normal.mod and _chain.mod.
f19dbdb7 19741
8ddad845 19742 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
19743 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
19744 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
19745 Deleted prototype.
19746 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
19747 but arguments parsing moved to ...
19748 (grub_chainloader_cmd): ... here. New function.
19749 * include/grub/i386/pc/chainloader.h: New file.
19750 * loader/i386/pc/chainloader_normal.c: Likewise.
19751
2c1f4ce3 197522004-09-11 Marco Gerards <metgerards@student.han.nl>
19753
19754 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
19755 (grub_mkimage_LDFLAGS): Likewise.
19756 (grub_emu_SOURCES): Likewise.
19757 (kernel_img_HEADERS): Added fshelp.h.
19758 * fs/ext2.c: Include <grub/fshelp.h>.
19759 (FILETYPE_REG): New macro.
19760 (FILETYPE_INO_REG): Likewise.
19761 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
19762 Changed all users.
19763 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
19764 all users.
19765 (grub_fshelp_node): New struct.
19766 (grub_ext2_data): Added member `diropen'. Changed member `inode'
19767 to a pointer.
19768 (grub_ext2_get_file_block): Removed function.
19769 (grub_ext2_read_block): New function.
19770 (grub_ext2_read_file): Replaced parameter `data' by `node'.
19771 This function was written.
19772 (grub_ext2_mount): Read the root inode. Create a diropen struct.
19773 (grub_ext2_find_file): Removed function.
19774 (grub_ext2_read_symlink): New function.
19775 (grub_ext2_iterate_dir): Likewise.
19776 (grub_ext2_open): Rewritten.
19777 (grub_ext2_dir): Rewritten.
19778 * include/grub/fshelp.h: New file.
19779 * fs/fshelp.c: Likewise.
19780
3c52136a 197812004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
19782
19783 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
19784 (print_message): Add a missing newline.
19785 (run_menu): Added timeout support.
19786 (run_menu_entry): New local function.
19787 (grub_menu_run): Added support for booting.
19788
19789 * kern/loader.c (grub_loader_is_loaded): New function.
19790
19791 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
19792 (grub_get_rtc): Exported.
19793
19794 * include/grub/i386/pc/time.h: Include grub/symbol.h.
19795 (grub_get_rtc): Exported.
19796
19797 * include/grub/normal.h (struct grub_command_list): Remove
19798 constant from the member `command'.
19799
19800 * include/grub/loader.h (grub_loader_is_loaded): Declared.
19801
19802 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
19803
19804 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
19805
aa033560 198062004-08-28 Marco Gerards <metgerards@student.han.nl>
19807
19808 Add support for the JFS filesystem.
19809
19810 * fs/jfs.c: New file.
19811 * include/grub/fs.h (grub_jfs_init): New prototype.
19812 (grub_jfs_fini): New prototype.
19813 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
19814 (grub_emu_SOURCES): Likewise.
19815 (pkgdata_MODULES): Add jfs.mod.
19816 (jfs_mod_SOURCES): New variable.
19817 (jfs_mod_CFLAGS): Likewise.
19818 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
19819 (grubof_SOURCES): Likewise.
19820 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
19821
19822 * fs/fat.c (grub_fat_find_dir): Convert the filename little
19823 endian to the host endian.
19824 (grub_fat_utf16_to_utf8): Move function from there...
19825 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
fe987087 19826 the endianness of the source string anymore.
aa033560 19827 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
19828
94bc45af 198292004-08-24 Marco Gerards <metgerards@student.han.nl>
19830
19831 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
19832 (grub_boot_fini) [GRUB_UTIL]: Likewise.
19833 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
19834 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
f19dbdb7 19835
94bc45af 19836 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
19837 (grub_hfs_iterate_dir): Make the function static. Add prototypes
19838 for `node_found' and `it_dir'.
19839 (grub_hfs_dir): Add prototype for `dir_hook'.
19840
19841 * fs/minix.c (grub_minix_get_file_block): Add prototype for
19842 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
19843 and `indir32' to silence a gcc warning.
19844
19845 * include/grub/fs.h (grub_hfs_init): New prototype.
19846 (grub_hfs_fini): Likewise.
f19dbdb7 19847
19848
97543f08 198492004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
19850
19851 Each disk device has its own id now. This is useful to make use
19852 of multiple disk devices.
f19dbdb7 19853
97543f08 19854 * include/grub/disk.h (grub_disk_dev_id): New enum.
19855 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
19856 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
19857
19858 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
19859 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
19860
19861 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
19862 GRUB_DISK_DEVICE_OFDISK_ID as an id.
19863
19864 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
19865 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
19866
19867 * include/grub/disk.h (struct grub_disk_dev): Added a new member
19868 "id" which is used by the cache manager.
19869
19870 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
19871 of just "GRUB".
19872
64372eb4 198732004-08-18 Marco Gerards <metgerards@student.han.nl>
19874
19875 * fs/hfs.c: New file.
19876 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
19877 (grub_emu_SOURCES): Likewise.
19878 (pkgdata_MODULES): Add hfs.mod.
19879 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
19880 (grubof_SOURCES): Likewise.
19881 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
19882
19883 * include/grub/misc.h (grub_strncasecmp): Add prototype.
19884 * kern/misc.c (grub_strncasecmp): Add function.
19885
cc61b58f 198862004-08-14 Marco Gerards <metgerards@student.han.nl>
19887
19888 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
19889 with parentheses.
19890
19891 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
19892 (grub_ext2_dir): In case the directory entry type is unknown, read
19893 it from the inode.
19894
0ef123f6 198952004-08-02 Peter Bruin <pjbruin@dds.nl>
19896
19897 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
19898 grub_load_linux instead of grub_rescue_cmd_linux as second
19899 argument of grub_rescue_register_command.
19900
19901 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
19902
a447c5df 199032004-07-27 Marco Gerards <metgerards@student.han.nl>
19904
19905 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
19906 function.
19907 * commands/boot.c: Remove the check for `GRUB_UTIL'.
19908 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
19909 `loader/powerpc/ieee1275/linux.c',
19910 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
19911 * include/grub/powerpc/ieee1275/ieee1275.h
19912 (grub_ieee1275_release): New prototype.
19913 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
19914 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
19915 normal, boot, linux and linux_normal.
19916 * loader/powerpc/ieee1275/linux.c: New file.
19917 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
19918
5a9e3546 199192004-07-12 Marco Gerards <metgerards@student.han.nl>
19920
19921 * normal/arg.c (grub_arg_parse): Correct error handling after
19922 reallocating the argumentlist (check if `argl' is not null instead
19923 of checking if `args' is not null).
19924 * kern/mm.c (grub_realloc): Return the same pointer when using the
19925 same region, instead of returning the header address.
19926
e15199cb 199272004-07-11 Marco Gerards <metgerards@student.han.nl>
19928
19929 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
19930 one block instead of two when looking for the initial partition.
19931 (grub_partition_probe): Initialize the local variable `p' with 0.
19932 Use base 10 for the grub_strtoul call.
19933 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
19934 need for one local variable.
19935 (grub_strtoul): Don't add the new value to `num', instead of that
19936 just assign it.
19937
020616c2 199382004-07-11 Marco Gerards <metgerards@student.han.nl>
19939
19940 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
19941 (pxeboot_img_SOURCES): New variable.
19942 (pxeboot_img_ASFLAGS): Likewise.
19943 (pxeboot_img_LDFLAGS): Likewise.
19944 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
19945 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
19946 <lode_leroy@hotmail.com>.
19947
6c51eb64 199482004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
19949
19950 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
19951 there was no input.
19952
cfb12aff 199532004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
19954
19955 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
19956 the history buffer logic.
19957
6eabba74 199582004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
19959
19960 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
19961 (FILETYPE_INO_SYMLINK): New macros.
19962 (grub_ext2_find_file): Check if the node is a directory using the
19963 inode stat information instead of using the filetype in the
19964 dirent. Exclude the first character of an absolute symlink.
19965 (grub_ext2_dir): Mask out the filetype part of the mode member of
19966 the inode.
19967
66e19ef8 199682004-05-24 Marco Gerards <metgerards@student.han.nl>
19969
19970 Add support for UFS version 1 and 2. Add support for the minix
19971 filesystem version 1 and 2, both the variants with 14 and 30 long
19972 filenames.
f19dbdb7 19973
66e19ef8 19974 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
19975 fs/minix.c.
19976 (grub_emu_SOURCES): Likewise.
19977 (pkgdata_MODULES): Add ufs.mod and minix.mod.
19978 (ufs_mod_SOURCES): New variable.
19979 (ufs_mod_CFLAGS): Likewise.
19980 (minix_mod_SOURCES): Likewise.
19981 (minix_mod_CFLAGS): Likewise.
19982 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
19983 fs/minix.c.
19984 (grubof_SOURCES): Likewise.
19985 * fs/ufs.c: New file.
19986 * fs/minix.c: New file.
19987 * include/grub/fs.h (grub_ufs_init): New prototype.
19988 (grub_ufs_fini): Likewise.
19989 (grub_minix_init): Likewise.
19990 (grub_minix_fini): Likewise.
19991 * util/grub-emu.c (main): Initialize and deinitialize UFS and
19992 minix fs.
19993
cc2e748a 199942004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
19995
19996 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
19997 commands/ls.c, commands/terminal.c, commands/boot.c,
19998 commands/cmp.c and commands/cat.c.
19999 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
20000
20001 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
20002 "env.h"
20003
4b13b216 200042004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20005
20006 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
20007 and grub_, respectively. Because the conversion is trivial and
20008 mechanical, I omit the details here. Please refer to the CVS
20009 if you need more information.
20010
6a142551 200112004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20012
20013 * include/pupa: Renamed to ...
20014 * include/grub: ... this.
20015 * util/i386/pc/pupa-mkimage.c: Renamed to ...
20016 * util/i386/pc/grub-mkimage.c: ... this.
20017 * util/i386/pc/pupa-setup.c: Renamed to ...
20018 * util/i386/pc/grub-setup.c: ... this.
20019 * util/pupa-emu.c: Renamed to ...
20020 * util/grub-emu.c: ... this.
20021
e56cdf21 200222004-03-29 Marco Gerards <metgerards@student.han.nl>
20023
20024 Add support for the newworld apple macintosh (PPC). This has been
20025 tested on the powerbook 2000 only. It only adds support for
20026 generic ieee1275 functions, console and disk support. This should
20027 be easy to port to other architectures with support for Open
20028 Firmware.
f19dbdb7 20029
e56cdf21 20030 * configure.ac: Accept the powerpc as host_cpu. In the case of
20031 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
20032 specific tests are only executed while building for the i386.
20033 Inverse test for crosscompile.
20034 * genmk.rb (Utility): Allow assembler files.
20035 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
20036 * conf/powerpc-ieee1275.rmk: New file.
20037 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
20038 * disk/powerpc/ieee1275/partition.c: Likewise.
20039 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
20040 * include/pupa/powerpc/ieee1275/console.h: Likewise.
20041 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
20042 * include/pupa/powerpc/ieee1275/time.h: Likewise.
20043 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
20044 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
20045 * include/pupa/powerpc/ieee1275/loader.h
20046 * include/pupa/powerpc/setjmp.h: Likewise.
20047 * include/pupa/powerpc/types.h: Likewise.
20048 * kern/powerpc/ieee1275/init.c: Likewise.
20049 * kern/powerpc/ieee1275/openfw.c: Likewise.
20050 * term/powerpc/ieee1275/ofconsole.c: Likewise.
20051
20052 These files were written by Johan Rydberg
20053 (jrydberg@night.trouble.net) and I only modified them slightly.
f19dbdb7 20054
e56cdf21 20055 * boot/powerpc/ieee1275/cmain.c: New file.
20056 * boot/powerpc/ieee1275/crt0.S: Likewise.
20057 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
20058 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
20059
8c8cc205 200602004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
20061
20062 * Makefile.in: Update copyright.
20063 * genmodsrc.sh: Likewise.
20064 * gensymlist.sh: Likewise.
20065 * term/i386/pc/vga.c: Indent correctly.
20066
20067 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
20068 bugreporting address.
20069 * util/i386/pc/pupa-setup.c (usage): Likewise,
20070 (main): Call pupa_ext2_init and pupa_ext2_fini.
20071
f19dbdb7 20072 * fs/fat.c (log2): Renamed to ...
8c8cc205 20073 (fat_log2): ... this.
20074 All callers changed.
20075 * kern/misc.c (memcpy): Alias to pupa_memmove.
20076 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
20077 lvalue cast.
20078 * util/console.c (pupa_ncurses_fini): Return 0.
20079
20080 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
20081 Move fail label here.
20082 [__GNU__]: Don't warn when using stat.
20083 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
20084 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
20085 long int. Use strtol instead of strtoul.
f19dbdb7 20086
db1771cf 200872004-03-14 Marco Gerards <metgerards@student.han.nl>
20088
20089 * commands/boot.c: New file.
20090 * commands/cat.c: Likewise.
20091 * commands/cmp.c: Likewise.
20092 * commands/ls.c: Likewise.
20093 * commands/terminal.c: Likewise.
20094 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
20095 (pupa_register_command): Changed interface to match the new
20096 argument parser.
20097 (pupa_command_execute): Changed (almost rewritten) so it uses
20098 pupa_split_command. Added support for setting variables using the
20099 syntax `foo=bar'.
20100 (rescue_command): Changed to work with the new argument parser.
20101 (terminal_command): Moved from here to commands/terminal.c.
20102 (set_command): New function.
20103 (unset_command): New function.
20104 (insmod_command): New function.
20105 (rmmod_command): New function.
20106 (lsmod_command): New function.
20107 (pupa_command_init): Don't initialize the command terminal
20108 anymore. Initialize the commands set, unset, insmod, rmmod and
20109 lsmod.
20110 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
20111 (kernel_img_HEADERS): Add arg.h and env.h.
20112 (pupa_mkimage_LDFLAGS): Add kern/env.c.
20113 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
20114 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
20115 normal/arg.c.
20116 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
20117 terminal.mod.
20118 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
20119 (boot_mod_SOURCES): New variable.
20120 (terminal_mod_SOURCES): Likewise.
20121 (ls_mod_SOURCES): Likewise.
20122 (cmp_mod_SOURCES): Likewise.
20123 (cat_mod_SOURCES): Likewise.
20124
20125 * normal/arg.c: New file.
20126 * kern/env.c: Likewise.
20127 * include/pupa/arg.h: Likewise.
20128 * include/pupa/env.h: Likewise.
20129 * font/manager.c (font_command): Changed to match argument parsing
20130 interface changes.
20131 (PUPA_MOD_INIT): Likewise.
20132 * hello/hello.c (pupa_cmd_hello): Likewise.
20133 (PUPA_MOD_INIT): Likewise.
20134 * include/pupa/disk.h: Include <pupa/device.h>.
20135 (pupa_print_partinfo): New prototype.
20136 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
20137 (pupa_dl_get_prefix): Likewise.
20138 * include/pupa/misc.h: Include <pupa/err.h>.
20139 (pupa_isgraph): New prototype.
20140 (pupa_isdigit): Likewise.
20141 (pupa_split_cmdline): Likewise.
20142 * include/pupa/normal.h: Include <pupa/arg.h>.
20143 (pupa_command): Changed the prototype of the member `func' to
20144 match the argument parsing interface. Added member `options'.
20145 (pupa_register_command): Updated to match function.
20146 (pupa_arg_parse): New prototype.
20147 (pupa_hello_init) [PUPA_UTIL]: New prototype.
20148 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
20149 (pupa_ls_init) [PUPA_UTIL]: Likewise.
20150 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
20151 (pupa_cat_init) [PUPA_UTIL]: Likewise.
20152 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
20153 (pupa_boot_init) [PUPA_UTIL]: Likewise.
20154 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
20155 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
20156 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
20157 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
20158 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
20159 * kern/disk.c: Include <pupa/file.h>.
20160 (pupa_print_partinfo): New function.
20161 * kern/dl.c: Include <pupa/env.h>.
20162 (pupa_dl_dir): Variable removed.
20163 (pupa_dl_load): Use the environment variable `prefix' instead of
20164 the variable pupa_dl_dir.
20165 (pupa_dl_set_prefix): Function removed.
20166 (pupa_dl_get_prefix): Likewise.
20167 * kern/i386/pc/init.c: Include <pupa/env.h>.
20168 (pupa_machine_init): Use the environment variable `prefix' instead of
20169 using pupa_dl_set_prefix to set the prefix.
20170 * kern/main.c: Include <pupa/env.h>.
20171 (pupa_set_root_dev): Use the environment variable `prefix' instead of
20172 using pupa_dl_get_prefix to get the prefix.
20173 * kern/misc.c: Include <pupa/env.h>.
20174 (pupa_isdigit): New function.
20175 (pupa_isgraph): Likewise.
20176 (pupa_ftoa): Likewise.
20177 (pupa_vsprintf): Added support for printing values of the type
20178 `double'. Make it possible to format variable output when using
20179 formatting like `%1.2%f'.
20180 (pupa_split_cmdline): New function.
20181 * kern/rescue.c: Include <pupa/env.h>.
20182 (next_word): Removed function.
20183 (pupa_rescue_cmd_prefix): Likewise.
20184 (pupa_rescue_cmd_set): New function.
20185 (pupa_rescue_cmd_unset): New function.
20186 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
20187 split the command line instead of splitting it here. Added
20188 support for setting variables using the syntax `foo=bar'. Don't
20189 initialize the prefix command anymore. Initialized the set and
20190 unset commands.
20191 * normal/cmdline.c: Include <pupa/env.h>.
20192 (pupa_tab_complete): Added prototypes for print_simple_completion,
20193 print_partition_completion, add_completion, iterate_commands,
20194 iterate_dev, iterate_part and iterate_dir. Moved code to print
20195 partition information from here to kern/disk.c.
fe6b695a 20196 (pupa_cmdline_run): Don't check if the function exists anymore.
db1771cf 20197 * normal/main.c: Include <pupa/env.h>.
20198 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
20199 instead of using pupa_dl_get_prefix to get the prefix.
20200 * term/i386/pc/vga.c: Include <pupa/arg.h>.
20201 (check_vga_mem): Cast pointers to `void *' to silence a gcc
20202 warning.
20203 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
20204 (pupa_vga_setcolor): Declare unused variables with `__attribute__
20205 ((unused))' to silence a gcc warning.
20206 (pupa_vga_setcolor): Likewise.
20207 (debug_command): Changed to match argument parsing
20208 interface changes.
20209 * util/pupa-emu.c: Include <pupa/env.h>.
20210 (options): Added 0's for unused fields to silence a gcc warning.
20211 (argp): Likewise.
20212 (main): Use the environment variable `prefix' instead of using
20213 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
20214 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
20215 and terminal.
20216
20217 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
20218 * util/misc.c: Include <malloc.h>.
20219 (pupa_malloc): Rewritten so errors are correctly reported.
20220 (pupa_realloc): Likewise.
20221 (pupa_memalign): Likewise.
20222 (pupa_mm_init_region): Declare unused variables with
20223 `__attribute__ ((unused))' to silence a gcc warning.
20224 * normal/i386/setjmp.S: Remove tab at the end of the file to
20225 silence a gcc warning.
20226 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
20227 variables with `__attribute__ ((unused))' to silence a gcc
20228 warning.
20229 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
20230 local variable i unsigned to silence a gcc warning.
20231
20232 * kern/term.c: Include <pupa/misc.h>.
20233 (pupa_more_lines): New variable.
20234 (pupa_more): Likewise.
20235 (pupa_putcode): When the pager is active pause at the end of every
20236 screen.
20237 (pupa_set_more): New function.
20238 * include/pupa/term.h (pupa_set_more): New prototype.
20239
20240
3b1139cb 202412004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
20242
20243 Now this project is GRUB 2 rather than PUPA. The location of
20244 the CVS repository was moved to GRUB's.
f19dbdb7 20245
3b1139cb 20246 * configure.ac: Use bug-grub as the reporting address.
20247 Use GRUB instead of PUPA.
20248 Change the version number to 1.90.
20249
8367695c 202502004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
20251
20252 * genkernsyms.sh: Updated copyright information.
20253 * genmk.rb: Likewise.
20254 * genmodsrc.sh: Likewise.
20255 * gensymlist.sh: Likewise.
20256 * boot/i386/pc/boot.S: Likewise.
20257 * boot/i386/pc/diskboot.S: Likewise.
20258 * disk/i386/pc/biosdisk.c: Likewise.
20259 * disk/i386/pc/partition.c: Likewise.
20260 * font/manager.c: Likewise.
20261 * fs/ext2.c: Likewise.
20262 * fs/fat.c: Likewise.
20263 * include/pupa/boot.h: Likewise.
20264 * include/pupa/device.h: Likewise.
20265 * include/pupa/disk.h: Likewise.
20266 * include/pupa/dl.h: Likewise.
20267 * include/pupa/elf.h: Likewise.
20268 * include/pupa/err.h: Likewise.
20269 * include/pupa/file.h: Likewise.
20270 * include/pupa/font.h: Likewise.
20271 * include/pupa/fs.h: Likewise.
20272 * include/pupa/kernel.h: Likewise.
20273 * include/pupa/loader.h: Likewise.
20274 * include/pupa/misc.h: Likewise.
20275 * include/pupa/mm.h: Likewise.
20276 * include/pupa/net.h: Likewise.
20277 * include/pupa/normal.h: Likewise.
20278 * include/pupa/rescue.h: Likewise.
20279 * include/pupa/setjmp.h: Likewise.
20280 * include/pupa/symbol.h: Likewise.
20281 * include/pupa/term.h: Likewise.
20282 * include/pupa/types.h: Likewise.
20283 * include/pupa/i386/setjmp.h: Likewise.
20284 * include/pupa/i386/types.h: Likewise.
20285 * include/pupa/i386/pc/biosdisk.h: Likewise.
20286 * include/pupa/i386/pc/boot.h: Likewise.
20287 * include/pupa/i386/pc/console.h: Likewise.
20288 * include/pupa/i386/pc/init.h: Likewise.
20289 * include/pupa/i386/pc/kernel.h: Likewise.
20290 * include/pupa/i386/pc/linux.h: Likewise.
20291 * include/pupa/i386/pc/loader.h: Likewise.
20292 * include/pupa/i386/pc/memory.h: Likewise.
20293 * include/pupa/i386/pc/multiboot.h: Likewise.
20294 * include/pupa/i386/pc/partition.h: Likewise.
20295 * include/pupa/i386/pc/time.h: Likewise.
20296 * include/pupa/i386/pc/vga.h: Likewise.
20297 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
20298 * include/pupa/util/getroot.h: Likewise.
20299 * include/pupa/util/misc.h: Likewise.
20300 * include/pupa/util/resolve.h: Likewise.
20301 * kern/device.c: Likewise.
20302 * kern/disk.c: Likewise.
20303 * kern/dl.c: Likewise.
20304 * kern/err.c: Likewise.
20305 * kern/file.c: Likewise.
20306 * kern/fs.c: Likewise.
20307 * kern/loader.c: Likewise.
20308 * kern/main.c: Likewise.
20309 * kern/misc.c: Likewise.
20310 * kern/mm.c: Likewise.
20311 * kern/rescue.c: Likewise.
20312 * kern/term.c: Likewise.
20313 * kern/i386/dl.c: Likewise.
20314 * kern/i386/pc/init.c: Likewise.
20315 * kern/i386/pc/lzo1x.S: Likewise.
20316 * kern/i386/pc/startup.S: Likewise.
20317 * loader/i386/pc/chainloader.c: Likewise.
20318 * loader/i386/pc/linux.c: Likewise.
20319 * loader/i386/pc/multiboot.c: Likewise.
20320 * normal/cmdline.c: Likewise.
20321 * normal/command.c: Likewise.
20322 * normal/main.c: Likewise.
20323 * normal/menu.c: Likewise.
20324 * normal/i386/setjmp.S: Likewise.
20325 * term/i386/pc/console.c: Likewise.
20326 * term/i386/pc/vga.c: Likewise.
20327 * util/console.c: Likewise.
20328 * util/genmoddep.c: Likewise.
20329 * util/misc.c: Likewise.
20330 * util/pupa-emu.c: Likewise.
20331 * util/resolve.c: Likewise.
20332 * util/unifont2pff.rb: Likewise.
20333 * util/i386/pc/biosdisk.c: Likewise.
20334 * util/i386/pc/getroot.c: Likewise.
20335 * util/i386/pc/pupa-mkimage.c: Likewise.
20336 * util/i386/pc/pupa-setup.c: Likewise.
20337
e6eced71 203382004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
20339
20340 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
20341 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
20342 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
20343 reading and reset it after reading.
20344 (pupa_ext2_close): Return PUPA_ERR_NONE.
20345
20346 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
20347 Correct value.
20348 (struct linux_kernel_header): Add kernel_version and
20349 initrd_addr_max.
20350 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
20351 pupa_file_read succeeds.
20352 (pupa_rescue_cmd_initrd): Implement.
20353
5aded270 203542003-12-03 Marco Gerards <metgerards@student.han.nl>
20355
20356 * fs/ext2.c (pupa_ext2_label): New function.
20357 (pupa_ext2_fs): Added label.
20358 * fs/fat.c (pupa_fat_label): New function.
20359 (pupa_fat_fs): Added label.
20360 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
20361
20362 * kern/misc.c (pupa_strndup): New function.
20363 * include/pupa/misc.h (pupa_strndup): New prototype.
20364
20365 * include/pupa/normal.h: Include <pupa/err.h>.
20366 (pupa_set_history): New prototype.
20367 (pupa_iterate_commands): New prototype.
20368 * normal/cmdline.c: Include <pupa/machine/partition.h>,
20369 <pupa/disk.h>, <pupa/file.h>.
20370 (hist_size): New variable.
20371 (hist_lines): Likewise.
20372 (hist_end): Likewise.
20373 (hist_used): Likewise.
20374 (pupa_set_history): New function.
20375 (pupa_history_get): Likewise.
20376 (pupa_history_add): Likewise.
20377 (pupa_history_replace): Likewise.
20378 (pupa_tab_complete): Likewise.
20379 (pupa_cmdline_run): Added tab completion and history buffer. Tab
20380 completion shows partitionnames while completing partitions, this
20381 feature was suggested by Jeff Bailey.
20382 * normal/command.c (pupa_iterate_commands): New function.
20383 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
20384 (pupa_normal_init): Initialize history buffer.
20385 (PUPA_MOD_INIT): Likewise.
20386 (pupa_normal_fini): Free the history buffer.
20387 (PUPA_MOD_FINI): Likewise.
20388
20389 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
20390 key.
20391
20392 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
20393 * configure.ac [i386]: Check for regparam bug.
20394 (NESTED_FUNC_ATTR) [! i386]: Defined.
20395
1f7315a3 203962003-11-17 Marco Gerards <metgerards@student.han.nl>
20397
20398 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
20399 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
20400 (pupa_emu_SOURCES): New variable.
20401 (pupa_emu_LDFLAGS): Likewise.
20402 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
20403 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
20404 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
20405 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20406 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
20407 (pupa_jmp_buf): New typedef.
20408 (pupa_setjmp) [PUPA_UTIL]: New macro.
20409 (pupa_longjmp) [PUPA_UTIL]: Likewise.
20410 * include/pupa/term.h (struct pupa_term): New member `refresh'.
20411 (pupa_refresh): New prototype.
20412 * include/pupa/util/getroot.h: New file.
20413 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
20414 it.
20415 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
20416 (pupa_rescue_cmd_cat): Likewise.
20417 (pupa_rescue_cmd_ls): Likewise.
20418 (pupa_rescue_cmd_testload): Likewise.
20419 (pupa_rescue_cmd_lsmod): Likewise.
20420 * normal/cmdline.c (pupa_cmdline_get): Likewise.
20421 * normal/menu.c (run_menu): Likewise.
20422 * kern/term.c (pupa_cls): Likewise.
20423 (pupa_refresh): New function.
20424 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
20425 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20426 * util/console.c: New file.
f19dbdb7 20427
1f7315a3 20428 * util/i386/pc/getroot.c: New file.
20429 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
20430 (pupa_putchar): New function.
20431 (pupa_refresh): Likewise.
20432 (xgetcwd): Function moved to ...
20433 (strip_extra_slashes): Likewise.
20434 (get_prefix): Likewise.
f19dbdb7 20435 * util/i386/pc/getroot.c: ... here.
1f7315a3 20436 (find_root_device): Function moved and renamed to...
20437 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
20438 Changed all callers.
20439 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
20440 and renamed to...
20441 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
20442 Changed all callers.
20443 * util/misc.c (pupa_memalign): New function.
20444 (pupa_mm_init_region): Likewise.
20445 (pupa_register_exported_symbols): Likewise.
20446 (pupa_putchar): Function removed.
20447 * util/pupa-emu.c: New file.
20448
9a5c1ade 204492003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
20450
20451 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
20452 (_multiboot_mod_SOURCES): New variable.
20453 (_multiboot_mod_CFLAGS): Likewise.
20454 * loader/i386/pc/multiboot.c: New file.
20455 * include/pupa/i386/pc/multiboot.h: Likewise.
20456 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
20457 (pupa_multiboot_real_boot): New function.
20458 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
20459 (pupa_multiboot_real_boot): New prototype.
20460 (pupa_rescue_cmd_multiboot): Likewise
20461 (pupa_rescue_cmd_module): Likewise.
20462
20463 * kern/loader.c (pupa_loader_set): Continue when
20464 pupa_loader_unload_func() fails.
20465 (pupa_loader_unset): New function.
20466 * include/pupa/loader.h (pupa_loader_unset): New prototype.
20467
20468 * kern/misc.c (pupa_stpcpy): New function.
20469 * include/pupa/misc.h (pupa_stpcpy): New prototype.
20470
8e72a9c0 204712003-11-12 Marco Gerards <metgerards@student.han.nl>
20472
20473 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
20474 for available extensions.
20475
20476 * include/pupa/i386/pc/time.h: New file.
20477 * kern/disk.c: Include <pupa/machine/time.h>.
20478 (PUPA_CACHE_TIMEOUT): New macro.
20479 (pupa_last_time): New variable.
20480 (pupa_disk_open): Flush the cache when there was a timeout.
20481 (pupa_disk_close): Reset the timer.
20482 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
20483 pupa_currticks.
20484 * util/misc.c: Include <sys/times.h>
20485 (pupa_get_rtc): New function.
20486
c4adbd32 204872003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
20488
20489 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
20490 as blocks.
20491 (pupa_ext2_get_file_block): Use blocks member.
20492
20493 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
20494 first block. Return -1 instead of pupa_errno on error.
20495
bfd30f06 204962003-10-27 Marco Gerards <metgerards@student.han.nl>
20497
20498 * README: In the pupa-mkimage example use _chain instead of chain
20499 and ext2 instead of fat.
20500 * TODO: Replace ext2fs with jfs as an example. Add an item for
20501 adding journal playback for ext2fs.
20502 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
20503 (pkgdata_MODULES): Added ext2.mod.
20504 (ext2_mod_SOURCES): New variable.
20505 (ext2_mod_CFLAGS): Likewise.
20506 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
20507 * include/pupa/misc.h (pupa_strncpy): New prototype.
20508 (pupa_strcat): Likewise.
20509 (pupa_strncmp): Likewise.
20510 * kern/misc.c (pupa_strcat): Enable function.
20511 (pupa_strncpy): New function.
20512 (pupa_strncmp): Likewise.
20513 * fs/ext2.c: New file.
f19dbdb7 20514
bfd30f06 20515 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
20516 when the read failed before retrying.
20517 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
20518 (_FILE_OFFSET_BITS): Likewise.
20519 * configure.ac: Added AC_SYS_LARGEFILE.
20520
98d15063 205212003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20522
20523 * genmk.rb (PModule#rule): Make sure to get only symbol names
20524 from the output of nm.
20525 Reported by Robert Millan <zeratul2@wanadoo.es>.
20526
18d9c7cd 205272003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20528
20529 I forgot to check in these changes for a long time. This adds
20530 incomplete support for VGA console, and this is still very
20531 buggy. Also, a lot of consideration is required for I18N,
20532 UNICODE, and VGA font issues. Therefore, assume that this is
20533 such that "better than nothing".
f19dbdb7 20534
18d9c7cd 20535 * font/manager.c: New file.
20536 * include/pupa/font.h: Likewise.
20537 * include/pupa/i386/pc/vga.h: Likewise.
20538 * term/i386/pc/vga.c: Likewise.
20539 * util/unifont2pff.rb: Likewise.
20540
20541 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
20542 (pkgdata_MODULES): Added vga.mod and font.mod.
20543 (vga_mod_SOURCES): New variables.
20544 (vga_mod_CFLAGS): Likewise.
20545 (font_mod_SOURCES): Likewise.
20546 (font_mod_CFLAGS): Likewise.
20547
20548 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
20549
20550 * include/pupa/term.h: Include pupa/err.h.
f19dbdb7 20551 (struct pupa_term): Added init and fini.
18d9c7cd 20552 Changed the argument of putchar to pupa_uint32_t.
20553
20554 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
20555 (pupa_console_real_putchar): New prototype.
20556 (pupa_console_putchar): Removed.
20557 (pupa_console_checkkey): Exported.
20558 (pupa_console_getkey): Likewise.
20559
20560 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
20561 characters.
20562
20563 * kern/term.c (pupa_term_set_current): Rewritten.
20564 (pupa_putchar): Likewise.
20565 (pupa_putcode): New function.
20566
20567 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
20568 (pupa_console_real_putchar): ... this.
20569 (pupa_vga_set_mode): New function.
20570 (pupa_vga_get_font): Likewise.
20571
20572 * normal/command.c: Include pupa/term.h.
20573 (terminal_command): New function.
20574 (pupa_command_init): Register the command "terminal".
20575
20576 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
20577 (DISP_UP): Likewise.
20578 (DISP_RIGHT): Likewise.
20579 (DISP_DOWN): Likewise.
20580 (DISP_HLINE): Likewise.
20581 (DISP_VLINE): Likewise.
20582 (DISP_UL): Likewise.
20583 (DISP_UR): Likewise.
20584 (DISP_LL): Likewise.
20585 (DISP_LR): Likewise.
20586
20587 * term/i386/pc/console.c (pupa_console_putchar): New function.
f19dbdb7 20588
977329f5 205892003-02-08 NIIBE Yutaka <gniibe@m17n.org>
20590
20591 * util/resolve.c (pupa_util_resolve_dependencies): BUG
20592 FIX. Reverse the path_list.
20593
20594 * include/pupa/normal.h: Export pupa_register_command and
20595 pupa_unregister_command.
20596
20597 * hello/hello.c (pupa_cmd_hello): New module.
20598 * conf/i386-pc.rmk: Added hello.mod.
20599
1f5ab428 206002003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
20601
20602 * kern/i386/pc/lzo1x.S: New file.
f19dbdb7 20603
1f5ab428 20604 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
20605 (compress_kernel): New variable.
20606 (generate_image): Heavily modified to support compressing a
20607 large part of the core image.
20608
20609 * util/misc.c (pupa_util_read_image): Fix a file descriptor
20610 leak.
20611 (pupa_util_load_image): New function.
20612
20613 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
20614 (pupa_compressed_size): New variable.
20615 (codestart): Enable Gate A20 here.
20616 Decompress the compressed part of the core image.
20617 Rearrange the code to put functions and variables which are
20618 required for initialization in the non-compressed part.
20619 Include lzo1x.S.
20620
20621 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
20622 here.
20623
20624 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
20625
f19dbdb7 20626 * include/pupa/i386/pc/kernel.h
1f5ab428 20627 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
20628 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
20629 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
20630 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
20631 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
20632
20633 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
20634
20635 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
20636 (Utility#rule): Likewise.
20637
20638 * configure.ac: Check if LZO is available.
20639
ce5bf700 206402003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
20641
20642 * include/pupa/normal.h: New file.
20643 * include/pupa/setjmp.h: Likewise.
20644 * include/pupa/i386/setjmp.h: Likewise.
20645 * normal/cmdline.c: Likewise.
20646 * normal/command.c: Likewise.
20647 * normal/main.c: Likewise.
20648 * normal/menu.c: Likewise.
20649 * normal/i386/setjmp.S: Likewise.
f19dbdb7 20650
ce5bf700 20651 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
20652 (pupa_rescue_cmd_initrd): Likewise.
20653
20654 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
20655 Likewise.
20656
20657 * kern/i386/pc/startup.S (translation_table): New variable.
20658 (translate_keycode): New function.
20659 (pupa_console_getkey): Call translate_keycode.
20660
20661 * kern/rescue.c (attempt_normal_mode): New function.
20662 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
20663 it failed, print a message.
20664
20665 * kern/mm.c (pupa_real_malloc): Print more information when a
20666 free magic is broken.
20667 (pupa_free): If the first free header is not free actually, set
20668 it to P.
20669
20670 * kern/main.c (pupa_load_normal_mode): Just load the module
20671 "normal".
20672 (pupa_main): Don't print the message
20673 "Entering into rescue mode..." here.
20674
20675 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
20676 Declared.
20677 (pupa_rescue_cmd_initrd): Likewise.
20678 (pupa_rescue_cmd_initrd): Likewise.
20679
20680 * include/pupa/symbol.h (FUNCTION): Specify the type.
20681 (VARIABLE): Likewise.
20682
20683 * include/pupa/err.h (pupa_err_t): Added
20684 PUPA_ERR_UNKNOWN_COMMAND.
20685
20686 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
20687 (pupa_dl_get_prefix): Likewise.
20688
20689 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
20690 Added _chain.mod and _linux.mod instead of chain.mod and
20691 linux.mod.
20692 (chain_mod_SOURCES): Renamed to ...
20693 (_chain_mod_SOURCES): ... this.
20694 (chain_mod_CFLAGS): Renamed to ...
20695 (_chain_mod_CFLAGS): ... this.
20696 (linux_mod_SOURCES): Renamed to ...
20697 (_linux_mod_SOURCES): ... this.
20698 (linux_mod_CFLAGS): Renamed to ...
20699 (_linux_mod_CFLAGS): ... this.
20700 (normal_mod_SOURCES): New variable.
20701 (normal_mod_CFLAGS): Likewise.
20702 (normal_mod_ASFLAGS): Likewise.
20703
207042003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
20705
20706 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
20707 possible.
20708
fe6b695a 20709 * kern/dl.c (pupa_dl_ref): Refer depending modules
ce5bf700 20710 recursively.
20711 (pupa_dl_unref): Unrefer depending modules recursively.
20712 Don't call pupa_dl_unload implicitly, because PUPA can crash if
20713 a module is unloaded before one depending on that module is
20714 unloaded.
20715 (pupa_dl_unload): Unload depending modules explicitly,
20716 if possible.
20717
c04da074 207182003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
20719
20720 * include/pupa/i386/pc/linux.h: New file.
20721 * loader/i386/pc/linux.c: Likewise.
f19dbdb7 20722
c04da074 20723 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
20724 Removed.
20725 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
20726 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
20727 of PUPA_CHAINLOADER_BOOT_SECTOR.
20728
20729 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
20730 (pupa_linux_prot_size): New variable.
20731 (pupa_linux_tmp_addr): Likewise.
20732 (pupa_linux_real_addr): Likewise.
20733 (pupa_linux_boot_zimage): New function.
20734 (pupa_linux_boot_bzimage): Likewise.
20735
20736 * kern/i386/pc/init.c (struct mem_region): New structure.
20737 (MAX_REGIONS): New macro.
20738 (mem_regions): New variable.
20739 (num_regions): Likewise.
20740 (pupa_os_area_addr): Likewise.
20741 (pupa_os_area_size): Likewise.
20742 (pupa_lower_mem): Likewise.
20743 (pupa_upper_mem): Likewise.
20744 (add_mem_region): New function.
20745 (compact_mem_regions): Likewise.
20746 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
20747 the size of the conventional memory and that of so-called upper
20748 memory (before the first memory hole).
20749 Instead of adding each found region to free memory, use
20750 add_mem_region and add them after removing overlaps.
20751 Also, add only 1/4 of the upper memory to free memory. The rest
20752 is used for loading OS images. Maybe this is ad hoc, but this
20753 makes it much easier to relocate OS images when booting.
20754
20755 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
20756 (pupa_enter_rescue_mode): Don't register initrd and module.
20757
20758 * kern/mm.c: Include pupa/dl.h.
20759
20760 * kern/main.c: Include pupa/file.h and pupa/device.h.
20761
20762 * kern/loader.c (pupa_loader_load_module_func): Removed.
20763 (pupa_loader_load_module): Likewise.
20764
20765 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
20766 ``.o''.
20767
20768 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
20769 (pupa_linux_tmp_addr): Likewise.
20770 (pupa_linux_real_addr): Likewise.
20771 (pupa_linux_boot_zimage): Likewise.
20772 (pupa_linux_boot_bzimage): Likewise.
20773
20774 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
20775 (pupa_upper_mem): Likewise.
20776 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
20777 module is too dangerous.
20778
20779 * include/pupa/loader.h (pupa_os_area_addr): Declared.
20780 (pupa_os_area_size): Likewise.
20781 (pupa_loader_set): Remove the first argument. Loader doesn't
20782 manage modules or initrd any longer.
20783 (pupa_loader_load_module): Removed.
20784
20785 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
20786 (linux_mod_SOURCES): New variable.
20787 (linux_mod_CFLAGS): Likewise.
20788
a13f9237 207892003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
20790
20791 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
20792 the length of a blocklist correctly.
20793
20794 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
20795 Use ioctl only if the OS file is a block device.
20796 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
20797 not very useful for normal files.
20798
20799 * kern/main.c (pupa_set_root_dev): New function.
20800 (pupa_load_normal_mode): Likewise.
20801 (pupa_main): Call those above.
20802
20803 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
20804 pupa_uint16_t.
20805
20806 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
20807
a5ffe966 208082003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
20809
20810 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
20811 (setup): Configure the installed partition information and the
20812 dl prefix.
20813
20814 * loader/i386/pc/chainloader.c (my_mod): New variable.
20815 (pupa_chainloader_unload): New function.
20816 (pupa_rescue_cmd_chainloader): Refer itself.
20817 (PUPA_MOD_INIT): Save its own module in MY_MOD.
20818
20819 * kern/i386/pc/startup.S (install_partition): Removed.
20820 (version_string): Likewise.
20821 (config_file): Likewise.
20822 (pupa_install_dos_part): New variable.
20823 (pupa_install_bsd_part): Likewise.
20824 (pupa_prefix): Likewise.
20825 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
20826
20827 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
20828 and pupa/misc.h.
20829 (make_install_device): New function.
20830 (pupa_machine_init): Set the dl prefix.
20831
20832 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
20833 (buf): Renamed to ...
20834 (linebuf): ... this.
20835 (pupa_rescue_cmd_prefix): New function.
20836 (pupa_rescue_cmd_insmod): Likewise.
20837 (pupa_rescue_cmd_rmmod): Likewise.
20838 (pupa_rescue_cmd_lsmod): Likewise.
20839 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
20840 rmmod and lsmod.
20841
20842 * kern/mm.c (pupa_memalign): If failed even after invalidating
20843 disk caches, unload unneeded modules and retry.
20844
20845 * kern/misc.c (pupa_memmove): New function.
20846 (pupa_memcpy): Removed.
20847 (pupa_strcpy): New function.
20848 (pupa_itoa): Made static.
20849
20850 * kern/dl.c (pupa_dl_iterate): New function.
20851 (pupa_dl_ref): Likewise.
20852 (pupa_dl_unref): Likewise.
20853 (pupa_dl_unload): Return if succeeded or not.
20854 (pupa_dl_unload_unneeded): New function.
20855 (pupa_dl_unload_all): Likewise.
20856 (pupa_dl_init): Renamed to ...
20857 (pupa_dl_set_prefix): ... this.
20858 (pupa_dl_get_prefix): New function.
20859
20860 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
20861 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
20862 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
20863 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
20864 (pupa_install_dos_part): Declared.
20865 (pupa_install_bsd_part): Likewise.
20866 (pupa_prefix): Likewise.
20867 (pupa_boot_drive): Likewise.
20868
20869 * include/pupa/types.h: Fix a typo.
20870
20871 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
20872 pupa_memmove.
20873 (pupa_memmove): Declared.
20874 (pupa_strcpy): Likewise.
20875
20876 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
20877 pupa_mod_init takes one argument, its own module.
20878 (pupa_dl_unload_unneeded): Declared.
20879 (pupa_dl_unload_all): Likewise.
20880 (pupa_dl_ref): Likewise.
20881 (pupa_dl_unref): Likewise.
20882 (pupa_dl_iterate): Likewise.
20883 (pupa_dl_init): Renamed to ...
20884 (pupa_dl_set_prefix): ... this.
20885 (pupa_dl_get_prefix): Declared.
20886
20887 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
f19dbdb7 20888 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
a5ffe966 20889 unloaded.
20890 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
20891 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
20892
20893 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
20894 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
20895
012d7999 208962003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
20897
20898 * util/i386/pc/pupa-setup.c (setup): Define the internal
20899 function find_first_partition_start at the top level, because GCC
20900 3.0.x cannot compile internal functions in deeper scopes
20901 correctly.
20902 (find_root_device): Use lstat instead of stat.
20903 Don't follow symbolic links.
20904 Fix the path-constructing code.
20905
20906 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
20907 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
20908 by a BLKGETSIZE ioctl first, because block devices don't fill
20909 the member st_mode of the structure stat on Linux.
20910 [__linux__] (linux_find_partition): Use a temporary buffer
20911 REAL_DEV for the working space. Copy it to DEV before returning.
20912 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
20913 buffer cache consistent.
20914 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
20915 strncmp. The previous value was merely wrong.
20916 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
20917
20918 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
20919 FAT size is 12. The previous value was merely wrong.
20920
20921 * kern/main.c (pupa_main): Don't split the starting message from
20922 newlines.
20923
20924 * kern/term.c (pupa_putchar): Put CR after LF instead of before
20925 LF, because BIOS goes crazy about character attributes in this
20926 case.
20927
1cc73a62 209282003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
20929
20930 * include/i386/pc/util/biosdisk.h: New file.
20931 * util/i386/pc/biosdisk.c: Likewise.
20932 * util/i386/pc/pupa-setup.c: Likewise.
f19dbdb7 20933
1cc73a62 20934 * Makefile.in (INCLUDE_DISTFILES): Added
20935 include/pupa/i386/pc/util/biosdisk.h.
20936 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
20937 directory util/i386/pc.
20938 (install-local): Added a rule for sbin_UTILITIES.
20939 (uninstall): Likewise.
20940
20941 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
20942
20943 * util/misc.c (xrealloc): New function.
20944 (pupa_malloc): Likewise.
20945 (pupa_free): Likewise.
20946 (pupa_realloc): Likewise.
20947 (pupa_stop): Likewise.
20948 (pupa_putchar): Likewise.
20949
20950 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
20951
20952 * include/pupa/util/misc.h (xrealloc): Declared.
20953
20954 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
20955 macro.
20956 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
20957 (PUPA_BOOT_MACHINE_BPB_END): ... this.
20958
20959 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
20960 [PUPA_UTIL] (pupa_fat_fini): Likewise.
20961
20962 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
20963 way should be implemented.
20964 [PUPA_UTIL] (pupa_fat_fini): Likewise.
20965
20966 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
20967 the size of NAME for safety.
20968 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
20969 0x88.
20970
20971 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
20972 (pupa_setup_SOURCES): Likewise.
20973
20974 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
20975
08b70fe8 209762002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
20977
20978 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
20979 bunch of pushl's from pusha, because this destroys the return
20980 value.
20981
62ddcc8f 209822002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
20983
20984 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
20985 This means that any missing prototypes could be fatal. Also, you
20986 must take care when writing assembly code. See the comments at
20987 the beginning of startup.S, for more details.
f19dbdb7 20988
62ddcc8f 20989 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
20990 compilation mechanism.
20991 (pupa_chainloader_real_boot): Likewise.
20992 (pupa_biosdisk_rw_int13_extensions): Likewise.
20993 (pupa_biosdisk_rw_standard): Likewise.
20994 (pupa_biosdisk_check_int13_extensions): Likewise.
20995 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
20996 (pupa_biosdisk_get_diskinfo_standard): Likewise.
20997 (pupa_get_memsize): Likewise.
20998 (pupa_get_mmap_entry): Likewise.
20999 (pupa_console_putchar): Likewise.
21000 (pupa_console_setcursor): Likewise.
21001 (pupa_getrtsecs): Use pushl instead of push.
21002
21003 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
21004 memory instead of the stack for a mmap entry, because some
21005 BIOSes may ignore the maximum size and overflow.
21006
21007 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
21008
21009 * genmk.rb (PModule#rule): Compile automatically generated
21010 sources with module-specific CFLAGS as well as other sources.
21011
9962ed99 210122002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21013
21014 * configure.ac: Check ld.
21015 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
21016 respectively, before checking endianness and sizes.
21017
21018 * Makefile.in (LD): New variable.
f19dbdb7 21019
abdfc3c5 210202002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21021
21022 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
21023
6a161fa9 210242002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21025
21026 * Changelog: New file.
21027