]> git.proxmox.com Git - grub2.git/blame - ChangeLog
2009-11-28 Vladimir Serbinenko <phcoder@gmail.com>
[grub2.git] / ChangeLog
CommitLineData
2f857f98
VS
12009-11-28 Vladimir Serbinenko <phcoder@gmail.com>
2
3 Correct module naming.
4
5 * video/efi_uga.c (GRUB_MOD_INIT(efi_fb)): Renamed from this ...
6 (GRUB_MOD_INIT(efi_uga)): ... to this
7 (GRUB_MOD_FINI(efi_fb)): Renamed from this ...
8 (GRUB_MOD_FINI(efi_uga)): ... to this
9 * video/efi_gop.c (GRUB_MOD_INIT(efi_fb)): Renamed from this ...
10 (GRUB_MOD_INIT(efi_gop)): ... to this
11 (GRUB_MOD_FINI(efi_fb)): Renamed from this ...
12 (GRUB_MOD_FINI(efi_gop)): ... to this
13
c5448046
RM
142009-11-28 Robert Millan <rmh.grub@aybabtu.com>
15
16 * util/mkisofs/mkisofs.c (ld_options): Mark all `arg' strings as
17 translatable.
18 (usage): Translate `arg' strings using gettext().
19 Thanks to Jordi Mallach for the suggestion.
20
c85184ad
VS
212009-11-28 Vladimir Serbinenko <phcoder@gmail.com>
22
23 GOP support. Based on patch from Bean
24 (http://lists.gnu.org/archive/html/grub-devel/2009-08/msg00384.html)
25
26 * video/efi_gop.c: New file.
27 * include/grub/efi/graphics_output.h: Likewise.
28 * conf/i386-efi.rmk (pkglib_MODULES): Add `efi_gop.mod'.
29 (efi_fb_mod_SOURCES, efi_fb_mod_CFLAGS, efi_fb_mod_LDFLAGS): New
30 variables.
31 * conf/x86_64-efi.rmk: Likewise.
32
8a4c48d8
VS
332009-11-28 Vladimir Serbinenko <phcoder@gmail.com>
34
35 Rename efi_fb to efi_uga.
36
37 * conf/i386-efi.rmk (pkglib_MODULES): Rename 'efi_fb.mod' to
38 'efi_uga.mod'.
39 (efi_fb_mod_SOURCES): Rename this ...
40 (efi_uga_mod_SOURCES): ... to this.
41 (efi_fb_mod_CFLAGS): Rename this ...
42 (efi_uga_mod_CFLAGS): ... to this.
43 (efi_fb_mod_LDFLAGS): Rename this ...
44 (efi_uga_mod_LDFLAGS): ... to this.
45 * conf/x86_64-efi.rmk (pkglib_MODULES): Rename 'efi_fb.mod' to
46 'efi_uga.mod'.
47 (efi_fb_mod_SOURCES): Rename this ...
48 (efi_uga_mod_SOURCES): ... to this.
49 (efi_fb_mod_CFLAGS): Rename this ...
50 (efi_uga_mod_CFLAGS): ... to this.
51 (efi_fb_mod_LDFLAGS): Rename this ...
52 (efi_uga_mod_LDFLAGS): ... to this.
53 * video/efi_fb.c: Move this ...
54 * video/efi_uga.c: ... to this. Change prefix to 'grub_video_uga_'.
55
fb6c1a7b
RM
562009-11-27 Robert Millan <rmh.grub@aybabtu.com>
57
58 * po/README: New file. Explain our PO file workflow.
59
3bc7896c
RM
602009-11-27 Robert Millan <rmh.grub@aybabtu.com>
61
62 * po/ChangeLog: Remove. Move relevant entries back to ...
63 * ChangeLog: ... here.
64 * po/ca.po: Remove (now handled by TLP).
65 * po/id.po: Likewise.
66 * po/zh_CN.po: Likewise.
67 * Makefile.in (LINGUAS): Initialize in a way that supports
68 empty set.
69
9ed4841d
RM
702009-11-27 Robert Millan <rmh.grub@aybabtu.com>
71
72 * Makefile.in (LINGUAS): Rewrite by scanning po/ directory instead of
73 reliing on po/LINGUAS.
74 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po)): Rewrite as ...
75 (po/%.po): ... this.
76
242668a2
FZ
772009-11-26 Felix Zielcke <fzielcke@z-51.de>
78
79 * util/i386/efi/grub-mkimage.c: Include "progname.h".
80 (main): Use `program_name' instead of nonexistent `progname'.
81
e30dd392
FZ
822009-11-26 Felix Zielcke <fzielcke@z-51.de>
83
84 * conf/i386-efi.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
85 * conf/x86_64-efi.rmk (grub_mkimage_SOURCES): Likewise.
86
7656de4f
RM
872009-11-26 Robert Millan <rmh.grub@aybabtu.com>
88
89 * conf/i386-coreboot.rmk: Cleanup stale filenames from my previous
90 commit.
91 * conf/i386-efi.rmk: Likewise.
92 * conf/i386-ieee1275.rmk: Likewise.
93 * conf/powerpc-ieee1275.rmk: Likewise.
94 * conf/sparc64-ieee1275.rmk: Likewise.
95 * conf/x86_64-efi.rmk: Likewise.
96
db77c4d4
FZ
972009-11-26 Felix Zielcke <fzielcke@z-51.de>
98
99 * conf/any-emu.rmk (grub_emu_SOURCES): Add `gnulib/progname.c'.
100
a755bb04
FZ
1012009-11-26 Felix Zielcke <fzielcke@z-51.de>
102
103 * conf/any-emu.rmk (grub_mkfont_SOURCES): Add `gnulib/progname.c'.
104
8a4c07fd
RM
1052009-11-26 Robert Millan <rmh.grub@aybabtu.com>
106
107 * conf/common.rmk (sbin_UTILITIES): Add `grub-mkdevicemap'.
108 (grub_mkdevicemap_SOURCES): New variable.
109 (grub_probe_SOURCES, grub_fstest_SOURCES, grub_mkfont_SOURCES)
110 (grub_mkrelpath_SOURCES, grub_editenv_SOURCES)
111 (grub_pe2elf_SOURCES): Add `gnulib/progname.c'.
112 * conf/i386-coreboot.rmk (sbin_UTILITIES): Remove `grub-mkdevicemap'.
113 (grub_mkdevicemap_SOURCES): Remove.
114 * conf/i386-efi.rmk: Likewise.
115 * conf/i386-ieee1275.rmk: Likewise.
116 * conf/i386-pc.rmk: Likewise.
117 * conf/powerpc-ieee1275.rmk: Likewise.
118 * conf/sparc64-ieee1275.rmk: Likewise.
119 * conf/x86_64-efi.rmk: Likewise.
120 * util/elf/grub-mkimage.c: Include `<grub/i18n.h>' and `"progname.h"'.
121 (usage): Fix strings to use `program_name'.
122 (main): Initialize gettext.
123 * util/grub-editenv.c: Likewise.
124 * util/grub-emu.c: Likewise.
125 * util/grub-fstest.c: Likewise.
126 * util/grub-mkdevicemap.c: Likewise.
127 * util/grub-mkfont.c: Likewise.
128 * util/grub-mkrelpath.c: Likewise.
129 * util/grub-pe2elf.c: Likewise.
130 * util/grub-probe.c: Likewise.
131 * util/sparc64/ieee1275/grub-mkimage.c: Likewise.
132 * util/sparc64/ieee1275/grub-ofpathname.c: Likewise.
133 * util/sparc64/ieee1275/grub-setup.c: Likewise.
134
135 * util/misc.c: Include `"progname.h"'.
136 (progname): Remove variable.
137 (grub_util_warn, grub_util_info, grub_util_error): Use `program_name'.
138
6f61ed55
FZ
1392009-11-25 Felix Zielcke <fzielcke@z-51.de>
140
141 * util/grub.d/10_linux.in (linux_entry): Quote the arguments to
142 printf and print a newline after the menuentry header line.
143 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
144
f022876b
FZ
1452009-11-25 Felix Zielcke <fzielcke@z-51.de>
146
147 autoconf >= 2.60 support $(localedir).
148
149 * INSTALL: Note that autoconf 2.60 is required.
150 * configure.ac (AC_PREREQ): Bump to 2.60.
151 * util/grub.d/10_kfreebsd.in (TEXTDOMAINDIR): Set to lowercased @localedir@.
152 * util/grub.d/10_linux.in (TEXTDOMAINDIR): Likewise.
153
6717926e
YB
1542009-11-25 Yves Blusseau <yves.blusseau@zetam.org>
155
156 * configure.ac: move the call to AM_GNU_GETTEXT to avoid warnings when
157 aclocal is run.
158
08806a54
RM
1592009-11-25 Robert Millan <rmh.grub@aybabtu.com>
160
161 * normal/main.c (grub_normal_read_line): Fix off-by-one
162 buffer overflow.
163
13b33fba
RM
1642009-11-25 Robert Millan <rmh.grub@aybabtu.com>
165
166 * normal/main.c (grub_normal_execute): Replace "parser.sh" with
167 "parser.grub" in grub_command_execute() call.
168
4a8572e9
CPE
1692009-11-24 Carles Pina i Estany <carles@pina.cat>
170
171 * conf/i386-coreboot.rmk (kernel_img_HEADERS): Add i18n.h.
172 * conf/i386-efi.rmk: Likewise.
173 * conf/i386-ieee1275.rmk: Likewise.
174 * conf/i386-pc.rmk: Likewise.
175 * conf/powerpc-ieee1275.rmk: Likewise.
176 * conf/sparc64-ieee1275.rmk: Likewise.
177 * conf/x86_64-efi.rmk: Likewise.
178 * gettext/gettex.c: Include <grub/i18n.h>.
179 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): Move from
180 here ...
181 * include/grub/i18n.h: ... to here
182 * include/grub/i18n.h: ... to here.
183 * kern/misc.c: Include <grub/i18n.h>
184 (grub_gettext_dummy): Move above user.
185
bee48093
FZ
1862009-11-24 Felix Zielcke <fzielcke@z-51.de>
187
188 * util/Makefile.in (install-local): Convert a `for' into a normal
189 shell expansion.
190
a031e91c
RM
1912009-11-24 Robert Millan <rmh.grub@aybabtu.com>
192
193 * autogen.sh: Add automake call.
194 * config.guess: Remove.
195 * config.sub: Likewise.
196 * install-sh: Likewise.
197
26bec39d
FZ
1982009-11-24 Felix Zielcke <fzielcke@z-51.de>
199
200 * util/Makefile.in (install-local): Fix the use of $lang shell variable.
201
8e2532fd
FZ
2022009-11-24 Felix Zielcke <fzielcke@z-51.de>
203
204 * util/Makefile.in (install-local): Convert a make `$(foreach)'
205 function to a normal shell `for'.
206
fefa1b7d
FZ
2072009-11-24 Felix Zielcke <fzielcke@z-51.de>
208
209 * conf/i386-coreboot.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
210
4501250b
FZ
2112009-11-24 Felix Zielcke <fzielcke@z-51.de>
212
213 * util/grub-mkrelpath.c: New file.
214 * conf/common.rmk (bin_UTILITIES): Add grub-mkrelpath.
215 (grub_mkrelpath_SOURCES): New variable.
216 * include/grub/util/misc.h: New function prototype.
217 * util/misc.c (make_system_path_relative_to_its_root): New function.
218
219 * util/grub-mkconfig_lib.in (bindir): New variable.
220 (grub_mkrelpath): Likewise.
221 (make_system_path_relative_to_its_root): Use grub-mkrelpath.
222
223 * util/probe.c (probe): Make the file path relative to its root.
224 Change a info message to use the GRUB path. Enable again the
225 check if we can read the file with GRUB facilities.
226
227 * util/i386/pc/grub-setup.c (setup): Make core.img path relative
228 to its root.
229
11d9778b
FZ
2302009-11-24 Felix Zielcke <fzielcke@z-51.de>
231
232 * Makefile.in: Don't include GRUB_CONTRIB makefiles with emu
233 platform.
234
4465287d
FZ
2352009-11-24 Felix Zielcke <fzielcke@z-51.de>
236
237 * util/getroot.c (grub_util_get_dev_abstraction): Properly use
238 strncmp().
239
62b47f22
FZ
2402009-11-24 Felix Zielcke <fzielcke@z-51.de>
241
242 * util/getroot.c (grub_util_is_dmraid): New function.
243 (grub_util_get_dev_abstraction): Treat dmraid and multipath
244 devices as normal ones, not as LVM.
245
1eafb9b9 2462009-11-23 Carles Pina i Estany <carles@pina.cat>
c3ea6bd4
CPE
247
248 * conf/common.rmk: Add grub-gettext_lib target and updates
249 lib_DATA and CLEANFILES. Adds gettext.mod SOURCES, CFLAGS,
250 LDFLAGS.
251 * gettext/gettext.c: New file. (Reads mo files).
252 * include/grub/file.h (grub_file_pread): New prototype.
253 * include/grub/i18n.h (_): New prototype.
254 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): New
255 prototypes.
256 * kern/misc.c (grub_gettext_dummy): New function.
257 * normal/menu_text.c: Include <grub/i18n.h>.
258 * normal/menu_text.c (print_timeout): Gettexttize string.
259 * normal/menu_text.c (print_message): Gettexttize string.
3bc7896c
RM
260 * po/POTFILES: Add `normal/menu_text.c'.
261 * po/ca.po: Add new translations.
c3ea6bd4
CPE
262 * util/grub.d/00_header.in: Define locale_dir and lang. insmod
263 gettext module and defines locale_dir and lang in grub.cfg.
264 * NEWS: Add gettext support.
265
0fdb2568
RM
2662009-11-23 Robert Millan <rmh.grub@aybabtu.com>
267
268 * util/hostdisk.c: Include `<grub/i18n.h>'.
269 (find_grub_drive): Use ARRAY_SIZE for map size calculation.
270 (make_device_name): Rewrite using asprintf.
271 (convert_system_partition_to_system_disk): Replace 0 with NULL.
272 (find_system_device): If a device is not found, generate one just
273 by reusing the OS path name.
274 (read_device_map): Make it permissible for device.map not to exist.
275
f515aa62
RM
2762009-11-23 Robert Millan <rmh.grub@aybabtu.com>
277
278 * script/sh/execute.c: Move from here ...
279 * script/execute.c: ... to here. Update all users.
280 * script/sh/function.c: Move from here ...
281 * script/function.c: ... to here. Update all users.
282 * script/sh/lexer.c: Move from here ...
283 * script/lexer.c: ... to here. Update all users.
284 * script/sh/main.c: Move from here ...
285 * script/main.c: ... to here. Update all users.
286 * script/sh/parser.y: Move from here ...
287 * script/parser.y: ... to here. Update all users.
288 * script/sh/script.c: Move from here ...
289 * script/script.c: ... to here. Update all users.
290
f84b481b
RM
2912009-11-23 Robert Millan <rmh.grub@aybabtu.com>
292
293 * configure.ac: Detect all `emu' platforms. Define
294 GRUB_MACHINE_* macros in TARGET_CFLAGS. Remove
295 --enable-grub-emu logic. Disable include/grub/machine
296 symlink on `emu' platforms.
297
298 * genkernsyms.sh.in: Use @TARGET_CFLAGS@ during symbol generation.
299 * gensymlist.sh.in: Likewise.
300
301 * include/grub/i386/coreboot/machine.h: Remove file.
302 * include/grub/i386/efi/machine.h: Likewise.
303 * include/grub/i386/ieee1275/machine.h: Likewise.
304 * include/grub/i386/pc/machine.h: Likewise.
305 * include/grub/i386/qemu/machine.h: Likewise.
306 * include/grub/powerpc/ieee1275/machine.h: Likewise.
307 * include/grub/sparc64/ieee1275/machine.h: Likewise.
308 * include/grub/x86_64/efi/machine.h: Likewise.
309
310 * commands/acpi.c: Remove `<grub/machine/machine.h>'.
311 * commands/halt.c: Likewise.
312 * commands/reboot.c: Likewise.
313 * include/grub/autoefi.h: Likewise.
314 * include/grub/i386/at_keyboard.h: Likewise.
315 * include/grub/i386/kernel.h: Likewise.
316 * include/grub/i386/loader.h: Likewise.
317 * include/grub/i386/pc/memory.h: Likewise.
318 * kern/dl.c: Likewise.
319 * kern/i386/coreboot/init.c: Likewise.
320 * loader/i386/bsd.c: Likewise.
321 * loader/i386/linux.c: Likewise.
322 * loader/multiboot_loader.c: Likewise.
323 * term/i386/pc/serial.c: Likewise.
324 * term/usb_keyboard.c: Likewise.
325
326 * include/grub/time.h [!GRUB_MACHINE_EMU]: Remove
327 `<grub/machine/machine.h>'
328 [!GRUB_MACHINE_EMU] (GRUB_TICKS_PER_SECOND): New macro.
329 * util/misc.c: Remove `<grub/machine/machine.h>' and
330 `<grub/machine/time.h>'.
331
332 * Makefile.in (enable_grub_emu): Remove variable.
333 Include $(srcdir)/conf/any-emu.mk for the `emu' platform.
334
335 * conf/any-emu.rmk: New file.
336 * conf/common.rmk (grub_emu_init.lst, grub_emu_init.h)
337 (grub_emu_init.c): Move from here ...
338 * conf/any-emu.rmk: ... to here.
339
340 * conf/i386-coreboot.rmk (sbin_UTILITIES): Remove `grub-emu'.
341 (grub_emu_SOURCES, grub_emu_LDFLAGS): Move from here ...
342 * conf/any-emu.rmk: ... to here.
343
4efeab03
RM
3442009-11-23 Robert Millan <rmh.grub@aybabtu.com>
345
346 * include/grub/parser.h (grub_parser_register): Document need
347 of `name' parameter.
348 * normal/main.c (grub_normal_read_line): Simplify prompt string.
349 * script/sh/main.c (grub_sh_parser, GRUB_MOD_INIT(sh)): Rename
350 "sh" to "grub".
351
ea1dd8bf
RM
3522009-11-23 Robert Millan <rmh.grub@aybabtu.com>
353
354 * Makefile.in ($(srcdir)/po/$(PACKAGE).pot): Pass --keyword=N_ to
355 `$(XGETTEXT)'.
356 * include/grub/i18n.h (N_): New macro.
357 * util/mkisofs/mkisofs.h: Likewise.
358 * util/mkisofs/mkisofs.c (ld_options): Wrap all translatable strings
359 around N_().
360 (usage): Use gettext() to translate help strings when printing them.
361
0c140626
RM
3622009-11-23 Robert Millan <rmh.grub@aybabtu.com>
363
364 Based on patch from Bean
365 (http://lists.gnu.org/archive/html/grub-devel/2009-08/msg00384.html)
366
367 * video/efi_fb.c: New file.
368 * conf/i386-efi.rmk (pkglib_MODULES): Add `efi_fb.mod'.
369 (efi_fb_mod_SOURCES, efi_fb_mod_CFLAGS, efi_fb_mod_LDFLAGS): New
370 variables.
371 * conf/x86_64-efi.rmk: Likewise.
372
87d58298
RM
3732009-11-22 Robert Millan <rmh.grub@aybabtu.com>
374
375 * util/i386/pc/grub-mkimage.c: Ungettextize grub_util_info() strings.
376 * util/i386/pc/grub-setup.c: Likewise.
377
994cc3a3
ST
3782009-11-21 Samuel Thibault <samuel.thibault@ens-lyon.org>
379
380 * util/getroot.c [__GNU__]: Include <hurd.h>, <hurd/lookup.h>, and
381 <hurd/fs.h>
382 [__GNU__] (grub_guess_root_device): Call file_name_lookup and
383 file_get_storage_info to implement grub_guess_root_device.
384
26a61d6a
FZ
3852009-11-21 Felix Zielcke <fzielcke@z-51.de>
386
387 * Makefile.in (target): Use make's builtin $(shell) function
388 instead of calling directly $(SHELL) to create the locale directories,
389 inside the $(foreach) function.
390
74ff1dd5
FZ
3912009-11-21 Felix Zielcke <fzielcke@z-51.de>
392
393 * util/grub-mkrescue.in: Print an error and usage if output option
394 has not been given.
395
0b787d0e
FZ
3962009-11-21 Felix Zielcke <fzielcke@z-51.de>
397
398 Patch from Loïc Minier <loic.minier@ubuntu.com>.
399 * util/grub.d/30_os-prober.in: Cope with Linux entries where
400 root and /boot are on different devices.
401
1164b270
RM
4022009-11-21 Robert Millan <rmh.grub@aybabtu.com>
403
404 Fix build for srcdir != objdir.
405
406 * Makefile.in (po/$(PACKAGE).pot): Rename to ...
407 ($(srcdir)/po/$(PACKAGE).pot): ... this. Run $(XGETTEXT) from
408 $(srcdir).
409 ($(foreach lang, $(LINGUAS), po/$(lang).po)): Rename to ...
410 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po): ... this. Use $^
411 reference for input.
412
13774a2f
RM
4132009-11-21 Robert Millan <rmh.grub@aybabtu.com>
414
415 * util/grub-mkrescue.in: Use source directory direcly (without copiing
416 or hardlinking it). Remove -J option, Joliet is not compatible with
417 multiple source directories.
418
efda854e
RM
4192009-11-21 Carles Pina i Estany <carles@pina.cat>
4202009-11-21 Robert Millan <rmh.grub@aybabtu.com>
421
422 * util/grub-mkrescue.in: Recognize `--override-directory' option.
423 (process_input_dir): New function. Process an arbitrary input
424 directory.
425 Misc adjustments to support both "override mode" and system-wide mode.
426
6c09890c
FZ
4272009-11-20 Felix Zielcke <fzielcke@z-51.de>
428
429 * configure.ac (UNIFONT_BDF): Rename to ...
430 (FONT_SOURCE): ... this. Update all users.
431
a797824f
FZ
4322009-11-20 Felix Zielcke <fzielcke@z-51.de>
433
434 * configure.ac: Add `/usr/share/fonts/X11/misc/unifont.pcf.gz'
435 to the list of unifont files to look for.
436
cd4f42b0
RM
4372009-11-19 Robert Millan <rmh.grub@aybabtu.com>
438
439 Patch from Joe Auricchio <jauricchio@gmail.com>
440 * commands/minicmd.c (grub_mini_cmd_clear): New function.
441 (GRUB_MOD_INIT(minicmd)): Register grub_mini_cmd_clear().
442 (GRUB_MOD_FINI(minicmd)): Unregister grub_mini_cmd_clear().
443
393c783d
FZ
4442009-11-19 Felix Zielcke <fzielcke@z-51.de>
445
446 * Makefile.in (install-local): Add a missing backslash.
447
b2f1e327
FZ
4482009-11-19 Felix Zielcke <fzielcke@z-51.de>
449
450 * include/grub/x86_64/io.h: New file.
451
f577f7a0
RM
4522009-11-19 Robert Millan <rmh.grub@aybabtu.com>
453
454 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `gnulib/progname.c'.
455 * util/i386/pc/grub-setup.c: Include `<grub/i18n.h>'.
456 Include `"progname.h"'.
457 (main): Initialize gettext.
458 * util/i386/pc/grub-setup.c: Gettexttize.
459 * util/i386/pc/grub-mkimage.c: Likewise.
460
461 * Makefile.in (po/*.po): Redefine as ...
462 ($(foreach lang, $(LINGUAS), po/$(lang).po)): ... this.
463
3bc7896c
RM
464 * po/POTFILES: Add `util/i386/pc/grub-setup.c'.
465
c37943b6
RM
4662009-11-19 Robert Millan <rmh.grub@aybabtu.com>
467
468 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/progname.c'.
469 * util/mkisofs/mkisofs.c: Include `"progname.h"'.
470 (program_name): Remove.
471 (main): Initialize gettext support.
6323f705
RM
472 * util/mkisofs/mkisofs.h: Include `<locale.h>'.
473 Include `<libintl.h>'.
474 (_): New macro.
c37943b6
RM
475
476 * util/mkisofs/eltorito.c: Gettexttize.
477 * util/mkisofs/joliet.c: Likewise.
478 * util/mkisofs/mkisofs.c: Likewise.
c37943b6
RM
479 * util/mkisofs/multi.c: Likewise.
480 * util/mkisofs/rock.c: Likewise.
481 * util/mkisofs/tree.c: Likewise.
482 * util/mkisofs/write.c: Likewise.
483
3bc7896c
RM
484 * po/POTFILES: Update with new files.
485
5ce77c6e
RM
4862009-11-18 Robert Millan <rmh.grub@aybabtu.com>
487
488 * util/mkisofs/eltorito.c: Fix minor mistake in license text.
489 * util/mkisofs/iso9660.h: Likewise.
490 * util/mkisofs/joliet.c: Likewise.
491 * util/mkisofs/mkisofs.c: Likewise.
492 * util/mkisofs/mkisofs.h: Likewise.
493 * util/mkisofs/rock.c: Likewise.
494 * util/mkisofs/tree.c: Likewise.
495 * util/mkisofs/write.c: Likewise.
496
497 * util/mkisofs/eltorito.c (rcsid): Remove.
498 * util/mkisofs/hash.c: Likewise.
499 * util/mkisofs/joliet.c: Likewise.
500 * util/mkisofs/name.c: Likewise.
501 * util/mkisofs/rock.c: Likewise.
502 * util/mkisofs/tree.c: Likewise.
503 * util/mkisofs/write.c: Likewise.
504
1dabbc77
RM
5052009-11-18 Robert Millan <rmh.grub@aybabtu.com>
506
507 * util/mkisofs/match.c: Rewrite from scratch, using a linked list
508 instead of static allocation.
509 * util/mkisofs/match.h: Likewise.
510
633877cb
RM
5112009-11-18 Robert Millan <rmh.grub@aybabtu.com>
512
3bc7896c
RM
513 * po/POTFILES-shell: New file. List `util/grub.d/10_kfreebsd.in'
514 and `util/grub.d/10_linux.in'.
633877cb
RM
515 * Makefile.in (po/$(PACKAGE).pot): Process `po/POTFILES-shell' for
516 translatable Shell files.
517
af1c0c85
RM
5182009-11-18 Robert Millan <rmh.grub@aybabtu.com>
519
520 * Makefile.in ($(srcdir)/aclocal.m4): New target.
521
769ae37b
RM
5222009-11-17 Robert Millan <rmh.grub@aybabtu.com>
523
524 * INSTALL: Document Automake is needed for bootstrap.
3bc7896c 525 * po/ca.po: Fix PO-Revision-Date and Language-Team fields.
769ae37b
RM
526 * util/grub.d/10_kfreebsd.in (bindir): New variable.
527 Add gettext initialization.
528 (kfreebsd_entry): Make menuentry output translatable.
529
5302009-11-17 Robert Millan <rmh.grub@aybabtu.com>
531
532 * Makefile.in (XGETTEXT, MSGMERGE, MSGFMT): New variables.
533 (po/$(PACKAGE).pot): Replace `xgettext' with `$(XGETTEXT)'.
534 (po/*.po): Replace `msgmerge' with `$(MSGMERGE)'.
535 (po/%.mo): Replace `msgfmt' with `$(MSGFMT)'.
536 (LINGUAS): Auto-generate using `po/LINGUAS'.
3bc7896c 537 * po/LINGUAS: New file.
769ae37b
RM
538
5392009-11-17 Robert Millan <rmh.grub@aybabtu.com>
540
541 * configure.ac: Call AM_GNU_GETTEXT() (defines localedir, among
542 other things).
543 * Makefile.in (CPPFLAGS): Add `-DLOCALEDIR=\"$(localedir)\"'.
544 * util/i386/pc/grub-mkimage.c (main): Issue setlocale() and
545 bindtextdomain() calls for gettext initialization.
546
5472009-11-17 Robert Millan <rmh.grub@aybabtu.com>
548
549 * gnulib/progname.c: New file (imported from Gnulib).
550 * gnulib/progname.h: Likewise.
551 * conf/i386-pc.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
552 * util/i386/pc/grub-mkimage.c: Include `"progname.h"'.
553 (usage): Replace `progname' with `program_name'.
554 (main): Use set_program_name() for program name initialization.
555
5562009-11-17 Robert Millan <rmh.grub@aybabtu.com>
557
558 * conf/common.rmk (grub_mkisofs_CFLAGS): Move `-I$(srcdir)/gnulib'
559 from here ...
560 * Makefile.in (CPPFLAGS): ... to here.
561
5622009-11-16 Robert Millan <rmh.grub@aybabtu.com>
563
564 * aclocal.m4: Move from here ...
565 * acinclude.m4: ... to here.
566 * autogen.sh: Add call to `aclocal'.
567 * configure.ac: Add AM_INIT_AUTOMAKE() after AC_INIT() call.
568
5692009-11-16 Robert Millan <rmh.grub@aybabtu.com>
570
571 * Makefile.in (CLEANFILES): Add `po/*.mo'.
572 (LINGUAS): New variable.
573 (all-local): Add `$(foreach lang, $(LINGUAS), po/$(lang).mo)'.
574 (install-local): Install MO files.
575 (po/$(PACKAGE).pot, po/*.po, po/%.mo): New rules.
576 * include/grub/i18n.h: New file.
3bc7896c
RM
577 * po/POTFILES: New file.
578 * po/ca.po: New file.
769ae37b
RM
579 * util/grub.d/10_linux.in (bindir): New variable.
580 Add gettext initialization.
581 (linux_entry): Make menuentry output translatable.
582 * util/i386/pc/grub-mkimage.c: Include `<grub/i18n.h>'.
583 (usage): Make --help output translatable.
584 (main): Initialize gettext.
585
02c0a6ad
RM
5862009-11-17 Robert Millan <rmh.grub@aybabtu.com>
587
588 * import_gcry.py: New file (written by Vladimir with minor
589 adjustments).
590 * autogen.sh: Use import_gcry.py to auto-generate GRUB-ified
591 ciphers.
592 * INSTALL: Document that Python is required for bootstrap.
593
5942009-11-17 Robert Millan <rmh.grub@aybabtu.com>
595
596 Import ciphers from libgcrypt 1.4.4.
597
598 * lib/libgcrypt/cipher/ChangeLog
599 * lib/libgcrypt/cipher/ac.c
600 * lib/libgcrypt/cipher/arcfour.c
601 * lib/libgcrypt/cipher/bithelp.h
602 * lib/libgcrypt/cipher/blowfish.c
603 * lib/libgcrypt/cipher/camellia-glue.c
604 * lib/libgcrypt/cipher/camellia.c
605 * lib/libgcrypt/cipher/camellia.h
606 * lib/libgcrypt/cipher/cast5.c
607 * lib/libgcrypt/cipher/cipher.c
608 * lib/libgcrypt/cipher/crc.c
609 * lib/libgcrypt/cipher/des.c
610 * lib/libgcrypt/cipher/dsa.c
611 * lib/libgcrypt/cipher/ecc.c
612 * lib/libgcrypt/cipher/elgamal.c
613 * lib/libgcrypt/cipher/hash-common.c
614 * lib/libgcrypt/cipher/hash-common.h
615 * lib/libgcrypt/cipher/hmac-tests.c
616 * lib/libgcrypt/cipher/md.c
617 * lib/libgcrypt/cipher/md4.c
618 * lib/libgcrypt/cipher/md5.c
619 * lib/libgcrypt/cipher/primegen.c
620 * lib/libgcrypt/cipher/pubkey.c
621 * lib/libgcrypt/cipher/rfc2268.c
622 * lib/libgcrypt/cipher/rijndael-tables.h
623 * lib/libgcrypt/cipher/rijndael.c
624 * lib/libgcrypt/cipher/rmd.h
625 * lib/libgcrypt/cipher/rmd160.c
626 * lib/libgcrypt/cipher/rsa.c
627 * lib/libgcrypt/cipher/seed.c
628 * lib/libgcrypt/cipher/serpent.c
629 * lib/libgcrypt/cipher/sha1.c
630 * lib/libgcrypt/cipher/sha256.c
631 * lib/libgcrypt/cipher/sha512.c
632 * lib/libgcrypt/cipher/tiger.c
633 * lib/libgcrypt/cipher/twofish.c
634 * lib/libgcrypt/cipher/whirlpool.c
635
af2f93ac
RM
6362009-11-16 Robert Millan <rmh.grub@aybabtu.com>
637
638 Fix build for systems without error().
639
640 * gnulib/error.c: New file (imported from Gnulib).
641 * gnulib/error.h: Likewise.
642 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/error.c'.
643 * util/mkisofs/mkisofs.c (program_name): Remove `static' qualifier
644 (this variable is now used by error()).
645
73fb3dd5
FZ
6462009-11-16 Felix Zielcke <fzielcke@z-51.de>
647
814f5e96
FZ
648 * util/mkisofs/name.c (iso9660_file_length): Use isascii macro
649 instead of relying that char is signed.
73fb3dd5 650
a691ca33
VS
6512009-11-16 Vladimir Serbinenko <phcoder@gmail.com>
652
653 * fs/i386/pc/pxe.c (grub_pxefs_open): Correctly handle PXE choosing
654 blocksize different from specified.
655 (grub_pxefs_read): Likewise.
656
2af8f0f4
FZ
6572009-11-16 Felix Zielcke <fzielcke@z-51.de>
658
659 Enable ata.mod on x86_64-efi, i386-efi and i386-ieee1275.
660
661 * disk/ata.c (grub_ata_dumpinfo): Add a cast.
662 (grub_ata_readwrite): Likewise. Update 2 format strings.
663 (grub_atapi_read): Likewise.
664
665 * conf/i386-coreboot.rmk (pkglib_MODULES): Move `ata.mod' from here ...
666 * conf/i386.rmk (pkglib_MODULES): ... to here ...
667 * conf/x86_64-efi.rmk (pkglib_MODULES): ... and here.
668 * conf/i386-coreboot.rmk (ata_mod_SOURCES, ata_mod_CFLAGS)
669 (ata_mod_LDFLAGS): Move from here ...
670 * conf/i386.rmk: ... to here ...
671 * conf/x86_64-efi.rmk: ... and here.
672 * conf/i386-pc.rmk (pkglib_MODULES): Remove `ata.mod'
673 (ata_mod_SOURCES, ata_mod_CFLAGS, ata_mod_LDFLAGS): Remove.
674
83bdecaf
RM
6752009-11-16 Robert Millan <rmh.grub@aybabtu.com>
676
677 Relicense multiboot.h, with RMS' blessing.
678
679 * include/multiboot.h: Change to X11 license.
680
fd6fd3d7
RM
6812009-11-15 Robert Millan <rmh.grub@aybabtu.com>
682
683 Support --version in grub-mkisofs.
684
685 * util/mkisofs/mkisofs.c (rcsid): Remove variable.
686 (OPTION_VERSION): New macro.
687 (ld_options): Recognize --version.
688 (usage): Move `program_name' from here ...
689 (program_name): ... to here. Add `static' qualifier.
690 (main): Recognize `OPTION_VERSION'.
691
16a88c49
FZ
6922009-11-15 Felix Zielcke <fzielcke@z-51.de>
693
694 * Makefile.in (TARGET_CPPFLAGS): Replace `-isystem=$(srcdir)/include'
695 with `-nostdinc -isystem $(shell $(TARGET_CC) -print-file-name=include)'.
696
a4158476
RM
6972009-11-14 Robert Millan <rmh.grub@aybabtu.com>
698
699 Fix help2man generation for mkisofs.
700
701 * util/mkisofs/mkisofs.c (ld_options): Recognize --help.
702 (usage): Send output to stdout (rather than stderr).
703
fc2208b0
RM
7042009-11-14 Robert Millan <rmh.grub@aybabtu.com>
705
706 * conf/i386-coreboot.rmk (grub_mkrescue_SOURCES): Replace
707 `util/i386/coreboot/grub-mkrescue.in' with `util/grub-mkrescue.in'.
708 * conf/i386-pc.rmk (grub_mkrescue_SOURCES): Replace
709 `util/i386/pc/grub-mkrescue.in' with `util/grub-mkrescue.in'.
710 (bin_SCRIPTS): Add `grub-mkfloppy'.
711 (grub_mkfloppy_SOURCES): New variable.
712
713 * util/grub-mkrescue.in: New file.
714 * util/i386/pc/grub-mkfloppy.in: New file.
715
716 * util/i386/coreboot/grub-mkrescue.in: Remove.
717 * util/i386/pc/grub-mkrescue.in: Remove.
718
8d0edf4a
RM
7192009-11-13 Robert Millan <rmh.grub@aybabtu.com>
720
721 * include/grub/multiboot.h (struct grub_multiboot_header): Move
722 from here ...
723 * include/multiboot.h (struct multiboot_header): ... to here. Update
724 all users.
725 * include/grub/multiboot.h (struct grub_multiboot_info): Move
726 from here ...
727 * include/multiboot.h (struct multiboot_info): ... to here. Update
728 all users.
729 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): Move
730 from here ...
731 * include/multiboot.h (struct multiboot_mmap_entry): ... to here.
732 Update all users.
733 * include/grub/multiboot.h (struct grub_mod_list): Move
734 from here ...
735 * include/multiboot.h (struct multiboot_mod_list): ... to here.
736 Update all users.
737
a73f5969
RM
7382009-11-13 Robert Millan <rmh.grub@aybabtu.com>
739
740 * include/multiboot2.h (multiboot_word): Rename from this ...
741 (multiboot2_word): ... to this. Update all users.
742 (multiboot_header): Rename from this ...
743 (multiboot2_header): ... to this. Update all users.
744 (multiboot_tag_header): Rename from this ...
745 (multiboot2_tag_header): ... to this. Update all users.
746 (multiboot_tag_start): Rename from this ...
747 (multiboot2_tag_start): ... to this. Update all users.
748 (multiboot_tag_name): Rename from this ...
749 (multiboot2_tag_name): ... to this. Update all users.
750 (multiboot_tag_module): Rename from this ...
751 (multiboot2_tag_module): ... to this. Update all users.
752 (multiboot_tag_memory): Rename from this ...
753 (multiboot2_tag_memory): ... to this. Update all users.
754 (multiboot_tag_unused): Rename from this ...
755 (multiboot2_tag_unused): ... to this. Update all users.
756 (multiboot_tag_end): Rename from this ...
757 (multiboot2_tag_end): ... to this. Update all users.
758
1c8927f0
RM
7592009-11-13 Robert Millan <rmh.grub@aybabtu.com>
760
761 Disable Multiboot2 in i386-ieee1275. It didn't actually work, and on
762 this platform we should support Multiboot1 first.
763
764 * conf/i386-ieee1275.rmk (pkglib_MODULES): Remove `multiboot.mod'.
765 (multiboot_mod_SOURCES, multiboot_mod_CFLAGS)
766 (multiboot_mod_LDFLAGS, multiboot_mod_ASFLAGS): Remove.
767
6e1e0d89
RM
7682009-11-12 Robert Millan <rmh.grub@aybabtu.com>
769
770 * util/mkisofs/eltorito.c (init_boot_catalog): Handle return code
771 of write calls (converting them to fwrite() if they aren't already).
772 (get_torito_desc): Likewise.
773 * util/mkisofs/rock.c (generate_rock_ridge_attributes): Likewise.
774
7f2b34d8
RM
7752009-11-12 Robert Millan <rmh.grub@aybabtu.com>
776
777 * util/i386/pc/grub-install.in: Move from here ...
778 * util/grub-install.in: ... to here. Update all users.
779
c0ef3311
CW
7802009-11-11 Colin Watson <cjwatson@ubuntu.com>
781
782 * util/powerpc/ieee1275/grub-mkrescue.in: Fix --version output.
783
e1f240ff
RM
7842009-11-11 Robert Millan <rmh.grub@aybabtu.com>
785
786 Support for El Torito without floppy emulation.
787
788 * util/mkisofs/eltorito.c: Include `<errno.h>'.
789 (init_boot_catalog): Improve error handling.
790 (get_torito_desc): Don't use floppy emulation unless requested by
791 user. Patch boot information table when requested via
792 `-boot-info-table'.
793 * util/mkisofs/iso9660.h (struct eltorito_boot_info): New struct.
794 * util/mkisofs/mkisofs.c (use_eltorito_emul_floppy)
795 (use_boot_info_table): New variables.
796 (OPTION_BOOT_INFO_TABLE, OPTION_NO_EMUL_BOOT)
797 (OPTION_ELTORITO_EMUL_FLOPPY): New macros.
798 (ld_options): Handle `-boot-info-table', `-no-emul-boot' and
799 `--eltorito-emul-floppy'.
800 (main): Handle `OPTION_BOOT_INFO_TABLE', `OPTION_NO_EMUL_BOOT'
801 and `OPTION_ELTORITO_EMUL_FLOPPY'.
802 * util/mkisofs/mkisofs.h (use_eltorito_emul_floppy)
803 (use_boot_info_table, get_731): New prototypes.
804 * util/mkisofs/write.c (get_731): New function.
805
af7d4de5
FZ
8062009-11-11 Felix Zielcke <fzielcke@z-51.de>
807
808 Fix the generation of the man page.
809
810 * util/pc/i386/grub-install.in: Source
811 `${libdir}/grub/grub-mkconfig_lib' after options have been parsed.
812
2c55dbc0
RM
8132009-11-11 Robert Millan <rmh.grub@aybabtu.com>
814
815 Large file support for grub-mkisofs.
816
817 * conf/common.rmk (grub_mkisofs_CFLAGS): Add `-D_FILE_OFFSET_BITS=64'.
818 * util/mkisofs/mkisofs.c (next_extent, last_extent)
819 (session_start): Upgrade type to `uint64_t'. Update all users.
820 * util/mkisofs/mkisofs.h: Include `<stdint.h>'.
821 (struct directory_entry): Upgrade type of `starting_block' and
822 `size' to `uint64_t'. Update all users.
823 (struct deferred): Remove unused structure.
824 (xfwrite): Upgrade type of `count' and `size' to `uint64_t'.
825 Update all users.
826 * util/mkisofs/tree.c (stat_filter, lstat_filter): Return -1 when
827 file is larger than `UINT32_MAX'.
828 * util/mkisofs/write.c (xfwrite): Upgrade type of `count' and
829 `size' to `uint64_t'. Update all users. Fix handling of fwrite()
830 return value.
831 (struct deferred_write): Upgrade type of `extent' and `size' to
832 `uint64_t'. Update all users.
833 (last_extent_written): Upgrade type to `uint64_t'. Update all
834 users.
835 (write_one_file): Upgrade type of `count' and `size' to `uint64_t'.
836 Update all users. Upgrade type of `remain' to `int64_t' and
837 `use' to `size_t'. Use error() to handle fread() errors.
838 (write_files): Rely on write_one_file() rather than calling
839 xfwrite() directly.
840
6a9cead5
FZ
8412009-11-09 Felix Zielcke <fzielcke@z-51.de>
842
843 * util/mkisofs/mkisofs.c (ld_options): Fix a spelling mistake.
844
4825d790
RM
8452009-11-09 Robert Millan <rmh.grub@aybabtu.com>
846
847 * util/mkisofs/fnmatch.c: Remove.
848 * util/mkisofs/getopt1.c: Likewise.
849 * util/mkisofs/getopt.c: Likewise.
850 * conf/common.rmk (grub_mkisofs_SOURCES): Replace
851 `util/mkisofs/fnmatch.c', `util/mkisofs/getopt1.c' and
852 `util/mkisofs/getopt.c' with `gnulib/fnmatch.c',
853 `gnulib/getopt1.c' and `gnulib/getopt.c'.
854 (grub_mkisofs_CFLAGS): Add `-I$(srcdir)/gnulib'.
855
856 * configure.ac: Detect `mingw32msvc' host_os.
857 Check for lstat(), getuid() and getgid().
858
859 * util/mkisofs/joliet.c: Include `<stdint.h>'. Replace all
860 instances of `u_char' with `uint8_t'.
861
862 * util/mkisofs/mkisofs.h: Include `<sys/stat.h>'.
863 [!HAVE_GETUID] (getuid): New function (stub).
864 [!HAVE_GETGID] (getgid): Likewise.
865 [!HAVE_LSTAT] (lstat): Likewise.
866 [!S_IROTH] (S_IROTH): New macro (dummy).
867 [!S_IRGRP] (S_IRGRP): Likewise.
868
84b860d8
RM
8692009-11-09 Robert Millan <rmh.grub@aybabtu.com>
870
871 * gnulib/fnmatch_loop.c (EXT): Fix warning (signed and unsigned type in
872 conditional expression).
873
66e9b712
RM
8742009-11-09 Robert Millan <rmh.grub@aybabtu.com>
875
876 Import from Gnulib.
877
878 * gnulib/fnmatch.c: New file.
879 * gnulib/fnmatch.h: Likewise.
880 * gnulib/fnmatch_loop.c: Likewise.
881 * gnulib/getopt.c: Likewise.
882 * gnulib/getopt.h: Likewise.
883 * gnulib/getopt1.c: Likewise.
884 * gnulib/getopt_int.h: Likewise.
885 * gnulib/gettext.h: Likewise.
886
34f4a5b0
RM
8872009-11-09 Robert Millan <rmh.grub@aybabtu.com>
888
889 * normal/dyncmd.c (read_command_list): Replace `0' with `NULL'.
890 * normal/handler.c (read_handler_list): Likewise.
891
ac451143
RM
8922009-11-09 Robert Millan <rmh.grub@aybabtu.com>
893
894 Misc cleanup.
895
896 * kern/command.c (grub_register_command_prio): Use
897 grub_zalloc() instead of explicitly zeroing data.
898 * kern/list.c: Include `<grub/mm.h>'.
899 (grub_named_list_find): Replace `0' with `NULL'.
900 * normal/autofs.c (struct grub_fs_module_list): Remove ad-hoc type.
901 (fs_module_list): Change type to `grub_named_list_t'. Update all
902 users.
903 * normal/dyncmd.c (read_command_list): Add space between function
904 call and parenthesis.
905 * normal/handler.c (read_handler_list): Likewise.
906
4089b167
RM
9072009-11-09 Robert Millan <rmh.grub@aybabtu.com>
908
909 * normal/auth.c (punishment_delay): Moved from here ...
910 (grub_auth_strcmp): ... to here (inside function).
911
325f5037
RM
9122009-11-09 Robert Millan <rmh.grub@aybabtu.com>
913
914 * include/grub/list.h (struct grub_named_list): Remove `const'
915 qualifier from `name'.
916 (struct grub_prio_list): Likewise.
917
7aea29a3
RM
9182009-11-09 Robert Millan <rmh.grub@aybabtu.com>
919
920 * normal/auth.c: Include `<grub/time.h>'.
921 (grub_auth_strcmp): Replace `strcmp' with `grub_strcmp'.
922
3fd6f044
RM
9232009-11-09 Robert Millan <rmh.grub@aybabtu.com>
924
925 * normal/auth.c (punishment_delay): New variable.
926 (grub_auth_strcmp): Rewrite using grub_get_time_ms ().
927 (grub_auth_check_authentication): Punish failed login attempts with
928 an incremental (2^N) delay.
929
a4cd68e4
RM
9302009-11-09 Robert Millan <rmh.grub@aybabtu.com>
931
932 * conf/common.rmk (grub_mkisofs_CFLAGS): Prefix include
933 path with $(srcdir).
934
7ad12f43
VS
9352009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
936
937 * normal/auth.c (grub_auth_strcmp): Fixed incorrect variable usage.
938
c1129f03
RM
9392009-11-09 Robert Millan <rmh.grub@aybabtu.com>
940
941 * util/i386/coreboot/grub-mkrescue.in: New file.
942 * conf/i386-coreboot.rmk (bin_SCRIPTS, grub_mkrescue_SOURCES): New
943 variables.
944
945 * conf/common.rmk (bin_UTILITIES): Add `grub-mkisofs'.
946 (grub_mkisofs_SOURCES, grub_mkisofs_CFLAGS): New variables.
947 * configure.ac: Add header and function checks to satisfy grub-mkisofs
948 requirements.
949 * util/mkisofs/defaults.h: New file.
950 * util/mkisofs/eltorito.c: Likewise.
951 * util/mkisofs/exclude.h: Likewise.
952 * util/mkisofs/fnmatch.c: Likewise.
953 * util/mkisofs/getopt.c: Likewise.
954 * util/mkisofs/getopt1.c: Likewise.
955 * util/mkisofs/hash.c: Likewise.
956 * util/mkisofs/include/fctldefs.h: Likewise.
957 * util/mkisofs/include/mconfig.h: Likewise.
958 * util/mkisofs/include/prototyp.h: Likewise.
959 * util/mkisofs/include/statdefs.h: Likewise.
960 * util/mkisofs/iso9660.h: Likewise.
961 * util/mkisofs/joliet.c: Likewise.
962 * util/mkisofs/match.c: Likewise.
963 * util/mkisofs/match.h: Likewise.
964 * util/mkisofs/mkisofs.c: Likewise.
965 * util/mkisofs/mkisofs.h: Likewise.
966 * util/mkisofs/multi.c: Likewise.
967 * util/mkisofs/name.c: Likewise.
968 * util/mkisofs/rock.c: Likewise.
969 * util/mkisofs/tree.c: Likewise.
970 * util/mkisofs/write.c: Likewise.
971
ec8bb77d
VS
9722009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
973
974 * normal/auth.c (grub_auth_strcmp): Fix bug which resulted in function
975 being insecure.
976
3716b12c
RM
9772009-11-08 Robert Millan <rmh.grub@aybabtu.com>
978
979 * util/i386/pc/grub-mkrescue.in: Fix miss-identification as
980 `grub-mkimage' (and use $0 when possible).
981
b97b7b91
RM
9822009-11-08 Robert Millan <rmh.grub@aybabtu.com>
983
984 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve
985 error message for excessively large memory map.
986
04114812
RM
9872009-11-08 Robert Millan <rmh.grub@aybabtu.com>
988
989 * autogen.sh: Use `sh gendistlist.sh' to avoid reliing on
990 executable bit.
991
e4eb2373
RM
9922009-11-08 Robert Millan <rmh.grub@aybabtu.com>
993
994 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve error
995 message for coreboot users.
996
c926e1d5 9972009-11-07 Robert Millan <rmh.grub@aybabtu.com>
998
999 Fix build with GNU gold.
1000
1001 * conf/i386-pc.rmk (boot_img_LDFLAGS, pxeboot_img_LDFLAGS)
1002 (diskboot_img_LDFLAGS, lnxboot_img_LDFLAGS)
1003 (cdboot_img_LDFLAGS): Prepend `0x' qualifier to hexadecimal
1004 link addresses.
1005 * aclocal.m4: Likewise.
1006
86e5b1db 10072009-11-04 Felix Zielcke <fzielcke@z-51.de>
1008
1009 * configure.ac (AC_PREREQ): Bump to 2.59d.
1010 * INSTALL: Make it more clear when Autoconf and Ruby are
1011 needed and when to run `./autogen.sh'.
1012
246cd78f 10132009-11-03 Samuel Thibault <samuel.thibault@ens-lyon.org>
1014
1015 * util/grub.d/30_os-prober.in: Restore default behavior for unsupported
1016 OSes.
1017
4f9dfb37 10182009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1019
1020 * util/grub.d/30_os-prober.in: Add GNU/Hurd support
1021
b82bd5e1 10222009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1023
1024 * util/grub.d/10_hurd.in: Drop /dev/ prefix from root device path before
1025 giving it to GNU Mach.
1026
ff1a9bca 10272009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1028
1029 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Subtract 1 from
1030 GNU partition number to get internal GRUB partition number.
1031
61697d9c 10322009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1033
1034 * util/grub.d/10_hurd.in: Call prepare_grub_to_access_device
1035 ${GRUB_DEVICE_BOOT} before loading /boot kernel.
1036
a50569e1 10372009-11-01 Robert Millan <rmh.grub@aybabtu.com>
1038
1039 Based on patch from BVK Chaitanya <bvk.groups@gmail.com>
1040 * kern/misc.c (grub_strchr, grub_strrchr): Fix to handle c == '\0'
1041 case.
1042
5b153867 10432009-11-01 Felix Zielcke <fzielcke@z-51.de>
1044
1045 * Makefile.in (TARGET_CPPFLAGS): Add `-I$(srcdir)/include'.
1046
d9e2cd70 10472009-10-30 Robert Millan <rmh.grub@aybabtu.com>
1048
1049 Fix build problem.
1050
1051 * Makefile.in (TARGET_CPPFLAGS): Replace `-nostdinc' with
1052 `-isystem=$(srcdir)/include'.
1053
805111a4 10542009-10-30 Robert Millan <rmh.grub@aybabtu.com>
1055
1056 * util/i386/pc/grub-install.in: Remove hint that device.map should be
1057 checked (grub-install doesn't currently rely on it).
1058
fa6e945f 10592009-10-29 Robert Millan <rmh.grub@aybabtu.com>
1060
1061 Revert SVN r2660.
1062
1063 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): Moved from here ...
1064 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
1065 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): ... and here.
1066 * conf/i386-ieee1275.rmk: Likewise.
1067 * conf/i386-pc.rmk: Likewise.
1068 * conf/powerpc-ieee1275.rmk: Likewise.
1069 * conf/sparc64-ieee1275.rmk: Likewise.
1070 * conf/x86_64-efi.rmk: Likewise.
1071
cee15086 10722009-10-28 Robert Millan <rmh.grub@aybabtu.com>
1073
1074 * Makefile.in (TARGET_CPPFLAGS): Add `-nostdinc'.
1075
95b9239e 10762009-10-28 Robert Millan <rmh.grub@aybabtu.com>
1077
1078 * include/grub/misc.h: Stop checking for APPLE_CC.
1079
2ed19dfd 10802009-10-28 Robert Millan <rmh.grub@aybabtu.com>
1081
1082 * kern/i386/coreboot/init.c (grub_exit): Reimplement in a way that
1083 doesn't cause an infinite call loop.
1084
fdcdde19 10852009-10-28 Felix Zielcke <fzielcke@z-51.de>
1086
1087 * commands/acpi.c (grub_cmd_acpi): Fix the out of memory error
1088 strings.
1089
cefabfe1 10902009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1091
1092 * autogen.sh: Support addition of external modules via `GRUB_CONTRIB'
1093 variable.
1094 * Makefile.in: Likewise.
1095
ed96ab6d 10962009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1097
1098 * gendistlist.sh: Simplify .svn check. Skip .bzr as well.
1099
0579b753 11002009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1101
1102 * Makefile.in (RMKFILES): Rewrite using $(wildcard).
1103
478df409 11042009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1105
1106 * disk/scsi.c: Remove `<grub/machine/kernel.h>' (not needed).
1107
083d1679 11082009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1109
1110 * gensymlist.sh.in (COMPILE_TIME_ASSERT): Copy macro declaration
1111 from here ...
1112 * include/grub/misc.h (COMPILE_TIME_ASSERT): ... to here.
1113
5947ae32 11142009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1115
1116 * Makefile.in (docs/grub.info): Use make syntax to ignore errors
1117 in $(MAKEINFO) invocation. This makes it clear in output that
1118 errors are being ignored.
1119
94180ff6 11202009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1121
1122 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): Moved
1123 from here ...
1124 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
1125 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): Remove.
1126 * conf/i386-ieee1275.rmk: Likewise.
1127 * conf/i386-pc.rmk: Likewise.
1128 * conf/powerpc-ieee1275.rmk: Likewise.
1129 * conf/sparc64-ieee1275.rmk: Likewise.
1130 * conf/x86_64-efi.rmk: Likewise.
1131
9031b03a 11322009-10-26 Colin Watson <cjwatson@ubuntu.com>
1133
1134 * util/grub-editenv.c (main): If only a command is given, use
1135 DEFAULT_DIRECTORY "/" GRUB_ENVBLK_DEFCFG as a default file name.
1136 (usage): FILENAME is now optional and has a default.
1137
e4f6809b 11382009-10-26 Colin Watson <cjwatson@ubuntu.com>
1139
1140 Improve grub-mkconfig performance when there are several menu
1141 entries on a single filesystem.
1142
1143 * util/grub.d/10_linux.in (linux_entry): Cache the output of
1144 prepare_grub_to_access_device.
1145 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
1146 * util/grub.d/30_os-prober.in: Likewise.
1147
67937d4d 11482009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1149
1150 * util/grub.d/10_freebsd.in: Remove.
1151 * util/grub.d/10_kfreebsd.in: New file (based on 10_linux.in).
1152 * configure.ac: Set host_kernel=kfreebsd for FreeBSD and GNU/kFreeBSD.
1153
ee3756cc 11542009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1155
5c35048e 1156 * docs/grub.cfg: Fix example usage of *BSD loaders.
ee3756cc 1157
4dea1c6f 11582009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1159
1160 * util/i386/pc/grub-setup.c (setup): Add missing parameter to
1161 grub_util_error() call.
1162
042484d7 11632009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1164
1165 * include/grub/fs.h [GRUB_UTIL] (struct grub_fs): Add
1166 `reserved_first_sector' member.
1167 * fs/ext2.c [GRUB_UTIL] (grub_ext2_fs): Initialize
1168 `reserved_first_sector' to 1.
1169 * fs/fat.c [GRUB_UTIL] (grub_fat_fs): Likewise.
1170 * fs/ntfs.c [GRUB_UTIL] (grub_ntfs_fs): Likewise.
1171 * fs/hfsplus.c [GRUB_UTIL] (grub_hfsplus_fs): Likewise.
1172 * util/i386/pc/grub-setup.c (setup): Add safety check that probes for
1173 filesystems which begin at first sector.
1174 (options): New option --skip-fs-probe.
1175 (main): Handle --skip-fs-probe and pass it to setup().
1176
d64448a7 11772009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1178
1179 * include/grub/misc.h: Fix wrong evaluation of APPLE_CC.
1180 (memset): Fix function prototype.
1181
508d42ec 11822009-10-25 Robert Millan <rmh.grub@aybabtu.com>
11832009-10-25 Vasily Averin <vvs@parallels.com>
1184
1185 * fs/ext2.c (grub_ext2_iterate_dir): Avoid infinite loop when
1186 `dirent.direntlen == 0'.
1187
b240e30c 11882009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1189
1190 * fs/cpio.c [MODE_USTAR]: Initialize `tar' module instead of
1191 `cpio'.
1192 [! MODE_USTAR]: Initialize `cpio' module instead of `tar'.
1193
346e7fbe 11942009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1195
1196 * configure.ac: Check for `__ashldi3', `__ashrdi3', `__lshrdi3',
1197 `__trampoline_setup' and `__ucmpdi2'.
1198 * include/grub/powerpc/libgcc.h: Only export symbols for functions
1199 that libgcc provides.
1200
cdb308b0 12012009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1202
1203 * include/grub/powerpc/libgcc.h (memset): Remove function prototype.
1204 * include/grub/sparc64/libgcc.h (memset): Likewise.
1205 * include/grub/misc.h (memset, memcmp): New function prototypes.
1206
fb26abc2 12072009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1208
1209 * fs/cpio.c [MODE_USTAR]: Finish `tar' module instead of
1210 `cpio'.
1211 [! MODE_USTAR]: Finish `cpio' module instead of `tar'.
1212
f6693890 12132009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1214
1215 Patch from Samuel Thibault <samuel.thibault@ens-lyon.org>
1216 * docs/grub.cfg: Compensate for recent change in multiboot
1217 loader (since 2009-08-14 it won't pass filename to payload).
1218 * util/grub.d/10_hurd.in: Likewise.
1219
0933cdc0 12202009-10-21 Felix Zielcke <fzielcke@z-51.de>
1221
1222 * config.guess: Update to latest version from config git
1223 repository.
1224 * config.sub: Likewise.
1225
3b2fe8c2 12262009-10-20 Robert Millan <rmh.grub@aybabtu.com>
1227
1228 Fix build on sparc64.
1229
1230 * configure.ac: Perform checks for libgcc symbols before
1231 adding `-nostdlib' to LDFLAGS.
1232
46695a62 12332009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1234
1235 Let user specify OpenBSD root device.
1236
1237 * loader/i386/bsd.c (openbsd_root): New variable.
1238 (openbsd_opts): New option 'root'.
1239 (OPENBSD_ROOT_ARG): New macro.
1240 (grub_openbsd_boot): Use 'openbsd_root'.
1241 (grub_cmd_openbsd): Fill 'openbsd_root'.
1242
d2b6b7fc 12432009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1244
1245 * NEWS: Misc adjustments.
1246
421bd7ac 12472009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1248
1249 * NEWS: Mentioned XNU, ACPI, gptsync, password and parttool.
1250
f1d29d87 12512009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1252
1253 * configure.ac: Bump version to 1.97.
1254
6f3cd880 12552009-10-16 Colin Watson <cjwatson@ubuntu.com>
1256
1257 * configure.ac (TARGET_CFLAGS): Add -mno-mmx -mno-sse -mno-sse2
1258 -mno-3dnow on x86 architectures. Some toolchains enable these
1259 features by default, but they rely on registers that aren't enabled
1260 in GRUB. Thanks to Vladimir Serbinenko for the suggestion.
1261
035f7122 12622009-10-15 Robert Millan <rmh.grub@aybabtu.com>
1263
1264 Make entry text a bit more readable.
1265
1266 * util/grub.d/10_linux.in: Add `with' before `Linux'.
1267
44998e58 12682009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1269
1270 * loader/i386/pc/xnu.c (grub_xnu_set_video): Fix loading splash image.
1271
cd2851b3 12722009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1273
1274 * commands/xnu_uuid.c (grub_cmd_xnu_uuid): Remove duplicated bitwise
1275 operations.
1276
c6f3b249 12772009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1278
1279 * configure.ac: Add missing dollar.
1280
6b5886ba 12812009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1282
1283 Revert 2009-06-10 Pavel Roskin <proski@gnu.org>
1284
1285 * configure.ac: Put checks for __bswapsi2 and __bswapdi2.
1286 * include/grub/powerpc/libgcc.h: Don't use weak attribute for all
1287 exports.
1288 * include/grub/sparc64/libgcc.h: Likewise. Use
1289 preprocessor conditionals.
1290
e9d66f6d 12912009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1292
1293 * conf/common.rmk (grub-dumpbios): Remove rule.
1294 (sbin_SCRIPTS, CLEANFILES): Remove `grub-dumpbios'.
1295 * util/grub-dumpbios.in: Remove file.
1296
9155bc17 12972009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1298
1299 Refer to kernel of FreeBSD "kFreeBSD" to avoid confusion between
1300 the Operating System (FreeBSD) and its kernel (kernel of FreeBSD).
1301
1302 * loader/i386/bsd.c (grub_freebsd_boot): Read kernel environment
1303 from "kFreeBSD" namespace (rather than "FreeBSD"). Update all
1304 users.
1305
1306 (GRUB_MOD_INIT (bsd)): Rename "freebsd" command to "kfreebsd",
1307 "openbsd" to "kopenbsd", "netbsd" to "knetbsd", "freebsd_loadenv"
1308 to "kfreebsd_loadenv", "freebsd_module" to "kfreebsd_module",
1309 and "freebsd_module_elf" to "kfreebsd_module_elf". Update all
1310 users.
1311
bf7f7a18 13122009-10-12 Robert Millan <rmh.grub@aybabtu.com>
1313
1314 * term/tparm.c: Switch to GPLv3.
1315
86564c26 13162009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1317
1318 * include/grub/i386/cpuid.h: Add header protection.
1319
5c936493 13202009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1321
1322 Fail gracefuly when attempting to load 64-bit kFreeBSD on IA32 CPU.
1323
1324 * include/grub/i386/cpuid.h: New file.
1325 * commands/i386/cpuid.c: Include `<grub/i386/cpuid.h>'.
1326 (has_longmode): Rename to ...
1327 (grub_cpuid_has_longmode): ... this. Update all users. Remove
1328 `static' attribute.
1329 * loader/i386/bsd.c: Include `<grub/i386/cpuid.h>'.
1330 (grub_bsd_load_elf): Fail if load of 64-bit kernel was requested
1331 on a CPU that doesn't implement AMD64 instruction set.
1332
186e7cf2 13332009-10-06 Colin Watson <cjwatson@ubuntu.com>
1334
1335 * Makefile.in (docs/stamp-vti): Depend on configure.ac as well, so
1336 that version.texi is rebuilt on version number changes.
1337
83b65c4a 13382009-10-06 Colin Watson <cjwatson@ubuntu.com>
1339
1340 * Makefile.in: Don't set info_INFOS unless makeinfo was found.
1341 Fixes bug #27602.
1342
d244281c 13432009-10-06 Colin Watson <cjwatson@ubuntu.com>
1344
1345 * util/i386/pc/grub-install.in: Source
1346 ${libdir}/grub/grub-mkconfig_lib before option processing, in order
1347 that the --grub-probe option will work.
1348 * util/sparc64/ieee1275/grub-install.in: Likewise.
1349
da25306d 13502009-10-05 Robert Millan <rmh.grub@aybabtu.com>
1351
1352 * configure.ac: Bump version to 1.97~beta4.
1353
e8ee83c0 13542009-10-03 Robert Millan <rmh.grub@aybabtu.com>
1355
1356 Resync grub-mkdevicemap in x86_64-efi.
1357
1358 * conf/x86_64-efi.rmk (sbin_UTILITIES): Enable `grub-mkdevicemap'.
1359 (grub_mkdevicemap_SOURCES): Add missing `util/deviceiter.c' and
1360 `util/devicemap.c'.
1361
50dcabcf 13622009-10-01 Colin Watson <cjwatson@ubuntu.com>
1363
1364 * util/grub-editenv.c (create_envblk_file): Write new block with a
1365 .new suffix and then rename it into place, to ensure atomic
1366 creation.
1367
0e51c3a7 13682009-09-28 Robert Millan <rmh.grub@aybabtu.com>
1369
1370 Do not automatically install headers.
1371
1372 * Makefile.in (include_DATA): Remove. Update all users.
1373
31299a95 13742009-09-26 Robert Millan <rmh.grub@aybabtu.com>
1375
1376 * conf/common.rmk (pkglib_MODULES): Remove `lua.mod'.
1377 (lua_mod_SOURCES, lua_mod_CFLAGS, lua_mod_LDFLAGS): Remove.
1378
1379 * util/osdetect.lua: Remove.
1380 * script/lua/lauxlib.c: Likewise.
1381 * script/lua/ldebug.c: Likewise.
1382 * script/lua/grub_main.c: Likewise.
1383 * script/lua/lauxlib.h: Likewise.
1384 * script/lua/ldebug.h: Likewise.
1385 * script/lua/ltablib.c: Likewise.
1386 * script/lua/liolib.c: Likewise.
1387 * script/lua/lstrlib.c: Likewise.
1388 * script/lua/lualib.h: Likewise.
1389 * script/lua/ldo.c: Likewise.
1390 * script/lua/ldump.c: Likewise.
1391 * script/lua/ldo.h: Likewise.
1392 * script/lua/loslib.c: Likewise.
1393 * script/lua/lundump.c: Likewise.
1394 * script/lua/grub_lib.c: Likewise.
1395 * script/lua/ldblib.c: Likewise.
1396 * script/lua/lundump.h: Likewise.
1397 * script/lua/lmem.c: Likewise.
1398 * script/lua/grub_lib.h: Likewise.
1399 * script/lua/lmathlib.c: Likewise.
1400 * script/lua/lstate.c: Likewise.
1401 * script/lua/ltm.c: Likewise.
1402 * script/lua/lvm.c: Likewise.
1403 * script/lua/lmem.h: Likewise.
1404 * script/lua/lstate.h: Likewise.
1405 * script/lua/ltm.h: Likewise.
1406 * script/lua/ltable.c: Likewise.
1407 * script/lua/lvm.h: Likewise.
1408 * script/lua/llex.c: Likewise.
1409 * script/lua/lgc.c: Likewise.
1410 * script/lua/grub_lua.h: Likewise.
1411 * script/lua/loadlib.c: Likewise.
1412 * script/lua/lfunc.c: Likewise.
1413 * script/lua/lopcodes.c: Likewise.
1414 * script/lua/lparser.c: Likewise.
1415 * script/lua/ltable.h: Likewise.
1416 * script/lua/llex.h: Likewise.
1417 * script/lua/lgc.h: Likewise.
1418 * script/lua/lfunc.h: Likewise.
1419 * script/lua/lbaselib.c: Likewise.
1420 * script/lua/lopcodes.h: Likewise.
1421 * script/lua/lparser.h: Likewise.
1422 * script/lua/lzio.c: Likewise.
1423 * script/lua/linit.c: Likewise.
1424 * script/lua/lobject.c: Likewise.
1425 * script/lua/llimits.h: Likewise.
1426 * script/lua/lstring.c: Likewise.
1427 * script/lua/lzio.h: Likewise.
1428 * script/lua/lapi.c: Likewise.
1429 * script/lua/lcode.c: Likewise.
1430 * script/lua/lua.h: Likewise.
1431 * script/lua/lobject.h: Likewise.
1432 * script/lua/lstring.h: Likewise.
1433 * script/lua/lapi.h: Likewise.
1434 * script/lua/lcode.h: Likewise.
1435 * script/lua/luaconf.h: Likewise.
1436
cb8a2c38 14372009-09-26 Colin Watson <cjwatson@ubuntu.com>
1438
1439 * docs/grub.texi (Command-line and menu entry commands): Document
1440 date and echo commands.
1441
6b9b6276 14422009-09-24 Pavel Roskin <proski@gnu.org>
1443
1444 * include/grub/kernel.h (struct grub_module_header): Remove
1445 `grub_module_header_types'. Make `type' unsigned. Make `size'
1446 32-bit on all platforms.
1447 * util/elf/grub-mkimage.c (load_modules): Treat `type' as an
1448 8-bit field. Use grub_host_to_target32() for `size'.
1449 * util/i386/efi/grub-mkimage.c (make_mods_section): Likewise.
1450 * util/i386/pc/grub-mkimage.c (generate_image): Likewise.
1451 * util/sparc64/ieee1275/grub-mkimage.c (generate_image): Likewise.
1452
4e5a02a7 14532009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1454
1455 Fix "lost keypress" bug in at_keyboard.
1456
1457 * term/i386/pc/at_keyboard.c (grub_at_keyboard_checkkey): New function.
1458 Checks for readyness of input buffer (without flushing it).
1459 (grub_at_keyboard_term): Use grub_at_keyboard_checkkey() rather
1460 than grub_at_keyboard_getkey_noblock() for `checkkey' struct member.
1461
c6dcedf6 14622009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1463
1464 * util/i386/pc/grub-mkimage.c (generate_image): Enclose BIOS-specific
1465 size check within GRUB_MACHINE_PCBIOS section.
1466
74c958b1 14672009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1468
1469 * include/grub/i386/at_keyboard.h (KEYBOARD_ISREADY): Negate
1470 return value.
1471 * term/i386/pc/at_keyboard.c (grub_keyboard_getkey): Negate
1472 KEYBOARD_ISREADY check.
1473 (grub_at_keyboard_checkkey): Rename to ...
1474 (grub_at_keyboard_getkey_noblock): ... this. Update all users.
1475 Remove gratuitous cast.
1476
ff420223 14772009-09-23 Colin Watson <cjwatson@ubuntu.com>
1478
1479 * configure.ac: Call AC_PROG_MKDIR_P.
1480 * Makefile.in (docs/stamp-vti): Create docs directory. Create
1481 version.texi in $(builddir) rather than $(srcdir).
1482 (docs/grub.info): Create docs directory. Prepend $(builddir)/docs
1483 to makeinfo's @include search path.
1484
d96875df 14852009-09-23 Felix Zielcke <fzielcke@z-51.de>
1486
1487 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Cope with `*.dpkg-*'
1488
9b3f8365 14892009-09-23 Felix Zielcke <fzielcke@z-51.de>
1490
1491 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Add support
1492 for `*.dpkg-new'.
1493
c44c90db 14942009-09-21 Colin Watson <cjwatson@ubuntu.com>
1495
1496 Build info documentation. Some code borrowed from Automake.
1497
1498 * configure.ac: Check for makeinfo.
1499 * Makefile.in (MAKEINFO, INFOS, info_INFOS): New variables.
1500 (MAINTAINER_CLEANFILES): Add $(INFOS), docs/stamp-vti, and
1501 docs/version.texi.
1502 (MOSTLYCLEANFILES): Add vti.tmp.
1503 (docs/version.texi, docs/stamp-vti): Update automatically.
1504 (docs/grub.info): Build info documentation. Use --force and ignore
1505 errors for now.
1506 (all-local): Add $(INFOS).
1507 (install-local): Install info files.
1508 (uninstall): Uninstall info files.
1509 * docs/version.texi: Remove from revision control. This file is
1510 automatically generated on build now.
1511 * gendistlist.sh: Add `*.info'.
1512
e0b37bb5 15132009-09-21 Felix Zielcke <fzielcke@z-51.de>
1514
1515 * kern/term.c: Fix indentation.
1516
5a78865b 15172009-09-21 Felix Zielcke <fzielcke@z-51.de>
1518
1519 * util/hostdisk.c: Fix a comment.
1520
dace7e8a 15212009-09-20 Robert Millan <rmh.grub@aybabtu.com>
1522
1523 Fix regression introduced in r2539.
1524
1525 * term/usb_keyboard.c (USB_HID_DEVICE_TO_HOST): Change from 0x61
1526 to 0xA1.
1527
a83d079b 15282009-09-19 Colin Watson <cjwatson@ubuntu.com>
1529
1530 * util/grub.d/30_os-prober.in: Don't throw away stderr from
4cbbccec 1531 os-prober. Under normal operation, it does not print anything to
1532 stderr; if it does, we need to debug it, and throwing away stderr
1533 makes that excessively difficult.
a83d079b 1534
be94a509 15352009-09-16 Vladimir Serbinenko <phcoder@gmail.com>
1536
1537 * mmap/mmap.c (grub_cmd_badram): Fix off-by-one error.
1538
63f745e8 15392009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1540
1541 * aclocal.m4 (AC_LANG_PROGRAM): New macro. Overrides stock
1542 AC_LANG_PROGRAM from autoconf.
1543 (grub_ASM_USCORE, grub_PROG_OBJCOPY_ABSOLUTE): Add missing
1544 prototypes (fixes warning).
1545
1546 * configure.ac: Add `-Werror' to TARGET_CFLAGS unless
1547 `--disable-werror' was used.
1548
bbb2a70f 15492009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1550
1551 * partmap/msdos.c (pc_partition_map_iterate): Fix possible use of
1552 uninitialized `lastaddr'.
1553
77c24f1d 15542009-09-15 Vladimir Serbinenko <phcoder@gmail.com>
1555
0f0b8c87 1556 * partmap/msdos.c (pc_partition_map_iterate): Detect and break loops.
77c24f1d 1557
07197f23 15582009-09-14 Colin Watson <cjwatson@ubuntu.com>
1559
1560 * commands/test.c (get_fileinfo): Return immediately if
1561 grub_fs_probe fails.
1562
dabf1798 15632009-09-14 José Martínez <xosemp@gmail.com>
1564
1565 * commands/acpi.c (grub_cmd_acpi): Fix loading ACPI tables from file.
1566
d52109a7 15672009-09-14 Colin Watson <cjwatson@ubuntu.com>
1568
1569 * util/grub.d/30_os-prober.in: Cope with Windows 7 in os-prober
1570 output.
1571
56532179 15722009-09-13 Robert Millan <rmh.grub@aybabtu.com>
1573
1574 * configure.ac: Remove --enable-grub-pe2elf. Only build
1575 grub-pe2elf when needed by the build system itself.
1576 * conf/common.rmk: Remove $(enable_grub_pe2elf) check.
1577
8ef070f5 15782009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1579
1580 * configure.ac: Bump version to 1.97~beta3.
1581 * docs/version.texi: Likewise.
1582
61229557 15832009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1584
1585 * video/i386/pc/vbe.c (grub_vbe_get_video_mode_info): Move packed
1586 mode special handling (grub_vbe_bios_set_dac_palette_width() call)
1587 from here ...
1588 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS]
1589 (grub_linux_setup_video): ... to here (with some adjustments).
1590
5c9f8d84 15912009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1592
1593 Fix memory corruption issue (spotted by Colin Watson).
1594
1595 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette): Fix bug
1596 causing returned size to be stored in an incorrect memory location.
1597 Fix use of uninitialized value when storing the returned size.
1598
e8f5d6e9 15992009-09-12 Yves Blusseau <blusseau@zetam.org>
1600
1601 Change clean rules to properly remove files
1602
1603 * genmk.rb: add new clean rules
1604 * Makefile.in (clean): add the new targets
1605 (mostlyclean): likewise
1606
cda2a409 16072009-09-11 Colin Watson <cjwatson@ubuntu.com>
1608
1609 * include/grub/ntfs.h (struct grub_fshelp_node): Change `size'
1610 to grub_uint64_t.
1611 * fs/ntfs.c (init_file): Understand 64-bit sizes for
1612 non-resident files.
1613
86695375 16142009-09-11 Colin Watson <cjwatson@ubuntu.com>
1615
1616 * configure.ac: Don't look for help2man when cross-compiling. Fixes
1617 part of bug #27349.
1618
8aa1541a 16192009-09-10 Felix Zielcke <fzielcke@z-51.de>
1620
1621 * util/grub-mkconfig.in: Make the created config mode 400 and
1622 print a warning if it fails.
1623
48d9bb0a 16242009-09-10 Robert Millan <rmh.grub@aybabtu.com>
1625
1626 * util/grub.d/40_custom.in: Ask user to type custom entries below
1627 comment, rather than below 'exec tail' line.
1628
3b0521be 16292009-09-10 Colin Watson <cjwatson@ubuntu.com>
1630
1631 * util/grub.d/40_custom.in: Make sure that the explanatory text is
1632 visible in grub.cfg.
1633
50051d55 16342009-09-10 Colin Watson <cjwatson@ubuntu.com>
1635
1636 * util/grub.d/40_custom.in: Make it a little clearer how to use this
1637 file.
1638
c0d34387 16392009-09-10 Felix Zielcke <fzielcke@z-51.de>
1640
1641 * docs/grub.cfg: Add an example menu entry for memtest86+.
1642
80a608f3 16432009-09-09 Felix Zielcke <fzielcke@z-51.de>
1644
a2094832 1645 * config.guess: Update to latest version from config git.
80a608f3 1646 * config.sub: Likewise.
1647
99423078 16482009-09-08 Colin Watson <cjwatson@ubuntu.com>
1649
1650 * script/sh/execute.c (grub_script_execute_cmdline): Set "?" in
1651 unknown-command case. Fixes bug #27320.
1652
44454e4c 16532009-09-08 Felix Zielcke <fzielcke@z-51.de>
1654
1655 * kern/rescue_parser.c (grub_rescue_parse_line): Only suggest to try
1656 `help' if the command exists.
1657
e30d87ad 16582009-09-06 Robert Millan <rmh.grub@aybabtu.com>
1659
1660 * INSTALL: Require GCC 4.1.3 or later.
1661
9a86f1ec 16622009-09-06 Yves Blusseau <blusseau@zetam.org>
1663
1664 * Makefile.in (RMKFILES): add i386-qemu.rmk
1665 (MAINTAINER_CLEANFILES): add $(srcdir)/DISTLIST $(srcdir)/config.h.in
1666 $(srcdir)/stamp-h.in
1667
7f26d466 16682009-09-05 Robert Millan <rmh.grub@aybabtu.com>
1669
1670 * util/grub-probe.c (probe): Comment out buggy codepath, which
1671 was unexpectedly enabled by Colin Watson's 2009-09-02 fix. This
1672 should be re-enabled after 1.97.
1673
3a613259 16742009-09-05 Felix Zielcke <fzielcke@z-51.de>
1675
1676 * gendistlist.sh: Add `grub-dumpdevtree' and `*.lua' to the list
1677 find searches for.
1678
197f76c7 16792009-09-04 Vladimir Serbinenko <phcoder@gmail.com>
1680
1681 * loader/i386/xnu.c (grub_cpu_xnu_fill_devicetree): Remove
1682 unnecessary calls to grub_error.
1683
70ba68ce 16842009-09-04 Colin Watson <cjwatson@ubuntu.com>
1685
1686 * NEWS: Mention `keystatus' and Unicode fonts.
1687
4ff0d7a4 16882009-09-04 Robert Millan <rmh.grub@aybabtu.com>
1689
1690 * configure.ac: Bump version to 1.97~beta2.
1691 * docs/version.texi: Likewise.
1692
77c55a87 16932009-09-03 Colin Watson <cjwatson@ubuntu.com>
1694
1695 * configure.ac: By default, GCC 4.4 generates .eh_frame sections
1696 containing unwind information in some cases where it previously did
1697 not. Use -fno-dwarf2-cfi-asm if available to restore the old
1698 behaviour. See http://patchwork.kernel.org/patch/8555/ for related
1699 discussion.
1700
f79572cd 17012009-09-02 Yves BLUSSEAU <blusseau@zetam.org>
1702
1703 Embedding loadenv module into grub-emu
1704
1705 * conf/i386-pc.rmk (grub_emu_SOURCES): add lib/envblk.c and
1706 commands/loadenv.c
1707 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise
1708 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise
1709 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise
1710 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise
1711 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise
1712 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise
1713
93a81088 17142009-09-03 Magnus Granberg <zorry@ume.nu>
1715
1716 * aclocal.m4: Add grub_CHECK_PIE. It check if the compiler
1717 include -fPIE in the default specs.
1718 * configure.ac: Check if pie_possible is yes and add -fno-PIE
1719 to TARGET_CFLAGS.
1720
160034b2 17212009-09-03 Felix Zielcke <fzielcke@z-51.de>
1722
1723 * INSTALL: Note that GNU Bison 2.3 or later is required.
1724
087c07c4 17252009-09-03 Colin Watson <cjwatson@ubuntu.com>
1726
1727 * kern/i386/pc/startup.S: Fix typo.
1728
cbf978c0 17292009-09-02 Vladimir Serbinenko <phcoder@gmail.com>
1730
1731 * efiemu/loadcore.c (SUFFIX (grub_efiemu_loadcore_load)): Fix style
1732 according to GCS.
1733
17342009-09-02 Colin Watson <cjwatson@ubuntu.com>
f0910644 1735
1736 * docs/grub.texi (Naming convention): Describe one-based partition
1737 numbering.
1738 (Device syntax): Likewise.
1739 (File name syntax): Likewise.
1740 (Block list syntax): Likewise.
1741 (Making a GRUB bootable CD-ROM): Talk about grub.cfg rather than
1742 menu.lst.
1743 (File name syntax): Likewise.
1744 (Command-line and menu entry commands): Document acpi, blocklist,
1745 crc, export, insmod, keystatus, ls, set, and unset commands.
1746
f3e8cdfd 17472009-09-02 Colin Watson <cjwatson@ubuntu.com>
1748
1749 * commands/keystatus.c (GRUB_MOD_INIT (keystatus)): Adjust summary
1750 to avoid implying that only one of --shift, --ctrl, or --alt may be
1751 used.
1752
c0bc232b 17532009-09-02 Colin Watson <cjwatson@ubuntu.com>
1754
1755 * util/grub-probe.c (probe): Test st.st_mode using S_ISREG macro
1756 rather than comparing against S_IFREG, which will almost never work.
1757
aa0f752d 17582009-09-01 Vladimir Serbinenko <phcoder@gmail.com>
1759
1760 * commands/loadenv.c (check_blocklists): Fix off-by-one error.
1761 (write_blocklists): Likewise.
1762
ecb3166a 17632009-09-01 Colin Watson <cjwatson@ubuntu.com>
1764
1765 * script/lua/grub_lua.h (fputs): Supply a format string as the first
1766 argument to grub_printf.
1767
c403a125 17682009-09-01 Felix Zielcke <fzielcke@z-51.de>
31aba781 1769
1770 * genmk.rb: Add quotes around $(TARGET_OBJ2ELF) to cope with
c403a125 1771 non GNU test.
31aba781 1772
b5e7312c 17732009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1774
1775 * kern/file.c (grub_file_read): Spelling fix
1776
fe00f472 17772009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1778
1779 * loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix
1780 loading of headers in some cases.
1781
cc55302e 17822009-08-30 Robert Millan <rmh.grub@aybabtu.com>
1783
1784 * configure.ac: Bump version to 1.97~beta1.
1785 * docs/version.texi: Likewise.
1786
5c90cdd2 17872009-08-29 Vladimir Serbinenko <phcoder@gmail.com>
64bf71d0 1788
1789 * include/grub/i386/xnu.h: Add license header.
1790 include grub/err.h explicitly.
1791
c90edae4 17922009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1793
1794 * util/grub.d/10_freebsd.in: Detect `ufs1' and `ufs2' and map them
1795 to `ufs' in the vfs.root.mountfrom kernel parameter.
1796
d8888b5c 17972009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1798
1799 * term/i386/pc/serial.c: Include `<grub/machine/memory.h>'.
1800
1801 [GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Macroify initialization
1802 value (0x0400 -> GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR).
1803
1804 [! GRUB_MACHINE_PCBIOS] (GRUB_SERIAL_PORT_NUM): Calculate using
1805 `ARRAY_SIZE' macro.
1806
6f07b921 18072009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1808
1809 * kern/file.c (grub_file_read): Check offset.
1810 * fs/hfs.c (grub_hfs_read_file): Remove unnecessary offset check.
1811 * fs/jfs.c (grub_jfs_read_file): Likewise.
1812 * fs/ntfs.c (grub_ntfs_read): Likewise.
1813 * fs/reiserfs.c (grub_reiserfs_read): Likewise.
1814 * fs/minix.c (grub_minix_read_file): Correct offset check.
1815 * fs/ufs.c (grub_ufs_read_file): Likewise.
1816
b4f34077 18172009-08-28 Colin Watson <cjwatson@ubuntu.com>
1818
1819 * term/i386/pc/console.c (bios_data_area): Cast
1820 GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR explicitly.
1821
e7c69859 18222009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1823
1824 1-bit optimised blitters.
1825
1826 * include/grub/fbblit.h (grub_video_fbblit_replace_32bit_1bit): New
1827 prototype.
1828 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1829 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1830 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1831 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1832 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1833 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1834 * video/fb/fbblit.c (grub_video_fbblit_replace_32bit_1bit): New
1835 function.
1836 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1837 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1838 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1839 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1840 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1841 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1842 * video/fb/video_fb.c (common_blitter): Use 1-bit optimised blitters
1843 when possible.
1844 * video/video.c (grub_video_get_blit_format): Return
1845 GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED if bpp = 1.
1846
a57da43f 18472009-08-28 Colin Watson <cjwatson@ubuntu.com>
1848
1849 * normal/cmdline.c (grub_cmdline_get): Supply a format string as
1850 the first argument to grub_printf.
1851
4cbe67e5 18522009-08-28 Colin Watson <cjwatson@ubuntu.com>
18532009-08-28 Robert Millan <rmh.grub@aybabtu.com>
1854
1855 Add `getkeystatus' terminal method. Add a new `keystatus' command
1856 to query it.
1857
1858 * include/grub/term.h (GRUB_TERM_STATUS_SHIFT,
1859 GRUB_TERM_STATUS_CTRL, GRUB_TERM_STATUS_ALT): Definitions for
1860 modifier key bitmasks.
1861 (struct grub_term_input): Add `getkeystatus' member.
1862 (grub_getkeystatus): Add prototype.
1863 * kern/term.c (grub_getkeystatus): New function.
1864
1865 * include/grub/i386/pc/memory.h
1866 (GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR): New macro.
1867 (struct grub_machine_bios_data_area): Define necessary parts of BIOS
1868 Data Area layout.
1869 * term/i386/pc/console.c (grub_console_getkeystatus): New function.
1870 (grub_console_term_input): Set `getkeystatus' member.
1871 * term/usb_keyboard.c (grub_usb_hid): Macroify HID protocol
1872 constants.
1873 (grub_usb_keyboard_getreport): Likewise.
1874 (grub_usb_keyboard_checkkey): Likewise.
1875 (grub_usb_keyboard_getkeystatus): New function.
1876 (grub_usb_keyboard_term): Set `getkeystatus' member.
1877
1878 * commands/keystatus.c: New file.
1879 * conf/common.rmk (pkglib_MODULES): Add keystatus.mod.
1880 (keystatus_mod_SOURCES): New variable.
1881 (keystatus_mod_CFLAGS): Likewise.
1882 (keystatus_mod_LDFLAGS): Likewise.
1883 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add
1884 commands/keystatus.c.
1885 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1886 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1887 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1888 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1889 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1890 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4cbe67e5 1891
6e2a9085 18922009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1893
1894 Split befs.mod and afs.mod into *_be.mod and *.mod
1895
1896 * conf/common.rmk (grub_probe_SOURCES): Add afs_be.c and befs_be.c.
1897 (grub_fstest_SOURCES): Likewise.
1898 (pkglib_MODULES): Add afs_be.mod and befs_be.mod.
1899 (afs_be_mod_SOURCES): New variable.
1900 (afs_be_mod_CFLAGS): Likewise.
1901 (afs_be_mod_LDFLAGS): Likewise.
1902 (befs_be_mod_SOURCES): Likewise.
1903 (befs_be_mod_CFLAGS): Likewise.
1904 (befs_be_mod_LDFLAGS): Likewise.
1905 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add afs_be.c and befs_be.c.
1906 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1907 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1908 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
1909 (grub_emu_SOURCES): Likewise.
1910 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1911 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1912 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1913 * fs/afs_be.c: New file.
1914 * fs/befs_be.c: New file.
1915 * fs/afs.c (GRUB_AFS_FSNAME_SUFFIX): New definition.
1916 (GRUB_AFS_FSNAME): Use GRUB_AFS_FSNAME_SUFFIX.
1917 (U16): Replaced with ...
1918 (grub_afs_to_cpu16): ...this. All users updated.
1919 (U32): Replaced with ...
1920 (grub_afs_to_cpu32): ...this. All users updated.
1921 (U64): Replaced with ...
1922 (grub_afs_to_cpu64): ...this. All users updated.
1923 (GRUB_AFS_BO_LITTLE_ENDIAN): Remove.
1924 (GRUB_AFS_BO_BIG_ENDIAN): Likewise.
ad8ea1f4 1925 (grub_afs_validate_sblock): Check only one endianness.
6e2a9085 1926 (GRUB_MOD_INIT (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1927 (GRUB_MOD_INIT (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1928 (GRUB_MOD_INIT (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1929 (GRUB_MOD_INIT (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1930 (GRUB_MOD_FINI (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1931 (GRUB_MOD_FINI (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1932 (GRUB_MOD_FINI (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1933 (GRUB_MOD_FINI (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1934
32a71655 19352009-08-26 Bean <bean123ch@gmail.com>
1936
1937 * fs/xfs.c (GRUB_XFS_INO_INOINAG): Replace 1L with 1LL to support
1938 64-bit number.
1939 (GRUB_XFS_FSB_TO_BLOCK): Likewise.
1940 (grub_xfs_inode_block): Change return type to grub_uint64_t.
1941 (grub_xfs_read_inode): Change type of block to grub_uint64_t.
1942
552bf6c5 19432009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1944
1945 NetBSD memory map support.
1946
1947 * include/grub/i386/bsd.h (NETBSD_BTINFO_MEMMAP): New definition.
1948 (grub_netbsd_btinfo_mmap_header): New structure.
1949 (grub_netbsd_btinfo_mmap_entry): Likewise.
1950 * loader/i386/bsd.c (grub_netbsd_boot): Pass memory map.
1951
1ae2078c 19522009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1953
1954 Enable bsd.mod on coreboot.
1955
1956 * conf/i386-coreboot.rmk (pkglib_MODULES): Add bsd.mod.
1957 (bsd_mod_SOURCES): New variable.
1958 (bsd_mod_CFLAGS): Likewise.
1959 (bsd_mod_LDFLAGS): Likewise.
1960 (bsd_mod_ASFLAGS): Likewise.
1961 * loader/i386/bsd.c [!GRUB_MACHINE_PCBIOS]: Fix includes.
1962 (grub_bsd_get_device) [!GRUB_MACHINE_PCBIOS]: Set *biosdev to 0xff.
1963
beefc598 19642009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1965
1966 Cleanup NetBSD root support.
1967
1968 * loader/i386/bsd.c (grub_netbsd_boot): Remove call to
1969 grub_bsd_get_device.
1970 Fix typo.
1971
3b76e68b 19722009-08-25 Felix Zielcke <fzielcke@z-51.de>
1973
1974 * util/grub.d/00_header.in: Move check for the video backend of
1975 gfxterm from here ...
1976 * util/grub-mkconfig.in: ... to here. Enable gfxterm if there's
1977 a suitable video backend.
1978
aea664ea 19792009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1980
1981 Fix breakage in grub-setup.
1982
1983 * util/i386/pc/grub-setup.c (setup): Use "part_msdos" instead of
1984 "msdos_partition_map".
1985
ff747d50 19862009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1987
1988 Fix breakage in normal/auth.c.
1989
1990 * normal/auth.c (grub_iswordseparator): New function.
1991
e7e1f93f 19922009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1993
1994 Authentication support.
1995
1996 * commands/password.c: New file.
1997 * conf/common.rmk (pkglib_MODULES): Add password.mod.
1998 (password_mod_SOURCES): New variable.
1999 (password_mod_CFLAGS): Likewise.
2000 (password_mod_LDFLAGS): Likewise.
2001 (normal_mod_SOURCES): Add normal/auth.c.
2002 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add commands/password.c and
2003 normal/auth.c.
2004 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2005 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2006 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2007 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2008 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2009 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
2010 * include/grub/auth.h: New file.
2011 * include/grub/err.h (grub_err_t): New enum value
2012 GRUB_ERR_ACCESS_DENIED.
2013 * include/grub/menu.h (grub_menu_entry): New fields 'restricted' and
2014 'users'.
2015 * include/grub/normal.h (grub_cmdline_get): New argument 'history'.
2016 * normal/cmdline.c (grub_cmdline_get): New argument 'history'. All
2017 users updated.
2018 * normal/auth.c: New file.
2019 * normal/main.c (grub_normal_add_menu_entry): Handle --users option.
2020 (grub_cmdline_run): Don't allow to go to command line without
2021 authentication.
2022 * normal/menu.c (grub_menu_execute_entry): Handle restricted entries.
2023 * normal/menu_entry.c (grub_menu_entry_run): Don't allow editing
2024 menuentry without superuser rights.
2025 * normal/menu_viewer.c (grub_menu_viewer_show_menu): Don't exit if
2026 user isn't a superuser.
2027
70f1161d 20282009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2029
2030 Save space by inlining misc.c functions.
2031
2032 * kern/misc.c (grub_iswordseparator): Made static.
2033 * kern/misc.c (grub_strcat): Moved from here ...
2034 * include/grub/misc.h (grub_strcat): ... here. Inlined.
2035 * kern/misc.c (grub_strncat): Moved from here ...
2036 * include/grub/misc.h (grub_strncat): ... here. Inlined.
2037 * kern/misc.c (grub_strcasecmp): Moved from here ...
2038 * include/grub/misc.h (grub_strcasecmp): ... here. Inlined.
2039 * kern/misc.c (grub_strncasecmp): Moved from here ...
2040 * include/grub/misc.h (grub_strncasecmp): ... here. Inlined.
2041 * kern/misc.c (grub_isalpha): Moved from here ...
2042 * include/grub/misc.h (grub_isalpha): ... here. Inlined.
2043 * kern/misc.c (grub_isdigit): Moved from here ...
2044 * include/grub/misc.h (grub_isdigit): ... here. Inlined.
2045 * kern/misc.c (grub_isgraph): Moved from here ...
2046 * include/grub/misc.h (grub_isgraph): ... here. Inlined.
2047 * kern/misc.c (grub_tolower): Moved from here ...
2048 * include/grub/misc.h (grub_tolower): ... here. Inlined.
2049
48e40bff 20502009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2051
2052 * script/sh/function.c (grub_script_function_find): Cut error message
2053 not to flood terminal.
2054 * script/sh/lexer.c (grub_script_yylex): Remove command line length
2055 limit.
2056 * script/sh/script.c (grub_script_arg_add): Duplicate string.
2057
c385bfc3 20582009-08-24 Colin Watson <cjwatson@ubuntu.com>
2059
2060 * term/usb_keyboard.c (grub_usb_keyboard_getreport): Make
2061 `report' grub_uint8_t *.
2062 (grub_usb_keyboard_checkkey): Make `data' elements grub_uint8_t.
2063 Use a 50-millisecond timeout rather than just repeating
2064 grub_usb_keyboard_getreport 50 times.
2065 (grub_usb_keyboard_getkey): Make `data' elements grub_uint8_t.
2066
2d21e3e8 20672009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2068
2069 Rename *_partition_map to part_*
2070
2071 * partmap/acorn.c (grub_acorn_partition_map): Set name to 'part_acorn'.
2072 * partmap/amiga.c (grub_amiga_partition_map): Set name to 'part_amiga'.
2073 * partmap/apple.c (grub_apple_partition_map): Set name to 'part_apple'.
2074 * partmap/gpt.c (grub_gpt_partition_map): Set name to 'part_gpt'.
2075 All users updated.
2076 * partmap/msdos.c (grub_msdos_partition_map): Set name to 'part_msdos'.
2077 All users updated.
2078 * partmap/sun.c (grub_sun_partition_map): Set name to 'part_sun'.
2079 * util/grub-probe.c (probe_partmap): Don't transform partition name
2080 to get module name.
2081
dd103c4e 20822009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2083
2084 Fix OpenBSD and NetBSD support.
2085
2086 * include/grub/i386/bsd.h (GRUB_BSD_TEMP_BUFFER): Change to resolve
2087 memory address conflict.
2088 (OPENBSD_MMAP_ACPI): New definition.
2089 (OPENBSD_MMAP_NVS): Likewise.
2090 * loader/i386/bsd.c (grub_openbsd_boot): Support OPENBSD_MMAP_ACPI
2091 and OPENBSD_MMAP_NVS.
2092 Add memory map terminator
2093 Explicit cast when calling grub_unix_real_boot.
ad8ea1f4 2094 (grub_netbsd_boot): Explicit cast when calling grub_unix_real_boot.
dd103c4e 2095
16c84d74 20962009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2097
2098 Let user specify NetBSD root device.
2099
2100 * loader/i386/bsd.c (netbsd_root): New variable.
2101 (netbsd_opts): New option 'root'.
2102 (NETBSD_ROOT_ARG): New macro.
2103 (grub_netbsd_boot): Use 'netbsd_root'.
2104 (grub_bsd_unload): Free 'netbsd_root'.
2105 (grub_cmd_netbsd): Fill 'netbsd_root'.
2106
adb29902 21072009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2108
2109 Support for 64-bit NetBSD.
2110
2111 * loader/i386/bsd.c (grub_bsd_load_elf): Apply correct mask to entry
2112 point when booting non-FreeBSD.
2113
f5ae9f74 21142009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2115
2116 Support --no-smp and --no-acpi for NetBSD.
2117
2118 * include/grub/i386/bsd.h (NETBSD_AB_NOSMP): New definition.
2119 (NETBSD_AB_NOACPI): Likewise.
2120 * loader/i386/bsd.c (netbsd_opts): New entries no-smp and no-acpi.
2121 (netbsd_flags): Add NETBSD_AB_NOSMP, NETBSD_AB_NOACPI.
2122
de74f136 21232009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2124
2125 * fs/hfsplus.c (grub_hfsplus_mount): Don't ignore grub_hfsplus_read_file
2126 errors.
2127 (grub_hfsplus_btree_iterate_node): Don't ignore grub_hfsplus_read_file
2128 errors. Call grub_error when needed.
2129
e9a925da 21302009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2131
2132 * commands/search.c (search_fs): Try searching without autoload first.
2133 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Load
2134 filesystem module explicitly for faster booting.
2135
5174302b 21362009-08-23 Colin Watson <cjwatson@ubuntu.com>
2137
2138 * util/grub-mkconfig.in: Export GRUB_DISABLE_OS_PROBER.
2139
c8c80635 21402009-08-23 Colin Watson <cjwatson@ubuntu.com>
2141
2142 * util/grub.d/30_os-prober.in: Disable os-prober if
2143 `GRUB_DISABLE_OS_PROBER' was set to true.
2144
71acf5e5 21452009-08-23 Robert Millan <rmh.grub@aybabtu.com>
2146
2147 * partmap/pc.c: Rename to ...
2148 * partmap/msdos.c: ... this. Update all users.
2149 (grub_pc_partition_map): Rename to ...
2150 (grub_msdos_partition_map): ... this. Update all users.
2151
2152 * parttool/pcpart.c: Rename to ...
2153 * parttool/msdospart.c: ... this. Update all users.
2154
2155 * include/grub/pc_partition.h: Rename to ...
2156 * include/grub/msdos_partition.h: ... this. Update all users.
2157 (grub_pc_partition_bsd_entry): Rename to ...
2158 (grub_msdos_partition_bsd_entry): ... this. Update all users.
2159 (grub_pc_partition_disk_label): Rename to ...
2160 (grub_msdos_partition_disk_label): ... this. Update all users.
2161 (grub_pc_partition_entry): Rename to ...
2162 (grub_msdos_partition_entry): ... this. Update all users.
2163 (grub_pc_partition_mbr): Rename to ...
2164 (grub_msdos_partition_mbr): ... this. Update all users.
2165 (grub_pc_partition): Rename to ...
2166 (grub_msdos_partition): ... this. Update all users.
2167 (grub_pc_partition_is_empty): Rename to ...
2168 (grub_msdos_partition_is_empty): ... this. Update all users.
2169 (grub_pc_partition_is_extended): Rename to ...
2170 (grub_msdos_partition_is_extended): ... this. Update all users.
2171 (grub_pc_partition_is_bsd): Rename to ...
2172 (grub_msdos_partition_is_bsd): ... this. Update all users.
2173
2174 * conf/common.rmk (amiga_mod_SOURCES, amiga_mod_CFLAGS)
2175 (amiga_mod_LDFLAGS, apple_mod_SOURCES, apple_mod_CFLAGS)
2176 (apple_mod_LDFLAGS, msdos_mod_SOURCES, msdos_mod_CFLAGS)
2177 (msdos_mod_LDFLAGS, sun_mod_SOURCES, sun_mod_CFLAGS)
2178 (sun_mod_LDFLAGS, acorn_mod_SOURCES, acorn_mod_CFLAGS)
2179 (acorn_mod_LDFLAGS, gpt_mod_SOURCES, gpt_mod_CFLAGS)
2180 (gpt_mod_LDFLAGS): Rename to ...
2181 (part_amiga_mod_SOURCES, part_amiga_mod_CFLAGS, part_amiga_mod_LDFLAGS)
2182 (part_apple_mod_SOURCES, part_apple_mod_CFLAGS, part_apple_mod_LDFLAGS)
2183 (part_msdos_mod_SOURCES, part_msdos_mod_CFLAGS, part_msdos_mod_LDFLAGS)
2184 (part_sun_mod_SOURCES, part_sun_mod_CFLAGS, part_sun_mod_LDFLAGS)
2185 (part_acorn_mod_SOURCES, part_acorn_mod_CFLAGS, part_acorn_mod_LDFLAGS)
2186 (part_gpt_mod_SOURCES, part_gpt_mod_CFLAGS)
2187 (part_gpt_mod_LDFLAGS): ... this.
2188 (pkglib_MODULES): Prefix partition modules with `part_'. Rename
2189 `pcpart.mod' to `msdospart.mod'.
2190 (pcpart_mod_SOURCES, pcpart_mod_CFLAGS, pcpart_mod_LDFLAGS): Rename
2191 to ...
2192 (msdospart_mod_SOURCES, msdospart_mod_CFLAGS)
2193 (msdospart_mod_LDFLAGS): ... this.
2194
c11fded5 21952009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2196
2197 * loader/i386/bsd.c (freebsd_opts): Rewritten to use extcmd.
2198 (openbsd_opts): Likewise.
2199 (netbsd_opts): Likewise.
2200 (freebsd_flags): Added 0 terminator.
2201 (openbsd_flags): Likewise.
2202 (netbsd_flags): Likewise.
2203 (grub_bsd_parse_flags): Rewritten to use extcmd. All users updated.
2204 (grub_cmd_freebsd): Transformed into extended command.
2205 (grub_cmd_openbsd): Likewise.
2206 (grub_cmd_netbsd): Likewise.
2207 (cmd_freebsd): Changed type to grub_extcmd_t.
2208 (cmd_openbsd): Likewise.
2209 (cmd_netbsd): Likewise.
2210 (GRUB_MOD_INIT (bsd)): Register grub_cmd_freebsd, grub_cmd_netbsd and
2211 grub_cmd_openbsd as extended commands.
2212 (GRUB_MOD_FINI (bsd)): Use grub_unregister_extcmd for cmd_freebsd,
2213 cmd_netbsd and cmd_openbsd
2214
11d1c769 22152009-08-22 Vladimir Serbinenko <phcoder@gmail.com>
2216
2217 * commands/xnu_uuid.c (transform): Use grub_memcpy instead of memcpy.
2218
7a9094e5 22192009-08-21 Pavel Roskin <proski@gnu.org>
2220
5496c37e 2221 * Makefile.in (install-local): When checking if a file is in the
2222 build directory, use "test -e" to detect symlinks.
2223
7a9094e5 2224 * Makefile.in (install-local): Remove all files in
2225 $(DESTDIR)$(pkglibdir) before installing new files there.
2226
e53cea11 22272009-08-18 Felix Zielcke <fzielcke@z-51.de>
2228
2229 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Use
2230 grub-mkelfimage.
2231
9aced544 22322009-08-18 Felix Zielcke <fzielcke@z-51.de>
2233
2234 * util/grub-mkconfig.in: Don't use gfxterm by default if not
2235 explicitly specified by the user.
2236
b7da6bab 22372009-08-18 Pavel Roskin <proski@gnu.org>
2238
2239 * include/grub/fbfill.h (struct grub_video_fbrender_target): Use
2240 grub_uint8_t pointer for data.
2241 * include/grub/fbutil.h (struct grub_video_fbblit_info):
2242 Likewise.
2243 * video/fb/fbutil.c: Remove unnecessary casts.
2244
19f1b335 22452009-08-17 Michal Suchanek <hramrach@centrum.cz>
2246
2247 VBE cleanup.
2248
2249 * video/i386/pc/vbe.c (vbe_mode_in_use): Removed (duplicate).
2250 (grub_vbe_set_video_mode): Save active mode info
2251 only after setting the mode.
2252 (grub_video_vbe_setup): Call 'grub_vbe_set_video_mode' with NULL as
2253 second argument.
2254
2f467aa9 22552009-08-17 Michal Suchanek <hramrach@centrum.cz>
2256
2257 Rename variables for clarity.
2258
2259 * video/i386/pc/vbe.c (active_mode_info): Renamed to ...
2260 (active_vbe_mode_info): ... this. All users updated.
2261 (framebuffer): Rename 'active_mode' to 'active_vbe_mode'.
2262 All users updated.
2263 (initial_mode): Rename to ...
2264 (initial_vbe_mode): ... this. All users updated.
2265 (mode_in_use): Rename to ..
2266 (vbe_mode_in_use): ... this. All users updated.
2267 (mode_list): Rename to ..
2268 (vbe_mode_list): ... this. All users updated.
2269 (grub_vbe_set_video_mode): Rename 'mode' to 'vbe_mode', 'mode_info' to
2270 'vbe_mode_info' and 'old_mode' to 'old_vbe_mode'.
2271 (grub_video_vbe_init): Rename 'rm_mode_list' to 'rm_vbe_mode_list' and
2272 'mode_list_size' to 'vbe_mode_list_size'.
2273 (grub_video_vbe_setup): Rename 'mode_info' to 'vbe_mode_info',
2274 'best_mode_info' to 'best_vbe_mode_info' and
2275 'best_mode' to 'best_vbe_mode'
2276
6025fcd7 22772009-08-17 Michal Suchanek <hramrach@centrum.cz>
2278
2279 Remove duplicate grub_video_fb_get_video_ptr.
2280
2281 * include/grub/fbutil.h (get_data_ptr): Rename to ...
2282 (grub_video_fb_get_video_ptr): ... this.
2283 * include/grub/video_fb.h (grub_video_fb_get_video_ptr): Removed.
2284 * video/fb/fbutil.c: Add comment about addressing.
2285 (get_data_ptr): Rename to ...
2286 (grub_video_fb_get_video_ptr): ... this. All users updated.
2287 * video/fb/video_fb.c (grub_video_fb_get_video_ptr): Remove.
2288
cc8c6faf 22892009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2290
2291 * fs/fat.c (grub_fat_read_data): Remove `#if 0' braces around the
2292 grub_dprintf() that was just added.
2293
08aa61f0 22942009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2295
2296 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT)
2297 (DEFAULT_VIDEO_MODE): Remove macros.
2298 (grub_linux_boot): Remove assumption that Linux has FB support,
2299 and use "text" as default video mode.
2300
7cef4f75 23012009-08-15 Vladimir Serbinenko <phcoder@gmail.com>
2302
2303 * fs/affs.c (grub_affs_read_symlink): Change leftover grub_printf into
2304 grub_dprintf.
2305 * fs/fat.c (grub_fat_read_data): Likewise.
2306
e1f39873 23072009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2308
2309 * loader/i386/multiboot.c (grub_multiboot): Don't pass filename to
2310 payload.
2311 (grub_module): Likewise.
2312
c166d79e 23132009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2314
2315 * loader/i386/multiboot.c (grub_multiboot_unload): Don't free mbi and
2316 mbi->cmdline but free playground.
2317
c60cee8e 23182009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2319
2320 Handle group offset on UFS1.
2321
2322 * fs/ufs.c (grub_ufs_sblock): New field 'cylg_mask'.
2323 (grub_ufs_read_inode) [!MODE_UFS2]: handle cylg_offset and cylg_mask.
2324
c0d8b5d4 23252009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2326
2327 Split ufs.mod into ufs1.mod and ufs2.mod.
2328
2329 * conf/common.rmk (grub_probe_SOURCES): Add fs/ufs2.c.
2330 (grub_fstest_SOURCES): Likewise.
2331 (pkglib_MODULES): Remove ufs.mod. Add ufs1.mod and ufs2.mod.
2332 (ufs_mod_SOURCES): Remove.
2333 (ufs_mod_CFLAGS): Likewise.
2334 (ufs_mod_LDFLAGS): Likewise.
2335 (ufs1_mod_SOURCES): New variable.
2336 (ufs1_mod_CFLAGS): Likewise.
2337 (ufs1_mod_LDFLAGS): Likewise.
25fbd77a 2338 (ufs2_mod_SOURCES): New variable.
2339 (ufs2_mod_CFLAGS): Likewise.
2340 (ufs2_mod_LDFLAGS): Likewise.
c0d8b5d4 2341 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add fs/ufs2.c.
2342 * conf/i386-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2343 Likewise.
2344 (grub_emu_SOURCES): Likewise.
2345 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2346 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2347 (grub_setup_SOURCES): Likewise.
2348 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2349 * conf/sparc64.rmk (grub_emu_SOURCES): Likewise.
2350 (grub_setup_SOURCES): Likewise.
2351 * conf/x86_64-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2352 Likewise.
2353 * fs/ufs2.c: New file.
2354 * fs/ufs.c: Separate UFS1 from UFS2 by using preprocessor.
2355
d3539132 23562009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2357
2358 Framebuffer split.
2359
2360 * commands/i386/pc/vbetest.c (grub_cmd_vbetest): Restore video
2361 subsystem at the end.
2362 * conf/common.rmk (pkglib_MODULES): Add video_fb.mod.
2363 (video_fb_mod_SOURCES): New variable.
2364 (video_fb_mod_CFLAGS): Likewise.
2365 (video_fb_mod_LDFLAGS): Likewise.
2366 * conf/i386-pc.rmk (vbe_mod_SOURCES): Remove video/i386/pc/vbeblit.c,
2367 video/i386/pc/vbefill.c and video/i386/pc/vbeutil.c.
2368 * video/i386/pc/vbeblit.c: Moved from here ...
2369 * video/fb/fbblit.c: ..here. Replaced 'vbe' with 'fb'.
2370 * video/i386/pc/vbefill.c: Moved from here ...
2371 * video/fb/fbfill.c: ..here. Replaced 'vbe' with 'fb'.
2372 * video/i386/pc/vbeutil.c: Moved from here ...
2373 * video/fb/fbutil.c: ..here. Replaced 'vbe' with 'fb'.
2374 * include/grub/i386/pc/vbeblit.h: Moved from here ...
2375 * include/grub/fbblit.h: ... here. Replaced 'vbe' with 'fb'.
2376 * include/grub/i386/pc/vbefill.h: Moved from here ...
2377 * include/grub/fbfill.h: ... here. Replaced 'vbe' with 'fb'.
2378 * include/grub/i386/pc/vbeutil.h: Moved from here ...
2379 * include/grub/fbutil.h: ... here. Replaced 'vbe' with 'fb'.
2380 * include/grub/i386/pc/vbe.h: Moved framebuffer part ...
2381 * include/grub/video_fb.h: ... here. Replaced 'vbe' with 'fb'.
2382 * include/grub/video.h (GRUB_VIDEO_RENDER_TARGET_FRONT_BUFFER): Removed.
2383 (GRUB_VIDEO_RENDER_TARGET_BACK_BUFFER): Likewise.
2384 (grub_video_adapter): Added 'get_info_and_fini'.
2385 (grub_video_get_info_and_fini): New prototype.
2386 (grub_video_set_mode): make modestring const char *.
2387 * loader/i386/linux.c (grub_linux_setup_video): Use
2388 grub_video_get_info_and_fini.
2389 (grub_linux_boot): Move modesetting just before booting.
2390 * loader/i386/pc/xnu.c (grub_xnu_set_video): Use
2391 grub_video_get_info_and_fini.
2392 * video/i386/pc/vbe.c: Moved framebuffer part ...
2393 * video/fb/video_fb.c: ... here. Replaced 'vbe' with 'fb'.
2394 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): Use
2395 grub_video_fbstd_colors and grub_video_fb_set_palette.
2396 (grub_video_vbe_init): Clear 'framebuffer' variable and use
2397 grub_video_fb_init.
2398 (grub_video_vbe_fini): Use grub_video_fb_fini.
2399 (grub_video_vbe_setup): Use framebuffer.render_target instead of
2400 render_target and use grub_video_fb_set_active_render_target and
2401 grub_video_fb_set_palette.
2402 (grub_video_vbe_set_palette): Use grub_video_fb_set_palette.
2403 (grub_video_vbe_set_viewport): Use grub_video_fb_set_viewport.
2404 (grub_video_vbe_adapter): Use framebuffer.
2405 * video/video.c (grub_video_get_info_and_fini): New function.
2406 (grub_video_set_mode): Make modestring const char *.
2407 (GRUB_MOD_INIT(video_video)): Don't set variables to 0 since these
2408 values are already initialised.
2409
d404ee56 24102009-08-14 Pavel Roskin <proski@gnu.org>
2411
2412 * boot/i386/pc/cdboot.S: Use LOCAL for local labels. Eliminate
2413 ABS and APPLE_CC.
2414 * boot/i386/pc/diskboot.S: Likewise.
2415 * boot/i386/pc/lnxboot.S: Likewise. Hardcode the number of code
2416 sectors allow compilation on MacOSX.
2417 * conf/i386-pc.rmk: Enable unconditional compilation of
2418 lnxboot.img.
2419
9a10df16 24202009-08-13 Colin Watson <cjwatson@ubuntu.com>
2421
2422 * util/grub-mkconfig.in: Export GRUB_HIDDEN_TIMEOUT.
2423 * util/grub.d/00_header.in: Enter interruptible sleep if
2424 GRUB_HIDDEN_TIMEOUT is set.
2425
be3c9ca7 24262009-08-13 Yves Blusseau <blusseau@zetam.org>
2427
2428 * include/grub/symbol.h: Add the LOCAL macro.
2429 * boot/i386/pc/boot.S: Use the LOCAL macro for all labels
2430 starting with "L_".
2431
1f9e557e 24322009-08-13 Pavel Roskin <proski@gnu.org>
2433
9ca62843 2434 * boot/i386/pc/boot.S: Remove ABS macro, it's not required by
2435 any modern compilers we support.
2436
1f9e557e 2437 * boot/i386/pc/boot.S: Remove all code dependent on APPLE_CC.
2438 Use local labels starting with "L_" so that Apple assembler
2439 knows they are local.
2440
81623db6 24412009-08-10 Robert Millan <rmh.grub@aybabtu.com>
2442
2443 * include/grub/i386/bsd.h (KERNEL_TYPE_NONE, KERNEL_TYPE_FREEBSD)
2444 (KERNEL_TYPE_OPENBSD, KERNEL_TYPE_NETBSD): Convert to ...
2445 (bsd_kernel_types): ... this enum.
2446
2447 * loader/i386/bsd.c (grub_cmd_freebsd_loadenv, grub_cmd_freebsd_module)
2448 (grub_cmd_freebsd_module_elf): Abort with "You need to load the
2449 kernel first." when `kernel_type' is set to KERNEL_TYPE_NONE.
2450
2451 (grub_bsd_load_aout, grub_bsd_load, grub_cmd_freebsd_loadenv)
2452 (grub_cmd_freebsd_module, grub_cmd_freebsd_module_elf)
2453 (GRUB_MOD_INIT (bsd)): Fix capitalization in a few error
2454 messages.
2455
f5d35e7a 24562009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2457
2458 * util/grub-dumpdevtree: Moved from here ...
2459 * util/i386/efi/grub-dumpdevtree: ... to here.
2460 (hexify): New function. Converts a string to its hex version.
2461 Generate hex versions of "efi" and "device-properties" by calling
2462 hexify() on the ASCII strings rather than by hardcoding numbers.
2463
d1e1d527 24642009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2465
2466 * fs/jfs.c: Update copyright year.
2467
1ebbe064 24682009-08-08 Felix Zielcke <fzielcke@z-51.de>
2469
2470 * util/grub.d/00_header.in: Fix a comment.
2471 * util/grub.d/10_linux.in: Likewise.
2472 * util/grub.d/10_windows.in: Likewise.
2473 * util/grub.d/10_hurd.in: Likewise.
2474
a78c8d24 24752009-08-08 Felix Zielcke <fzielcke@z-51.de>
2476
2477 * util/grub-mkconfig.in: Allow the user to specify the used font
2478 with GRUB_FONT.
2479
29a6b9e8 24802009-08-08 Pavel Roskin <proski@gnu.org>
2481
b5f16cc4 2482 * include/grub/powerpc/libgcc.h: Export __ashrdi3() if
2483 available, xfs.mod needs it now.
2484
2f5cb827 2485 * util/grub-mkconfig_lib.in (version_test_numeric): Don't use
2486 the "g" modifier in sed when the intention is to strip something
2487 once. This fixes comparison of kernels with multiple dashes.
2488
29a6b9e8 2489 * util/grub-mkconfig.in: Define datarootdir, datadir may depend
2490 on it. Add missing space before closing bracket. Fix
2491 misleading formatting.
2492
892a3d98 24932009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2494
2495 * docs/grub.texi: Major overhaul. Remove all sections that are
2496 specific to GRUB Legacy, or mostly composed of Legacy-specific
2497 information.
2498
ed94253f 24992009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2500
2501 * docs/version.texi: New file. Provides version information for
2502 grub.texi.
2503
126d6628 25042009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2505
2506 * docs/grub.texi: Update CVS information to SVN.
2507 Replace outdated "GRUB 2 will include" phrase with "GRUB 2 includes".
2508
998b5aa9 25092009-08-07 Felix Zielcke <fzielcke@z-51.de>
2510
2511 * util/grub-mkconfig.in: Remove a wrong `fi'.
2512
818e094a 25132009-08-07 Felix Zielcke <fzielcke@z-51.de>
2514
2515 * fs/uuid.c (grub_jfs_superblock): New fields unused2 and uuid.
2516 (grub_jfs_uuid): New function.
2517 (grub_jfs_fs): Set uuid field to grub_jfs_uuid.
2518
b969c52f 25192009-08-07 Felix Zielcke <fzielcke@z-51.de>
2520
2521 * util/grub-mkconfig_lib.in (font_path): Move the functionality
2522 of it to ...
2523 * util/grub-mkconfig.in: ... here. Prefer unicode.pf2 and
2524 unifont.pf2 over ascii.pf2. Export LANG=C in case ascii.pf2 gets used.
2525
7a4894cc 25262009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2527
2528 * util/grub.d/10_linux.in (test_numeric): Moved from here ...
2529 * util/grub-mkconfig_lib.in (version_test_numeric): ... to here.
2530 Update all users.
2531
2532 * util/grub.d/10_linux.in (test_gt): Strip any basename prefix,
2533 not just "vmlinu[zx]".
2534 Moved from here ...
2535 * util/grub-mkconfig_lib.in (version_test_gt): ... to here. Update
2536 all users.
2537
2538 * util/grub.d/10_linux.in (find_latest): Moved from here ...
2539 * util/grub-mkconfig_lib.in (version_find_latest): ... to here. Update
2540 all users.
2541
4e2171f8 25422009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2543
2544 * util/grub.d/10_freebsd.in: Use an absolute device path for
2545 `vfs.root.mountfrom'. Set `vfs.root.mountfrom.options=rw'.
2546
6dcfcb32 25472009-08-06 Felix Zielcke <fzielcke@z-51.de>
2548
2549 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Fix
2550 handling of multiple abstraction modules.
2551
f56a8756 25522009-08-04 Robert Millan <rmh.grub@aybabtu.com>
2553
2554 Fix a bug resulting in black screen when loading Linux using a
2555 packed video mode.
2556
2557 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette_width): New
2558 function.
2559
2560 * include/grub/i386/pc/vbe.h (GRUB_VBE_CAPABILITY_DACWIDTH): New macro.
2561 (grub_vbe_bios_getset_dac_palette_width): New function.
2562 (grub_vbe_bios_get_dac_palette_width)
2563 (grub_vbe_bios_set_dac_palette_width): New macros (act as wrappers for
2564 grub_vbe_bios_getset_dac_palette_width()).
2565
2566 * video/i386/pc/vbe.c (grub_vbe_probe): Use `GRUB_VBE_STATUS_OK' to
2567 check for return status.
2568 (grub_vbe_get_video_mode_info): When getting information for a packed
2569 mode (<= 8 bpp), obtain DAC palette width using
2570 grub_vbe_bios_getset_dac_palette_width(), and use that for initializing
2571 {red,green,blue}_mark_size.
2572
222671b2 25732009-08-04 Felix Zielcke <fzielcke@z-51.de>
2574
ecb1a6d9 2575 * commands/search.c (options): Fix help output to match actual code.
222671b2 2576
f84114f5 25772009-08-02 Vladimir Serbinenko <phcoder@gmail.com>
2578
2579 * commands/hexdump.c (grub_cmd_hexdump): Use grub_disk_read instead
2580 of homegrown code.
2581
bd288a20 25822009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
e768b770 2583
2584 * util/hostfs.c (grub_hostfs_dir): Don't use DT_DIR: It doesn't work
2585 on XFS or ReiserFS.
2586
8aab5e25 25872009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
2588
2589 Support Apple partition map with sector size different from 512 bytes.
2590
2591 * partmap/apple.c (grub_apple_header): New field 'blocksize'.
2592 (apple_partition_map_iterate): Respect 'aheader.blocksize'
2593 and 'apart.partmap_size'.
2594
6ad6258a 25952009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
25962009-08-01 Robert Millan <rmh.grub@aybabtu.com>
2597
2598 Fix cpuid command.
2599
2600 * commands/i386/cpuid.c (options): New variable.
2601 (grub_cmd_cpuid): Return real error.
2602 (GRUB_MOD_INIT(cpuid)): Declare options.
2603
67459bc6 26042009-07-31 Vladimir Serbinenko <phcoder@gmail.com>
2605
2606 * partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
2607 valid.
2608
fbc6ab54 26092009-07-31 Bean <bean123ch@gmail.com>
2610
2611 * fs/xfs.c (grub_xfs_sblock): Change unused5 field to log2_sect and
2612 log2_inode.
2613 (grub_fshelp_node): Move inode field to the end.
2614 (grub_xfs_data): Remove inode field.
2615 (grub_xfs_inode_block): Calculate inode size using sblock.
2616 (grub_xfs_inode_offset): Likewise.
2617 (grub_xfs_read_inode): Calculate inode size using sblock.
2618 (grub_xfs_read_block): Replace XFS_INODE_EXTENTS with nrec.
2619 (grub_xfs_iterate_dir): Calculate inode size using sblock.
2620 (grub_xfs_mount): Use grub_zalloc instead of grub_malloc. Realloc data
2621 to match inode size.
2622 (grub_xfs_dir): goto mount_fail when mount fails, as data->diropen is
2623 not accessible when data is null.
2624 (grub_xfs_open): Likewise.
2625
f45d6cfc 26262009-07-31 Bean <bean123ch@gmail.com>
2627
2628 * disk/lvm.c (grub_lvm_scan_device): Ignore extra copy of metadata.
2629 Don't change pv->disk if it's already set.
2630
2631 * disk/raid.c (grub_raid_scan_device): Merge this function into ...
2632 (grub_raid_register): ... here.
2633 (grub_raid_rescan): Removed.
2634
2635 * include/grub/raid.h (grub_raid_rescan): Removed.
2636
2637 * util/grub-fstest.c: Remove include file <grub/raid.h>.
2638 (fstest): Replace grub_raid_rescan with module fini function followed
2639 by init function.
2640
2641 * util/grub-probe.c: Add include file <grub/raid.h>.
2642 (probe_raid_level): New function.
2643 (probe): Detect abstraction by walking the disk device, support two
2644 level of abstraction (LVM on RAID) when detecting partition map.
2645
24443b5a 26462009-07-31 Pavel Roskin <proski@gnu.org>
2647
2648 * disk/raid5_recover.c (grub_raid5_recover): Revert conversion
2649 to grub_zalloc(), it was erroneous.
2650 Reported by Bean <bean123ch@gmail.com>
2651
a275d9e7 26522009-07-30 Vladimir Serbinenko <phcoder@gmail.com>
2653
2654 * util/i386/pc/grub-setup.c (setup): Check that no partition is in
ad8ea1f4 2655 embedding zone, not only the first one.
a275d9e7 2656
56c5a47f 26572009-07-29 Joe Auricchio <jauricchio@gmail.com>
2658
2659 * term/gfxterm.c (clear_char): New function.
2660 (grub_virtual_screen_setup): Use clear_char.
2661 (scroll_up): Likewise.
2662 (grub_virtual_screen_cls): Likewise.
2663
67bb323a 26642009-07-29 Felix Zielcke <fzielcke@z-51.de>
2665
2666 * util/deviceiter.c (get_acceleraid_disk_name): New static
2667 function.
2668 (grub_util_iterate_devices): Handle Accelraid devices.
2669 * util/hostdisk.c (convert_system_partition_to_system_disk): Likewise.
2670
388a7c75 26712009-07-28 Robert Millan <rmh.grub@aybabtu.com>
2672
2673 * loader/i386/linux.c (grub_cmd_linux): Use ',' rather than ';' as
2674 separator for the suggested gfxpayload string (';' collides with the
2675 parser and needs escaping).
2676
3bb7abcf 26772009-07-28 Vladimir Serbinenko <phcoder@gmail.com>
2678
2679 * loader/i386/multiboot_helper.S (grub_multiboot_backward_relocator):
2680 Clear direction flag before jumping to OS.
2681 (grub_multiboot2_real_boot): Likewise.
2682
2ddd36d7 26832009-07-28 Felix Zielcke <fzielcke@z-51.de>
2684
2685 * util/i386/pc/grub-install: Fix parsing of --disk-module
2686 option.
2687
c521b62b 26882009-07-28 Felix Zielcke <fzielcke@z-51.de>
2689
2690 * util/i386/pc/grub-setup.c (setup): Fix 2 incorrect checks
2691 when embedding.
2692
880e0a0c 26932009-07-26 Felix Zielcke <fzielcke@z-51.de>
2694
2695 * util/grub-mkconfig.in (package_version): New variable.
2696 Use it do display the version.
2697
2366e356 26982009-07-25 Felix Zielcke <fzielcke@z-51.de>
2699
2700 * kern/file.c (grub_file_open): Revert to previous check with
2701 grub_errno.
2702
7ad8c80e 27032009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2704
2705 * commands/probe.c (GRUB_MOD_INIT (probe)): Remove "[--target=target]"
2706 from help line. It's out of sync with code.
2707
72b9658b 27082009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2709
2710 * kern/parser.c (grub_parser_execute): Fix a bug causing truncated
2711 entries on failed boot.
2712
77435277 27132009-07-25 Felix Zielcke <fzielcke@z-51.de>
2714
2715 * kern/file.c (grub_file_open): Fix an error check.
2716
fcaa8b21 27172009-07-24 Vladimir Serbinenko <phcoder@gmail.com>
2718
35d16c74 2719 * util/i386/pc/grub-setup.c (setup): Fix segmentation fault when
2720 partition map couldn't be identified.
fcaa8b21 2721
48904cd1 27222009-07-23 Pavel Roskin <proski@gnu.org>
2723
ef3c317f 2724 * commands/xnu_uuid.c (transform): Use GRUB_CPU_WORDS_BIGENDIAN
2725 instead of WORDS_BIGENDIAN. Use grub_le_to_cpu32(), so that the
2726 case of little endian words becomes just an optimization.
2727 Respect const modifier.
ad8ea1f4 2728 (md5_final): Use code that doesn't depend on endianness.
ef3c317f 2729
48904cd1 2730 * include/grub/misc.h (ALIGN_UP): Cast align to the type of addr
2731 to avoid loss of upper bits if align is unsigned and shorter
2732 than addr.
2733
260c9a89 27342009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2735
2736 UUID support for UFS
2737
2738 * fs/ufs.c (grub_ufs_sblock): Add uuidhi and uuidlow.
2739 (grub_ufs_uuid): New function.
2740 (grub_ufs_fs): add .uuid
2741
f76ce889 27422009-07-21 Pavel Roskin <proski@gnu.org>
2743
2744 * kern/dl.c (grub_dl_check_header): Make static.
2745
6a6cbcaf 27462009-07-21 Felix Zielcke <fzielcke@z-51.de>
2747
2748 * util/grub.d/30_os-prober.in: Remove unused CHAINROOT. Don't
2749 add drivemap for Vista. It breaks Windows 7.
2750
cffcddb2 27512009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2752
2753 * fs/ufs.c (grub_ufs_sblock): Fix offset of mtime2 which was off by
2754 128 bytes
2755
1ef44b80 27562009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2757
2758 Add BFS support
2759
2760 * conf/common.rmk (grub_probe_SOURCES): Add fs/befs.c.
2761 (grub_fstest_SOURCES): Likewise.
2762 (pkglib_MODULES): Add befs.mod.
2763 (befs_mod_SOURCES): New variable.
2764 (befs_mod_CFLAGS): Likewise.
2765 (befs_mod_LDFLAGS): Likewise.
2766 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
2767 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2768 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2769 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2770 (grub_setup_SOURCES): Likewise.
2771 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2772 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2773 (grub_setup_SOURCES): Likewise.
2774 * fs/befs.c: New file.
2775 * fs/afs.c (GRUB_AFS_FSNAME): New declaration.
2776 (GRUB_AFS_SBLOCK_SECTOR): Likewise.
2777 (GRUB_AFS_SBLOCK_MAGIC1) [MODE_BFS]: New conditional declaration.
2778 (GRUB_AFS_BTREE_MAGIC) [MODE_BFS]: Likewise
2779 (B_KEY_INDEX_ALIGN): New declaration.
2780 (B_KEY_INDEX_OFFSET): Use B_KEY_INDEX_ALIGN.
2781 (grub_afs_bnode) [MODE_BFS]: Make key_count and key_size 16-bit
2782 (grub_afs_btree) [MODE_BFS]: New conditional declaration.
2783 (grub_afs_sblock) [MODE_BFS]: Remove link_count.
2784 (grub_afs_validate_sblock) [MODE_BFS]: Support BFS
2785 (grub_afs_mount) [MODE_BFS]: Likewise.
2786 (grub_afs_dir) [MODE_BFS]: Divide mtime by 65536 and not 1000000.
2787 (grub_afs_fs): Use GRUB_AFS_FSNAME
2788 (GRUB_MOD_INIT (afs)) [MODE_BFS]: Rename to ...
2789 (GRUB_MOD_INIT (befs)) [MODE_BFS]: ... this
2790 (GRUB_MOD_FINI (afs)) [MODE_BFS]: Rename to ...
2791 (GRUB_MOD_FINI (befs)) [MODE_BFS]: ... this
2792
4f253044 27932009-07-19 Yves BLUSSEAU <yves.grub-devel@zetam.org>
2794
2795 * util/getroot.c (find_root_device): Add support for MacOSX.
2796 * util/hostdisk.c: Likewise.
2797
57a55913 27982009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2799
2800 * font/font.c (find_glyph): Check whether a font is present to avoid
2801 segmentation fault.
75421ca9 2802
28032009-07-20 Joe Auricchio <jauricchio@gmail.com>
04c7c429 2804
2805 * term/gfxterm.c (grub_virtual_screen_setup): Clear virtual_screen.
2806
e98cd0c2 28072009-07-20 Pavel Roskin <proski@gnu.org>
2808
2809 * configure.ac: Trim excessively wordy excuses.
2810
1d2d169a 28112009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2812
2813 Add symlink, mtime and label support to AtheFS.
2814
2815 * fs/afs.c (grub_afs_sblock): Declare `name' as char.
2816 (grub_afs_iterate_dir): Handle symlinks.
2817 (grub_afs_open): Use grub_afs_read_symlink.
2818 (grub_afs_dir): Likewise.
2819 Pass mtime.
2820 (grub_afs_label): New function.
2821 (grub_afs_fs): Add grub_afs_label.
2822 (grub_afs_read_symlink): New function.
2823
186f3189 28242009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2825
2826 Fix AtheFS support.
2827
2828 * fs/afs.c: Fix comments style.
2829 (grub_afs_blockrun): Declare as packed.
2830 (grub_afs_datastream): Likewise.
2831 (grub_afs_bnode): Likewise.
2832 (grub_afs_btree): Likewise.
2833 (grub_afs_sblock): Likewise.
2834 Declare `name' as char.
2835 (grub_afs_inode): Declare as packed.
2836 Change void *vnode to grub_uint32_t unused.
2837 (grub_afs_iterate_dir): Check that key_size is positive.
2838 (grub_afs_mount): Don't read superblock twice.
75421ca9 2839 (grub_afs_dir): Don't free node in case of error,
186f3189 2840 grub_fshelp_find_file already handles this.
2841 (grub_afs_open): Likewise.
2842
5680109e 28432009-07-19 Pavel Roskin <proski@gnu.org>
2844
2845 * Makefile.in: Remove LIBLZO and enable_lzo.
2846 * conf/i386-pc.rmk: Remove lzo support.
2847 * configure.ac: Remove checks for lzo, don't define ENABLE_LZMA.
2848 * include/grub/i386/pc/kernel.h: Define ENABLE_LZMA. Remove lzo
2849 support.
2850 * kern/i386/pc/lzo1x.S: Remove.
2851 * kern/i386/pc/startup.S: Remove lzo support.
2852 * util/i386/pc/grub-mkimage.c: Likewise.
2853
ac70fa32 28542009-07-19 Vladimir Serbinenko <phcoder@gmail.com>
2855
2856 * disk/usbms.c (grub_usbms_transfer): Fix double semicolon.
2857 * fs/xfs.c (grub_xfs_dir): Likewise.
2858 * fs/afs.c (grub_afs_dir): Likewise.
2859 * fs/iso9660.c (grub_iso9660_iterate_dir): Likewise.
2860 (grub_iso9660_open): Likewise.
2861 * fs/jfs.c (grub_jfs_open): Likewise.
2862 * fs/ext2.c (grub_ext2_dir): Likewise.
2863 * include/grub/macho.h (grub_macho_fat_arch): Likewise.
2864 * script/sh/lexer.c (grub_script_yylex): Likewise.
75421ca9 2865
eab58da2 28662009-07-16 Pavel Roskin <proski@gnu.org>
2867
d2838156 2868 * configure.ac: Never add "-c" to CFLAGS.
2869
55c70904 2870 * configure.ac: Fix incorrect comparison for grub_cv_cc_efiemu.
2871
43e6200c 2872 * configure.ac: Fix wrong use of grub_cv_cc_no_red_zone where
2873 grub_cv_cc_efiemu should be used.
2874
ce7a733d 2875 * configure.ac: Typo fixes.
2876
eab58da2 2877 * kern/mm.c (grub_zalloc): New function.
2878 (grub_debug_zalloc): Likewise.
2879 * include/grub/mm.h: Declare grub_zalloc() and
2880 grub_debug_zalloc().
2881 * util/misc.c (grub_zalloc): New function.
2882 * bus/usb/uhci.c (grub_uhci_pci_iter): Use grub_zalloc()
2883 instead of grub_malloc(), remove unneeded initializations.
2884 * bus/usb/usbhub.c (grub_usb_hub_add_dev): Likewise.
2885 * commands/extcmd.c (grub_extcmd_dispatcher): Likewise.
2886 * commands/parttool.c (grub_cmd_parttool): Likewise.
2887 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Likewise.
2888 * disk/raid5_recover.c (grub_raid5_recover): Likewise.
2889 * disk/raid6_recover.c (grub_raid6_recover): Likewise.
2890 * disk/usbms.c (grub_usbms_finddevs): Likewise.
2891 * efiemu/mm.c (grub_efiemu_request_memalign): Likewise.
2892 * efiemu/pnvram.c (grub_efiemu_pnvram): Likewise.
2893 (grub_cmd_efiemu_pnvram): Likewise.
2894 * fs/i386/pc/pxe.c (grub_pxefs_open): Likewise.
2895 * fs/iso9660.c (grub_iso9660_mount): Likewise.
2896 (grub_iso9660_iterate_dir): Likewise.
2897 * fs/jfs.c (grub_jfs_opendir): Likewise.
2898 * fs/ntfs.c (list_file): Likewise.
2899 (grub_ntfs_mount): Likewise.
2900 * kern/disk.c (grub_disk_open): Likewise.
2901 * kern/dl.c (grub_dl_load_core): Likewise.
2902 * kern/elf.c (grub_elf_file): Likewise.
2903 * kern/env.c (grub_env_context_open): Likewise.
2904 (grub_env_set): Likewise.
2905 (grub_env_set_data_slot): Likewise.
2906 * kern/file.c (grub_file_open): Likewise.
2907 * kern/fs.c (grub_fs_blocklist_open): Likewise.
2908 * loader/i386/multiboot.c (grub_module): Likewise.
2909 * loader/xnu.c (grub_xnu_create_key): Likewise.
2910 (grub_xnu_create_value): Likewise.
2911 * normal/main.c (grub_normal_add_menu_entry): Likewise.
2912 (read_config_file): Likewise.
2913 * normal/menu_entry.c (make_screen): Likewise.
2914 * partmap/sun.c (sun_partition_map_iterate): Likewise.
2915 * script/sh/lexer.c (grub_script_lexer_init): Likewise.
2916 * script/sh/script.c (grub_script_parse): Likewise.
2917 * video/bitmap.c (grub_video_bitmap_create): Likewise.
2918 * video/readers/jpeg.c (grub_video_reader_jpeg): Likewise.
2919 * video/readers/png.c (grub_png_output_byte): Likewise.
2920 (grub_video_reader_png): Likewise.
2921
830afef7 29222009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
5ce5507f 2923
2924 Enable all targets that can be built by default
2925
830afef7 2926 * configure.ac: enable efiemu runtime, grub-emu, grub-emu-usb,
5ce5507f 2927 grub-mkfont and grub-fstest if they can be built
2928
ee293aee 29292009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2930
2931 Fix hang and segmentation fault in grub-emu-usb
2932
2933 * disk/scsi.c (grub_scsi_open): return err and not grub_errno
2934 * util/usb.c (grub_libusb_devices): likewise
2935 (grub_libusb_init): rename to ...
2936 (GRUB_MOD_INIT (libusb)):...this
2937 (grub_libusb_fini): rename to ..
2938 (GRUB_MOD_FINI (libusb)):...this
2939 * disk/usbms.c (grub_usbms_transfer): fix retry logic
2940 * include/grub/disk.h (grub_raid_init): removed, it's useless
2941 (grub_raid_fini): likewise
2942 (grub_lvm_init): likewise
2943 (grub_lvm_fini): likewise
2944 * util/grub-emu.c (main): don't call grub_libusb_init, it's done
2945 by grub_init_all
2946
94414221 29472009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2948
2949 Fix libusb
2950
2951 * Makefile.in (LIBUSB): new macro
2952 * genmk.rb (Utility/print_tail): new method
2953 (Utility/rule): use intermediary variable #{prefix}_OBJECTS
2954 (top level): call util.print_tail at the end.
2955
59ade63d 29562009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2957
2958 Make FreeBSD accept zpool.cache
2959
2960 * loader/i386/bsd.c (grub_freebsd_add_meta_module): spoof filename if
2961 type is /boot/zfs/zpool.cache
2962
a58da8c7 29632009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2964
2965 Fix 64-bit efiemu
2966
2967 * include/grub/efiemu/efiemu.h (grub_efiemu_configuration_table64_t):
2968 correct wrong typedef
2969 * efiemu/prepare.c (SUFFIX (grub_efiemu_prepare)): minor style fixes
2970
20591577 29712009-07-15 Pavel Roskin <proski@gnu.org>
2972
560ca572 2973 * include/grub/disk.h (struct grub_disk_dev): Use enum for id.
2974 * kern/disk.c (struct grub_disk_cache): Likewise.
2975
e8e8e4fd 2976 * commands/probe.c (options): Typo fix.
2977
fde24e10 2978 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_BPB_END):
2979 Increase to 0x5a to accommodate FAT32. Adjust other offsets
2980 accordingly.
2981 Original patch by Yves Blusseau <yves.grub-devel@zetam.org>
2982
379c54c1 2983 * boot/i386/pc/boot.S (general_error_string): Add DOS newline at
2984 the end of "Error" to make the message more readable.
2985
7bd8f5bf 2986 * boot/i386/pc/boot.S (kernel_segment): Remove.
2987 (copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
2988 for destination.
2989
40b132c5 2990 * boot/i386/pc/boot.S (boot_version): Remove.
2991 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
2992 Remove.
2993
20591577 2994 * include/grub/i386/pc/boot.h: Sort all offsets.
2995 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Remove, it's unused.
2996 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Likewise.
2997 * boot/i386/pc/boot.S: Assert location of every offset listed in
2998 include/grub/i386/pc/boot.h.
2999
2df32b2c 30002009-07-13 Pavel Roskin <proski@gnu.org>
3001
44b5d879 3002 * include/grub/i386/coreboot/machine.h: Rename
3003 GRUB_MACHINE_LINUXBIOS to GRUB_MACHINE_COREBOOT.
3004 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Allow
3005 multiboot 1 for GRUB_MACHINE_COREBOOT and GRUB_MACHINE_QEMU.
3006
17dc3751 3007 * kern/dl.c: Force native word size to suppress warnings when
3008 compiling grub-emu.
3009
2df32b2c 3010 * kern/device.c (grub_device_iterate): Change struct part_ent to
3011 hold the name, not a pointer to it. Use one grub_malloc() per
3012 partition, not two. Free partition_name if grub_malloc() fails.
3013 Set ents to NULL only before grub_partition_iterate() is called.
3014
75c59f59 30152009-07-11 Bean <bean123ch@gmail.com>
3016
3017 * kern/ieee1275/openfw.c (grub_children_iterate): Fix size of
3018 childname.
3019
0ae1bf88 30202009-07-10 Bean <bean123ch@gmail.com>
30212009-07-10 Robert Millan <rmh.grub@aybabtu.com>
3022
3023 * kern/ieee1275/openfw.c (grub_children_iterate)
3024 (grub_devalias_iterate): Fix size evaluation for property or path
3025 strings, which was broken since r2132.
3026
8279cade 30272009-07-07 Pavel Roskin <proski@gnu.org>
3028
7d8a52d3 3029 * commands/search.c (search_file): Merge into ...
3030 (search_fs): ... this. Accept search type as argument.
3031 (grub_cmd_search): Pass search type to search_fs().
3032
25f9a05a 3033 * include/grub/util/console.h: New file.
3034 * util/console.c: Use it instead of grub/machine/console.h.
3035 * util/grub-emu.c: Likewise.
3036
8279cade 3037 * lib/arg.c (find_long_option): Remove.
3038 (find_long): Add `len' argument, make `s' const char *.
3039 (grub_arg_parse): Parse long options in place, not in a
3040 temporary buffer.
3041
4a11b60f 30422009-07-06 Pavel Roskin <proski@gnu.org>
3043
99f68041 3044 * commands/search.c (search_fs): Fix potential NULL pointer
3045 dereference.
3046
4a11b60f 3047 * commands/search.c (search_fs): Replace QUID macro with quid_fn
3048 function pointer.
3049
e110f4de 30502009-07-06 Daniel Mierswa <impulze@impulze.org>
3051
3052 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
3053 comparison.
3054
46eeb6a2 30552009-07-05 Pavel Roskin <proski@gnu.org>
3056
bab74958 3057 * include/grub/i386/linux.h (struct linux_kernel_params):
3058 Restore padding3, it's still needed.
3059
46eeb6a2 3060 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
3061 FreeBSD.
3062 * util/osdetect.lua: Likewise.
3063
b4a1dc79 30642009-07-05 Bean <bean123ch@gmail.com>
3065
3066 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
3067
3068 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
3069 (grub_lua_getenv): Likewise.
3070 (grub_lua_setenv): Likewise.
3071 (save_errno): New function.
3072 (push_result): Likewise.
3073 (grub_lua_enum_device): Likewise.
3074 (grub_lua_enum_file): Likewise.
3075 (grub_lua_file_open): Likewise.
3076 (grub_lua_file_close): Likewise.
3077 (grub_lua_file_seek): Likewise.
3078 (grub_lua_file_read): Likewise.
3079 (grub_lua_file_getline): Likewise.
3080 (grub_lua_file_getsize): Likewise.
3081 (grub_lua_file_getpos): Likewise.
3082 (grub_lua_file_eof): Likewise.
3083 (grub_lua_file_exist): Likewise.
3084 (grub_lua_add_menu): Likewise.
3085
3086 * script/lua/grub_lua.h (isupper): New inline function.
3087 (islower): Likewise.
3088 (ispunct): Likewise.
3089 (isxdigit): Likewise.
3090 (strcspn): Change to normal function.
3091 (strpbkr): New function declaration.
3092 (memchr): Likewise.
3093
3094 * script/lua/grub_main.c (scan_str): New function.
3095 (strcspn): Likewise.
3096 (strpbrk): Likewise.
3097 (memchr): Likewise.
3098
3099 * script/lua/linit.c (lualibs): Enable the string library.
3100
3101 * util/osdetect.lua: New file.
3102
2da92295 31032009-07-04 Robert Millan <rmh.grub@aybabtu.com>
3104
3105 * include/grub/i386/linux.h (struct linux_kernel_params): Add
3106 `capabilities' member.
3107
b2582ec9 31082009-07-02 Pavel Roskin <proski@gnu.org>
3109
3110 * genparttoollist.sh: Add missing newline at the end.
3111
32622956 31122009-07-01 Pavel Roskin <proski@gnu.org>
3113
87a7339e 3114 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
3115
d23af54e 3116 * util/hostdisk.c (open_device): Remove `const' from
3117 `sysctl_size', as sysctlbyname() can change it (in this case it
3118 doesn't actually happen).
3119
c94b18a9 3120 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
3121 using signed long int constants.
3122
c6cd3ef0 3123 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
3124 constant to avoid a warning on FreeBSD.
3125
0df63420 3126 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
3127 where it's needed.
3128
999577f1 3129 * Makefile.in: Install include/grub/machine symlink.
3130
6f41557f 3131 * Makefile.in: When installing symlinks, use "cp -fR", which
3132 works on FreeBSD and MacOSX.
3133 From Yves Blusseau <cl7m42e02@sneakemail.com>
3134
c8d22988 3135 * kern/dl.c (grub_dl_resolve_symbol): Make static.
3136 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
3137
1b96e952 3138 * util/misc.c: Move grub_reboot() and grub_halt() ...
3139 * util/grub-emu.c: ... here. Make main_env static.
3140 * include/grub/util/misc.h: Remove main_env.
3141
2ef0084d 3142 * kern/mm.c: Use correct format to print size_t.
3143
32622956 3144 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
3145 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
3146 * kern/powerpc/dl.c: Likewise.
3147 * kern/sparc64/dl.c: Likewise.
3148 * kern/x86_64/dl.c: Likewise.
3149
3f7f0cd0 31502009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3151
3152 Fix grub-emu build on sparc64-ieee1275.
3153
75421ca9 3154 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Synchronize with ...
3f7f0cd0 3155 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
3156
211d06b5 31572009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3158
3159 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
3160 (grub_reboot, grub_halt): New functions.
3161
3162 * util/i386/pc/misc.c: Delete. Update all users.
3163 * util/sparc64/ieee1275/misc.c: Likewise.
3164 * util/powerpc/ieee1275/misc.c: Likewise.
3165
aaf53e3c 31662009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3167
3168 * conf/i386.rmk (setjmp_mod_SOURCES)
3169 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
3170 * conf/common.rmk (setjmp_mod_SOURCES)
3171 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
3172 to use $(target_cpu).
3173 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
3174 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
3175 * conf/powerpc-ieee1275.rmk: Likewise.
3176 * conf/sparc64-ieee1275.rmk: Likewise.
3177
3178 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
3179 $(target_cpu) for kern/$(target_cpu)/dl.c.
3180 * conf/i386-efi.rmk: Likewise.
3181 * conf/i386-ieee1275.rmk: Likewise.
3182 * conf/x86_64-efi.rmk: Likewise.
3183 * conf/i386-coreboot.rmk: Likewise.
3184 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
3185 $(target_cpu) for kern/$(target_cpu)/dl.c and for
3186 kern/$(target_cpu)/cache.S.
3187 * conf/sparc64-ieee1275.rmk: Likewise.
3188
a337130b 31892009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3190
3191 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
3192 type to `grub_uint8_t', and adjust `padding9' accordingly.
3193
c6fe4d53 31942009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3195
b09db61d 3196 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
3197
c6fe4d53 3198 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
3199 assembly in final jump, using register constraints.
3200
b09db61d 3201 (grub_linux_boot): For text mode, initialize `have_vga' using
3202 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
3203
3204 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
3205 right before the final jump.
3206
3207 Set `video_mode' to 0x3.
3208
3209 Document initialization of `video_page', `video_mode' and
3210 `video_ega_bx'.
3211
28333ad0 32122009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3213
3214 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
3215 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
75421ca9 3216 and set GRUB_LINUX_FLAG_QUIET appropriately.
28333ad0 3217
02164e1b 32182009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3219
3220 Fix build on Debian / sparc.
3221
3222 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
3223
18b6c557 32242009-06-28 Pavel Roskin <proski@gnu.org>
3225
85f2aab6 3226 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
3227 fix a warning.
3228
18b6c557 3229 * util/grub.d/10_linux.in: Match SUSE style initrd names.
3230
ad760f81 32312009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3232
3233 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
3234 `err'.
3235
87a4623b 32362009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3237
3238 Revert r2338.
3239
3240 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
3241 file can't be opened. grub_file_open() is already supposed to set
75421ca9 3242 grub_errno / grub_errmsg appropriately.
87a4623b 3243 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3244
8231fb77 32452009-06-27 Pavel Roskin <proski@gnu.org>
32462009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3247
3248 * include/grub/dl.h: Include grub/elf.h.
3249 (struct grub_dl): Add symtab field.
3250 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
3251 GRUB_MODULES_MACHINE_READONLY.
3252 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
3253 of the header for read-only modules.
3254 (grub_dl_unload): Free mod->symtab for read-only modules.
3255 * kern/i386/dl.c: Use mod->symtab.
3256 * kern/powerpc/dl.c: Likewise.
3257 * kern/sparc64/dl.c: Likewise.
3258 * kern/x86_64/dl.c: Likewise.
3259
3260 * conf/i386-qemu.rmk: New file.
3261 * kern/i386/qemu/startup.S: Likewise.
3262 * kern/i386/qemu/mmap.c: Likewise.
3263 * boot/i386/qemu/boot.S: Likewise.
3264 * include/grub/i386/qemu/time.h: Likewise.
3265 * include/grub/i386/qemu/serial.h: Likewise.
3266 * include/grub/i386/qemu/kernel.h: Likewise.
3267 * include/grub/i386/qemu/console.h: Likewise.
3268 * include/grub/i386/qemu/boot.h: Likewise.
3269 * include/grub/i386/qemu/init.h: Likewise.
3270 * include/grub/i386/qemu/machine.h: Likewise.
3271 * include/grub/i386/qemu/loader.h: Likewise.
3272 * include/grub/i386/qemu/memory.h: Likewise.
3273
3274 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
3275 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
3276 [qemu] (pkglib_IMAGES): Add `boot.img'.
3277 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
3278 [qemu] (boot_img_FORMAT): New variables.
3279 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
3280 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
3281 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
3282 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
3283 [qemu] (kernel_img_FORMAT): New variables.
3284
3285 * configure.ac: Recognise `i386-qemu'.
3286
3287 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
3288 (for no compression).
3289 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
3290 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
3291 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
3292 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
3293 ifdefs).
3294
97fe384e 32952009-06-27 Pavel Roskin <proski@gnu.org>
3296
3297 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
3298 read.
3299 * efiemu/prepare32.c: Likewise.
3300 * efiemu/prepare64.c: Likewise.
3301
c402ab17 33022009-06-26 Pavel Roskin <proski@gnu.org>
3303
3304 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
3305 * include/grub/elf.h: Define symbols without "32" or "64" based
3306 on GRUB_TARGET_WORDSIZE.
3307 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
3308 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
3309 ELF definitions.
3310 * efiemu/loadcore64.c: Likewise.
3311 * loader/i386/bsd32.c: Likewise.
3312 * loader/i386/bsd64.c: Likewise.
3313 * kern/dl.c: Remove own ELF definitions.
3314 * util/i386/efi/grub-mkimage.c: Likewise.
3315
9bbdfd4d 33162009-06-23 Robert Millan <rmh.grub@aybabtu.com>
3317
3318 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
3319 segment 0x0 unconditionally, because the reference generated by
3320 GAS is an absolute address.
3321
a42ce6e9 33222009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3323
3324 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
3325 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
3326
c952cf92 33272009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3328
3329 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
3330 indexes. Check for -f explicitly.
cc3752ad 3331 (search_file): Improve error message.
3332 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
c952cf92 3333
132a0a59 33342009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3335
3336 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
3337 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
3338
387a140c 33392009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3340
3341 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
3342 * conf/i386-ieee1275.rmk: Likewise.
3343 * conf/i386-coreboot.rmk: Likewise.
3344
3345 * kern/i386/pc/startup.S (grub_stop): Remove function.
3346 * kern/i386/ieee1275/startup.S: Likewise.
3347 * kern/i386/coreboot/startup.S: Likewise.
3348 * kern/i386/misc.S (grub_stop): New function.
3349
41da9665 33502009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3351
3352 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
3353 * kern/i386/realmode.S (real_to_prot): ... to here.
3354
bf337234 33552009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3356
3357 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
3358 with `kernel.img'.
3359 (kernel_elf_SOURCES): Rename to ...
3360 (kernel_img_SOURCES): ... this.
3361 (kernel_elf_HEADERS): Rename to ...
3362 (kernel_img_HEADERS): ... this. Update all users.
3363 (kernel_elf_ASFLAGS): Rename to ...
3364 (kernel_img_ASFLAGS): ... this.
3365 (kernel_elf_CFLAGS): Rename to ...
3366 (kernel_img_CFLAGS): ... this.
3367 (kernel_elf_LDFLAGS): Rename to ...
3368 (kernel_img_LDFLAGS): ... this.
3369 * conf/i386-coreboot.rmk: Likewise.
3370 * conf/powerpc-ieee1275.rmk: Likewise.
3371
3372 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
3373 with "kernel.img".
3374
f52196ff 33752009-06-21 Pavel Roskin <proski@gnu.org>
3376
c3cee413 3377 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
3378 to match nested functions.
3379 * loader/sparc64/ieee1275/linux.c: Likewise.
3380
f52196ff 3381 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
3382
58750afc 33832009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3384
3385 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
3386 all i386 platforms.
3387
15355c7d 33882009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3389
3390 Fix asm file handling on ELF, and remove workarounds.
3391
3392 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
75421ca9 3393 and -DASM_FILE=1 appropriately (copied from `class Images' stanza).
15355c7d 3394 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
3395 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
3396
3f3ec72b 33972009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
3398
3399 Load BSD ELF modules
3400
3401 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
3402 and loader/i386/bsd64.c
3403 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
3404 (FREEBSD_MODTYPE_ELF_MODULE): New definition
3405 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
3406 (grub_freebsd_load_elfmodule32): New declaration
3407 (grub_freebsd_load_elfmoduleobj64): Likewise
3408 (grub_freebsd_load_elf_meta32): Likewise
3409 (grub_freebsd_load_elf_meta64): Likewise
3410 (grub_freebsd_add_meta): Likewise
3411 (grub_freebsd_add_meta_module): Likewise
3412 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
3413 (grub_freebsd_add_meta_module): Likewise and move module-specific
3414 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
3415 (grub_cmd_freebsd): Add elf-kernel specific parts
3416 based on grub_freebsd_add_meta_module
3417 (grub_cmd_freebsd_module): Add type parsing moved from
3418 grub_freebsd_add_meta_module
3419 (grub_cmd_freebsd_module_elf): New function
3420 (cmd_freebsd_module_elf): New variable
3421 (GRUB_MOD_INIT): Register freebsd_module_elf
3422 * loader/i386/bsd32.c: New file
3423 * loader/i386/bsd64.c: Likewise
3424 * loader/i386/bsdXX.c: Likewise
3425 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
3426 (grub_elf64_load): Likewise
3427 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
3428 All users updated
3429 (grub_elf64_load_hook_t): Likewise
3430
0db15301 34312009-06-21 Colin Watson <cjwatson@ubuntu.com>
3432
3433 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
3434 variable.
3435 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
3436 don't write a menu entry for recovery mode.
3437
546796c1 34382009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3439
3440 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
3441 after it's no longer needed.
3442
cd7310d5 34432009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3444
3445 * include/grub/i386/loader.h (grub_linux_prot_size)
3446 (grub_linux_tmp_addr, grub_linux_real_addr)
3447 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
3448 GRUB_MACHINE_PCBIOS.
3449 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
3450 common grub_util_info() call to ...
3451 (generate_image): ... here.
3452 Fix use of uninitialized memory, comparison of signed with
3453 unsigned integers and memory leak.
3454 Remove bogus module address message.
3455
ab32d3b5 34562009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
3457
3458 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
3459 grub_raid_register
3460 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
3461
024ef597 34622009-06-19 Pavel Roskin <proski@gnu.org>
3463
3464 * configure.ac: Remove stray AC_MSG_CHECKING.
3465
3ac72b51 34662009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
3467
3468 * disk/scsi.c (grub_scsi_open): use continue instead of big if
dd74360c 3469
e14cd814 34702009-06-18 Pavel Roskin <proski@gnu.org>
3471
3472 * conf/common.rmk: Add fs_file.mod.
3473 * disk/fs_file.c: New file.
3474 * include/grub/disk.h (enum grub_disk_dev_id): Add
3475 GRUB_DISK_DEVICE_FILE_ID.
3476
26586d98 34772009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3478
3479 Fix build with Apple's toolchain. Part 2
3480
3481 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
3482 a fake start
3483
26de2bcd 34842009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3485
3486 Fix build with Apple's toolchain. Part 1
3487
3488 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
3489 for long calls
3490 * configure.ac: remove a leftover AC_MSG_RESULT
dd74360c 3491 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
26de2bcd 3492 Apple's toolchain
3493
09b3490b 34942009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3495
3496 Fix warnings
3497
3498 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
3499 (decomp_block): initialize ch
3500 use grub_memcpy instead of memcpy
3501
c22a006a 35022009-06-17 Pavel Roskin <proski@gnu.org>
3503
d3638678 3504 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
3505 version, use declarations needed to use vga_text as the startup
3506 console.
3507
c22a006a 3508 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
3509 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
3510 the kernel.
3511 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
3512 and grub_at_keyboard_fini(), it's done on module load and
3513 unload.
3514
05b129e0 35152009-06-17 Felix Zielcke <fzielcke@z-51.de>
3516
3517 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
3518 file can't be found.
3519 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3520
cf24ed9e 35212009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3522
3523 Fix newline handling
3524
3525 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
dd74360c 3526 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
cf24ed9e 3527 (grub_script_yylex): don't segfault on unterminated script
3528 newline terminates command and variable
3529
74aa8e4b 35302009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3531
3532 avoid double grub_adjust_range call. Bug reported by David Simner
3533
3534 * kern/disk.c (grub_disk_write): change to raw disk access before
3535 calling disk_read
3536
1bd265f3 35372009-06-17 Colin Watson <cjwatson@ubuntu.com>
3538
3539 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
3540 spaces, for the benefit of help2man.
3541 * util/i386/efi/grub-mkimage.c (usage): Likewise.
3542
a2d08c06 35432009-06-16 Pavel Roskin <proski@gnu.org>
3544
3545 * kern/i386/halt.c: Include grub/machine/init.h.
3546 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
3547
b97bcb19 35482009-06-16 Felix Zielcke <fzielcke@z-51.de>
3549
3550 * util/grub.d/30_os-prober.in: Use ${root} in the generated
3551 drivemap menuentry.
3552
0644f96c 35532009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
3554
3555 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
3556 `echo' command.
3557
3ef17a2e 35582009-06-16 Pavel Roskin <proski@gnu.org>
3559
3560 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
3561 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
3562 save %dx, we only need %dl and we never change it.
3563 * boot/i386/pc/cdboot.S: Don't set the root drive.
3564 * boot/i386/pc/pxeboot.S: Likewise.
3565 * include/grub/i386/pc/boot.h: Remove
3566 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
3567 GRUB_BOOT_MACHINE_DRIVE_CHECK.
3568 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
3569 * kern/i386/pc/init.c (make_install_device): Remove references
3570 to grub_root_drive.
3571 * kern/i386/pc/startup.S: Likewise.
3572 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
3573
693fe637 35742009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3575
3576 xnu_uuid command
3577
3578 * commands/xnu_uuid.c: new file
3579 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
3580 (xnu_uuid_mod_SOURCES): new variable
3581 (xnu_uuid_mod_CFLAGS): likewise
3582 (xnu_uuid_mod_LDFLAGS): likewise
3583 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3584 * conf/i386-ieee1275.rmk: likewise
3585 * conf/i386-pc.rmk: likewise
3586 * conf/powerpc-ieee1275.rmk: likewise
3587 * conf/sparc64-ieee1275.rmk: likewise
3588 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
3589
c9da87d0 35902009-06-16 Pavel Roskin <proski@gnu.org>
3591
3592 * configure.ac: Avoid '==' in test command, it's not portable.
3593
9c6f4596 35942009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3595
3596 Probe command
3597
3598 * commands/probe.c: new file
3599 * conf/common.rmk (pkglib_MODULES): add probe.mod
3600 (probe_mod_SOURCES): new variable
3601 (probe_mod_CFLAGS): likewise
3602 (probe_mod_LDFLAGS): likewise
3603 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3604 * conf/i386-ieee1275.rmk: likewise
3605 * conf/i386-pc.rmk: likewise
3606 * conf/powerpc-ieee1275.rmk: likewise
3607 * conf/sparc64-ieee1275.rmk: likewise
3608
70b7f9fd 36092009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
3610
3611 Fix handling of string like \"hello\" and "a
3612 b"
3613
3614 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
3615 (grub_script_yylex): fix parsing of quoting, escaping and newline
3616
71c79a6b 36172009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
3618
dd74360c 3619 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
71c79a6b 3620 handling
dd74360c 3621
0644f96c 36222009-06-13 Jun Inoue <jun.lambda@gmail.com>
880fc3c4 3623
3624 * util/grub-mkconfig.in: Fix parsing of --output option.
3625
e40893c3 36262009-06-12 Pavel Roskin <proski@gnu.org>
3627
3628 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
3629 genmk.rb don't need to be generated or installed.
3630
3a1acfe2 36312009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
3632
3633 * commands/i386/pc/drivemap_int13h.S: add more comments
3634
3a4575d4 36352009-06-11 Pavel Roskin <proski@gnu.org>
3636
0658e928 3637 * Makefile.in (uninstall): Uninstall manuals.
3638
ca0388f0 3639 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
3640 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
3641 and update-grub_lib in two places.
3642 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
3643
e3b27c39 3644 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
3645 a compiler warning.
3646
3a4575d4 3647 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
3648 `entry_lo' to fix variable shadowing.
3649
af1f4f55 36502009-06-11 Christian Franke <franke@computer.org>
3651
3652 * kern/misc.c (__enable_execute_stack): Add missing return type
3653 to prevent gcc warning.
3654
5225e649 36552009-06-11 Felix Zielcke <fzielcke@z-51.de>
3656
3657 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
3658
7d83bd47 36592009-06-11 Pavel Roskin <proski@gnu.org>
3660
c1cb63ba 3661 * Makefile.in: Don't rely on any scripts being executable.
3662 Always use $(SHELL) to run shell scripts.
3663
7d83bd47 3664 * configure.ac: Always define ___main if using -nostdlib. This
3665 fixes tests on Cygwin.
3666
948f48e7 36672009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
3668
3669 UDF fix
3670
7d83bd47 3671 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
948f48e7 3672 is in bytes and not in blocks
7d83bd47 3673
8ada9bc1 36742009-06-11 Pavel Roskin <proski@gnu.org>
3675
3676 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
3677 warning.
3678
25ad2323 36792009-06-11 Felix Zielcke <fzielcke@z-51.de>
3680
3681 * util/grub.d/30_os-prober.in: Fix a comment. Source
3682 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
3683 to set the root device. Place drivemap command in the generated
3684 chain entry.
3685
e65acb0c 36862009-06-11 Pavel Roskin <proski@gnu.org>
3687
3688 * configure.ac: Remove host_m32. Issues with 64-bit utilities
3689 have long been resolved.
3690
f285fe2d 36912009-06-11 Colin Watson <cjwatson@ubuntu.com>
3692
bd47b0b5 3693 * util/grub.d/10_linux.in: Capitalise "Linux".
3694
f285fe2d 3695 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
3696
a0c62e4e 36972009-06-11 Pavel Roskin <proski@gnu.org>
3698
b6783cb2 3699 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
3700 fix a gcc warning and ensure that the function won't ever exit.
3701
dde032e8 3702 * kern/i386/ieee1275/init.c: Add missing prototype for
3703 grub_stop_floppy().
3704
22cd079d 3705 * loader/ieee1275/multiboot2.c [__i386__]: Include
3706 grub/cpu/multiboot.h.
3707
a0c62e4e 3708 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
3709 casts to short - they are not portable and cause warnings. Fix
3710 use of uninitialized values in input_buf. Use ARRAY_SIZE.
3711
63963d17 37122009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
3713
3714 Drivemap fixes
3715
3716 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
3717 new function
3718 (grub_get_root_biosnumber_saved): new variable
3719 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
3720 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
775dbc4d 3721 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
63963d17 3722 %dx after the call if necessary
3723 * conf/common.rmk (pkglib_MODULES): remove boot.mod
3724 (boot_mod_SOURCES): remove
3725 (boot_mod_CFLAGS): remove
3726 (boot_mod_LDFLAGS): remove
3727 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
3728 (boot_mod_SOURCES): new variable
3729 (boot_mod_CFLAGS): likewise
3730 (boot_mod_LDFLAGS): likewise
3731 * conf/i386-efi.rmk: likewise
3732 * conf/i386-ieee1275.rmk: likewise
3733 * conf/i386-pc.rmk: likewise
3734 * conf/powerpc-ieee1275.rmk: likewise
3735 * conf/sparc64-ieee1275.rmk: likewise
3736 * conf/x86_64-efi.rmk: likewise
3737 * include/grub/i386/pc/biosnum.h: new file
3738 * lib/i386/pc/biosnum.c: likewise
3739 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
3740 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
3741 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
775dbc4d 3742
33abf7ae 37432009-06-10 Pavel Roskin <proski@gnu.org>
3744
5ac35b35 3745 * io/gzio.c (test_header): Don't reuse one buffer for all data.
3746 Use separate variables. Read only the file size at the end, but
3747 not the checksum that we don't use.
3748
5c5215d5 3749 * kern/file.c (grub_file_read): Use void pointer for the buffer.
3750 Adjust all callers.
3751
27d5fef7 3752 * kern/ieee1275/openfw.c: Remove libc includes.
3753 * kern/ieee1275/cmain.c: Likewise.
3754 * include/grub/ieee1275/ieee1275.h: Likewise.
3755
33abf7ae 3756 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
3757 compiler warnings.
3758
19d50c2b 37592009-06-10 Felix Zielcke <fzielcke@z-51.de>
3760
3761 * Makefile.in: Remove all trailing whitespace.
3762 * conf/i386-pc.rmk: Likewise.
3763 * conf/powerpc-ieee1275.rmk: Likewise.
3764 * conf/sparc64-ieee1275.rmk: Likewise.
3765 * docs/grub.texi: Likewise.
3766 * docs/texinfo.tex: Likewise.
3767 * disk/fs_uuid.c: Likewise.
3768 * disk/lvm.c: Likewise.
3769 * disk/scsi.c: Likewise.
3770 * disk/ata.c: Likewise.
3771 * disk/ieee1275/ofdisk.c: Likewise.
3772 * disk/i386/pc/biosdisk.c: Likewise.
3773 * disk/host.c: Likewise.
3774 * disk/raid.c: Likewise.
3775 * disk/efi/efidisk.c: Likewise.
3776 * disk/usbms.c: Likewise.
3777 * disk/memdisk.c: Likewise.
3778 * disk/loopback.c: Likewise.
3779 * kern/powerpc/dl.c: Likewise.
3780 * kern/device.c: Likewise.
3781 * kern/dl.c: Likewise.
3782 * kern/sparc64/dl.c: Likewise.
3783 * kern/ieee1275/ieee1275.c: Likewise.
3784 * kern/term.c: Likewise.
3785 * kern/fs.c: Likewise.
3786 * kern/i386/dl.c: Likewise.
3787 * kern/i386/pc/startup.S: Likewise.
3788 * kern/i386/pc/init.c: Likewise.
3789 * kern/i386/pc/mmap.c: Likewise.
3790 * kern/i386/pc/lzo1x.S: Likewise.
3791 * kern/i386/ieee1275/init.c: Likewise.
3792 * kern/i386/realmode.S: Likewise.
3793 * kern/i386/tsc.c: Likewise.
3794 * kern/partition.c: Likewise.
3795 * kern/corecmd.c: Likewise.
3796 * kern/file.c: Likewise.
3797 * kern/efi/efi.c: Likewise.
3798 * kern/efi/init.c: Likewise.
3799 * kern/efi/mm.c: Likewise.
3800 * kern/main.c: Likewise.
3801 * kern/err.c: Likewise.
3802 * kern/env.c: Likewise.
3803 * kern/disk.c: Likewise.
3804 * kern/generic/millisleep.c: Likewise.
3805 * kern/generic/rtc_get_time_ms.c: Likewise.
3806 * kern/misc.c: Likewise.
3807 * kern/parser.c: Likewise.
3808 * genmk.rb: Likewise.
3809 * configure.ac: Likewise.
3810 * boot/i386/pc/diskboot.S: Likewise.
3811 * boot/i386/pc/pxeboot.S: Likewise.
3812 * boot/i386/pc/boot.S: Likewise.
3813 * boot/i386/pc/lnxboot.S: Likewise.
3814 * boot/i386/pc/cdboot.S: Likewise.
3815 * parttool/pcpart.c: Likewise.
3816 * video/readers/tga.c: Likewise.
3817 * video/video.c: Likewise.
3818 * video/bitmap.c: Likewise.
3819 * lib/envblk.c: Likewise.
3820 * lib/i386/setjmp.S: Likewise.
3821 * fs/xfs.c: Likewise.
3822 * fs/afs.c: Likewise.
3823 * fs/fat.c: Likewise.
3824 * fs/ntfs.c: Likewise.
3825 * fs/udf.c: Likewise.
3826 * fs/affs.c: Likewise.
3827 * fs/iso9660.c: Likewise.
3828 * fs/hfs.c: Likewise.
3829 * fs/fshelp.c: Likewise.
3830 * fs/ext2.c: Likewise.
3831 * fs/jfs.c: Likewise.
3832 * fs/reiserfs.c: Likewise.
3833 * fs/hfsplus.c: Likewise.
3834 * fs/minix.c: Likewise.
3835 * fs/cpio.c: Likewise.
3836 * fs/sfs.c: Likewise.
3837 * fs/ufs.c: Likewise.
3838 * efiemu/prepare.c: Likewise.
3839 * efiemu/loadcore_common.c: Likewise.
3840 * efiemu/runtime/efiemu.sh: Likewise.
3841 * efiemu/runtime/efiemu.S: Likewise.
3842 * efiemu/runtime/efiemu.c: Likewise.
3843 * efiemu/pnvram.c: Likewise.
3844 * efiemu/main.c: Likewise.
3845 * efiemu/i386/pc/cfgtables.c: Likewise.
3846 * efiemu/i386/loadcore64.c: Likewise.
3847 * efiemu/i386/loadcore32.c: Likewise.
3848 * efiemu/loadcore.c: Likewise.
3849 * efiemu/symbols.c: Likewise.
3850 * efiemu/mm.c: Likewise.
3851 * include/grub/autoefi.h: Likewise.
3852 * include/grub/datetime.h: Likewise.
3853 * include/grub/term.h: Likewise.
3854 * include/grub/hfs.h: Likewise.
3855 * include/grub/lvm.h: Likewise.
3856 * include/grub/i386/tsc.h: Likewise.
3857 * include/grub/i386/linux.h: Likewise.
3858 * include/grub/i386/xnu.h: Likewise.
3859 * include/grub/i386/efiemu.h: Likewise.
3860 * include/grub/i386/pc/biosdisk.h: Likewise.
3861 * include/grub/i386/pc/memory.h: Likewise.
3862 * include/grub/i386/pc/vbe.h: Likewise.
3863 * include/grub/parttool.h: Likewise.
3864 * include/grub/video.h: Likewise.
3865 * include/grub/memory.h: Likewise.
3866 * include/grub/fs.h: Likewise.
3867 * include/grub/partition.h: Likewise.
3868 * include/grub/xnu.h: Likewise.
3869 * include/grub/efi/api.h: Likewise.
3870 * include/grub/efi/pe32.h: Likewise.
3871 * include/grub/efi/memory.h: Likewise.
3872 * include/grub/multiboot.h: Likewise.
3873 * include/grub/usbdesc.h: Likewise.
3874 * include/grub/multiboot2.h: Likewise.
3875 * include/grub/acpi.h: Likewise.
3876 * include/grub/efiemu/efiemu.h: Likewise.
3877 * include/grub/disk.h: Likewise.
3878 * include/grub/ieee1275/ieee1275.h: Likewise.
3879 * include/grub/net.h: Likewise.
3880 * include/grub/machoload.h: Likewise.
3881 * include/grub/macho.h: Likewise.
3882 * include/multiboot.h: Likewise.
3883 * genmoddep.awk: Likewise.
3884 * normal/main.c: Likewise.
3885 * normal/menu_entry.c: Likewise.
3886 * normal/menu_viewer.c: Likewise.
3887 * normal/completion.c: Likewise.
3888 * normal/cmdline.c: Likewise.
3889 * normal/misc.c: Likewise.
3890 * normal/datetime.c: Likewise.
3891 * bus/usb/usbtrans.c: Likewise.
3892 * bus/usb/ohci.c: Likewise.
3893 * bus/usb/uhci.c: Likewise.
3894 * bus/usb/usb.c: Likewise.
3895 * mmap/efi/mmap.c: Likewise.
3896 * mmap/i386/pc/mmap_helper.S: Likewise.
3897 * mmap/i386/pc/mmap.c: Likewise.
3898 * mmap/i386/mmap.c: Likewise.
3899 * mmap/i386/uppermem.c: Likewise.
3900 * mmap/mmap.c: Likewise.
3901 * commands/acpi.c: Likewise.
3902 * commands/echo.c: Likewise.
3903 * commands/blocklist.c: Likewise.
3904 * commands/loadenv.c: Likewise.
3905 * commands/usbtest.c: Likewise.
3906 * commands/boot.c: Likewise.
3907 * commands/parttool.c: Likewise.
3908 * commands/search.c: Likewise.
3909 * commands/cat.c: Likewise.
3910 * commands/i386/pc/play.c: Likewise.
3911 * commands/i386/pc/drivemap.c: Likewise.
3912 * commands/i386/pc/vbeinfo.c: Likewise.
3913 * commands/i386/pc/acpi.c: Likewise.
3914 * commands/i386/pc/vbetest.c: Likewise.
3915 * commands/ls.c: Likewise.
3916 * commands/cmp.c: Likewise.
3917 * commands/test.c: Likewise.
3918 * commands/efi/acpi.c: Likewise.
3919 * commands/gptsync.c: Likewise.
3920 * commands/help.c: Likewise.
3921 * partmap/amiga.c: Likewise.
3922 * partmap/apple.c: Likewise.
3923 * partmap/acorn.c: Likewise.
3924 * partmap/pc.c: Likewise.
3925 * partmap/sun.c: Likewise.
3926 * partmap/gpt.c: Likewise.
3927 * script/sh/lexer.c: Likewise.
3928 * script/sh/function.c: Likewise.
3929 * font/font.c: Likewise.
3930 * font/font_cmd.c: Likewise.
3931 * loader/powerpc/ieee1275/linux.c: Likewise.
3932 * loader/efi/chainloader.c: Likewise.
3933 * loader/multiboot_loader.c: Likewise.
3934 * loader/macho.c: Likewise.
3935 * loader/i386/multiboot.c: Likewise.
3936 * loader/i386/linux.c: Likewise.
3937 * loader/i386/pc/linux.c: Likewise.
3938 * loader/i386/pc/multiboot2.c: Likewise.
3939 * loader/i386/pc/chainloader.c: Likewise.
3940 * loader/i386/pc/xnu.c: Likewise.
3941 * loader/i386/bsd_trampoline.S: Likewise.
3942 * loader/i386/efi/linux.c: Likewise.
3943 * loader/i386/multiboot_elfxx.c: Likewise.
3944 * loader/i386/bsd_helper.S: Likewise.
3945 * loader/i386/bsd.c: Likewise.
3946 * loader/i386/linux_trampoline.S: Likewise.
3947 * loader/i386/xnu_helper.S: Likewise.
3948 * loader/i386/xnu.c: Likewise.
3949 * loader/i386/bsd_pagetable.c: Likewise.
3950 * loader/i386/multiboot_helper.S: Likewise.
3951 * loader/xnu.c: Likewise.
3952 * loader/xnu_resume.c: Likewise.
3953 * io/gzio.c: Likewise.
3954 * term/efi/console.c: Likewise.
3955 * term/terminfo.c: Likewise.
3956 * term/ieee1275/ofconsole.c: Likewise.
3957 * term/i386/pc/serial.c: Likewise.
3958 * term/i386/pc/vesafb.c: Likewise.
3959 * term/i386/pc/vga.c: Likewise.
3960 * term/usb_keyboard.c: Likewise.
3961 * term/gfxterm.c: Likewise.
3962 * aclocal.m4: Likewise.
3963 * util/lvm.c: Likewise.
3964 * util/grub.d/30_os-prober.in: Likewise.
3965 * util/grub.d/10_hurd.in: Likewise.
3966 * util/console.c: Likewise.
3967 * util/grub-macho2img.c: Likewise.
3968 * util/grub-probe.c: Likewise.
3969 * util/hostfs.c: Likewise.
3970 * util/i386/pc/grub-mkimage.c: Likewise.
3971 * util/i386/pc/grub-setup.c: Likewise.
3972 * util/i386/efi/grub-mkimage.c: Likewise.
3973 * util/grub-mkconfig.in: Likewise.
3974 * util/raid.c: Likewise.
3975 * util/resolve.c: Likewise.
3976 * util/grub-mkdevicemap.c: Likewise.
3977 * util/grub-emu.c: Likewise.
3978 * util/getroot.c: Likewise.
3979 * util/hostdisk.c: Likewise.
3980 * util/usb.c: Likewise.
3981 * util/grub-editenv.c: Likewise.
3982 * util/misc.c: Likewise.
3983
d2d49665 39842009-06-10 Felix Zielcke <fzielcke@z-51.de>
3985
3986 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
3987 `genparttoollist.sh'.
3988 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
3989 Add `*.sh' to the list find searches for and change `mdate.sh'
3990 to `mdate-sh'.
3991
fe052e37 39922009-06-10 Pavel Roskin <proski@gnu.org>
3993
2763ac18 3994 * include/grub/multiboot2.h: Provide compatibility defines for
3995 multiboot2.h.
3996 * include/multiboot2.h: Include stdint.h only if needed, using
3997 angle brackets.
3998 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
3999 grub/multiboot2.h.
4000 * loader/ieee1275/multiboot2.c: Likewise.
4001 * loader/multiboot2.c: Likewise.
4002 * loader/multiboot_loader.c: Likewise.
4003
437e6adc 4004 * configure.ac: Use -nostdlib when probing for the target. It
4005 should not be required to have libc for the target.
4006
06a6836c 4007 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
4008 they fail without libc headers for the target.
4009 * include/grub/powerpc/libgcc.h: Use weak attribute for all
4010 exports.
4011 * include/grub/sparc64/libgcc.h: Likewise. Don't use
4012 preprocessor conditionals.
4013
fe052e37 4014 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
4015 build system doesn't need to be aware of the tar.c internals.
4016
afd22553 40172009-06-09 Michel Hermier <michel.hermier@gmail.com>
87b8f28c 4018
afd22553 4019 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
8ec4a6d0 4020
6b787c4f 40212009-06-09 Robert Millan <rmh.grub@aybabtu.com>
4022
4023 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
4024 disk limit to 26 for IDE, Virtio, Xen and SCSI.
4025
40262009-06-09 Felix Zielcke <fzielcke@z-51.de>
4027
4028 * util/i386/pc/grub-install.in: Change the error message if UUIDs
473d1e45 4029 aren't available if ata.mod gets used.
6b787c4f 4030
473d1e45 40312009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
e23721e8 4032
473d1e45 4033 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
e23721e8 4034 initialising controller.
473d1e45 4035 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
e23721e8 4036
255a27d4 40372009-06-08 Felix Zielcke <fzielcke@z-51.de>
4038
4039 * util/i386/pc/grub-install.in: Add a parameter --disk-module
4040 to choose between ata and biosdisk module on i386-pc.
4041
473d1e45 40422009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
69da8877 4043
d55842d8 4044 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
4045 Subclass and Programming Interface fields in terms of the 3 byte
4046 Class Code register.
4047 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
4048
fa5db0b1 4049 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
4050 interface is OHCI. Add grub_dprintf for symmetry with
4051 bus/usb/uhci.c.
4052 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
4053 interface is UHCI. Add interf variable for programming
4054 interface. Print interface with class/subclass.
4055
c0947beb 4056 * bus/usb/ohci.c: Set interf with correct field.
4057
69da8877 4058 * bus/usb/uhci.c: Remove unneeded doubled lines.
4059 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
4060 Remove whitespace inside comment.
4061
9e172e30 40622009-06-08 Robert Millan <rmh.grub@aybabtu.com>
4063
4064 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
4065 as fallback an equivalent option without depth.
4066
de65ee2b 40672009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
4068
4069 Not fail if unable to retrieve C/H/S on LBA disks
4070
473d1e45 4071 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
de65ee2b 4072 if unable to retrieve C/H/S on LBA disks
4073
b57ea2c9 40742009-06-08 Pavel Roskin <proski@gnu.org>
4075
4076 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
4077 about aliasing.
4078
af361263 40792009-06-08 Felix Zielcke <fzielcke@z-51.de>
4080
4081 * Makefile.in (uninstall): Remove all $lib_DATA files.
4082
4c9ec6b3 40832009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
4084
4085 Bugfix: install on partitionless device
4086
4087 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
4088 is a whole disk
4089
e76fc924 40902009-06-08 Felix Zielcke <fzielcke@z-51.de>
4091
4092 * Makefile.in (uninstall): Remove all $include_DATA files.
4093
ba5a0d05 40942009-06-08 Felix Zielcke <fzielcke@z-51.de>
4095
4096 * commands/true.c: New file. Implement the true and false commands.
4097 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
4098 (true_mod_SOURCES): New variable.
4099 (true_mod_CFLAGS): Likewise.
4100 (true_mod_LDFLAGS): Likewise.
4101
c8048e32 41022009-06-05 Colin D Bennett <colin@gibibit.com>
4103
4104 Optimized font character lookup using binary search instead of linear
4105 search. Fonts now are required to have the character index ordered by
4106 code point.
4107
4108 * font/font.c (load_font_index): Verify that fonts have ordered
4109 character indices.
4110 (find_glyph): Use binary search instead of linear search to find a
4111 character in a font.
4112
408305be 41132009-06-05 Michael Scherer <misc@mandriva.org>
4114
4115 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
4116 uses case sensitive btree.
4117 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
4118 only for case insensitive filesystems.
4119
8ee1e0d9 41202009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
4121
4122 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
4123 * conf/common.rmk (search_mod_CFLAGS): likewise
4124
a9966eb1 41252009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4126
473d1e45 4127 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
a9966eb1 4128 compensate a compiler bug
4129
9e7100fb 41302009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4131
473d1e45 4132 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
9e7100fb 4133 instead of '\b'
473d1e45 4134
ede21d71 41352009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4136
4137 Definitions for creating asm symbols with Apple's CC
4138
4139 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
4140 [APPLE_CC] (VARIABLE): likewise
4141
9dbf7653 41422009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4143
4144 Disable lnxboot.img when compiled
4145 with Apple's CC
4146
4147 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
4148 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
4149 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
4150 [! APPLE_CC] (CODE_LENG): skip
4151 [! APPLE_CC] (setup_sects): likewise
4152 [! APPLE_CC]: skip filling
473d1e45 4153
e93cdc3d 41542009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4155
4156 Address in trampolines based on 32-bit registers when compiled
4157 with Apple's CC
4158
473d1e45 4159 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
e93cdc3d 4160 for addresses
4161 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
4162
6c688477 41632009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4164
4165 Avoid aliases when compiling with Apple's CC for PCBIOS machine
4166
4167 * kern/misc.c [APPLE_CC] (memcpy): new function
4168 [APPLE_CC] (memmove): likewise
4169 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
473d1e45 4170 (memcpy): define alias conditionally on !APPLE_CC
6c688477 4171 (memset): likewise
4172 (abort): likewise
4173 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
4174 APPLE_CC are defined
4175 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
4176 (grub_assert_fail): make prototype conditional
4177
e37ffc5c 41782009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4179
4180 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
4181
473d1e45 4182 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
4183 grub-macho2img
e37ffc5c 4184 (CLEANFILES): add grub-macho2img
4185 (grub_macho2img_SOURCES): new variable
4186 * kern/i386/pc/startup.S (bss_start): new variable
4187 (bss_end): likewise
4188 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
4189 * util/grub-macho2img.c: new file
4190
cf00df31 41912009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4192
4193 Use objconv when compiling with Apple's CC
4194
4195 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
4196 (efiemu64.o): likewise
4197 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
4198 when compiling with Apple's CC
4199 (efiemu64_s.o): likewise
4200 * configure.ac: check for objconv when compiling with Apple's CC
4201 * genmk.rb: use objconv for modules when compiled with Apple's CC
473d1e45 4202
d119a20c 42032009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4204
4205 Define segment as well as section when compiling with
4206 Apple's CC
4207
4208 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
4209 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
4210 (efiemu_convert_pointer): likewise
4211 (efiemu_set_virtual_address_map): likewise
4212 (efiemu_convert_pointer): likewise
4213 (efiemu_getcrc32): likewise
4214 (init_crc32_table): likewise
4215 (reflect): likewise
4216 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
4217 (GRUB_MOD_DEP): likewise
473d1e45 4218
c8600122 42192009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4220
4221 Allow a compilation without -mcmodel=large
4222
4223 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
4224 when compiled without -mcmodel=large
473d1e45 4225 (filter_memory_map): remove memory post 4 GiB when compiled
c8600122 4226 without -mcmodel=large
473d1e45 4227 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
c8600122 4228 TARGET_CFLAGS when -mcmodel=large isn't supported
473d1e45 4229
e8df1d4e 42302009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4231
4232 Remove nested functions in efiemu core
4233
4234 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
473d1e45 4235
cc6c3ac1 42362009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4237
4238 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
4239
4240 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
4241 temporary storage
473d1e45 4242 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
4243 using Apple's CC
cc6c3ac1 4244 (grub_cpu_is_tsc_supported): likewise
4245 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
473d1e45 4246
3e325901 42472009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4248
4249 Absolute addressing through constant with Apple's cc
4250
4251 * kern/i386/pc/startup.S: Define necessary constants
4252 and address through it when using ABS with Apple's CC
4253 * boot/i386/pc/diskboot.S: likewise
4254 * boot/i386/pc/boot.S: likewise
4255 * boot/i386/pc/lnxboot.S: likewise
4256 * boot/i386/pc/cdboot.S: likewise
4257 * mmap/i386/pc/mmap_helper.S: likewise
4258 * commands/i386/pc/drivemap_int13h.S: likewise
4259
2b167a72 42602009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4261
4262 Check if compiler is apple cc
4263
4264 * Makefile.in (ASFLAGS): new variable
4265 (TARGET_ASFLAGS): likewise
4266 (TARGET_MODULE_FORMAT): likewise
4267 (TARGET_APPLE_CC): likewise
4268 (OBJCONV): likewise
4269 (TARGET_IMG_CFLAGS): likewise
4270 (TARGET_CPPFLAGS): add includedir
4271 * configure.ac: call grub_apple_cc and grub_apple_target_cc
4272 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
4273 Check for linker script only if compiler isn't Apple's CC
4274 (TARGET_MODULE_FORMAT): set
4275 (TARGET_APPLE_CC): likewise
4276 (TARGET_ASFLAGS): likewise
4277 (ASFLAGS): likewise
4278 Check for objcopy only if compiler isn't Apple's CC
4279 Check for BSS symbol only if compiler isn't Apple's CC
4280 * genmk.rb: adapt nm options if we use Apple's utils
4281 * aclocal.m4 (grub_apple_cc): new test
4282 (grub_apple_target_cc): likewise
473d1e45 4283
fb14123e 42842009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4285
4286 Simplify sed expressions and improve awk
4287
4288 * Makefile.in (install-local): simplify sed expression
4289 * gencmdlist.sh: likewise
4290 * genmoddep.awk: avoid adding module as a dependency of itself
4291
5b889789 42922009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4293
4294 Add missing start symbols
4295
4296 * boot/i386/pc/boot.S: add start
fb14123e 4297 * boot/i386/pc/pxeboot.S: likewise
473d1e45 4298
fd2bf2e3 42992009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4300
4301 Fix wrong assumptions with grub-mkimage on EFI
473d1e45 4302
4303 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
fd2bf2e3 4304 (relocate_addresses): consider both r_addend and value at offset
4305 (make_mods_section): zerofill modinfo and header
4306 (convert_elf): write prefix here
473d1e45 4307
5389763d 43082009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4309
4310 Use .asciz instead of .string
4311
4312 * i386/pc/diskboot.S: use .asciz instead of .string
4313 * i386/pc/boot.S: likewise
4314 * include/grub/dl.h (GRUB_MOD_DEP): likewise
4315 (GRUB_MOD_NAME): likewise
473d1e45 4316
3eb5ed4e 43172009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4318
4319 gfxpayload support
4320
4321 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
4322 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
4323 (grub_video_setup): remove
4324 (grub_video_set_mode): new prototype
4325 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
4326 (vid_mode): remove
4327 (linux_vesafb_res): compile only on PCBIOS
4328 (grub_linux_boot): support gfxpayload
4329 * loader/i386/pc/xnu.c (video_hook): new function
4330 (grub_xnu_set_video): support gfxpayload
4331 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
4332 (DEFAULT_VIDEO_HEIGHT): likewise
4333 (DEFAULT_VIDEO_FLAGS): likewise
4334 (DEFAULT_VIDEO_MODE): new definition
4335 (video_hook): new function
4336 (grub_gfxterm_init): use grub_video_set_mode
473d1e45 4337 * util/grub.d/30_os-prober.in: remove explicit modesetting before
3eb5ed4e 4338 loading xnu
4339 * video/video.c (grub_video_setup): removed
473d1e45 4340 (grub_video_set_mode): new function based on grub_gfxterm_init and
3eb5ed4e 4341 grub_video_setup
4342
4b0e1143 43432009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4344
4345 Avoid calling biosdisk in drivemap
4346
4347 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
4348 (revparse_biosdisk): likewise
4349 (list_mappings): derive name from id directly
4350 (grub_cmd_drivemap): use tryparse_diskstring
473d1e45 4351
fda6cb98 43522009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4353
4354 Script fixes
4355
4356 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
4357 (grub_lexer_param): add tokenonhold
4358 (grub_script_create_cmdline): remove cmdline. All callers updated
4359 (grub_script_function_create): make functionname
4360 grub_script_arg. All callers updated
4361 (grub_script_execute_argument_to_string): new prototype
4362 * kern/parser.c (state_transitions): reorder
4363 (grub_parser_cmdline_state): fix a bug and make more compact
473d1e45 4364 * script/sh/execute.c (grub_script_execute_argument_to_string):
fda6cb98 4365 make global
4366 (grub_script_execute_cmdline): use new format
4367 * script/sh/function.c (grub_script_function_create): make functionname
4368 grub_script_arg. All callers updated
473d1e45 4369 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
fda6cb98 4370 (grub_script_yylex): remove
4371 (grub_script_yylex2): renamed to ...
4372 (grub_script_yylex): ...renamed
4373 parse the expressions like a${b}c
4374 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
4375 (GRUB_PARSER_TOKEN_VAR): remove
4376 (GRUB_PARSER_TOKEN_NAME): likewise
4377 ("if"): declare as typeless
4378 ("while"): likewise
4379 ("function"): likewise
4380 ("else"): likewise
4381 ("then"): likewise
4382 ("fi"): likewise
4383 (text): remove
4384 (argument): likewise
4385 (script): accept empty scripts and make exit on error
4386 (arguments): use GRUB_PARSER_TOKEN_ARG
4387 (function): likewise
4388 (command): move error handling to script
4389 (menuentry): move grub_script_lexer_ref before
473d1e45 4390 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
fda6cb98 4391 argument. All callers updated
4392
f4448a07 43932009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4394
4395 Prevent GRUB from probing floppies during boot.
4396
4397 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
4398 * commands/search.c (options): Add --no-floppy.
4399 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
4400 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
4401 --no-floppy when searching for UUIDs.
4402
2bf5885a 44032009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4404
4405 Simplify the code duplication in commands/search.c.
4406
4407 * commands/search.c (search_label, search_fs_uuid): Merge into ...
4408 (search_fs): ... this. Update all users.
4409
f6fd460a 44102009-06-03 Felix Zielcke <fzielcke@z-51.de>
4411
4412 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
4413
cbb3c83e 44142009-05-28 Pavel Roskin <proski@gnu.org>
4415
57788cfd 4416 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
4417 Remove the original symlink explicitly.
4418
cbb3c83e 4419 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
4420 just one slash. That's how grub_fshelp_find_file() does it.
4421
cd0d5e30 44222009-05-26 Pavel Roskin <proski@gnu.org>
4423
f0f8bbe2 4424 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
4425 to `str'.
4426
cd0d5e30 4427 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
4428 possibly unused.
4429
8c2cab51 44302009-05-25 Christian Franke <franke@computer.org>
4431
4432 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
4433 register.
4434 (grub_atapi_identify): Add wait after drive select.
4435 (grub_ata_identify): Do more strict status register check before
4436 calling grub_atapi_identify (). Suppress error message if status
4437 register is 0x00 after command failure. Add status register
4438 check after PIO read to avoid bogus identify due to stuck DRQ.
4439 Thanks to Pavel Roskin for testing.
4440 (grub_device_initialize): Remove unsafe status register check.
4441 Thanks to 'phcoder' for problem report and patch.
4442 Prevent sign extension in debug message.
4443
230c0ad6 44442009-05-23 Colin D Bennett <colin@gibibit.com>
4445
4446 Cleaned up `include/grub/normal.h'. Grouped prototypes by
4447 definition file, and functions defined in `normal/menu.c' have had
4448 their prototypes moved to `include/grub/menu.h' for consistency.
4449
4450 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
4451 from normal.h.
4452 (grub_menu_get_entry): Likewise.
4453 (grub_menu_get_timeout): Likewise.
4454 (grub_menu_set_timeout): Likewise.
4455 (grub_menu_execute_entry): Likewise.
4456 (grub_menu_execute_with_fallback): Likewise.
4457 (grub_menu_entry_run): Likewise.
4458
4459 * include/grub/normal.h: Re-ordered and grouped function
4460 prototypes by file that the function is defined in.
4461 (grub_menu_execute_callback): Removed; moved to menu.h.
4462 (grub_menu_get_entry): Likewise.
4463 (grub_menu_get_timeout): Likewise.
4464 (grub_menu_set_timeout): Likewise.
4465 (grub_menu_execute_entry): Likewise.
4466 (grub_menu_execute_with_fallback): Likewise.
4467 (grub_menu_entry_run): Likewise.
4468 (grub_menu_addentry): Renamed from this ...
4469 (grub_normal_add_menu_entry): ... to this.
4470
4471 * normal/main.c (grub_menu_addentry): Renamed from this ...
4472 (grub_normal_add_menu_entry): ... to this.
4473
4474 * script/sh/execute.c (grub_script_execute_menuentry): Update
4475 reference to renamed grub_menu_addentry function.
4476
861f03a5 44772009-05-23 Felix Zielcke <fzielcke@z-51.de>
4478
4479 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
4480
96b1619a 44812009-05-22 Pavel Roskin <proski@gnu.org>
4482
bf6a5fb2 4483 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
4484 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
4485 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
4486 compiling for the i386 targets, but not for the utilities.
4487
96b1619a 4488 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
4489 to grub_uint8_t.
4490 (grub_root_drive): Likewise.
4491 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
4492 remove alignment.
4493 (grub_root_drive): Change size to byte.
4494 (grub_start_addr): Remove.
4495 (grub_end_addr): Likewise.
4496 (grub_apm_bios_info): Likewise.
4497
b729776b 44982009-05-21 Felix Zielcke <fzielcke@z-51.de>
4499
4500 * normal/i386: Remove.
4501 * normal/powerpc: Likewise.
4502 * normal/sparc64: Likewise.
4503 * normal/x86_64: Likewise.
4504
0a15ce80 45052009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
4506
4507 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
473d1e45 4508 * loader/i386/linux_trampoline.S: Fix indentation
0a15ce80 4509 * loader/i386/xnu_helper.S: Likewise
d6da58e6 4510
33db9015 45112009-05-18 Colin D Bennett <colin@gibibit.com>
4512
d6da58e6 4513 Display error messages when parsing a Lua statement fails.
4514 Previously, executing a syntactically invalid statement like
4515 ")foo" or "bar;" would silently fail.
33db9015 4516
4517 * script/lua/grub_main.c (handle_lua_error): New function.
d6da58e6 4518 (grub_lua_parse_line): Improved reporting of Lua parser and
4519 execution errors.
33db9015 4520
46422c89 45212009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4522
4523 Remove -Werror which causes build to fail on some systems
4524
4525 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
4526 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
4527 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
18f547ad 4528
22f53a96 45292009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4530
4531 trampoline for linux on 64-bit platform
4532
18f547ad 4533 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
4534 loader/i386/efi/linux_trampoline.S
4535 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
473d1e45 4536 declaration
d6da58e6 4537 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
4538 here
22f53a96 4539 * loader/i386/linux_trampoline.S: moved here
d6da58e6 4540 * loader/i386/efi/linux.c (allocate_pages): reserve space for
4541 trampoline
22f53a96 4542 (jumpvector): removed
4543 (grub_linux_trampoline_start): new declaration
4544 (grub_linux_trampoline_end): likewise
4545 (grub_linux_boot): use trampoline when on 64-bit platform
4546 * loader/i386/linux.c: likewise
4547
cb5a0f40 45482009-05-16 Pavel Roskin <proski@gnu.org>
4549
4550 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
4551 const to avoid a warning.
4552 (grub_lua_setenv): Likewise.
4553 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
4554 lmsg to fix a warning.
4555
334f2c28 45562009-05-16 Felix Zielcke <fzielcke@z-51.de>
4557
4558 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
7dd10fce 4559 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4560 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
4561 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4562 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4563 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4564 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4565 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
334f2c28 4566
59e5d3ec 45672009-05-16 Felix Zielcke <fzielcke@z-51.de>
4568
4569 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
4570
9d87a1ba 45712009-05-16 Bean <bean123ch@gmail.com>
4572
4573 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
4574 (lua_mod_SOURCES): New variable.
4575 (lua_mod_CFLAGS): Likewise.
4576 (lua_mod_LDFLAGS): Likewise.
4577
4578 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
4579 (setjmp_mod_SOURCES): New variable.
4580 (setjmp_mod_CFLAGS): Likewise.
4581 (setjmp_LDFLAGS): Likewise.
4582
4583 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
4584 (setjmp_mod_SOURCES): New variable.
4585 (setjmp_mod_CFLAGS): Likewise.
4586 (setjmp_LDFLAGS): Likewise.
4587
4588 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4589 (setjmp_mod_SOURCES): New variable.
4590 (setjmp_mod_CFLAGS): Likewise.
4591 (setjmp_LDFLAGS): Likewise.
4592
4593 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4594 (setjmp_mod_SOURCES): New variable.
4595 (setjmp_mod_CFLAGS): Likewise.
4596 (setjmp_LDFLAGS): Likewise.
4597
4598 * normal/i386/setjmp.S: Moved from here ...
4599 * lib/i386/setjmp.S: ... Moved here
4600 * normal/x86_64/setjmp.S: Moved from here ...
4601 * lib/x86_64/setjmp.S: ... Moved here
4602 * normal/powerpc/setjmp.S: Moved from here ...
4603 * lib/powerpc/setjmp.S: ... Moved here
4604 * normal/sparc64/setjmp.S: Moved from here ...
4605 * lib/sparc64/setjmp.S: ... Moved here
4606
4607 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
4608 returns_twice in mingw.
4609
4610 * script/lua/grub_lib.c: New file.
4611 * script/lua/grub_lib.h: Likewise.
4612 * script/lua/grub_lua.h: Likewise.
4613 * script/lua/grub_main.c: Likewise.
4614 * script/lua/lapi.c: Likewise.
4615 * script/lua/lapi.h: Likewise.
4616 * script/lua/lauxlib.c: Likewise.
4617 * script/lua/lauxlib.h: Likewise.
4618 * script/lua/lbaselib.c: Likewise.
4619 * script/lua/lcode.c: Likewise.
4620 * script/lua/lcode.h: Likewise.
4621 * script/lua/ldblib.c: Likewise.
4622 * script/lua/ldebug.c: Likewise.
4623 * script/lua/ldebug.h: Likewise.
4624 * script/lua/ldo.c: Likewise.
4625 * script/lua/ldo.h: Likewise.
4626 * script/lua/ldump.c: Likewise.
4627 * script/lua/lfunc.c: Likewise.
4628 * script/lua/lfunc.h: Likewise.
4629 * script/lua/lgc.c: Likewise.
4630 * script/lua/lgc.h: Likewise.
4631 * script/lua/linit.c: Likewise.
4632 * script/lua/liolib.c: Likewise.
4633 * script/lua/llex.c: Likewise.
4634 * script/lua/llex.h: Likewise.
4635 * script/lua/llimits.h: Likewise.
4636 * script/lua/lmathlib.c: Likewise.
4637 * script/lua/lmem.c: Likewise.
4638 * script/lua/lmem.h: Likewise.
4639 * script/lua/loadlib.c: Likewise.
4640 * script/lua/lobject.c: Likewise.
4641 * script/lua/lobject.h: Likewise.
4642 * script/lua/lopcodes.c: Likewise.
4643 * script/lua/lopcodes.h: Likewise.
4644 * script/lua/loslib.c: Likewise.
4645 * script/lua/lparser.c: Likewise.
4646 * script/lua/lparser.h: Likewise.
4647 * script/lua/lstate.c: Likewise.
4648 * script/lua/lstate.h: Likewise.
4649 * script/lua/lstring.c: Likewise.
4650 * script/lua/lstring.h: Likewise.
4651 * script/lua/lstrlib.c: Likewise.
4652 * script/lua/ltable.c: Likewise.
4653 * script/lua/ltable.h: Likewise.
4654 * script/lua/ltablib.c: Likewise.
4655 * script/lua/ltm.c: Likewise.
4656 * script/lua/ltm.h: Likewise.
4657 * script/lua/lua.h: Likewise.
4658 * script/lua/luaconf.h: Likewise.
4659 * script/lua/lualib.h: Likewise.
4660 * script/lua/lundump.c: Likewise.
4661 * script/lua/lundump.h: Likewise.
4662 * script/lua/lvm.c: Likewise.
4663 * script/lua/lvm.h: Likewise.
4664 * script/lua/lzio.c: Likewise.
4665 * script/lua/lzio.h: Likewise.
4666
5e898c9d 46672009-05-16 Bean <bean123ch@gmail.com>
4668
4669 * include/grub/kernel.h (grub_module_header_types): Add type
4670 OBJ_TYPE_CONFIG.
4671
4672 * kern/main.c (grub_load_config): New function.
4673 (grub_main): Call grub_load_config to read boot config.
4674
4675 * grub-mkimage (generate_image): New parameter config_path.
4676 (options): New option --config.
4677 (main): Parse --config option, and pass it to generate_image.
4678
cf353a47 46792009-05-14 Christian Franke <franke@computer.org>
4680
4681 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
4682 This fixes build on Cygwin.
4683
3834887f 46842009-05-14 Pavel Roskin <proski@gnu.org>
4685
4686 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
4687 jump. This saves two bytes, so the typical case of 2 swapped
4688 drives would fit 32 bytes.
4689
8090fc01 46902009-05-13 Pavel Roskin <proski@gnu.org>
4691
ac963883 4692 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
4693 grub_uint32_t to avoid a warning.
4694
8090fc01 4695 * loader/i386/linux.c (allocate_pages): When assigning
4696 real_mode_mem, cast through grub_size_t to fix a warning. The
4697 code already makes sure that the value would fit a pointer.
4698 (grub_linux_setup_video): Cast render_target->data to
4699 grub_size_t to fix a warning.
4700
18f547ad 47012009-05-13 Javier Martín <lordhabbit@gmail.com>
4246b8a9 4702
4703 * commands/i386/pc/drivemap.c: New file - implement drivemap
4704 command.
4705 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
4706 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
4707
6f6a8b28 47082009-05-13 Pavel Roskin <proski@gnu.org>
4709
4710 * util/i386/pc/grub-setup.c (setup): Remove unused variable
4711 embedding_area_exists.
4712
15fbf4c4 47132009-05-13 Robert Millan <rmh.grub@aybabtu.com>
4714
4715 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
4716 it easier to understand / work with.
59978c8a 4717 Improve warning messages for cases where there's no embedding area,
4718 or when it is too small (or core.img too large).
15fbf4c4 4719
238e871f 47202009-05-13 Pavel Roskin <proski@gnu.org>
4721
0ab3a9a4 4722 * loader/i386/pc/multiboot2.c: Add necessary includes for
4723 grub_multiboot2_real_boot().
4724
a2c8c5f8 4725 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
4726 PX record is always little-endian. We only need the lower 2
4727 bytes of the mode.
4728
faec96af 4729 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
4730 facilitate code reuse.
4731 (grub_cpio_mount): Use "struct head", not a char buffer. This
4732 fixes a warning reported by gcc 4.4.
4733
238e871f 4734 * kernel/disk.c (grub_disk_read): Use void pointer for the
4735 buffer.
4736 (grub_disk_write): Use const void pointer for the buffer.
4737 Adjust all callers. Remove unnecessary casts.
4738
901d2f0c 47392009-05-10 Robert Millan <rmh.grub@aybabtu.com>
4740
4741 * util/i386/pc/grub-install.in: Update copyright year.
4742
18f547ad 47432009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
2eac4c16 4744
4745 gptsync
4746
4747 * commands/gptsync.c: new file
4748 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
4749 (gptsync_mod_SOURCES): new variable
4750 (gptsync_mod_CFLAGS): likewise
4751 (gptsync_mod_LDFLAGS): likewise
18f547ad 4752 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
2eac4c16 4753 new definition
4754 (GRUB_PC_PARTITION_TYPE_HFS): likewise
4755 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
4756 * conf/i386-ieee1275.rmk: likewise
4757 * conf/i386-pc.rmk: likewise
4758 * conf/powerpc-ieee1275.rmk: likewise
4759
b4ba690a 47602009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
4761
4762 Fixed grub-emu
4763
4764 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
4765 (grub_dl_ref): likewise
4766
317e1a44 47672009-05-08 Robert Millan <rmh.grub@aybabtu.com>
4768
4769 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
4770 split in two functions (one for msdos and one for gpt).
4771
041b8094 47722009-05-08 Pavel Roskin <proski@gnu.org>
4773
752473c2 4774 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
4775 not modified.
4776
041b8094 4777 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
4778 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
4779 Initialize them with -1. Add sanity check for bad1. Eliminate
4780 nerr variable.
4781
172800ce 47822009-05-08 David S. Miller <davem@davemloft.net>
4783
4784 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
4785
29aa5e81 47862009-05-06 Robert Millan <rmh.grub@aybabtu.com>
4787
4788 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
473d1e45 4789 existence.
29aa5e81 4790
96613b62 47912009-05-05 Felix Zielcke <fzielcke@z-51.de>
4792
4793 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
1905c57b 4794 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
96613b62 4795
eef73c8a 47962009-05-05 David S. Miller <davem@davemloft.net>
4797
4798 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
4799
119494b5 48002009-05-05 Pavel Roskin <proski@gnu.org>
4801
4802 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
4803 of grub_dl_ref() and grub_dl_unref().
4804 * commands/parttool.c: Remove preprocessor conditionals around
4805 grub_dl_ref() and grub_dl_unref().
4806 * fs/affs.c: Likewise.
4807 * fs/afs.c: Likewise.
4808 * fs/cpio.c: Likewise.
4809 * fs/ext2.c: Likewise.
4810 * fs/fat.c: Likewise.
4811 * fs/hfs.c: Likewise.
4812 * fs/hfsplus.c: Likewise.
4813 * fs/iso9660.c: Likewise.
4814 * fs/jfs.c: Likewise.
4815 * fs/minix.c: Likewise.
4816 * fs/ntfs.c: Likewise.
4817 * fs/reiserfs.c: Likewise.
4818 * fs/sfs.c: Likewise.
4819 * fs/udf.c: Likewise.
4820 * fs/ufs.c: Likewise.
4821 * fs/xfs.c: Likewise.
4822 * include/grub/dl.h: Likewise.
4823 * loader/xnu.c: Likewise.
4824
de5fd76e 48252009-05-04 Pavel Roskin <proski@gnu.org>
4826
4827 * commands/acpi.c: Remove unused variable my_mod.
4828 * partmap/amiga.c: Likewise.
4829 * partmap/apple.c: Likewise.
4830 * partmap/gpt.c: Likewise.
4831 * partmap/pc.c: Likewise.
4832 * partmap/sun.c: Likewise.
4833 * term/gfxterm.c: Likewise.
4834 * term/i386/pc/vesafb.c: Likewise.
4835 * term/i386/pc/vga.c: Likewise.
4836
983598ad 48372009-05-04 David S. Miller <davem@davemloft.net>
4838
4839 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
4840 pointer args to grub_ieee1275_get_property().
4841
8aadec43 4842 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
4843
9554b15e 4844 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
4845 devices, and do not traverse down under controller nodes.
4846
67e23c90 4847 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
4848 (grub_ofdisk_open): Use it to un-escape "," characters.
4849 * kern/disk.c (find_part_sep): New.
4850 (grub_disk_open): Use it to find the first non-escaped ','
4851 character in the disk name.
4852 * util/ieee1275/devicemap.c (escape_of_path): New.
4853 (grub_util_emit_devicemap_entry): Use it.
4854 * util/sparc64/ieee1275/grub-install.in: Update script to
4855 strip partition specifiers properly by not triggering on
4856 '\' escaped ',' characters.
4857
74bfdd2f 48582009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4859
4860 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
4861 to 0x300.
4862 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
4863 resolutions.
4864 (linux_vesafb_modes): Add a lot of additional modes to the list (based
4865 on documentation from Wikipedia).
4866
4241d2b1 48672009-05-04 Pavel Roskin <proski@gnu.org>
4868
4869 * disk/ata.c: Spelling fixes.
4870 * disk/raid.c: Likewise.
4871 * disk/usbms.c: Likewise.
4872 * disk/dmraid_nvidia.c: Likewise.
4873 * kern/ieee1275/openfw.c: Likewise.
4874 * kern/ieee1275/init.c: Likewise.
4875 * kern/ieee1275/cmain.c: Likewise.
4876 * boot/i386/pc/cdboot.S: Likewise.
4877 * video/readers/png.c: Likewise.
4878 * video/i386/pc/vbe.c: Likewise.
4879 * fs/udf.c: Likewise.
4880 * fs/hfs.c: Likewise.
4881 * fs/reiserfs.c: Likewise.
4882 * efiemu/runtime/efiemu.c: Likewise.
4883 * efiemu/main.c: Likewise.
4884 * efiemu/mm.c: Likewise.
4885 * include/grub/elf.h: Likewise.
4886 * include/grub/xnu.h: Likewise.
4887 * include/grub/usbdesc.h: Likewise.
4888 * include/grub/usb.h: Likewise.
4889 * include/grub/script_sh.h: Likewise.
4890 * include/grub/lib/LzmaEnc.h: Likewise.
4891 * include/grub/efiemu/efiemu.h: Likewise.
4892 * include/grub/command.h: Likewise.
4893 * normal/menu.c: Likewise.
4894 * normal/main.c: Likewise.
4895 * normal/datetime.c: Likewise.
4896 * bus/usb/uhci.c: Likewise.
4897 * mmap/i386/uppermem.c: Likewise.
4898 * mmap/mmap.c: Likewise.
4899 * commands/acpi.c: Likewise.
4900 * commands/test.c: Likewise.
4901 * partmap/apple.c: Likewise.
4902 * font/font.c: Likewise.
4903 * loader/sparc64/ieee1275/linux.c: Likewise.
4904 * loader/macho.c: Likewise.
4905 * loader/i386/bsd_trampoline.S: Likewise.
4906 * loader/i386/bsd.c: Likewise.
4907 * loader/xnu.c: Likewise.
4908 * term/i386/pc/vesafb.c: Likewise.
4909 * term/usb_keyboard.c: Likewise.
4910 * util/resolve.c: Likewise.
4911 * util/getroot.c: Likewise.
4912
0cfc0083 49132009-05-04 Felix Zielcke <fzielcke@z-51.de>
4914
4915 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
4916
7c1d00cd 49172009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4918
4919 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
4920 build error.
4921
b01f0548 49222009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4923
4924 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
4925 parameter only available on BIOS.
4926
ecc3eb22 49272009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4928
4929 Removed wrong semicolon in declaration
4930
4931 * grub/misc.h (grub_dprintf): remove semicolon
4932
112972a9 49332009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4934
4935 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
4936 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
4937 is done by grub_cmd_linux() now).
4938 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
4939 restore video to text mode.
4940 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
4941 indicates lack of "vga=" parameter. "vga=0" is mapped to
4942 `GRUB_LINUX_VID_MODE_NORMAL'.
4943
afd5c115 49442009-05-04 Felix Zielcke <fzielcke@z-51.de>
4945
4946 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
4947 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
4948 and `normal/script.c'. Add `kern/rescue_reader.c',
18f547ad 4949 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
afd5c115 4950 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
4951 `grub_script.tab.c'.
4952
4953 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4954 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4955 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4956 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
4957 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4958
faa517ce 4959 * Makefile.in: Remove duplicated 2008 in Copyright line.
4960
ae0c0bdc 49612009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4962
473d1e45 4963 * util/misc.c (grub_util_warn): New function. Emits a warning
ae0c0bdc 4964 unconditionally.
4965 * include/grub/util/misc.h (grub_util_warn): New declaration.
4966
4967 * util/i386/pc/grub-install.in: Understand --force and pass it down
4968 to grub-setup.
4969
4970 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
4971 down to setup().
4972 (setup): Improve error messages and add warnings when requested to
4973 install in odd layouts. Refuse to install using blocklists unless
4974 --force was set.
4975
18f547ad 49762009-05-04 martin f. krafft <madduck@madduck.net>
c149b500 4977
4978 * disk/raid.c (grub_raid_scan_device): Improve debug message.
4979
6d260daa 49802009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4981
4982 Updated copyright year
4983
4984 * fs/hfsplus.c: updated copyright year
18f547ad 4985
69f853f8 49862009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4987
4988 HFS+ UUID
4989
18f547ad 4990 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
69f853f8 4991 in the space previously used by unused3
4992 (grub_hfsplus_uuid): new function
4993 (grub_hfsplus_fs): added uuid field
4994
4c402e73 49952009-05-03 Pavel Roskin <proski@gnu.org>
4996
4997 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
4998 suppress warnings. It's no longer needed.
4999 * disk/host.c: Likewise.
5000 * disk/ata_pthru.c: Likewise.
5001 * disk/loopback.c: Likewise.
5002 * hook/datehook.c: Likewise.
5003 * parttool/pcpart.c: Likewise.
5004 * fs/i386/pc/pxe.c: Likewise.
5005 * fs/ntfscomp.c: Likewise.
5006 * efiemu/main.c: Likewise.
5007 * mmap/mmap.c: Likewise.
5008 * commands/crc.c: Likewise.
5009 * commands/hexdump.c: Likewise.
5010 * commands/hdparm.c: Likewise.
5011 * commands/acpi.c: Likewise.
5012 * commands/echo.c: Likewise.
5013 * commands/minicmd.c: Likewise.
5014 * commands/blocklist.c: Likewise.
5015 * commands/memrw.c: Likewise.
5016 * commands/loadenv.c: Likewise.
5017 * commands/usbtest.c: Likewise.
5018 * commands/lsmmap.c: Likewise.
5019 * commands/boot.c: Likewise.
5020 * commands/parttool.c: Likewise.
5021 * commands/configfile.c: Likewise.
5022 * commands/search.c: Likewise.
5023 * commands/ieee1275/suspend.c: Likewise.
5024 * commands/cat.c: Likewise.
5025 * commands/i386/pc/pxecmd.c: Likewise.
5026 * commands/i386/pc/play.c: Likewise.
5027 * commands/i386/pc/halt.c: Likewise.
5028 * commands/i386/pc/vbeinfo.c: Likewise.
5029 * commands/i386/pc/vbetest.c: Likewise.
5030 * commands/lspci.c: Likewise.
5031 * commands/date.c: Likewise.
5032 * commands/handler.c: Likewise.
5033 * commands/ls.c: Likewise.
5034 * commands/test.c: Likewise.
5035 * commands/cmp.c: Likewise.
5036 * commands/efi/loadbios.c: Likewise.
5037 * commands/efi/fixvideo.c: Likewise.
5038 * commands/halt.c: Likewise.
5039 * commands/help.c: Likewise.
5040 * commands/reboot.c: Likewise.
5041 * hello/hello.c: Likewise.
5042 * script/sh/main.c: Likewise.
5043 * loader/xnu.c: Likewise.
5044 * term/terminfo.c: Likewise.
5045 * term/i386/pc/serial.c: Likewise.
5046 * term/usb_keyboard.c: Likewise.
5047
515b5079 50482009-05-03 David S. Miller <davem@davemloft.net>
5049
5050 * normal/menu.c: Include grub/parser.h
5051
dfc31a22 50522009-05-03 Pavel Roskin <proski@gnu.org>
5053
2fee74f1 5054 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
5055 not char*.
5056 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
5057 Suggested by Javier Martín <lordhabbit@gmail.com>
5058
dfc31a22 5059 * util/i386/pc/grub-mkrescue.in: Allow for the case when
5060 efiemu??.o doesn't exist.
5061 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
5062 copying.
5063
18f547ad 50642009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
cef17233 5065
5066 FreeBSD 64-bit support
5067
18f547ad 5068 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
cef17233 5069 and loader/i386/bsd_trampoline.S
5070 (bsd_mod_ASFLAGS): new variable
5071 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
5072 (FREEBSD_MODTYPE_KERNEL64): likewise
5073 (grub_bsd64_trampoline_start): likewise
5074 (grub_bsd64_trampoline_end): likewise
5075 (grub_bsd64_trampoline_selfjump): likewise
5076 (grub_bsd64_trampoline_gdt): likewise
5077 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
5078 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
5079 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
5080 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
18f547ad 5081 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
cef17233 5082 of "attrib" member
5083 * loader/i386/bsd_pagetable.c: new file
5084 * loader/i386/bsd_trampoline.S: likewise
5085 * loader/i386/bsd.c (ALIGN_QWORD): new macro
5086 (ALIGN_VAR): likewise
5087 (entry_hi): new variable
5088 (kern_end_mdofs): likewise
5089 (is_64bit): likewise
5090 (grub_freebsd_add_meta): use ALIGN_VAR
5091 (grub_e820_mmap): new declaration
5092 (grub_freebsd_add_mmap): new function
5093 (grub_freebsd_add_meta_module): support 64 bit kernels
5094 (grub_freebsd_list_modules): use ALIGN_VAR
5095 (gdt_descriptor): new declaration
5096 (grub_freebsd_boot): support 64 bit kernels
5097 (grub_bsd_elf64_hook): new function
5098 (grub_bsd_load_elf): support elf64
5099
038c5720 51002009-05-03 Bean <bean123ch@gmail.com>
5101
5102 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
5103 after we get the result of if statement.
5104
fc45fb58 51052009-05-03 Bean <bean123ch@gmail.com>
5106
5107 * Makefile.in (enable_efiemu): New variable.
5108
5109 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
5110 set.
5111 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
5112 path.
5113 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
5114 path, add -mno-red-zone option.
5115 (efiemu64_s.o): Likewise.
5116 (efiemu64.o): Use macro $^ for source file.
5117
5118 * configure.ac (--enable-efiemu): New option.
5119
bbee0f2b 51202009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
5121
5122 xnu support
5123
5124 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
5125 (pkglib_MODULES): add xnu.mod
5126 (xnu_mod_SOURCES): new variable
5127 (xnu_mod_CFLAGS): likewise
5128 (xnu_mod_LDFLAGS): likewise
5129 (xnu_mod_ASFLAGS): likewise
5130 * conf/i386-pc.rmk: likewise
5131 * conf/x86_64-efi.rmk: likewise
7dd4a573 5132 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
bbee0f2b 5133 new declaration
5134 * include/grub/i386/macho.h: new file
5135 * include/grub/i386/xnu.h: likewise
5136 * include/grub/macho.h: likewise
5137 * include/grub/machoload.h: likewise
5138 * include/grub/x86_64/macho.h: likewise
5139 * include/grub/x86_64/xnu.h: likewise
5140 * include/grub/xnu.h: likewise
5141 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
5142 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
5143 * loader/i386/efi/xnu.c: new file
5144 * loader/i386/pc/xnu.c: likewise
5145 * loader/i386/xnu.c: likewise
5146 * loader/i386/xnu_helper.S: likewise
5147 * loader/macho.c: likewise
5148 * loader/xnu.c: likewise
5149 * loader/xnu_resume.c: likewise
5150 * util/grub-dumpdevtree: likewise
5151 * include/grub/i386/pit.h: include grub/err.h
5152 (grub_pit_wait): export
5153 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
7dd4a573 5154
5caf964d 51552009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5156
5157 Efiemu
7dd4a573 5158
5caf964d 5159 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
7dd4a573 5160 _linux_efi, linux_efi.
5161 new files in grub-emu
5caf964d 5162 new targets efiemu32.o and efiemu64.o
5163 * loader/linux_normal_efiemu.c: likewise
5164 * loader/i386/efi/linux.c: added preliminary efiemu support
7dd4a573 5165 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
5caf964d 5166 files to copy
5167 * include/grub/autoefi.h: new file
7dd4a573 5168 * include/grub/i386/efiemu.h: likewise
5caf964d 5169 * include/grub/i386/pc/efiemu.h: likewise
5170 * include/grub/efi/api.h: add LL suffix when necessary
5171 new definitions relating to tables
5172 * include/grub/efiemu/efiemu.h: new file
5173 * include/grub/efiemu/runtime.h: likewise
5174 * efiemu/prepare.c: likewise
5175 * efiemu/loadcore_common.c: likewise
5176 * efiemu/loadcore64.c: likewise
5177 * efiemu/runtime/efiemu.sh: likewise
5178 * efiemu/runtime/efiemu.S: likewise
5179 * efiemu/runtime/efiemu.c: likewise
5180 * efiemu/runtime/config.h: likewise
5181 * efiemu/prepare32.c: likewise
5182 * efiemu/main.c: likewise
5183 * efiemu/modules/pnvram.c: likewise
5184 * efiemu/modules/i386: likewise
5185 * efiemu/modules/i386/pc: likewise
5186 * efiemu/modules/acpi.c: likewise
5187 * efiemu/i386/pc/cfgtables.c: likewise
5188 * efiemu/i386/loadcore64.c: likewise
5189 * efiemu/i386/loadcore32.c: likewise
5190 * efiemu/prepare64.c: likewise
5191 * efiemu/loadcore.c: likewise
5192 * efiemu/symbols.c: likewise
5193 * efiemu/mm.c: likewise
5194 * efiemu/loadcore32.c: likewise
7dd4a573 5195
51962009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
f8efe3ad 5197
5198 ACPI spoofing
5199
5200 * commands/acpi.c: new file
5201 * commands/i386/pc/acpi.c: likewise
5202 * commands/efi/acpi.c: likewise
5203 * include/grub/acpi.h: likewise
5204 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
5205 (acpi_mod_SOURCES): new variable
5206 (acpi_mod_CFLAGS): likewise
5207 (acpi_mod_LDFLAGS): likewise
5208 * conf/i386-efi.rmk: likewise
5209 * conf/x86_64-efi.rmk: likewise
5210
7dd4a573 52112009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
28a85665 5212
5213 Missing part from mmap patch
5214
5215 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
5216 (grub_mmap_unregister)
5217 (grub_mmap_free_and_unregister): use grub_mmap_register
5218
7dd4a573 52192009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
09d842b9 5220
5221 Mmap services
5222
5223 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
5224 * loader/i386/linux.c (find_mmap_size): likewise
5225 (allocate_pages): likewise
5226 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
5227 (grub_fill_multiboot_mmap): likewise
5228 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
5229 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
5230 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
5231 (OPENBSD_MMAP_RESERVED): likewise
5232 * include/grub/i386/pc/memory.h: include grub/memory.h
5233 (grub_lower_mem): removed
5234 (grub_upper_mem): likewise
5235 (GRUB_MACHINE_MEMORY_ACPI): new definition
5236 (GRUB_MACHINE_MEMORY_NVS): likewise
5237 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
5238 (GRUB_MACHINE_MEMORY_HOLE): likewise
5239 (grub_machine_mmap_register): likewise
5240 (grub_machine_mmap_unregister): likewise
5241 (grub_machine_get_upper): likewise
5242 (grub_machine_get_lower): likewise
5243 (grub_machine_get_post64): likewise
5244 * include/grub/i386/efi/memory.h: new file
5245 * include/grub/x86_64/efi/memory.h: likewise
5246 * include/grub/efi/memory.h: likewise
5247 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
5248 (mmap_mod_SOURCES): new variable
5249 (mmap_mod_LDFLAGS): likewise
5250 (mmap_mod_ASFLAGS): likewise
5251 * conf/i386-coreboot.rmk: likewise
5252 * conf/i386-ieee1275.rmk: likewise
5253 * conf/i386-efi.rmk: likewise
5254 * conf/x86_64-efi.rmk: likewise
5255 * include/grub/types.h (UINT_TO_PTR): new macro
5256 (PTR_TO_UINT32): likewise
5257 (PTR_TO_UINT64): likewise
5258 * include/grub/memory.h: new file
5259 * mmap/i386/pc/mmap.c: likewise
5260 * mmap/i386/pc/mmap_helper.S: likewise
5261 * mmap/i386/uppermem.c: likewise
5262 * mmap/mmap.c: likewise
5263 * mmap/efi/mmap.c: likewise
7dd4a573 5264 * kern/i386/coreboot/init.c (grub_machine_init): don't use
09d842b9 5265 grub_upper_mem
5266 * kern/i386/pc/init.c (grub_lower_mem): removed variable
5267 (grub_upper_mem): likewise
5268 (grub_machine_init): don't use grub_upper_mem,
5269 make grub_lower_mem local
5270 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
5271 grub_mmap_iterate and grub_mmap_get_upper
5272 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
5273
d558e6b5 52742009-05-02 Bean <bean123ch@gmail.com>
5275
5276 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
5277 script/sh/parser.y.
5278 (pkglib_MODULES): Add normal.mod and sh.mod.
5279 (normal_SOURCES): New variable.
5280 (normal_mod_CFLAGS): Likewise.
5281 (normal_mod_LDFLAGS): Likewise.
5282 (sh_mod_SOURCES): Likewise.
5283 (sh_mod_CFLAGS): Likewise.
5284 (sh_mod_LDFLAGS): Likewise.
5285
5286 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
5287 script/sh/lexer.c_DEPENDENCIES.
5288 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
5289 kern/rescue_reader.c and kern/rescue_parser.c.
5290 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
5291 (grub_emu_SOURCES): Change source files.
5292 (pkglib_MODULES): Remove normal.mod.
5293 (normal_SOURCES): Removed.
5294 (normal_mod_CFLAGS): Likewise.
5295 (normal_mod_LDFLAGS): Likewise.
5296 * conf/i386-coreboot.rmk: Likewise.
5297 * conf/i386-efi.rmk: Likewise.
5298 * conf/i386-ieee1276.rmk: Likewise.
5299 * conf/powerpc-ieee1275.rmk: Likewise.
5300 * conf/sparc64-ieee1275.rmk: Likewise.
5301 * conf/x86_64-efi.rmk: Likewise.
5302
5303 * include/grub/command.h (grub_command_execute): New inline function.
5304
5305 * include/grub/menu.h (grub_menu_entry): Removed commands field.
5306
5307 * include/grub/normal.h: Remove <grub/setjmp.h>.
5308 (grub_fs_module_list): Moved to normal/autofs.c.
5309 (grub_exit_env): Removed.
5310 (grub_command_execute): Likewise.
5311 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
5312 parameter script.
5313 (read_command_list): New function declaration.
5314 (read_fs_list): Likewise.
5315
5316 * include/parser.h: Include <grub/reader.h>.
5317 (grub_parser_split_cmdline): Change type of getline parameter.
5318 (grub_parser): New structure.
5319 (grub_parser_class): New variable.
5320 (grub_parser_execute): New function declaration.
5321 (grub_register_rescue_parser): Likewise.
5322 (grub_parser_register): New inline function.
5323 (grub_parser_unregister): Likewise.
5324 (grub_parser_get_current): Likewise.
5325 (grub_parser_set_current): Likewise.
5326
5327 * include/grub/reader.h: New file.
5328 * kern/reader.c: Likewise.
5329 * kern/rescue_parser.c: Likewise.
5330 * kern/rescue_reader.c: Likewise.
5331 * normal/autofs.c: Likewise.
5332 * normal/dyncmd.c: Likewise.
5333
5334 * include/grub/rescue.h: Removed.
5335 * normal/command.h: Likewise.
5336
5337 * include/grub/script.h: Moved to ...
5338 * include/grub/script_sh.h: ... Moved here.
5339 * normal/execute.c: Moved to ...
5340 * script/sh/execute.c: ... Moved here.
5341 * normal/function.c: Moved to ...
5342 * script/sh/function.c: ... Moved here.
5343 * normal/lexer.c: Moved to ...
5344 * script/sh/lexer.c: ... Moved here.
5345 * normal/parser.y: Moved to ...
5346 * script/sh/parser.y: ... Moved here.
5347 * normal/script.c: Moved to ...
5348 * script/sh/script.c: ... Moved here.
5349
5350 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
5351 <grub/reader.h>.
5352 (grub_exit_env): Removed.
5353 (fs_module_list): Moved to normal/autofs.c.
5354 (grub_file_getline): Don't handle comment here.
5355 (free_menu): Skip removed field entry->commands.
5356 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
5357 script parameter.
5358 (read_config_file): Removed nested parameter, change getline function.
5359 (grub_enter_normal_mode): Removed.
5360 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
5361 (read_command_list): Likewise.
5362 (autoload_fs_module): Moved to normal/autofs.c.
5363 (read_fs_list): Likewise.
5364 (reader_nested): New variable.
5365 (grub_normal_execute): Run parser.sh to switch to sh parser.
5366 (grub_cmd_rescue): Removed.
5367 (cmd_normal): Removed.
5368 (grub_cmd_normal): Unregister itself at the beginning. Don't register
5369 rescue command.
5370 (grub_cmdline_run): New function.
5371 (grub_normal_reader_init): Likewise.
5372 (grub_normal_read_line): Likewise.
5373 (grub_env_write_pager): Likewise.
5374 (cmdline): New variable.
5375 (grub_normal_reader): Likewise.
5376 (GRUB_MOD_INIT): Register normal reader and set as current, register
5377 pager hook, register normal command with grub_register_command_prio,
5378 so that it won't show up in command.lst.
5379 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
5380 grub_fs_autoload_hook.
5381
5382 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
5383 (grub_menu_execute_entry): Replace grub_script_execute with
5384 grub_parser_execute, change parameter to grub_command_execute.
5385
5386 * normal/menu_text.c: Remove <grub/script.h>.
5387
5388 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
5389 and <grub/parser.h>.
5390 (run): Change editor_getline to use new parser interface. Change
5391 parameter to grub_command_execute.
5392
5393 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
5394 <grub/reader.h> and <grub/parser.h>.
5395 (grub_load_normal_mode): Execute normal command.
5396 (grub_main): Call grub_register_core_commands,
5397 grub_register_rescue_parser and grub_register_rescue_reader, use
5398 grub_reader_loop to enter input loop.
5399
7dd4a573 5400 * kern/parser.c (grub_parser_split_cmdline): Change type of
5401 getline parameter.
d558e6b5 5402 (grub_parser_class): New variable.
5403 (grub_parser_execute): New function.
5404
5405 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
5406 * loader/multiboot2.c: Likewise.
5407 * loader/sparc64/ieee1275/linux.c: Likewise.
5408
5409 * util/grub-emu.c (read_command_list): New dummy function.
5410
18db813d 54112009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5412
5413 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
5414 count to 16 for CCISS and IDA.
5415
6c67de15 54162009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5417
5418 * normal/menu_text.c (grub_wait_after_message): Print a newline
5419 after waiting for user input.
5420
5421 * loader/i386/linux.c: Include `<grub/normal.h>'.
5422 (grub_cmd_linux): Improve the error message about `ask' mode, by
5423 waiting for user input so it's not missed (we can do this, since
5424 user requested interaction).
5425
d9dc87b0 54262009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5427
5428 Added missing lst to grub-mkrescue
5429
5430 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
5431 and ${input_dir}/parttool.lst
5432
ac8a2baa 54332009-04-30 David S. Miller <davem@davemloft.net>
5434
ad22a610 5435 * util/hostdisk.c (device_is_wholedisk): New function.
5436 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
5437 zero only if device_is_wholedisk() returns true.
5438
6966215d 5439 * util/hostdisk.c (convert_system_partition_to_system_disk):
5440 Handle virtual disk devices named /dev/vdiskX as found on sparc
5441 and powerpc.
5442
ac8a2baa 5443 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
5444 lettered partition specifier is found, convert to numbered.
5445
979b4fb4 54462009-04-29 David S. Miller <davem@davemloft.net>
5447
e2bf39b2 5448 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
5449 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5450
3c64e104 5451 * normal/command.c: Add missing newline at end of file.
5452
979b4fb4 5453 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
5454 warnings.
5455 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
5456 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
5457 grub_ofdisk_read): Likewise, and deal similarly with the fact that
5458 ihandles have a 32-bit type but need to be stored in a "void *".
5459
136d9f82 54602009-04-28 Pavel Roskin <proski@gnu.org>
5461
9459c306 5462 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
5463 not disk. Adjust all dependencies.
2e08a26a 5464 (grub_fs_uuid_close): Use grub_device_close(), not
9459c306 5465 grub_disk_close().
5466
136d9f82 5467 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
5468 parent's partition, don't copy it by reference, as it gets freed
5469 on close.
5470
7dd4a573 54712009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
75a807cf 5472
5473 Preboot hooks support
5474
5475 * commands/boot.c (struct grub_preboot_t): new declaration
5476 (preboots_head): new variable
5477 (preboots_tail): likewise
5478 (grub_loader_register_preboot_hook): new function
5479 (grub_loader_unregister_preboot_hook): likewise
5480 (grub_loader_set): launch preboot hooks
5481 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
5482 (grub_loader_register_preboot_hook): new declaration
5483 (grub_loader_unregister_preboot_hook): likewise
5484
5af922b5 54852009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
5486
5487 Warning fix
5488
7dd4a573 5489 * disk/scsi.c (grub_scsi_open): added missing cast when
5af922b5 5490 calling grub_dprintf
5491
a5562c30 54922009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
5493
5494 Bug and warning fixes
5495
7dd4a573 5496 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
a5562c30 5497 declaration
5498 * commands/test.c (test_parse): fixed bug with file tests and corrected
5499 declaration of find_file
5500
4006f85c 55012009-04-26 Pavel Roskin <proski@gnu.org>
5502
5503 * Makefile.in: Don't install empty manual pages if help2man is
5504 missing. Use help2man option for output, not shell redirection.
5505
5c77c3de 55062009-04-26 David S. Miller <davem@davemloft.net>
5507
5508 * util/grub-mkdevicemap.c (make_device_map): Add missing
5509 NESTED_FUNC_ATTR to process_device().
5510
033b10a8 55112009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5512
5513 Test command
5514
5515 * commands/test.c: rewritten to use bash-like test
5516
e4343593 55172009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5518
5519 Parttool autoloading and improvements
5520
7dd4a573 5521 * Makefile.in (pkglib_DATA): add parttool.lst
e4343593 5522 (parttool.lst): new target
5523 * genmk.rb: generate parttool-*
5524 (CLEANFILES): add #{parttool}
5525 (PARTTOOLFILES): new variable
5526 * genparttoollist.sh: new file
7dd4a573 5527 * parttool/pcpart.c (grub_pcpart_boot): more feedback
e4343593 5528 (grub_pcpart_type): likewise
5529 * commands/parttool.c (helpmsg): new variable
5530 (grub_cmd_parttool): output help if not enough arguments are supplied
5531 autoload modules
5532 (GRUB_MOD_INIT(parttool)): use helpmsg
5533
0d312500 55342009-04-24 David S. Miller <davem@davemloft.net>
5535
7dd4a573 5536 Avoiding opening same device multiple times in device iterator.
0d312500 5537
5538 * kern/device.c: (grub_device_iterate): Define struct part_ent,
7dd4a573 5539 and use it to build a list of partitions in iterate_disk() and
0d312500 5540 iterate_partition().
5541
ac20caff 5542 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
5543 on disk->data.
5544
0dcf7495 5545 * disk/ieee1275/nand.c (grub_nand_iterate): Return
5546 grub_devalias_iterate() result instead of unconditional 0.
5547 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
5548 Also, capture hook return value, either directly or via
5549 grub_children_iterate(), and propagate to caller.
5550 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
5551 grub_children_iterate): Return value is now 'int' instead of
5552 'grub_err_t'.
5553 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
5554 like a proper iterator, stopping when hooks return non-zero.
5555 (grub_devalias_iterate): Likewise.
5556
c8c08833 55572009-04-23 David S. Miller <davem@davemloft.net>
5558
5559 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
5560
f01005a8 55612009-04-22 David S. Miller <davem@davemloft.net>
5562
5563 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
5564 is larger than address_cells, use that value for address_cells too.
5565
4e8269da 5566 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
5567 IEEE1275_MAX_PATH_LEN): Define.
5568 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
5569 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
5570 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
5571 'devtype'. Explicitly NULL terminate devalias expansion.
5572
a1447506 5573 * util/sparc64/ieee1275/misc.c: New file.
5574 * util/sparc64/ieee1275/grub-setup.c: New file.
5575 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
5576 * util/sparc64/ieee1275/grub-mkimage.c: New file.
5577 * util/sparc64/ieee1275/grub-install.in: New file.
5578 * util/ieee1275/ofpath.c: New file.
5579 * util/ieee1275/devicemap.c: New file.
5580 * util/devicemap.c: New file.
5581 * util/deviceiter.c: New file.
5582 * kern/sparc64/ieee1275/init.c: New file.
5583 * include/grub/util/ofpath.h: New file.
5584 * include/grub/util/deviceiter.h: New file.
5585 * util/grub-mkdevicemap.c: Include deviceiter.h.
5586 Implement using grub_util_emit_devicemap_entry and
5587 grub_util_iterate_devices.
5588 * conf/i386-corebook.rmk: Build util/deviceiter.c and
5589 util/devicemap.c into grub-mkdevicemap
5590 * conf/i386-efi.rmk: Likewise.
5591 * conf/i386-ieee1275.rmk: Likewise.
5592 * conf/i386-pc.rmk: Likewise.
5593 * conf/powerpc-ieee1275.rmk: Likewise.
5594 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
5595 images and installation utilities. Build kernel as image
5596 instead of as elf binary. Use common rules as much as possible.
5597
7dd4a573 55982009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
0aefc632 5599
5600 Correct GPT definition
5601
7dd4a573 5602 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
0aefc632 5603 of "attrib" member
5604
c6c5219f 56052009-04-19 Felix Zielcke <fzielcke@z-51.de>
5606
5607 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
5608
0552ff9f 56092009-04-19 David S. Miller <davem@davemloft.net>
5610
5611 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
5612 (grub_rescue_cmd_linux): Rename to...
5613 (grub_cmd_linux): and fix prototype.
5614 (grub_rescue_cmd_initrd): Rename to...
5615 (grub_cmd_initrd): and fix prototype.
5616 (cmd_linux, cmd_initrd): New.
5617 (GRUB_MOD_INIT(linux)): Use grub_register_command().
5618 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
5619
d1a282fc 56202009-04-17 Pavel Roskin <proski@gnu.org>
5621
07c5039f 5622 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
5623 format.
5624 (grub_ohci_transfer): Likewise.
5625
b012002d 5626 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
5627
1bc09c35 5628 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
5629 return without a value. Fix inconsistent indentation.
5630
e0ff9126 5631 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
5632 match struct grub_fs.
5633
d1a282fc 5634 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
5635 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
5636 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
5637 * commands/lspci.c (grub_lspci_iter): Likewise.
5638
a96df3f2 56392009-04-16 Bean <bean123ch@gmail.com>
5640
5641 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
5642 value.
5643
41bb0fe9 56442009-04-15 Pavel Roskin <proski@gnu.org>
5645
5646 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
5647 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
5648 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
5649 definitions.
5650
596c6970 56512009-04-15 Felix Zielcke <fzielcke@z-51.de>
5652
5653 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
7dd4a573 5654 that no multiple data or metadata areas are supported and `Unknown
596c6970 5655 metadata header'.
5656
7dd4a573 56572009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
0d5d5653 5658
5659 Move loader out of the kernel
5660
5661 * kern/loader.c: moved to ...
5662 * commands/boot.c: ... moved here
5663 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
5664 * commands/boot.c (grub_cmd_boot): moved here. All users updated
5665 * include/grub/kernel.h (grub_machine_fini): export
5666 * include/grub/loader.h (grub_loader_is_loaded): update declaration
5667 (grub_loader_set): likewise
5668 (grub_loader_unset): likewise
5669 (grub_loader_boot): likewise
5670 * conf/common.rmk: new module boot.mod
5671 (pkglib_MODULES): add boot.mod
5672 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
5673 (grub_emu_SOURCES): likewise
5674 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
5675 (grub_emu_SOURCES): likewise
5676 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
5677 (grub_emu_SOURCES): likewise
5678 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
5679 (grub_emu_SOURCES): likewise
5680 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
5681 (grub_emu_SOURCES): likewise
7dd4a573 5682 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
5683 (grub_emu_SOURCES): likewise
0d5d5653 5684 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
7dd4a573 5685 (grub_emu_SOURCES): likewise
0d5d5653 5686
7dd4a573 56872009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
5999d619 5688
5689 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
7dd4a573 5690
5999d619 5691 * kern/misc.c (grub_itoa): Removed function
5692 (grub_ltoa): likewise
5693 (grub_vsprintf): use grub_lltoa
5694
7dd4a573 56952009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
13c00781 5696
5697 Restore grub-emu
5698
5699 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
5700 * conf/i386-coreboot.rmk: likewise
5701 * conf/i386-ieee1275.rmk: likewise
5702 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 5703
20318222 57042009-04-15 Felix Zielcke <fzielcke@z-51.de>
5705
5706 * INSTALL: Add that `./autogen.sh' needs to be run before
5707 `./configure.'.
5708
d05f0df3 57092009-04-14 Bean <bean123ch@gmail.com>
5710
5711 * Makefile.in (pkglib_DATA): Add handler.lst.
5712 (handler.lst): New rule.
5713
5714 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
5715 * conf/i386-coreboot.rmk: Likewise.
5716 * conf/i386-ieee1275.rmk: Likewise.
5717 * conf/i386-efi.rmk: Likewise.
5718 * conf/x86_64-efi.rmk: Likewise.
5719 * conf/powerpc-ieee1275.rmk: Likewise.
5720 * conf/sparc64-ieee1275.rmk: Likewise.
5721
5722 * genhandlerlist.sh: New file.
5723
5724 * genmk.rb: Add rules to generate handler.lst.
5725
5726 * include/grub/normal.h (grub_file_getline): New function definition.
5727 (read_handler_list): Likewise.
5728 (free_handler_list): Likewise.
5729
5730 * include/grub/term.h (grub_term_register_input): Add name parameter
5731 for auto generation of handler.lst.
5732 (grub_term_register_output): Likewise.
5733
5734 * normal/handler.c: New file.
5735
5736 * normal/main.c (get_line): Renamed to grub_file_getline.
5737 (read_config_file): Use the newly renamed grub_file_getline.
5738 (read_command_list): Likewise.
5739 (read_fs_list): Likewise.
5740 (grub_normal_execute): Call read_handler_list to parse handler.lst.
5741 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
5742
5743 * term/efi/console.c (grub_console_init): Add name parameter for auto
5744 generation of handler.lst.
5745 * term/gfxterm.c: Likewise.
5746 * term/i386/pc/at_keyboard.c: Likewise.
5747 * term/i386/pc/console.c: Likewise.
5748 * term/i386/pc/serial.c: Likewise.
5749 * term/i386/pc/vesafb.c: Likewise.
5750 * term/i386/pc/vga.c: Likewise.
5751 * term/i386/pc/vga_text.c: Likewise.
5752 * term/ieee1275/ofconsole.c: Likewise.
5753 * term/usb_keyboard.c: Likewise.
5754
33c846be 57552009-04-14 Bean <bean123ch@gmail.com>
5756
5757 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
5758 properly with null character.
5759
4484e01e 57602009-04-14 Felix Zielcke <fzielcke@z-51.de>
5761
5762 * configure: Remove.
5763 * config.h.in: Likewise.
f93d668e 5764 * stamp-h.in: Likewise.
4484e01e 5765 * DISTLIST: Likewise.
5766 * conf/common.mk: Likewise.
5767 * conf/i386-coreboot.mk: Likewise.
5768 * conf/i386-efi.mk: Likewise.
5769 * conf/i386-ieee1275.mk: Likewise.
5770 * conf/i386.mk: Likewise.
5771 * conf/i386-pc.mk: Likewise.
5772 * conf/powerpc-ieee1275.mk: Likewise.
5773 * conf/sparc64-ieee1275.mk: Likewise.
5774 * conf/x86_64-efi.mk: Likewise.
5775
5776 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
5777 develop on GRUB.
5778
7dd4a573 57792009-04-14 John Stanley <jpsinthemix@verizon.net>
5c5bf96a 5780 David S. Miller <davem@davemloft.net>
5781
5782 * util/hostdisk.c (make_device_name): Fix buffer length
5783 calculations.
5784
e25b5a8c 57852009-04-14 Felix Zielcke <fzielcke@z-51.de>
5786
5787 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
5788 <sys/param.h> and <sys/sysctl.h>.
5789 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
5790 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
5791 opening the device and reset them afterwards.
5792
1f1f580c 57932009-04-13 Pavel Roskin <proski@gnu.org>
5794
5795 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
5796 Reported by John Stanley <jpsinthemix@verizon.net>
5797
7ebc2d6b 57982009-04-13 Robert Millan <rmh@aybabtu.com>
5799
5800 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
7dd4a573 5801 that name for menuentries when appropriate.
7ebc2d6b 5802
d8ba3667 58032009-04-13 Felix Zielcke <fzielcke@z-51.de>
5804
5805 * util/grub.d/10_freebsd.in: Add a missing `fi'.
5806
cba416eb 58072009-04-13 Robert Millan <rmh@aybabtu.com>
5808
5809 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
5810 to Linux, simply abort telling the user it's no longer supported.
5811
a547a745 58122009-04-13 Felix Zielcke <fzielcke@z-51.de>
5813
5814 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
7dd4a573 5815 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
a547a745 5816 `freebsd_loadenv' only when devices.hints exist.
5817
232a769c 58182009-04-13 Pavel Roskin <proski@gnu.org>
5819
5820 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
5821
c3012039 58222009-04-13 Felix Zielcke <fzielcke@z-51.de>
5823
5824 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
5825 partition number.
5826 (grub_drive): Likewise.
5827
234022fe 58282009-04-13 David S. Miller <davem@davemloft.net>
5829
5830 * kern/sparc64/ieee1275/ieee1275.c: New file.
5831 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
5832 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
5833 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
5834 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
5835 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
5836 grub_ieee1275_alloc_physmem): Declare new exported functions.
5837
d8e1836c 5838 * include/grub/sparc64/ieee1275/loader.h: New file.
5839 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5840 * include/grub/sparc64/kernel.h: Likewise.
5841 * loader/sparc64/ieee1275/linux.c: Likewise.
5842
96bd81ec 5843 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
5844 (grub_fstest_SOURCES): Likewise.
5845
6a4737e5 5846 * util/hostdisk.c (make_device_name): Do not make any assumptions
5847 about the length of drive names.
5848
1d7a72fd 5849 * kern/dl.c (grub_dl_load_file): Close file immediately when
5850 we are done using it.
5851
56bc2471 58522009-04-12 David S. Miller <davem@davemloft.net>
5853
5854 * kern/misc.c (grub_ltoa): Fix cast when handling negative
5855 values. Noticed by Pavel Roskin.
5856
df38d0bb 5857 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
5858 target compiler.
7dd4a573 5859
e382e93a 5860 * genmk.rb: Add more flexible image type specification, also
5861 pass --strip-unneeded to objcopy.
5862 * conf/i386-pc.rmk: Use *_FORMAT.
5863 * conf/i386-pc.mk: Rebuilt.
5864
f5dbbca9 5865 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
5866 (OFDISK_HASH_SZ): Define.
5867 (ofdisk_hash): New hash table.
5868 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
5869 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
5870 instead of device phandle which is not unique.
5871
91c88b12 5872 * kern/sparc64/ieee1275/init.c: Delete, replace with...
5873 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
5874 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
5875 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
5876 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
5877 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
5878 GRUB_KERNEL_MACHINE_DATA_END): Define.
5879 (grub_kernel_image_size, grub_total_module_size): Declare.
5880
5b5d4aa5 58812009-04-12 Pavel Roskin <proski@gnu.org>
5882
7dd4a573 5883 * configure.ac: Change the logic when we check for target tools.
5884 Do it when the target is specified and it's different from the
5885 specified value of the host.
5b5d4aa5 5886
c91e1793 58872009-04-11 Felix Zielcke <fzielcke@z-51.de>
5888
5889 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
5890 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
5891 GNU/kFreeBSD. Check if a device is a character device. Use
5892 DIOCGMEDIASIZE to get the size.
5893 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
5894 support for GNU/kFreeBSD.
5895 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
5896 is a character device instead of a block device. Add support for
5897 FreeBSD device names.
5898
5899 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
5900 is a character device instead of a block device.
5901
5902 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
5903 is a character device instead of a block device.
5904
b1ac8644 59052009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
5906
5907 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
5908 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
5909 FreeBSD. Check if a device is a character device. Use
5910 DIOCGMEDIASIZE to get the size.
5911 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
5912 support for FreeBSD.
5913 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
5914 is a character device instead of a block device. Add support for
5915 FreeBSD device names.
5916
5917 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
5918 a character device instead of a block device.
5919 (grub_util_check_char_device): New function.
5920
5921 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
5922 a character device instead of a block device.
5923
5924 * include/grub/util/getroot.h (grub_util_check_char_device): New
5925 prototype.
5926
a3f7515a 59272009-04-11 David S. Miller <davem@davemloft.net>
5928
5929 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
5930 static libgcc.
5931 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
5932 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
5933 function, if present.
5934 (__bswapdi2): Likewise.
5935
0d44993d 5936 * include/grub/sparc64/ieee1275/boot.h: New file.
5937 * boot/sparc64/ieee1275/boot.S: Likewise.
5938 * boot/sparc64/ieee1275/diskboot.S: Likewise.
5939
ed3d2bc2 5940 * kern/misc.c (grub_ltoa): New function.
5941 (grub_vsprintf): Use it to format 'long' integers.
5942
d3bfb59c 59432009-04-10 David S. Miller <davem@davemloft.net>
5944
5945 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
5946 slots are of type grub_ieee1275_cell_t.
5947 (grub_nand_read): Likewise.
5948 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
5949 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
5950 macros are used to compare values in arg/ret block of the call.
5951 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
5952 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
5953 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
5954 grub_ieee1275_instance_to_path, grub_ieee1275_write,
5955 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
5956 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
5957 grub_ieee1275_close, grub_ieee1275_set_property,
5958 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
5959 grub_ieee1275_cell_t.
5960 * kern/ieee1275/openfw.c (grub_map): Likewise.
5961 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
5962 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
5963
450e2238 5964 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
5965 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
5966 (grub_devalias_iterate): Likewise.
5967
7dd4a573 59682009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
6df8cc76 5969
5970 UFS improvements
5971
5972 * fs/ufs.c (INODE_NBLOCKS): new definition
5973 (struct grub_ufs_dirent): added fields for non-BSD dirents
5974 (grub_ufs_get_file_block): fixed double indirect handling
5975 (grub_ufs_lookup_symlink): use more robust way to determine whether
5976 symlink is inline
5977 (grub_ufs_find_file): support for non-BSD dirents
5978 (grub_ufs_dir): support for non-BSD dirents
5979
e7e6862a 59802009-04-10 Bean <bean123ch@gnail.com>
5981
5982 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
5983 attribute, otherwise the size would be wrong for i386 platform.
5984
5985 * include/grub/pci.h (grub_pci_read_word): New inline function.
5986 (grub_pci_read_byte): Likewise.
5987 (grub_pci_write): Likewise.
5988 (grub_pci_write_word): Likewise.
5989 (grub_pci_write_byte): Likewise.
5990
5991 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
5992
5993 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
5994 (find_framebuf): Scan pci to locate the frame buffer address.
5995
5996 * commands/efi/fixvideo.c: New file.
5997
5998 * commands/efi/loadbios.c: Likewise.
5999
6000 * commands/memrw.c: Likewise.
6001
6002 * util/grub-dumpbios.in: Likewise.
6003
6004 * conf/common.rmk (grub-dumpbios): New utility.
6005 (pkglib_MODULES): New module memrw.mod.
6006 (memrw_mod_SOURCE): New macro.
6007 (memrw_mod_CFLAGS): Likewise.
6008 (memrw_mod_LDFLAGS): Likewise.
6009
7dd4a573 6010 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 6011 fixvideo.mod.
6012 (loadbios_mod_SOURCE): New macro.
6013 (loadbios_mod_CFLAGS): Likewise.
6014 (loadbios_mod_LDFLAGS): Likewise.
6015 (fixvideo_mod_SOURCE): Likewise.
6016 (fixvideo_mod_CFLAGS): Likewise.
6017 (fixvideo_mod_LDFLAGS): Likewise.
6018
7dd4a573 6019 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 6020 fixvideo.mod.
6021 (loadbios_mod_SOURCE): New macro.
6022 (loadbios_mod_CFLAGS): Likewise.
6023 (loadbios_mod_LDFLAGS): Likewise.
6024 (fixvideo_mod_SOURCE): Likewise.
6025 (fixvideo_mod_CFLAGS): Likewise.
6026 (fixvideo_mod_LDFLAGS): Likewise.
6027
af63ada2 60282009-04-08 Felix Zielcke <fzielcke@z-51.de>
6029
6030 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
6031
c2cdde70 60322009-04-07 David S. Miller <davem@davemloft.net>
6033
6034 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
6035 support for R_SPARC_OLO10 relocations. Fix compile warning for
6036 R_SPARC_WDISP30 case.
ea3f72cf 6037 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
c2cdde70 6038
761319cf 60392009-04-06 Pavel Roskin <proski@gnu.org>
6040
1007d1f5 6041 * include/grub/misc.h (ARRAY_SIZE): New macro.
6042 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
6043 New macro.
6044 * loader/i386/linux.c (allocate_pages): Use free_pages().
6045 (grub_linux_unload): Don't use free_pages().
6046 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
6047 wrong index. Treat all other modes as text modes.
6048 (grub_cmd_linux): Initialize vid_mode unconditionally to
6049 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
6050
761319cf 6051 * commands/help.c (print_command_help): Use cmd->prio, not
6052 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
6053
ea761d40 60542009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
7dd4a573 6055
ea761d40 6056 Parttool
6057
6058 * parttool/pcpart.c: new file
6059 * commands/parttool.c: likewise
6060 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
6061 (parttool_mod_SOURCES): new variable
6062 (parttool_mod_CFLAGS): likewise
6063 (parttool_mod_LDFLAGS): likewise
6064 (pcpart_mod_SOURCES): likewise
6065 (pcpart_mod_CFLAGS): likewise
6066 (pcpart_mod_LDFLAGS): likewise
7dd4a573 6067 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
ea761d40 6068 and parttool/pcpart.c
6069 * conf/i386-efi.rmk: likewise
6070 * conf/i386-ieee1275.rmk: likewise
6071 * conf/i386-pc.rmk: likewise
6072 * conf/powerpc-ieee1275.rmk: likewise
6073 * conf/sparc64-ieee1275.rmk: likewise
6074 * conf/x86_64-ieee1275.rmk: likewise
6075
05aaebfb 60762009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
6077
6078 Support for mtime and further expandability of dir command
6079
6080 * include/grub/lib/datetime.h: moved to ...
7dd4a573 6081 * include/grub/datetime.h: ... moved here and added
05aaebfb 6082 declaration of grub_unixtime2datetime. All users updated
7dd4a573 6083 * include/grub/fs.h: new syntax for dir and mtime functions in
6084 struct grub_fs
05aaebfb 6085 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
6086 and GRUB_FSHELP_FLAGS_MASK
6087 * commands/ls.c (grub_ls_list_files): Write mtime in long format
6088 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
6089 (grub_ext2_mtime): new function
6090 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
6091 (grub_hfsplus_mtime): new function
6092 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
6093 (GRUB_UFS_ATTR_FILE): likewise
6094 (GRUB_UFS_ATTR_LNK): likewise
6095 (struct grub_ufs_sblock): new fields mtime
6096 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
6097 all users updated
6098 (grub_ufs_dir): mtime support
6099 (grub_ufs_mtime): new function
6100 * fs/affs.c (grub_affs_dir): use new dir syntax
6101 * fs/afs.c (grub_afs_dir): likewise
6102 * fs/cpio.c (grub_cpio_dir): likewise
6103 * fs/fat.c (grub_fat_find_dir): likewise
6104 * fs/hfs.c (grub_hfs_dir): likewise
6105 * fs/iso9660.c (grub_iso9660_dir): likewise
6106 * fs/jfs.c (grub_jfs_dir): likewise
6107 * fs/minix.c (grub_minix_dir): likewise
6108 * fs/ntfs.c (grub_ntfs_dir): likewise
6109 * fs/reiserfs.c (grub_reiserfs_dir): likewise
6110 * fs/sfs.c (grub_sfs_dir): likewise
6111 * fs/xfs.c (grub_xfs_dir): likewise
6112 * util/hostfs.c (grub_hostfs_dir): likewise
6113 * lib/datetime.c: moved to ...
6114 * normal/datetime.c: ... moved here
6115 (grub_unixtime2datetime): new function
6116 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
7dd4a573 6117 * normal/completion.c (iterate_dir): use new dir syntax
6118 * normal/misc.c (grub_normal_print_device_info): tell the
05aaebfb 6119 last modification time of a volume
7dd4a573 6120 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
05aaebfb 6121 * conf/common.rmk: added lib/datetime.c to ls.mod
7dd4a573 6122 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
05aaebfb 6123 (normal_mod_SOURCES): likewise
6124 (datetime_mod_SOURCES): Removed lib/datetime.c
6125 * conf/i386-efi.rmk: likewise
7dd4a573 6126 * conf/i386-ieee1275.rmk: likewise
05aaebfb 6127 * conf/i386-pc.rmk: likewise
6128 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 6129 * conf/sparc64-ieee1275.rmk: likewise
6130 * conf/x86_64-efi.rmk: likewise
05aaebfb 6131
8a7e1a14 61322009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
6133
6134 Trim trailing spaces in FAT label and support mtools-like labels
7dd4a573 6135
6136 * fs/fat.c (grub_fat_iterate_dir): New function based
8a7e1a14 6137 on grub_fat_find_dir
6138 (grub_fat_find_dir): use grub_fat_iterate_dir
6139 (grub_fat_label): likewise
6140
04186a9c 61412009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
6142
7dd4a573 6143 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
04186a9c 6144 and command.h
6145 remove extraneous kernel_elf_HEADERS
6146
da4c0bb6 61472009-04-04 Bean <bean123ch@gnail.com>
6148
6149 * include/grub/util/misc.h: Add dummy function fsync for mingw.
6150
6151 * util/misc.c: Likewise.
6152
54ad9555 61532009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
6154
6155 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
6156 instead of grub_printf.
6157
7a6bf9f2 61582009-04-03 Robert Millan <rmh@aybabtu.com>
6159
6160 * loader/i386/linux.c (grub_linux_setup_video): Fill
6161 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
6162 values from `mode info' structure instead of hardcoded
6163 values.
6164
3fcc2083 61652009-04-01 Pavel Roskin <proski@gnu.org>
6166
6167 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
6168 unused now.
6169 * genmk.rb: Likewise.
6170 * configure.ac: Likewise.
6171
5ec9740b 61722009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
6173
6174 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
6175 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
6176
5270cec8 61772009-04-01 David S. Miller <davem@davemloft.net>
6178
6179 * normal/sparc64/setjmp.S: Fix setjmp implementation.
7dd4a573 6180 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
5270cec8 6181 (grub_setjmp): Mark with 'returns_twice' attribute.
6182 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
6183 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
6184 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
6185
9c3dd854 61862009-04-01 Robert Millan <rmh@aybabtu.com>
6187
6188 Reapply fix from 2008-07-28 which was accidentally reverted; also
6189 perform the same fix to a similar check in same function.
6190
6191 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
6192 with the same number are found, just use issue a warning with
6193 grub_dprintf(), as this error has been reported to be non-fatal.
6194
0d818b7e 61952009-03-31 Pavel Roskin <proski@gnu.org>
6196
6197 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
6198 for cross-compilation.
6199
95646d92 62002009-03-30 Robert Millan <rmh@aybabtu.com>
6201
6202 Fix i386-ieee1275 build.
6203
6204 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
6205 Remove declaration.
6206
6a003ed1 62072009-03-30 Pavel Roskin <proski@gnu.org>
6208
6209 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
6210 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
6211 zero-terminated, rely only on the strlen value. Fix comparison
6212 of strings differing in length.
6213
92f33540 62142009-03-30 Robert Millan <rmh@aybabtu.com>
6215
6216 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
6217 checking for abi version. Improve error messages on BIOS to notify
6218 user about `linux16' command.
6219
a8c48fd5 62202009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
6221
f968172e 6222 Leak fixes
a8c48fd5 6223
f968172e 6224 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
6225 in case of collision
6226 * disk/scsi.c (grub_scsi_open): free scsi in case of error
a8c48fd5 6227
9c323f09 62282009-03-29 Robert Millan <rmh@aybabtu.com>
6229
6230 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
6231 set `vid_mode' accordingly.
6232 (grub_linux_boot): Process `vid_mode' and set video mode.
6233
ae68f423 62342009-03-29 Robert Millan <rmh@aybabtu.com>
6235
6236 * util/grub.d/10_linux.in (linux_entry): New function.
6237 Factorize generation of Linux boot entries.
6238
5709cfc4 62392009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
6240
6241 Make the format of Environment Block plain text. The boot loader
6242 part is not tested well yet.
7dd4a573 6243
5709cfc4 6244 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
6245 (buffer): Removed.
6246 (envblk): Likewise.
6247 (usage): Remove "info" and "clear". Add "unset". Update the
6248 description of "set", as this does not delete variables any
6249 longer.
6250 (create_envblk_file): Complete rewrite.
6251 (open_envblk_file): Likewise.
6252 (cmd_info): Removed.
6253 (cmd_list): Likewise.
6254 (cmd_set): Likewise.
6255 (cmd_clear): Likewise.
6256 (list_variables): New function.
6257 (write_envblk): Likewise.
6258 (set_variables): Likewise.
6259 (unset_variables): Likewise.
6260 (main): Complete rewrite.
6261
6262 * commands/loadenv.c (buffer): Removed.
6263 (envblk): Likewise.
6264 (open_envblk_file): New function.
6265 (read_envblk_file): Complete rewrite.
6266 (grub_cmd_load_env): Likewise.
6267 (grub_cmd_list_env): Likewise.
6268 (struct blocklist): New struct.
6269 (free_blocklists): New function.
6270 (check_blocklists): Likewise.
6271 (write_blocklists): Likewise.
6272 (grub_cmd_save_env): Complete rewrite.
6273
6274 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
6275 a plain text signature.
6276 (GRUB_ENVBLK_MAXLEN): Removed.
6277 (struct grub_envblk): Complete rewrite.
6278 (grub_envblk_find): Removed.
6279 (grub_envblk_insert): Likewise.
6280 (grub_envblk_open): New prototype.
6281 (grub_envblk_set): Likewise.
6282 (grub_envblk_delete): Put const to VALUE.
6283 (grub_envblk_iterate): Put const to NAME and VALUE.
6284 (grub_envblk_close): New prototype.
6285 (grub_envblk_buffer): New inline function.
6286 (grub_envblk_size): Likewise.
6287
6288 * lib/envblk.c: Include grub/mm.h.
6289 (grub_env_find): Removed.
6290 (grub_envblk_open): New function.
6291 (grub_envblk_close): Likewise.
6292 (escaped_value_len): Likewise.
6293 (find_next_line): Likewise.
6294 (grub_envblk_insert): Removed.
6295 (grub_envblk_set): New function.
6296 (grub_envblk_delete): Complete rewrite.
6297 (grub_envblk_iterate): Likewise.
6298
a9368fd3 62992009-03-28 Robert Millan <rmh@aybabtu.com>
6300
6301 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
6302 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
6303 variables. Use 16-bit loader.
6304 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
6305 loader.
6306 * kern/i386/loader.S (grub_linux_boot): Rename to ...
6307 (grub_linux16_boot): ... this. Update all users.
6308 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
6309 (grub_linux_boot): ... this. Update all users.
6310
6311 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
6312 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
6313 commands to `linux16' and `initrd16'.
6314 (GRUB_MOD_FINI(linux)): Rename to ...
6315 (GRUB_MOD_FINI(linux16)): ... this.
6316
e4dd5a7e 63172009-03-24 Pavel Roskin <proski@gnu.org>
6318
6319 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
6320 not just for compilation.
6321
c04d6e05 63222009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
6323
6324 Move multiboot helper out of kernel
6325
6326 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
6327 `loader/i386/multiboot_helper.S'.
6328 * conf/i386-coreboot.rmk: Likewise
6329 * conf/i386-ieee1275.rmk: Likewise
6330
6331 * kern/i386/loader.S: Move multiboot helpers from here...
6332 * loader/i386/multiboot_helper.S: ...moved here
6333 * include/grub/i386/loader.h: Move declarations of multiboot
6334 helpers from here...
6335 * include/grub/i386/multiboot.h: ...moved here
6336 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
6337
42a5b3fc 63382009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6339
6340 * kern/env.c (grub_env_context_open): Added an argument to specify
6341 whether a new context inherits exported variables from current
6342 one. This is useful when making a sandbox to interpret a config
6343 file.
6344 All callers updated.
6345
6346 * include/grub/env.h (grub_env_context_open): Updated the prototype.
6347
b28bbc4e 63482009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6349
6350 * kern/env.c (grub_env_context_close): Fix memory leaks.
6351
f04f02e4 63522009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6353
6354 * normal/main.c (grub_normal_execute): Added an argument
6355 BATCH to specify if an interactive interface should be provided
6356 after reading a config file.
6357 All callers updated.
6358 (read_command_list): Prevent being executed twice.
6359 (read_fs_list): Likewise.
6360
42a5b3fc 6361 * include/grub/normal.h (grub_normal_execute): Updated the
6362 prototype.
f04f02e4 6363
41473ac2 63642009-03-22 Pavel Roskin <proski@gno.org>
6365
fbc00b0c 6366 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
6367 _start.
6368 * kern/i386/pc/startup.S: Likewise.
6369 * kern/i386/efi/startup.S: Likewise.
6370 * kern/i386/ieee1275/startup.S: Likewise.
6371 * kern/i386/coreboot/startup.S: Likewise.
6372 * kern/x86_64/efi/startup.S: Likewise.
6373
41473ac2 6374 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
6375 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
6376 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
6377
2274cc8f 63782009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
6379
6380 Bugfixes in multiboot for bugs uncovered by solaris kernel.
6381
6382 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
6383 limit detection.
6384 Use vaddr of correct segment for entry_point.
6385
b1b797cb 63862009-03-21 Bean <bean123ch@gmail.com>
6387
6388 * commands/blocklist.c: Add include file <grub/command.h>, remove
6389 <grub/normal.h> and <grub/arg.h>.
6390 (grub_cmd_blocklist): Use the new command interface.
6391 (GRUB_MOD_INIT): Likewise.
6392 (GRUB_MOD_FINI): Likewise.
6393 * commands/boot.c: Likewise.
6394 * commands/cat.c: Likewise.
6395 * commands/cmp.c: Likewise.
6396 * commands/configfile.c: Likewise.
6397 * commands/crc.c: Likewise.
6398 * commands/echo.c: Likewise.
6399 * commands/halt.c: Likewise.
6400 * commands/handler.c: Likewise.
6401 * commands/hdparm.c: Likewise.
6402 * commands/help.c: Likewise.
6403 * commands/hexdump.c: Likewise.
6404 * commands/loadenv.c: Likewise.
6405 * commands/ls.c: Likewise.
6406 * commands/lsmmap.c: Likewise.
6407 * commands/lspci.c: Likewise.
6408 * commands/loadenv.c: Likewise.
6409 * commands/read.c: Likewise.
6410 * commands/reboot.c: Likewise.
6411 * commands/search.c: Likewise.
6412 * commands/sleep.c: Likewise.
6413 * commands/test.c: Likewise.
6414 * commands/usbtest.c: Likewise.
6415 * commands/videotest.c: Likewise.
6416 * commands/i386/cpuid.c: Likewise.
6417 * commands/i386/pc/halt.c: Likewise.
6418 * commands/i386/pc/play.c: Likewise.
6419 * commands/i386/pc/pxecmd.c: Likewise.
6420 * commands/i386/pc/vbeinfo.c: Likewise.
6421 * commands/i386/pc/vbetest.c: Likewise.
6422 * commands/ieee1275/suspend.c: Likewise.
6423 * disk/loopback.c: Likewise.
6424 * font/font_cmd.c: Likewise.
6425 * hello/hello.c: Likewise.
6426 * loader/efi/appleloader.c: Likewise.
6427 * loader/efi/chainloader.c: Likewise.
6428 * loader/i386/bsd.c: Likewise.
6429 * loader/i386/efi/linux.c: Likewise.
6430 * loader/i386/ieee1275/linux.c: Likewise.
6431 * loader/i386/linux.c: Likewise.
6432 * loader/i386/pc/chainloader.c: Likewise.
6433 * loader/i386/pc/linux.c: Likewise.
6434 * loader/powerpc/ieee1275/linux.c: Likewise.
6435 * loader/multiboot_loader.c: Likewise.
6436 * term/gfxterm.c: Likewise.
6437 * term/i386/pc/serial.c: Likewise.
6438 * term/terminfo.c: Likewise.
6439
6440 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
6441 * term/i386/pc/vga.c: Likewise.
6442 * video/readers/jpeg.c: Likewise.
6443 * video/readers/png.c: Likewise.
6444 * video/readers/tga.c: Likewise.
6445
6446 * util/grub-fstest (cmd_loopback): Removed.
6447 (cmd_blocklist): Likewise.
6448 (cmd_ls): Likewise.
6449 (grub_register_command): Likewise.
6450 (grub_unregister_command): Likewise.
6451 (execute_command): Use grub_command_find to locate command and execute
6452 it.
6453
6454 * include/grub/efi/chainloader.h: Removed.
6455 * loader/efi/chainloader_normal.c: Likewise.
6456 * loader/i386/bsd_normal.c: Likewise.
6457 * loader/i386/pc/chainloader_normal.c: Likewise.
6458 * loader/i386/pc/multiboot_normal.c: Likewise.
6459 * loader/linux_normal.c: Likewise.
6460 * loader/multiboot_loader_normal.c: Likewise.
6461 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
6462
6463 * gencmdlist.sh: Scan new registration command grub_register_extcmd
6464 and grub_register_command_p1.
6465
6466 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
6467 kern/command.c, lib/arg.c and commands/extcmd.c.
6468 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
6469 (minicmd_mod_SOURCES): New variable.
6470 (minicmd_mod_CFLAGS): Likewise.
6471 (minicmd_mod_LDFLAGS): Likewise.
6472 (extcmd_mod_SOURCES): Likewise.
6473 (extcmd_mod_CFLAGS): Likewise.
6474 (extcmd_mod_LDFLAGS): Likewise.
6475 (boot_mod_SOURCES): Removed.
6476 (boot_mod_CFLAGS): Likewise.
6477 (boot_mod_LDFLAGS): Likewise.
6478
6479 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
6480 kern/corecmd.c.
6481 (kernel_img_HEADERS): Add command.h.
6482 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
6483 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
6484 and lib/arg.c.
6485 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
6486 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
6487 remove the corresponding normal mode command.
6488 (normal_mod_SOURCES): Remove normal/arg.c.
6489 * conf/i386-coreboot.rmk: Likewise.
6490 * conf/i386-efi.rmk: Likewise.
6491 * conf/i386-ieee1275.rmk: Likewise.
6492 * conf/powerpc-ieee1275.rmk: Likewise.
6493 * conf/x86_64-efi.rmk: Likewise.
6494
6495 * include/grub/arg.h: Move from here ...
6496 * include/grub/lib/arg.h: ... to here.
6497
6498 * normal/arg.c: Move from here ...
6499 * lib/arg.c: ... to here.
6500
6501 * commands/extcmd.c: New file.
6502 * commands/minicmd.c: Likewise.
6503 * include/grub/command.h: Likewise.
6504 * include/grub/extcmd.h: Likewise.
6505 * kern/command.c: Likewise.
6506 * kern/corecmd.c: Likewise.
6507
6508 * kern/list.c (grub_list_iterate): Return int instead of void.
6509 (grub_list_insert): New function.
6510 (grub_prio_list_insert): Likewise.
6511
6512 * kern/rescue.c (grub_rescue_command): Removed.
6513 (grub_rescue_command_list): Likewise.
6514 (grub_rescue_register_command): Likewise.
6515 (grub_rescue_unregister_command): Likewise.
6516 (grub_rescue_cmd_boot): Move to minicmd.c
6517 (grub_rescue_cmd_help): Likewise.
6518 (grub_rescue_cmd_info): Likewise.
6519 (grub_rescue_cmd_boot): Likewise.
6520 (grub_rescue_cmd_testload): Likewise.
6521 (grub_rescue_cmd_dump): Likewise.
6522 (grub_rescue_cmd_rmmod): Likewise.
6523 (grub_rescue_cmd_lsmod): Likewise.
6524 (grub_rescue_cmd_exit): Likewise.
6525 (grub_rescue_print_devices): Moved to corecmd.c.
6526 (grub_rescue_print_files): Likewise.
6527 (grub_rescue_cmd_ls): Likewise.
6528 (grub_rescue_cmd_insmod): Likewise.
6529 (grub_rescue_cmd_set): Likewise.
6530 (grub_rescue_cmd_unset): Likewise.
7d074e3c 6531 (attempt_normal_mode): Use grub_command_find to get normal module.
b1b797cb 6532 (grub_enter_rescue_mode): Use grub_register_core_commands to register
7d074e3c 6533 commands, remove grub_rescue_register_command calls.
b1b797cb 6534
7d074e3c 6535 * normal/command.c (grub_register_command): Removed.
b1b797cb 6536 (grub_unregister_command): Likewise.
6537 (grub_command_find): Likewise.
6538 (grub_iterate_commands): Likewise.
6539 (rescue_command): Likewise.
6540 (export_command): Moved to corecmd.c.
6541 (set_command): Removed.
6542 (unset_command): Likewise.
6543 (insmod_command): Likewise.
6544 (rmmod_command): Likewise.
6545 (lsmod_command): Likewise.
6546 (grub_command_init): Likewise.
6547
6548 * normal/completion.c (iterate_command): Use cmd->prio to check for
6549 active command.
6550 (complete_arguments): Use grub_extcmd_t structure to find options.
6551 (grub_normal_do_completion): Change function grub_iterate_commands to
6552 grub_command_iterate.
6553
6554 * normal/execute.c (grub_script_execute_cmd): No need to parse
6555 argument here.
6556
6557 * normal/main.c (grub_dyncmd_dispatcher): New function.
6558 (read_command_list): Register unload commands as dyncmd.
6559 (grub_cmd_normal): Use new command interface, register rescue,
6560 unregister normal at entry, register normal, unregister rescue at exit.
6561
6562 * include/grub/list.h (grub_list_test_t): New type.
6563 (grub_list_iterate): Return int instead of void.
6564 (grub_list_insert): New function.
6565 (GRUB_AS_NAMED_LIST_P): New macro.
6566 (GRUB_AS_PRIO_LIST): Likewise.
6567 (GRUB_AS_PRIO_LIST_P): Likewise.
6568 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
6569 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
6570 (grub_prio_list): New structure.
6571 (grub_prio_list_insert): New function.
6572 (grub_prio_list_remove): New inline function.
6573
6574 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
6575 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
6576 (GRUB_COMMAND_FLAG_MENU): Likewise.
6577 (GRUB_COMMAND_FLAG_BOTH): Likewise.
6578 (GRUB_COMMAND_FLAG_TITLE): Likewise.
6579 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
6580 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
6581 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
6582 (grub_command): Likewise.
6583 (grub_register_command): Likewise.
6584 (grub_command_find): Likewise.
6585 (grub_iterate_commands): Likewise.
6586 (grub_command_init): Likewise.
6587 (grub_arg_parse): Likewise.
6588 (grub_arg_show_help): Likewise.
6589
6590 * include/grub/rescue.h (grub_rescue_register_command): Removed.
6591 (grub_rescue_unregister_command): Likewise.
6592
6593 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
6594 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
6595 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
6596
6597 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
6598 grub_rescue_cmd_initrd.
6599 * include/grub/i386/loader.h: Likewise.
6600 * include/grub/x86_64/loader.h: Likewise.
6601
6602 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
6603
1f4147aa 66042009-03-21 Bean <bean123ch@gmail.com>
6605
6606 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
6607 instead of stat in mingw environment.
6608
6609 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
6610
6611 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
6612
6613 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
6614 AC_CONFIG_LINKS.
6615
2156d5ba 66162009-03-21 Bean <bean123ch@gmail.com>
6617
6618 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
6619 out of range error.
6620
177b82ca 66212009-03-18 Michel Dänzer <michel@daenzer.net>
6622
6623 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
6624 checking inode flags for EXT4_EXTENTS_FLAG.
6625
14aad807 66262009-03-18 Robert Millan <rmh@aybabtu.com>
6627
6628 * loader/i386/linux.c: Include `<grub/video.h>' and
6629 `<grub/i386/pc/vbe.h>'..
6630 (grub_linux_setup_video): New function. Loosely based on the EFI one.
6631 (grub_linux32_boot): Attempt to configure video settings with
6632 grub_linux_setup_video().
6633 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
6634 to avoid grub_console_fini() which would step out of graphical mode
6635 unconditionally.
6636
8cf83a27 66372009-03-14 Robert Millan <rmh@aybabtu.com>
6638
6639 Fix build on powerpc.
6640 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
6641
40164e75 66422009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
6643
6644 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
6645 background image command.
6646
c58bc32a 66472009-03-12 Colin D Bennett <colin@gibibit.com>
6648
6649 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
6650 (grub_gfxterm_putchar): Extract pairs of identical calls to
6651 draw_cursor out of conditional blocks.
6652
5415144a 66532009-03-11 Pavel Roskin <proski@gnu.org>
6654
6655 * fs/hfs.c (grub_hfs_strncasecmp): New function.
6656 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
6657
6394042e 66582009-03-11 Robert Millan <rmh@aybabtu.com>
6659
6660 * loader/i386/multiboot_elfxx.c
6661 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
6662
b7b50e5f 66632009-03-11 Felix Zielcke <fzielcke@z-51.de>
6664
6665 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
6666 `kern/handler.c'.
6667
1ca7fc96 66682009-03-11 Robert Millan <rmh@aybabtu.com>
6669
6670 * loader/i386/multiboot.c (code_size): New variable.
6671 (grub_multiboot): Define offsets by adding to `code_size' rather
7d074e3c 6672 than subtracting from `grub_multiboot_payload_size'. Provide
1ca7fc96 6673 4-byte alignment to MBI and others by increasing
7d074e3c 6674 `boot_loader_name_length' appropriately.
1ca7fc96 6675
6676 * loader/i386/multiboot_elfxx.c
6677 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
6678
a83ea1d2 66792009-03-09 Felix Zielcke <fzielcke@z-51.de>
6680
6681 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
6682 `fs/ext2.c'.
6683
aa9f3bff 66842009-03-08 Robert Millan <rmh@aybabtu.com>
6685
6686 Make loader/i386/linux.c usable on i386-pc again.
6687
6688 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
6689 memory to heap.
6690 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
6691 `#error' stanza.
6692
d8b3b60e 66932009-03-07 Bean <bean123ch@gmail.com>
6694
6695 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
6696 allocation.
6697
b362c9e9 66982009-03-06 Robert Millan <rmh@aybabtu.com>
6699
6700 Fix display issue on terminals with screen size other than 80x25
6701 (e.g. gfxterm with resolution higher than 640x480).
6702
6703 * normal/main.c (grub_normal_init_page): Display title text in a
7d074e3c 6704 position relative to the center of the terminal instead of relying
b362c9e9 6705 on a hardcoded offset.
6706
9304eef1 67072009-03-04 Robert Millan <rmh@aybabtu.com>
6708
6709 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
6710 installed.
6711
6712 * Makefile.in (host_kernel): New variable.
6713 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
6714 scripts instead of just the windows one.
6715 * configure.ac: Initialize and AC_SUBST `host_kernel'.
6716
eabc95fb 67172009-03-04 Felix Zielcke <fzielcke@z-51.de>
2ba60b62 6718
6719 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
6720 `kern/handler.c'.
6721 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6722 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6723 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
6724 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6725 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6726 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6727
ceb1223c 67282009-03-04 Felix Zielcke <fzielcke@z-51.de>
6729
6730 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
6731 or if there's no space for the disk label and print the partition number on a
6732 invalid magic.
6733
4910684a 67342009-03-04 Felix Zielcke <fzielcke@z-51.de>
6735
6736 * util/misc.c: Include <time.h>.
6737 (grub_millisleep): New function.
6738
7e9ca17a 67392009-03-04 Bean <bean123ch@gmail.com>
6740
6741 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
6742 another option -mno-red-zone.
6743
6744 * commands/handler.c: Change module description.
6745
6746 * kern/handler.c: Add missing space at the end of description line.
6747
6748 * kern/list.c: Likewise.
6749
f501677c 67502009-03-03 Robert Millan <rmh@aybabtu.com>
6751
6752 Move more components to the relocation area, and fix mbi pointer
6753 handling to use the destination rather than the origin (thanks to
6754 Vladimir Serbinenko for spotting).
6755
6756 * loader/i386/multiboot.c (mbi_dest): New variable.
6757 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
6758 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
6759 relocation area.
6760
9902d047 67612009-03-01 Bean <bean123ch@gmail.com>
6762
50fb7002 6763 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
9902d047 6764 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
6765 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
6766 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
6767
6768 * loader/i386/efi/linux.c (acpi_guid): New variable.
6769 (acpi_guid): Likewise.
6770 (EBDA_SEG_ADDR): New constant.
6771 (LOW_MEM_ADDR): Likewise.
6772 (FAKE_EBDA_SEG): Likewise.
6773 (fake_bios_data): New function.
6774 (grub_linux_boot): Call fake_bios_data.
6775
71b9f361 67762009-03-01 Bean <bean123ch@gmail.com>
6777
6778 * commands/terminal.c: Removed.
6779
6780 * commands/handler.c: New file.
6781
6782 * include/grub/list.h: Likewise.
6783
6784 * include/grub/handler.h: Likewise.
6785
6786 * kern/list.c: Likewise.
6787
6788 * kern/handler.c: Likewise.
6789
6790 * kern/term.h: Include header file <grub/handler.h>.
6791 (grub_term_input): Move next field to the beginning.
6792 (grub_term_output): Likewise.
6793 (grub_term_input_class): New variable.
6794 (grub_term_output_class): Likewise.
6795 (grub_term_register_input): Changed to inline function.
6796 (grub_term_register_output): Likewise.
6797 (grub_term_unregister_input): Likewise.
6798 (grub_term_unregister_output): Likewise.
6799 (grub_term_set_current_input): Likewise.
6800 (grub_term_set_current_output): Likewise.
6801 (grub_term_get_current_input): Likewise.
6802 (grub_term_get_current_output): Likewise.
6803 (grub_term_iterate_input): Removed.
6804 (grub_term_iterate_output): Likewise.
6805
6806 * kern/term.c (grub_term_list_input): Removed.
6807 (grub_term_list_output): Likewise.
6808 (grub_term_input_class): New variable.
6809 (grub_term_output_class): Likewise.
50fb7002 6810 (grub_cur_term_input): Change variable as macro.
71b9f361 6811 (grub_cur_term_output): Likewise.
6812 (grub_term_register_input): Removed.
6813 (grub_term_register_output): Likewise.
6814 (grub_term_unregister_input): Likewise.
6815 (grub_term_unregister_output): Likewise.
6816 (grub_term_set_current_input): Likewise.
6817 (grub_term_set_current_output): Likewise.
6818 (grub_term_iterate_input): Likewise.
6819 (grub_term_iterate_output): Likewise.
6820 (grub_term_get_current_input): Likewise.
6821 (grub_term_get_current_output): Likewise.
6822
6823 * util/grub-editenv.c: Include header file <grub/handler.h>.
6824 (grub_term_get_current_input): Removed.
6825 (grub_term_get_current_output): Likewise.
6826 (grub_term_input_class): New variable.
50fb7002 6827 (grub_term_output_class): Likewise.
71b9f361 6828
6829 * util/grub-fstest.c (grub_term_get_current_input): Removed.
6830 (grub_term_get_current_output): Likewise.
6831 (grub_term_input_class): New variable.
50fb7002 6832 (grub_term_output_class): Likewise.
71b9f361 6833
6834 * util/grub-probe.c (grub_term_get_current_input): Removed.
6835 (grub_term_get_current_output): Likewise.
6836 (grub_term_input_class): New variable.
50fb7002 6837 (grub_term_output_class): Likewise.
71b9f361 6838
6839 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
6840 (grub_term_get_current_output): Likewise.
6841 (grub_term_input_class): New variable.
50fb7002 6842 (grub_term_output_class): Likewise.
71b9f361 6843
6844 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
6845 (terminal_mod_SOURCES): Likewise.
6846 (terminal_mod_CFLAGS): Likewise.
6847 (terminal_mod_LDFLAGS): Likewise.
6848
6849 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
6850 handler.c.
6851 (kernel_img_SOURCES): Add list.c and handler.c.
6852 (kernel_img_HEADERS): Add list.h and handler.h.
6853
6854 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6855 handler.c.
6856 (kernel_mod_SOURCES): Add list.c and handler.c.
6857 (kernel_mod_HEADERS): Add list.h and handler.h.
6858
6859 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
6860 handler.c.
6861 (kernel_elf_SOURCES): Add list.c and handler.c.
6862 (kernel_elf_HEADERS): Add list.h and handler.h.
6863
6864 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6865 handler.c.
6866 (kernel_elf_SOURCES): Add list.c and handler.c.
6867 (kernel_elf_HEADERS): Add list.h and handler.h.
6868
6869 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6870 handler.c.
6871 (kernel_mod_SOURCES): Add list.c and handler.c.
6872 (kernel_mod_HEADERS): Add list.h and handler.h.
6873
6874 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6875 handler.c.
6876 (kernel_elf_SOURCES): Add list.c and handler.c.
6877 (kernel_elf_HEADERS): Add list.h and handler.h.
6878
8a31787f 68792009-02-27 Robert Millan <rmh@aybabtu.com>
6880
6881 Factorize elf32 / elf64 code in Multiboot loader. This will
6882 prevent it from getting out of sync again.
6883
6884 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
6885 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
6886 grub_multiboot_load_elf64): Move from here ...
6887 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
6888 grub_multiboot_load_elf): ... to here (new file).
6889
51cd3dfc 68902009-02-27 Robert Millan <rmh@aybabtu.com>
6891
6892 * util/grub.d/10_linux.in: Rename "single-user mode" to
6893 "recovery mode".
6894
6e8c9c3a 68952009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
6896
6897 Don't leak in SCSI code.
6898 * disk/scsi.c (grub_scsi_close): free `scsi'.
6899
4b6bf4f9 69002009-02-27 Robert Millan <rmh@aybabtu.com>
6901
6902 * loader/i386/pc/multiboot.c: Move from here ...
6903 * loader/i386/multiboot.c: ... to here. Update all users.
6904
b9413424 69052009-02-27 Robert Millan <rmh@aybabtu.com>
6906
6907 Patch from Alexandre Bique <bique.alexandre@gmail.com>
6908 * util/i386/pc/grub-setup.c (setup): Fix directory path.
6909
50fb7002 69102009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
34519c3f 6911
6912 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
6913 b-tree.
6914
8cc50345 69152009-02-27 Robert Millan <rmh@aybabtu.com>
6916
6917 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
6918 `0x' qualifier as 0 when base is specified as parameter).
6919
6e09b8b7 69202009-02-24 Bean <bean123ch@gmail.com>
6921
6922 * configure.ac: Check for -mcmodel=large in x86_64 target.
6923
6924 * include/grub/efi/api.h (efi_call_10): New macro.
6925 (efi_wrap_10): New function.
6926
6927 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
6928 (GRUB_PE32_REL_BASED_HIGH): Likewise.
6929 (GRUB_PE32_REL_BASED_LOW): Likewise.
6930 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
6931 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
6932 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
6933 (GRUB_PE32_REL_BASED_SECTION): Likewise.
6934 (GRUB_PE32_REL_BASED_REL): Likewise.
6935 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
6936 (GRUB_PE32_REL_BASED_DIR64): Likewise.
6937 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
6938
6939 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
6940 issue.
6941
6942 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
6943 (efi_wrap_10): New function.
6944
6945 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
6946
6947 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
6948 MB/MBP model (NV chipset).
6949 (devdata_devs): Add devpath_5 to the list.
6950
6951 * load/i386/efi/linux.c (video_base): Remove variable.
6952 (RGB_MASK): New macro.
6953 (RGB_MAGIC): Likewise.
6954 (LINE_MIN): Likewise.
6955 (LINE_MAX): Likewise.
6956 (FBTEST_STEP): Likewise.
6957 (FBTEST_COUNT): Likewise.
6958 (fb_list): New variable.
6959 (grub_find_video_card): Remove function.
6960 (find_framebuf): New function.
6961 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
6962 line length.
6963
6964 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
6965 problem for x86_64.
6966
74b21bee 69672009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
6968
6969 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
6970
6971 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
6972 coding tool name.
6973
a455f472 69742009-02-22 Robert Millan <rmh@aybabtu.com>
6975
6976 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
6977 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
6978 in our relocation, instead of using it directly from heap. Also
6979 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
6980
6374daf3 69812009-02-21 Robert Millan <rmh@aybabtu.com>
6982
6983 Implement USB keyboard support (based on patch by Marco Gerards)
6984
6985 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
6986 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
6987 (usb_keyboard_mod_LDFLAGS): New variables.
6988
6989 * term/usb_keyboard.c: New file.
6990
8fa4ea70 69912009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
6992
6993 Corrected wrong declaration
6994
6995 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
6996
353976ac 69972009-02-14 Christian Franke <franke@computer.org>
6998
6999 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
7000 (grub_lspci_iter): Print class code and programming interface byte.
7001
6aa1169b 70022009-02-14 Christian Franke <franke@computer.org>
7003
7004 * gendistlist.sh: Ignore `.svn' directories.
7005
265372ca 70062009-02-14 Felix Zielcke <fzielcke@z-51.de>
7007
7008 * fs/fat.c: Add 2009 to Copyright line.
7009
9ff516f3 70102009-02-14 Christian Franke <franke@computer.org>
7011
7012 * commands/hdparm.c: New file. Provides `hdparm' command
7013 which sends ATA commands via grub_disk_ata_pass_through ().
7014
7015 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
7016
7017 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
7018 and <grub/cpu/io.h> to include/grub/ata.h.
7019 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
7020 (GRUB_CDROM_SECTOR_SIZE): Remove.
7021 (GRUB_ATA_*): Move to include/grub/ata.h.
7022 (GRUB_ATAPI_*): Likewise.
7023 (enum grub_ata_commands): Likewise.
7024 (enum grub_ata_timeout_milliseconds): Likewise.
7025 (struct grub_ata_device): Likewise.
7026 (grub_ata_regset): Likewise.
7027 (grub_ata_regget): Likewise.
7028 (grub_ata_regset2): Likewise.
7029 (grub_ata_regget2): Likewise.
7030 (grub_ata_check_ready): Likewise.
7031 (grub_ata_wait_not_busy): Remove static, exported in
7032 include/grub/ata.h.
7033 (grub_ata_wait_drq): Likewise.
7034 (grub_ata_pio_read): Likewise.
7035
7036 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
7037 function for hdparm.mod.
7038
7039 * include/grub/ata.h: New file, contains declarations from
7040 disk/ata.c.
7041 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
7042
7043 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
7044 (grub_disk_ata_pass_through): New exported variable.
7045
7046 * kern/disk.c (grub_disk_ata_pass_through): New variable.
7047
772e23da 70482009-02-13 Colin D Bennett <colin@gibibit.com>
7049
7050 Support multiple fallback entries, and provide an API to support
7051 executing default+fallback menu entries. Renamed the `terminal' menu
7052 viewer to `text'.
7053
7054 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
7055 variable declaration.
7056 (grub_menu_execute_callback): New structure declaration.
7057 (grub_menu_execute_callback_t): New typedef.
7058 (grub_menu_execute_with_fallback): New function declaration.
7059 (grub_menu_get_entry): Likewise.
7060 (grub_menu_get_timeout): Likewise.
7061 (grub_menu_set_timeout): Likewise.
7062
7063 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
7064
7065 * normal/menu.c (grub_wait_after_message): Moved to
7066 `normal/menu_text.c'.
7067 (draw_border): Likewise.
7068 (print_message): Likewise.
7069 (print_entry): Likewise.
7070 (print_entries): Likewise.
7071 (grub_menu_init_page): Likewise.
7072 (get_entry_number): Likewise.
7073 (print_timeout): Likewise.
7074 (run_menu): Likewise.
7075 (grub_menu_execute_entry): Likewise.
7076 (show_text_menu): Likewise.
7077 (get_and_remove_first_entry_number): New function.
7078 (grub_menu_execute_with_fallback): Likewise.
7079 (get_entry): Renamed to ...
7080 (grub_menu_get_entry): .. this and made it global.
7081 (get_timeout): Renamed to ...
7082 (grub_menu_get_timeout): ... this and made it global.
7083 (set_timeout): Renamed to ...
7084 (grub_menu_set_timeout): ... this and made it global.
7085 (grub_normal_terminal_menu_viewer): Renamed to ...
7086 (grub_normal_text_menu_viewer): ... this.
7087
7088 * normal/menu_text.c: New file. Extracted text-menu-specific code
7089 from normal/menu.c.
7090
7091 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
7092 (normal_mod_SOURCES): Likewise.
7093
7094 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7095 (normal_mod_SOURCES): Likewise.
7096
7097 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7098 (normal_mod_SOURCES): Likewise.
7099
7100 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
7101 (normal_mod_SOURCES): Likewise.
7102
7103 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7104 (normal_mod_SOURCES): Likewise.
7105
7106 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7107 (normal_mod_SOURCES): Likewise.
7108
7109 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7110 (normal_mod_SOURCES): Likewise.
7111
16ac430e 71122009-02-11 Robert Millan <rmh@aybabtu.com>
7113
7114 * util/grub.d/00_header.in: Update old reference to `font' command.
7115
06ff20fc 71162009-02-10 Felix Zielcke <fzielcke@z-51.de>
7117
7118 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
7119
7120 Based on patch from Javier Martín.
7121
96da9407 71222009-02-09 Felix Zielcke <fzielcke@z-51.de>
7123
7124 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
50fb7002 7125 to avoid false positives with FAT.
96da9407 7126 (grub_fstest_SOURCES): Likewise.
7127 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
7128 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7129 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7130 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7131 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7132 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7133
6dca6fe4 71342009-02-09 Felix Zielcke <fzielcke@z-51.de>
7135
06ff20fc 7136 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
6dca6fe4 7137 bpb.version_specific.fat12_or_fat16.fstype and
7138 bpb.version_specific.fat32.fstype.
7139
2550c62f 71402009-02-08 Robert Millan <rmh@aybabtu.com>
7141
be110b30 7142 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
2550c62f 7143
56978920 71442009-02-08 Robert Millan <rmh@aybabtu.com>
7145
7146 * Makefile.in (host_os, host_cpu): New variables.
7147 (target_os): Remove. Update all users.
7148
d64399b5 71492009-02-08 Marco Gerards <marco@gnu.org>
7150
7151 * Makefile.in (enable_grub_emu_usb): New variable.
7152 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
7153 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
7154 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
7155 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
7156 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
7157 `usbtest.mod' and `usbms.mod'.
7158 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
7159 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
7160 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
7161 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
7162 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
7163 variables.
7164
7165 * disk/usbms.c: New file.
7166
7167 * include/grub/usb.h: Likewise.
7168
7169 * include/grub/usbtrans.h: Likewise.
7170
7171 * include/grub/usbdesc.h: Likewise.
7172
7173 * bus/usb/usbtrans.c: Likewise.
7174
7175 * bus/usb/ohci.c: Likewise.
7176
7177 * bus/usb/uhci.c: Likewise.
7178
7179 * bus/usb/usbhub.c: Likewise.
7180
7181 * bus/usb/usb.c: Likewise.
7182
7183 * commands/usbtest.c: Likewise.
7184
7185 * util/usb.c: Likewise.
50fb7002 7186
d64399b5 7187 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
7188
7189 * configure.ac: Test for libusb presence.
50fb7002 7190
d64399b5 7191 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
7192
2b40d6bb 71932009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
7194
7195 * kern/mm.c: Add more comments.
7196
73a4ce81 71972009-02-08 Robert Millan <rmh@aybabtu.com>
7198
7199 Patch from Javier Martín.
7200 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
7201 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
7202
f821ce59 72032009-02-08 Robert Millan <rmh@aybabtu.com>
7204
7205 * fs/cpio.c: Split tar functionality to ...
7206 * fs/tar.c: ... here (new file). Update all users.
7207
aebfc4b0 72082009-02-07 Robert Millan <rmh@aybabtu.com>
7209
7210 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
7211 backward-incompatible features.
7212
7213 Based on patch from Javier Martín, with some adjustments.
7214
50fb7002 72152009-02-07 Michael Scherer <misc@mandriva.org>
cea15bca 7216
7217 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
7218
0bb5115e 72192009-02-07 Robert Millan <rmh@aybabtu.com>
7220
7221 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
7222 position of `disk/lvm.c' to ensure grub_init_all() always picks it
7223 after the RAID stuff.
7224
38a0f8e7 72252009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
7226
50fb7002 7227 Fixes problem when running vbetest command as reported by
38a0f8e7 7228 Vladimir Serbinenko <phcoder@gmail.com>.
7229
7230 * (grub_vbe_set_video_mode): Fixed problem with text modes.
7231
3143cc1c 72322009-02-04 Felix Zielcke <fzielcke@z-51.de>
7233
7234 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
7235 /dev/md/NpN style mdraid devices.
7236
9cba6fce 72372009-02-03 Felix Zielcke <fzielcke@z-51.de>
7238
7239 * util/unifont2pff.rb: Remove.
7240
e507a2c1 72412009-02-03 Felix Zielcke <fzielcke@z-51.de>
7242
7243 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
7244 `#'.
7245
d2c2b4cd 72462009-02-03 Felix Zielcke <fzielcke@z-51.de>
7247
7248 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
7249 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7250 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7251 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7252 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7253 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7254 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7255
b4315fb0 72562009-02-02 Christian Franke <franke@computer.org>
7257
7258 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
7259
de3aa260 72602009-02-01 Felix Zielcke <fzielcke@z-51.de>
7261
7c3ff286 7262 * INSTALL: Note that we now require at least autoconf 2.59 and
7263 that LZO is optional.
de3aa260 7264
825a182b 72652009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7266
7267 Base on patch on bug #24154 created by Tomas Tintera
7268 <trosos@seznam.cz>.
7269
7270 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
7271
a69ef770 72722009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7273
7c3ff286 7274 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
a69ef770 7275 <bero@arklinux.org>.
7276
7277 * normal/parser.y (script_init): Add missing semicolon.
7278
6fa42fa6 72792009-01-31 Colin D Bennett <colin@gibibit.com>
7280
7c3ff286 7281 * normal/main.c: Add include to grub/menu_viewer.h.
6fa42fa6 7282 (free_menu_entry_classes): Added.
7283 (grub_normal_menu_addentry): Added class property handling.
7284 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
7285 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
7286
7287 * normal/menu_viewer.c: New file.
7288
7289 * normal/menu.c (run_menu_entry): Renamed to ...
7290 (grub_menu_execute_entry): ... this and made it as global.
7291 (grub_menu_run): Renamed to ...
7292 (show_text_menu): ... this and made it local.
7293 (show_text_menu): Adapt to new function names.
7294 (grub_normal_terminal_menu_viewer): New global variable.
7295
7296 * include/grub/menu.h: New file.
7297
7298 * include/grub/menu_viewer.h: New file.
7299
7300 * include/grub/normal.h: Added include to grub/menu.h.
7301 (grub_menu_entry): Moved to include/grub/menu.h.
7302 (grub_menu_entry_t): Likewise.
7303 (grub_menu): Likewise.
7304 (grub_menu_t): Likewise.
7305 (grub_normal_terminal_menu_viewer): Added.
7306 (grub_menu_execute_entry): Likewise.
7307 (grub_menu_run): Removed.
7308
7309 * DISTLIST: Added include/grub/menu.h.
7310 Added include/grub/menu_viewer.h.
7311 Added normal/menu_viewer.c.
7312
73132009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
7314
7315 * normal/execute.c (grub_script_execute_menuentry): Changed to use
7316 arglist for menutitle arguments.
7317
7318 * normal/main.c (grub_normal_menu_addentry): Likewise.
7319
7320 * normal/parser.y (menuentry): Likewise.
7321
7322 * normal/script.c (grub_script_create_cmdmenu): Likewise.
7323
7324 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
7325 (grub_script_create_cmdmenu): Likewise.
7326
7327 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
7328
7329 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
7330 changes.
7331
7332 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
7333
7334 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
7335
7336 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
7337
7338 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7339
7340 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7341
7342 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7343
56192c23 73442009-01-30 Christian Franke <franke@computer.org>
7345
7346 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
7347 in option help text.
7348
d72521b3 73492009-01-27 Pavel Roskin <proski@gnu.org>
7350
7351 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
7352
994b5e84 73532009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7354
7355 * commands/lsmmap.c: Add include to grub/machine/memory.h.
7356
7357 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
7358
7359 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
7360 unregister function.
7361
6a7eab2c 73622009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7363
7364 * disk/scsi.c (grub_scsi_read): Fix sign problem.
7365
7366 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
7367
7368 * util/grub-mkfont.c (usage): Fix typo.
7369
7370 * util/elf/grub-mkimage.c (load_modules): Fix warning.
7371
1806b56e 73722009-01-26 Daniel Mierswa <impulze@impulze.org>
7373
3fb18f09 7374 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
7375
336e1fb9 7376 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
7377
1806b56e 7378 * kern/misc.c (grub_strcasecmp): New function.
7379 (grub_strcasecmp): Use grub_size_t instead of int for length.
7380 Fix return value.
7381 * include/grub/misc.h: Update function prototypes.
7382
580b2a0f 73832009-01-26 Robert Millan <rmh@aybabtu.com>
7384
7385 * configure.ac: Fix cross-compilation check.
ef257b36 7386
d31c24f1 73872009-01-22 Christian Franke <franke@computer.org>
7388
7389 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
7390 (precision) digit string. Allow `.format2' without `format1' (width).
7391 Limit input chars for `%s' output to `format2' if specified. This is
7392 compatible with standard printf ().
7393
3138b44c 73942009-01-22 Christian Franke <franke@computer.org>
7395
7396 * disk/ata.c (grub_ata_wait_status): Replace by ...
7397 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
7398 other status bits may be invalid while BSY is asserted.
7399 (grub_ata_check_ready): New function.
7400 (grub_ata_cmd): Removed.
7401 (grub_ata_wait_drq): New function.
7402 (grub_ata_strncpy): Remove inline.
7403 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
7404 and error check now done by grub_ata_wait_drq ().
7405 (grub_ata_pio_write): Likewise.
7406 (grub_atapi_identify): Set DEV before check for !BSY. Use
7407 grub_ata_wait_drq () to wait for data.
7408 (grub_ata_device_initialize): Add status register check to
7409 detect missing SATA slave devices. Add debug messages.
7410 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
7411 (grub_atapi_packet): Set DEV before check for !BSY. Replace
7412 transfer loop by grub_ata_pio_write ().
7413 (grub_ata_identify): Set DEV before check for !BSY. Use
7414 grub_ata_wait_drq () to wait for data.
ef257b36 7415 (grub_ata_setaddress): Set DEV before check for !BSY.
3138b44c 7416 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
7417 read/write in one loop. Fix invalid command on write. Fix incomplete
7418 command on (size % batch) == 0. Add missing error check after write of
7419 last block. Add debug messages.
7420 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
7421
59a64ef6 74222009-01-19 Christian Franke <franke@computer.org>
7423
7424 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
7425 (GRUB_ATAPI_IREASON_*): Likewise.
7426 (grub_ata_pio_write): Fix timeout error return.
7427 (grub_atapi_identify): Add grub_ata_wait () after cmd.
7428 (grub_atapi_wait_drq): New function.
7429 (grub_atapi_packet): New parameter `size'.
7430 Use grub_atapi_wait_drq () and direct write instead of
7431 grub_ata_pio_write ().
7432 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
7433 reads the number of bytes requested by the device for each DRQ
7434 assertion.
7435 (grub_atapi_write): Remove old implementation, return not
7436 implemented instead.
7437
1cfe20b3 74382009-01-19 Christian Franke <franke@computer.org>
7439
7440 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
7441 of 512 to calculate data size.
7442 (grub_scsi_read12): Likewise.
7443 (grub_scsi_write10): Likewise.
7444 (grub_scsi_write12): Likewise.
7445 (grub_scsi_read): Adjust size according to blocksize.
7446 Add checks for invalid blocksize and unaligned transfer.
7447
bee5fe5d 74482009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
7449
7450 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
7451
ef257b36 7452 * term/gfxterm.c (write_char): Fix background rendering for wide
bee5fe5d 7453 width glyphs.
7454
3e643f8c 74552009-01-19 Robert Millan <rmh@aybabtu.com>
7456
7457 * config.guess: Update to latest version from config git.
7458 * config.sub: Likewise.
7459
4fa80998 74602009-01-17 Felix Zielcke <fzielcke@z-51.de>
7461
7462 * Makefile.in: Change font compilation to use new grub-mkfont instead
7463 of java version.
7464
7465 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
7466 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
7467 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7468 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7469 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
7470 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
7471 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
7472 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
7473 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7474
7086085b 74752009-01-16 Christian Franke <franke@computer.org>
7476
7477 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
7478 (enum grub_ata_timeout_milliseconds): New enum.
7479 (grub_ata_wait_status): Add parameter milliseconds.
7480 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
7481 recovery from timed-out commands.
7482 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
7483 return grub_errno instead of REG_ERROR.
7484 (grub_ata_pio_write): Add parameter milliseconds.
7485 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
7486 Pass milliseconds to grub_ata_wait_status () and
7487 grub_ata_pio_read ().
7488 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
7489 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
7490 grub_ata_wait_status (). Fix IDENTIFY timeout check.
7491 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
7492 It is not suitable for device detection, because DEV bit is ignored,
7493 the command may run too long, and not all devices set the signature
7494 properly.
7495 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
7496 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
7497 Fix device selection, DEV bit must be set first to address the registers
7498 of the correct device.
7499 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
7500 grub_ata_pio_read/write ().
7501 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
7502 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
7503
4a412913 75042009-01-13 Carles Pina i Estany <carles@pina.cat>
7505
7506 * util/grub-editenv.c (main): Use fseeko(), not fseek().
7507
7795c55e 75082009-01-13 Bean <bean123ch@gmail.com>
d913988c 7509
7510 * util/grub-mkfont.c (write_font): forget to remove some debug code.
7511
7795c55e 75122009-01-13 Bean <bean123ch@gmail.com>
e52db1f7 7513
7514 * Makefile.in: (enable_grub_mkfont): New variable.
7515 (freetype_cflags): Likewise.
7516 (freetype_libs): Likewise.
7517
7518 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
7519 (grub_mkfont_SOURCES): New variable.
7520 (grub_mkfont_CFLAGS): Likewise.
7521 (grub_mkfont_LDFLAGS): Likewise.
7522
7523 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
7524 library if `--enable-grub-mkfont' is requested.
7525 (enable_grub_mkfont): New variable.
7526 (freetype_cflags): Likewise.
7527 (freetype_libs): Likewise.
7528
7529 * util/grub-mkfont.c: New file.
7530
093af1fe 75312009-01-12 Christian Franke <franke@computer.org>
7532
7533 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
7534 mode check. Fix setting of compat_use[].
7535
f36cc108 75362009-01-10 Robert Millan <rmh@aybabtu.com>
7537
7538 Update a few copyright years which we forgot to do in 2008 (only for
7539 files whose changes made in 2008 were copyright-significant)
7540
7541 * Makefile.in: Add 2008 to Copyright line.
7542 * disk/ieee1275/ofdisk.c: Likewise.
7543 * disk/efi/efidisk.c: Likewise.
7544 * kern/dl.c: Likewise.
7545 * kern/sparc64/ieee1275/init.c: Likewise.
7546 * kern/mm.c: Likewise.
7547 * kern/efi/mm.c: Likewise.
7548 * boot/i386/pc/boot.S: Likewise.
7549 * genfslist.sh: Likewise.
7550 * fs/iso9660.c: Likewise.
7551 * fs/hfs.c: Likewise.
7552 * fs/jfs.c: Likewise.
7553 * fs/minix.c: Likewise.
7554 * fs/ufs.c: Likewise.
7555 * gensymlist.sh.in: Likewise.
7556 * genkernsyms.sh.in: Likewise.
7557 * include/grub/misc.h: Likewise.
7558 * include/grub/types.h: Likewise.
7559 * include/grub/symbol.h: Likewise.
7560 * include/grub/elf.h: Likewise.
7561 * include/grub/kernel.h: Likewise.
7562 * include/grub/disk.h: Likewise.
7563 * include/grub/dl.h: Likewise.
7564 * include/grub/i386/linux.h: Likewise.
7565 * include/grub/i386/pc/biosdisk.h: Likewise.
7566 * include/grub/efi/api.h: Likewise.
7567 * include/grub/efi/pe32.h: Likewise.
7568 * include/grub/util/misc.h: Likewise.
7569 * normal/execute.c: Likewise.
7570 * normal/arg.c: Likewise.
7571 * normal/completion.c: Likewise.
7572 * normal/lexer.c: Likewise.
7573 * normal/parser.y: Likewise.
7574 * normal/misc.c: Likewise.
7575 * commands/i386/pc/vbeinfo.c: Likewise.
7576 * commands/hexdump.c: Likewise.
7577 * commands/terminal.c: Likewise.
7578 * commands/ls.c: Likewise.
7579 * commands/help.c: Likewise.
7580 * partmap/pc.c: Likewise.
7581 * loader/efi/chainloader.c: Likewise.
7582 * loader/multiboot_loader.c: Likewise.
7583 * loader/i386/pc/multiboot2.c: Likewise.
7584 * term/efi/console.c: Likewise.
7585 * term/i386/pc/serial.c: Likewise.
7586 * util/lvm.c: Likewise.
7587 * util/console.c: Likewise.
7588 * util/i386/efi/grub-mkimage.c: Likewise.
7589 * util/raid.c: Likewise.
7590
7f02114b 75912009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
7592
7593 * commands/videotest.c: Removed include to grub/machine/memory.h.
7594
7595 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
7596 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
7597 (video_mod_SOURCES): Removed.
7598 (video_mod_CFLAGS): Likewise.
7599 (video_mod_LDFLAGS): Likewise.
7600 (gfxterm_mod_SOURCES): Likewise.
7601 (gfxterm_mod_CFLAGS): Likewise.
7602 (gfxterm_mod_LDFLAGS): Likewise.
7603 (videotest_mod_SOURCES): Likewise.
7604 (videotest_mod_CFLAGS): Likewise.
7605 (videotest_mod_LDFLAGS): Likewise.
7606 (bitmap_mod_SOURCES): Likewise.
7607 (bitmap_mod_CFLAGS): Likewise.
7608 (bitmap_mod_LDFLAGS): Likewise.
7609 (tga_mod_SOURCES): Likewise.
7610 (tga_mod_CFLAGS): Likewise.
7611 (tga_mod_LDFLAGS): Likewise.
7612 (jpeg_mod_SOURCES): Likewise.
7613 (jpeg_mod_CFLAGS): Likewise.
7614 (jpeg_mod_LDFLAGS): Likewise.
7615 (png_mod_SOURCES): Likewise.
7616 (png_mod_CFLAGS): Likewise.
7617 (png_mod_LDFLAGS): Likewise.
7618
7619 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
7620 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
7621 (video_mod_SOURCES): Added.
7622 (video_mod_CFLAGS): Likewise.
7623 (video_mod_LDFLAGS): Likewise.
7624 (videotest_mod_SOURCES): Likewise.
7625 (videotest_mod_CFLAGS): Likewise.
7626 (videotest_mod_LDFLAGS): Likewise.
7627 (bitmap_mod_SOURCES): Likewise.
7628 (bitmap_mod_CFLAGS): Likewise.
7629 (bitmap_mod_LDFLAGS): Likewise.
7630 (tga_mod_SOURCES): Likewise.
7631 (tga_mod_CFLAGS): Likewise.
7632 (tga_mod_LDFLAGS): Likewise.
7633 (jpeg_mod_SOURCES): Likewise.
7634 (jpeg_mod_CFLAGS): Likewise.
7635 (jpeg_mod_LDFLAGS): Likewise.
7636 (png_mod_SOURCES): Likewise.
7637 (png_mod_CFLAGS): Likewise.
7638 (png_mod_LDFLAGS): Likewise.
7639 (gfxterm_mod_SOURCES): Likewise.
7640 (gfxterm_mod_CFLAGS): Likewise.
7795c55e 7641 (gfxterm_mod_LDFLAGS): Likewise.
7f02114b 7642
7643 * term/gfxterm.c: Removed include to grub/machine/memory.h,
7644 grub/machine/console.h.
7645
644fff97 76462009-01-04 Jerone Young <jerone@gmail.com>
7647
7648 Make on screen instructions clearer
7649
7650 Based on patch created by Jidanni <jidanni@jidanni.org>
7651
7652 * normal/menu.c: print clearer instructions on the screen
7653
1e901a75 76542009-01-02 Colin D Bennett <colin@gibibit.com>
7655
7656 New font engine.
34c44600 7657
1e901a75 7658 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
7659 build system and fixed gfxterm.c to work with different sized fonts.
7660
7661 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
34c44600 7662
1e901a75 7663 * configure: Re-generated.
34c44600 7664
1e901a75 7665 * DISTLIST: Removed font/manager.c.
7666 Added font/font.c.
7667 Added font/font_cmd.c.
34c44600 7668
1e901a75 7669 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
7670 compilation.
34c44600 7671
1e901a75 7672 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
34c44600 7673
7674 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
1e901a75 7675
7676 * kern/term.c: Changed users of grub_utf8_to_ucs4.
34c44600 7677
1e901a75 7678 * normal/menu.c: Likewise.
34c44600 7679
1e901a75 7680 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
7681 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
34c44600 7682
1e901a75 7683 * include/grub/font.h: Replaced with new file.
34c44600 7684
1e901a75 7685 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
7686 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
7687 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
7688 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
7689 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
34c44600 7690 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
1e901a75 7691 fg_red, fg_green, fg_blue, fg_alpha.
7692 (grub_video_adapter): Removed blit_glyph.
34c44600 7693 (grub_video_blit_glyph): Removed.
7694
1e901a75 7695 * font/manager.c: Removed file.
34c44600 7696
7697 * font/font.c: New file.
7698
1e901a75 7699 * font/font_cmd.c: Likewise.
34c44600 7700
1e901a75 7701 * video/video.c (grub_video_blit_glyph): Removed.
34c44600 7702
1e901a75 7703 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
7704 (grub_video_vbe_map_rgba): Likewise.
7705 (grub_video_vbe_unmap_color_int): Likewise.
7706 (grub_video_vbe_blit_glyph): Removed.
7707 (grub_video_vbe_adapter): Removed blit_glyph.
34c44600 7708
1e901a75 7709 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
7710 (get_pixel): Likewise.
34c44600 7711 (set_pixel): Likewise.
7712
1e901a75 7713 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
34c44600 7714
1e901a75 7715 * term/gfxterm.c: Adapted to new font engine.
34c44600 7716
1e901a75 7717 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
34c44600 7718
1e901a75 7719 * term/i386/pc/vga.c: Likewise.
34c44600 7720
1e901a75 7721 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
34c44600 7722
1e901a75 7723 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
34c44600 7724
1e901a75 7725 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7726
1e901a75 7727 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7728
1e901a75 7729 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
34c44600 7730
1e901a75 7731 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
34c44600 7732
1e901a75 7733 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
34c44600 7734
1e901a75 7735 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
34c44600 7736
1e901a75 7737 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7738
7739 * util/grub.d/00_header.in: Changed to use new loadfont command.
34c44600 7740
1e901a75 7741 * util/grub-mkconfig_lib.in: Changed font extension.
7742
278922e8 77432008-12-28 Felix Zielcke <fzielcke@z-51.de>
7744
7745 * util/getroot.c (grub_util_get_grub_dev): Add support for
7746 /dev/md/dNNpNN style partitionable mdraid devices.
7747
3ced05cf 77482008-12-12 Alex Smith <alex@alex-smith.me.uk>
7749
7750 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
7751 at a time limit of the PXE TFTP API correctly.
7752 (grub_pxefs_close): Likewise.
7753
7fd0ee30 77542008-11-29 Robert Millan <rmh@aybabtu.com>
7755
34c44600 7756 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
7fd0ee30 7757 grub_ata_device_initialize() calls.
7758
34c44600 77592008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
0c5e79ab 7760
7761 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
7762 iteration failed.
7763 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
7764
89313780 77652008-11-28 Robert Millan <rmh@aybabtu.com>
7766
7767 Fix build on powerpc-ieee1275. Based on patch created by
7768 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
7769 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
7770 `kern/ieee1275/mmap.c'.
7771 * include/grub/powerpc/ieee1275/memory.h: New file.
7772
15257703 7773 Provide grub-install on coreboot.
7774 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
7775 (grub_install_SOURCES): New variable.
7776 * util/i386/pc/grub-install.in: Add a few condition checks to make it
7777 usable on coreboot.
7778
9fc5388a 77792008-11-25 Felix Zielcke <fzielcke@z-51.de>
7780
7781 * util/grub-fstest.c (grub_term_get_current_input): Change return type
7782 to `grub_term_input_t'.
7783 (grub_term_get_current_output): Change return type to
7784 `grub_term_output_t'.
7785
bc3a2f31 77862008-11-22 Robert Millan <rmh@aybabtu.com>
7787
34c44600 7788 Fix breakage on coreboot due to declaration mismatch.
bc3a2f31 7789 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
7790 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
7791 grub_vga_text_cls().
7792
80fc88f2 7793 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
34c44600 7794 comments. Avoid copying one more byte than necessary (just in case).
80fc88f2 7795
cbf36fd3 7796 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
7797 to 0x200000 (avoids trouble with some OFW implementations, and matches
7798 with the one in Yaboot).
7799 Reported by Manoel Abranches
7800
73e8e268 78012008-11-20 Robert Millan <rmh@aybabtu.com>
3cf6ac19 7802
7803 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
7804 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
7805
73e8e268 7806 * util/grub-mkconfig_lib.in (grub_warn): New function.
7807 (convert_system_path_to_grub_path): Use grub_warn() when issuing
7808 warnings, to obtain consistent formatting.
7809 * util/grub.d/00_header.in: Likewise.
7810 * util/update-grub_lib.in: Likewise.
7811
e94045a1 7812 * loader/i386/linux.c (allocate_pages): Fix a warning.
40f9faa4 7813 Move comment text to `#error' stanza.
e94045a1 7814
79d29fd7 7815 Harmonize ieee1275's grub_available_iterate() with the generic
7816 grub_machine_mmap_iterate() interface (fixes a recently-introduced
7817 build problem on i386-ieee1275):
7818 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
7819 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
7820 parameter `type'. Update all users of this function.
7821 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
7822 `kern/ieee1275/mmap.c'.
7823 * kern/ieee1275/init.c
7824 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
7825 with ...
7826 (grub_machine_mmap_iterate): ... this.
7827 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
7828 return type to `grub_err_t'. Update all implementations of this
7829 function prototype.
7830 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
7831 Likewise.
7832
60d6b16e 7833 Add `lsmmap' command (lists firmware-provided memory map):
7834 * commands/lsmmap.c: New file.
7835 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
7836 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
7837 variables.
7838 * conf/powerpc-ieee1275.rmk: Likewise.
7839 * conf/i386-coreboot.rmk: Likewise.
7840 * conf/i386-ieee1275.rmk: Likewise.
7841
ebaaf49b 78422008-11-19 Robert Millan <rmh@aybabtu.com>
7843
7844 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
92907110 7845 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
7846 constraints to initrd allocation (based on code from
7847 loader/i386/pc/linux.c). Without them, initrd was allocated too high
7848 for Linux to find it.
ebaaf49b 7849
dfab719f 78502008-11-14 Robert Millan <rmh@aybabtu.com>
7851
7852 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
7853 order to cope with duplicate slashes.
7854
10fc3eb9 78552008-11-14 Robert Millan <rmh@aybabtu.com>
7856
7857 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
7858 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
7859 don't want to mess with lower memory, because it is used in the Linux
7860 loader.
7861
7862 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
34c44600 7863 an appropriate place in lower memory, between 0x10000 and 0x90000,
10fc3eb9 7864 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
7865 is in our heap (probably as a result of it being corrupted during
2f2a3442 7866 decompression). Add #error instance with comment to explain why this
7867 loader isn't currently usable on PC/BIOS.
10fc3eb9 7868
e2e07847 78692008-11-14 Robert Millan <rmh@aybabtu.com>
7870
7871 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
34c44600 7872 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
e2e07847 7873
fe8e8d69 78742008-11-12 Robert Millan <rmh@aybabtu.com>
7875
7876 Make loader/i386/linux.c buildable on i386-pc (although disabled).
7877
7878 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
7879 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
7880 from here ...
7881 * include/grub/i386/pc/memory.h: ... to here.
7882
976b07d0 78832008-11-12 Robert Millan <rmh@aybabtu.com>
7884
7885 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
7886 split).
7887
7888 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
7889 (grub_console_cur_color, grub_console_real_putchar)
7890 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7891 (grub_console_setcolorstate, grub_console_setcolor)
7892 (grub_console_getcolor): Move from here ...
7893 * include/grub/i386/vga_common.h: ... to here (new file).
7894
7895 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
7896 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
7897 `<grub/i386/io.h>'.
7898 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
7899 `<grub/i386/vga_common.h>'.
7900
76679cd3 79012008-11-12 Robert Millan <rmh@aybabtu.com>
7902
7903 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
7904 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
7905 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
7906 variables.
7907 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7908 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
7909
7910 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
7911 grub_console_init() with call to grub_vga_text_init().
7912 (grub_machine_fini): Replace call to
7913 grub_console_fini() with call to grub_vga_text_fini() and
7914 grub_at_keyboard_fini().
7915
7916 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
7917 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7918 (grub_console_setcolorstate, grub_console_setcolor)
7919 (grub_console_getcolor): New function prototypes.
7920
7921 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
7922 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
7923 (grub_vga_text_setcursor): Static-ize.
7924 (grub_vga_text_term): New structure.
7925 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
7926
7927 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
7928 (grub_console_cur_color, grub_console_standard_color)
7929 (grub_console_normal_color, grub_console_highlight_color)
7930 (map_char, grub_console_putchar, grub_console_getcharwidth)
7931 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
7932 (grub_console_getcolor): Move from here ...
7933 * term/i386/vga_common.c: ... to here (same function names).
7934
95b841d3 79352008-11-12 Robert Millan <rmh@aybabtu.com>
7936
7937 Use newly-added Multiboot support in coreboot.
7938
7939 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7940 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
7941
7942 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
7943 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
7944 (codestart): Store the MBI in `startup_multiboot_info' when we're
7945 being loaded using Multiboot.
7946
7947 * kern/i386/coreboot/init.c (grub_machine_init): Move
7948 grub_at_keyboard_init() call to beginning of function (useful for
7949 debugging). Call grub_machine_mmap_init() before attempting to use
7950 grub_machine_mmap_iterate().
7951 (grub_lower_mem, grub_upper_mem): Move from here ...
7952 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
7953 here (new file).
7954
7955 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
7956 function prototype.
7957
761ca975 79582008-11-12 Robert Millan <rmh@aybabtu.com>
7959
7960 Fix a regression introduced by the at_keyboard.mod split. Because
7961 some terminals are default on some platforms and non-default on
7962 others, the first terminal being registered determines which is
7963 going to be default.
7964
7965 * kern/term.c (grub_term_register_input): If this is the first
7966 terminal being registered, set it as the current one.
7967 (grub_term_register_output): Likewise.
7968
7969 * term/efi/console.c (grub_console_init): Do not call
7970 grub_term_set_current_output() or grub_term_set_current_input().
7971 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
7972 * term/i386/pc/console.c (grub_console_init): Likewise.
7973 (grub_console_fini): Do not call grub_term_set_current_input()
7974 (but leave grub_term_set_current_output() to restore text mode).
7975
6c529df7 79762008-11-10 Robert Millan <rmh@aybabtu.com>
7977
7978 * util/grub.d/00_header.in: Add backward compatibility check for
7979 versions of terminal.mod that don't understand `terminal_input' or
7980 `terminal_output'.
7981
132e4113 79822008-11-09 Robert Millan <rmh@aybabtu.com>
7983
7984 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
7985 `terminal_input' / `terminal_output', not `terminal'.
7986
ac293d50 79872008-11-08 Robert Millan <rmh@aybabtu.com>
7988
7989 * Makefile.in (include_DATA): Fix srcdir=. assumption.
2a9c5940 7990 (DISTCLEANFILES): Add `build_env.mk'.
ac293d50 7991
0025933a 79922008-11-08 Robert Millan <rmh@aybabtu.com>
7993
7994 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
dba3f844 7995 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
0025933a 7996 members. Update all users.
7997 * util/console.c (grub_ncurses_term): Split in ...
7998 (grub_ncurses_term_input): ... this, and ...
7999 (grub_ncurses_term_output): ... this. Update all users.
dcb6fa0a 8000 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
0025933a 8001
37c86336 80022008-11-08 Robert Millan <rmh@aybabtu.com>
8003
8004 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
8005 (PKGDATA): Add $(pkgdata_SRCDIR).
8006 (pkglib_BUILDDIR): New variable.
8007 (pkgdata_SRCDIR): New variable.
8008 (build_env.mk): New target.
8009 (include_DATA): New variable.
8010 (install-local): Install $(include_DATA) files in $(includedir).
8011
b6c15a2d 80122008-11-07 Pavel Roskin <proski@gnu.org>
8013
d99d46f1 8014 * gendistlist.sh: Use C locale for sorting to ensure consistent
8015 output on all systems.
8016
b6c15a2d 8017 * util/grub.d/00_header.in: Remove incorrect space before
8018 "serial".
8019
c32ee8c9 80202008-11-07 Robert Millan <rmh@aybabtu.com>
8021
8022 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
8023 per specification.
8024 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
8025 * loader/multiboot_loader.c (find_multi_boot2_header): New function
8026 (based on find_multi_boot1_header).
8027 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
8028 using find_multi_boot2_header(), and abort if neither Multiboot or
8029 Multiboot headers were found.
8030
651c29b7 80312008-11-07 Robert Millan <rmh@aybabtu.com>
8032
8033 Modularize at_keyboard.mod:
8034
8035 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
8036 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
8037 (at_keyboard_mod_LDFLAGS): New variables.
8038
8039 Actual terminal split:
8040
8041 * include/grub/term.h (struct grub_term): Split in ...
8042 (struct grub_term_input): ... this, and ...
8043 (struct grub_term_output): ... this. Update all users.
8044 (grub_term_set_current): Split in ...
8045 (grub_term_set_current_input): ... this, and ...
8046 (grub_term_set_current_output): ... this.
8047 (grub_term_get_current): Split in ...
8048 (grub_term_get_current_input): ... this, and ...
8049 (grub_term_get_current_output): ... this.
8050 (grub_term_register): Split in ...
8051 (grub_term_register_input): ... this, and ...
8052 (grub_term_register_output): ... this.
8053 (grub_term_unregister): Split in ...
8054 (grub_term_unregister_input): ... this, and ...
8055 (grub_term_unregister_output): ... this.
8056 (grub_term_iterate): Split in ...
8057 (grub_term_iterate_input): ... this, and ...
8058 (grub_term_iterate_output): ... this.
8059
8060 * kern/term.c (grub_term_list): Split in ...
8061 (grub_term_list_input): ... this, and ...
8062 (grub_term_list_output): ... this. Update all users.
8063 (grub_cur_term): Split in ...
8064 (grub_cur_term_input): ... this, and ...
8065 (grub_cur_term_output): ... this. Update all users.
8066 (grub_term_set_current): Split in ...
8067 (grub_term_set_current_input): ... this, and ...
8068 (grub_term_set_current_output): ... this.
8069 (grub_term_get_current): Split in ...
8070 (grub_term_get_current_input): ... this, and ...
8071 (grub_term_get_current_output): ... this.
8072 (grub_term_register): Split in ...
8073 (grub_term_register_input): ... this, and ...
8074 (grub_term_register_output): ... this.
8075 (grub_term_unregister): Split in ...
8076 (grub_term_unregister_input): ... this, and ...
8077 (grub_term_unregister_output): ... this.
8078 (grub_term_iterate): Split in ...
8079 (grub_term_iterate_input): ... this, and ...
8080 (grub_term_iterate_output): ... this.
8081
8082 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
8083 a check for input and one for output (and only attempt to get keys
8084 from user when input works).
8085
8086 * util/grub-probe.c (grub_term_get_current): Split in ...
8087 (grub_term_get_current_input): ... this, and ...
8088 (grub_term_get_current_output): ... this.
8089 * util/grub-fstest.c: Likewise.
8090 * util/i386/pc/grub-setup.c: Likewise.
8091 * util/grub-editenv.c: Likewise.
8092
8093 Portability adjustments:
8094
8095 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
8096 `term/i386/pc/at_keyboard.c'.
8097 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
8098 grub_keyboard_controller_init() (now handled by terminal .init).
8099 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
8100 grub_at_keyboard_init().
8101 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
8102 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
8103 at_keyboard.mod via input terminal interface).
8104 * include/grub/i386/coreboot/console.h: Convert into a stub for
8105 `<grub/i386/pc/console.h>'.
8106
8107 Migrate full terminals to new API:
8108
8109 * term/efi/console.c (grub_console_term): Split into ...
8110 (grub_console_term_input): ... this, and ...
8111 (grub_console_term_output): ... this. Update all users.
8112 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
8113 (grub_ofconsole_init): Split into ...
8114 (grub_ofconsole_init_input): ... this, and ...
8115 (grub_ofconsole_init_output): ... this.
8116 (grub_ofconsole_term): Split into ...
8117 (grub_ofconsole_term_input): ... this, and ...
8118 (grub_ofconsole_term_output): ... this. Update all users.
8119 * term/i386/pc/serial.c (grub_serial_term): Split into ...
8120 (grub_serial_term_input): ... this, and ...
8121 (grub_serial_term_output): ... this. Update all users.
8122 * term/i386/pc/console.c (grub_console_term): Split into ...
8123 (grub_console_term_input): ... this, and ...
8124 (grub_console_term_output): ... this. Update all users.
8125 (grub_console_term_input): Only enable it on PC/BIOS platform.
8126 (grub_console_init): Remove grub_keyboard_controller_init() call.
8127
8128 Migrate input terminals to new API:
8129
8130 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
8131 `i386' and `i386/pc' to enable build on x86_64 (this driver is
8132 i386-specific anyway).
8133 (grub_console_checkkey): Rename to ...
8134 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
8135 users.
8136 (grub_keyboard_controller_orig): New variable.
8137 (grub_console_getkey): Rename to ...
8138 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
8139 users.
8140 (grub_keyboard_controller_init): Static-ize. Save original
8141 controller value so that it can be restored ...
8142 (grub_keyboard_controller_fini): ... here (new function).
8143 (grub_at_keyboard_term): New structure.
8144 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
8145 functions.
8146
8147 Migrate output terminals to new API:
8148
8149 * term/i386/pc/vga.c (grub_vga_term): Change type to
8150 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8151 members. Update all users.
8152 * term/gfxterm.c (grub_video_term): Change type to
8153 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8154 members. Update all users.
8155 * include/grub/i386/pc/console.h (grub_console_checkkey)
8156 (grub_console_getkey): Do not export (no longer needed by gfxterm,
8157 etc).
8158
8159 Migrate `terminal' command and userland tools to new API:
8160
8161 * commands/terminal.c (grub_cmd_terminal): Split into ...
8162 (grub_cmd_terminal_input): ... this, and ...
8163 (grub_cmd_terminal_output): ... this.
8164 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
8165 `terminal_input' and `terminal_output'.
8166 * util/grub.d/00_header.in: Adjust `terminal' calls to new
8167 `terminal_input' / `terminal_output' API.
8168 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
8169 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
8170 provided ${GRUB_TERMINAL}, convert it).
8171
96e5d876 81722008-11-04 Robert Millan <rmh@aybabtu.com>
8173
8174 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
8175 for FreeBSD.
8176 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
8177
556f3775 81782008-11-03 Bean <bean123ch@gmail.com>
8179
8180 * kern/elf.c (grub_elf32_load): Revert to previous code.
8181 (grub_elf64_load): Likewise.
8182
8183 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
8184
926b9823 81852008-11-01 Robert Millan <rmh@aybabtu.com>
8186
8187 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
8188 (TARGET_CPPFLAGS): Likewise.
8189 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
8190
1432e958 81912008-11-01 Carles Pina i Estany <carles@pina.cat>
8192
8193 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
8194
dba3f844 81952008-10-29 Guillem Jover <guillem.jover@nokia.com>
de4fa71c 8196
8197 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
8198 addition of objects until the code is not going to be able to fail.
8199
dba3f844 82002008-10-29 Guillem Jover <guillem.jover@nokia.com>
b7279447 8201
8202 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
8203 (add a missing NULL check, and correct them by moving the pointer
8204 operations after the actual check).
8205
7ab28c21 82062008-10-29 Robert Millan <rmh@aybabtu.com>
8207
8208 * util/i386/pc/grub-install.in: Handle empty string as output from
8209 make_system_path_relative_to_its_root().
8210
1b7748eb 82112008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
8212
8213 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
8214 circular metadata worst case scenario. If the metadata is circular
8215 then copy the wrap in place.
8216 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
8217 project lib/format_text/layout.h
8218 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
8219
c9618ab2 82202008-10-03 Felix Zielcke <fzielcke@z-51.de>
8221
7a36edca 8222 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
c9618ab2 8223
bf981c62 82242008-10-03 Felix Zielcke <fzielcke@z-51.de>
8225
8226 * util/update-grub_lib.in: Mention filename in warning message.
8227
6d994591 82282008-09-29 Felix Zielcke <fzielcke@z-51.de>
8229
8230 * NEWS: Update for rename of update-grub to grub-mkconfig.
8231
18ade780 82322008-09-29 Felix Zielcke <fzielcke@z-51.de>
8233
8234 * util/update-grub_lib.in: Copy to ...
8235 * util/grub-mkconfig_lib.in: ... this. Update all users.
7c3ff286 8236 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
18ade780 8237 * util/update-grub.in: Rename to ...
8238 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
8239 option. Add `--output' option to allow users to specify the generated
8240 configuration file. Default to stdout.
8241 (update_grub_dir): Rename to ...
8242 (grub_mkconfig_dir): ... this.
8243 (grub_cfg): Default to an empty string.
8244 * conf/common.rmk (update-grub): Rename to ...
8245 (grub-mkconfig): ... this.
8246 (update-grub_lib): Copy to ...
8247 (grub-mkconfig_lib): ... this.
8248 (update-grub_SCRIPTS): Copy to ...
8249 (grub-mkconfig_SCRIPTS): ... this. Update all users.
8250 (update-grub_DATA): Rename to ...
8251 (grub-mkconfig_DATA): ... this.
8252
556ce6ac 82532008-09-28 Robert Millan <rmh@aybabtu.com>
8254
8255 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
8256 to `modified'. Add the real `created' field.
8257 (grub_iso9660_uuid): Use `modified' rather than `created' for
8258 constructing the UUID.
8259
82602008-09-28 Felix Zielcke <fzielcke@z-51.de>
eb079ba9 8261
8262 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
8263 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
8264
92274e85 82652008-09-28 Bean <bean123ch@gmail.com>
8266
8267 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
8268 Thanks to Christian Franke for finding this bug.
8269
add6f17a 82702008-09-25 Robert Millan <rmh@aybabtu.com>
8271
8272 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
8273 instances of grub_util_get_disk_name() (see previous commit).
8274
d2a367b8 82752008-09-25 Robert Millan <rmh@aybabtu.com>
8276
8277 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
8278 `util/i386/get_disk_name.c'.
8279 * conf/i386-efi.rmk: Likewise.
8280 * conf/x86_64-efi.rmk: Likewise.
8281 * conf/i386-coreboot.rmk: Likewise.
8282 * conf/i386-ieee1275.rmk: Likewise.
8283 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
8284 `util/ieee1275/get_disk_name.c'.
8285 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
8286 * util/ieee1275/get_disk_name.c: Remove file.
8287 * util/i386/get_disk_name.c: Remove file.
8288 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
8289 "hd%d" for device.map entries, rather than using
8290 grub_util_get_disk_name().
8291
81a06771 82922008-09-24 Carles Pina i Estany <carles@pina.cat>
b0c301f7 8293
8294 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
8295 warning.
8296 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
8297
5a004279 82982008-09-24 Carles Pina i Estany <carles@pina.cat>
8299
8300 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
8301 Changed to 0x5100.
8302 (GRUB_TERM_PPAGE): Changed to 0x4900.
8303
397093d3 83042008-09-24 Robert Millan <rmh@aybabtu.com>
8305
8306 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
8307 macros (they were i386-pc specific).
8308 * include/grub/sparc64/ieee1275/console.h: Likewise.
8309 * include/grub/efi/console.h: Likewise.
8310
a91b6c7c 83112008-09-22 Bean <bean123ch@gmail.com>
8312
8313 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
8314 resident and in attribute list.
8315
8316 * include/grub/ntfs.h (BMP_LEN): Removed.
8317
c40fd116 83182008-09-22 Bean <bean123ch@gmail.com>
8319
81a06771 8320 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
c40fd116 8321 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
8322
8323 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
8324 error occurs, as grub_disk_open will call grub_disk_close, which will
8325 call p->close (scsi).
8326
81a06771 83272008-09-21 Felix Zielcke <fzielcke@z-51.de>
eb73121d 8328
8329 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
8330 (AC_PREREQ): Bumped to 2.59.
8331 (AC_TRY_COMPILE): Replace obsolete macro with ...
8332 (AC_COMPILE_IFELSE): ... this.
8333 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
8334 (AC_LINK_IFELSE): ... this.
8335
5dc43410 83362008-09-21 Felix Zielcke <fzielcke@z-51.de>
8337
8338 * autogen.sh: Add a call to `gendistlist.sh'.
8339
9035dce4 83402008-09-19 Christian Franke <franke@computer.org>
8341
8342 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
8343 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
8344 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
8345 Export __enable_execute_stack() to modules.
8346 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
8347 New function.
8348
7fd75377 83492008-09-09 Felix Zielcke <fzielcke@z-51.de>
8350
040030b3 8351 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
8352 Sort the list.
8353
83542008-09-09 Felix Zielcke <fzielcke@z-51.de>
8355
8356 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
7fd75377 8357 #include <grub/util/hostdisk.h>.
8358
89d5ffcf 83592008-09-08 Robert Millan <rmh@aybabtu.com>
8360
8361 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
8362 segments when their filesz is zero (grub_file_read() interprets
81a06771 8363 zero-size as "read until EOF", which results in memory corruption).
89d5ffcf 8364 Use `lowest_segment' rather than 0 for calculating the current
8365 segment load address.
8366
40da438f 83672008-09-08 Robert Millan <rmh@aybabtu.com>
8368
8369 * util/hostdisk.c (open_device): Replace a grub_util_info() call
8370 with grub_dprintf("hostdisk", ...), as it was so verbose that it
8371 clobbered useful information.
8372
ddbf5556 83732008-09-08 Robert Millan <rmh@aybabtu.com>
8374
8375 * include/grub/util/biosdisk.h: Move to ...
8376 * include/grub/util/hostdisk.h: ... here. Update all users.
8377 * util/biosdisk.c: Move to ...
8378 * util/hostdisk.c: ... here. Update all users.
8379
783d0f48 83802008-09-07 Robert Millan <rmh@aybabtu.com>
8381
8382 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
8383 variables.
8384 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
8385 and length can be stored directly in the `mbi->mmap_addr' and
8386 `mbi->mmap_length' struct fields.
8387
548e2ea5 83882008-09-07 Robert Millan <rmh@aybabtu.com>
8389
8390 * conf/i386.rmk: New file. Provides declaration for building
8391 `cpuid.mod'.
8392 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
8393 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
8394 variables.
8395 Include `conf/i386.mk'.
8396 * conf/i386-efi.rmk: Likewise.
8397 * conf/x86_64-efi.rmk: Likewise.
8398 * conf/i386-coreboot.rmk: Likewise.
8399 * conf/i386-ieee1275.rmk: Likewise.
8400
0ea85a37 84012008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
8402
8403 Based on patch created by Colin D Bennett <colin@gibibit.com>.
8404 Adds optimization support for BGR based modes.
8405
8406 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
8407 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8408 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8409 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8410 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8411 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8412 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8413 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8414 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8415 (grub_video_i386_vbeblit_index_index): Likewise.
8416 (grub_video_i386_vbeblit_replace_directN): Added.
8417 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8418 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8419 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8420 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8421 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8422 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
81a06771 8423 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
0ea85a37 8424 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8425 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8426 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8427 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8428 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8429 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
8430
8431 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
8432 (grub_video_i386_vbefill_R8G8B8): Likewise.
8433 (grub_video_i386_vbefill_index): Likewise.
8434 (grub_video_i386_vbefill_direct32): Added.
8435 (grub_video_i386_vbefill_direct24): Likewise.
8436 (grub_video_i386_vbefill_direct16): Likewise.
8437 (grub_video_i386_vbefill_direct8): Likewise.
8438
81a06771 8439 * include/grub/video.h (grub_video_blit_format): Removed
0ea85a37 8440 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
8441 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
8442 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
8443 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
8444 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
81a06771 8445
0ea85a37 8446 * video/video.c (grub_video_get_blit_format): Updated to use new
8447 blit formats. Added handling for 16 bit color modes.
81a06771 8448
8449 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
0ea85a37 8450 fillers.
8451 (common_blitter): Updated to use new blitters.
8452
8453 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
8454 Removed.
8455 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8456 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8457 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8458 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8459 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8460 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8461 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8462 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8463 (grub_video_i386_vbeblit_index_index): Likewise.
8464 (grub_video_i386_vbeblit_replace_directN): Added.
8465 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8466 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8467 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8468 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8469 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8470 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
8471 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
8472 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8473 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8474 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8475 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8476 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8477 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
81a06771 8478
0ea85a37 8479 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
8480 (grub_video_i386_vbefill_R8G8B8): Likewise.
8481 (grub_video_i386_vbefill_index): Likewise.
8482 (grub_video_i386_vbefill_direct32): Added.
8483 (grub_video_i386_vbefill_direct24): Likewise.
8484 (grub_video_i386_vbefill_direct16): Likewise.
8485 (grub_video_i386_vbefill_direct8): Likewise.
81a06771 8486
0ea85a37 8487 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
8488 types.
81a06771 8489
0ea85a37 8490 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
8491 types.
81a06771 8492
0ea85a37 8493 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
8494 blitter types.
81a06771 8495
0ea85a37 8496 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
8497 types.
8498
e8a83df6 84992008-09-06 Felix Zielcke <fzielcke@z-51.de>
8500
8501 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
8502 RAID level 1.
8503
6bcd8ee5 85042008-09-06 Felix Zielcke <fzielcke@z-51.de>
c375ae58 8505
6bcd8ee5 8506 * fs/iso9660.c (grub_iso9660_date): New structure.
8507 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
8508 (grub_iso9660_uuid): New function.
c375ae58 8509
59261157 85102008-09-05 Bean <bean123ch@gmail.com>
8511
8512 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
8513
8514 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
8515 insensitive bit for names in Win32 and Win32 & DOS namespace.
8516
8517 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
8518
8519 * include/grub/types.h (LONG_MAX): Likewise.
8520
58b6645a 85212008-09-04 Felix Zielcke <fzielcke@z-51.de>
8522
4ee55921 8523 * util/getroot.c: Include <config.h>.
8524 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
8525 add support for /dev/md/N devices and handle LVM double dash escaping.
8526
85272008-09-04 Felix Zielcke <fzielcke@z-51.de>
8528
8529 * config.guess: Update to latest version from config git.
8530 * config.sub: Likewise.
58b6645a 8531
9124f65d 85322008-09-03 Robert Millan <rmh@aybabtu.com>
8533
8534 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
8535 `disk->total_sectors'.
8536
81a06771 85372008-09-01 Colin D Bennett <colin@gibibit.com>
a0224a4e 8538
8539 * include/grub/normal.h: Fixed incorrect comment for
8540 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
8541
81a06771 85422008-09-01 Colin D Bennett <colin@gibibit.com>
f0619958 8543
8544 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
8545 values with defines.
8546
8547 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
8548 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
8549 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
8550 (GRUB_VBE_MODEATTR_COLOR): Likewise.
8551 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
8552 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
8553 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
8554 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
8555 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
8556 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
8557 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
8558 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
8559 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
8560 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
8561 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
8562 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
8563 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
8564 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
8565 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
8566
93d5cbf8 85672008-08-31 Robert Millan <rmh@aybabtu.com>
8568
8569 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
8570 declaration.
8571 (grub_multiboot): Fix a few warnings.
8572
21751d50 85732008-08-31 Robert Millan <rmh@aybabtu.com>
8574
8575 * loader/i386/pc/multiboot.c: Update comment not to say that
8576 boot_device support is unimplemented.
8577
e27a75c5 85782008-08-31 Robert Millan <rmh@aybabtu.com>
8579
8580 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
8581 or memory map support are unimplemented.
8582
81a06771 85832008-08-31 Colin D Bennett <colin@gibibit.com>
64d2d53c 8584
8585 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
8586
81a06771 85872008-08-31 Colin D Bennett <colin@gibibit.com>
c08a6c18 8588
8589 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
8590 total video memory in 'vbeinfo' output; show color format details for
8591 each video mode.
8592
7c5d8d95 85932008-08-30 Pavel Roskin <proski@gnu.org>
8594
8595 * util/genmoddep.c: Remove for real this time.
8596 * DISTLIST: Remove util/genmoddep.c.
8597
4cebd25a 85982008-08-30 Robert Millan <rmh@aybabtu.com>
8599
8600 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
8601 as required by Multiboot spec (it was already 4-byte aligned, but
8602 only by chance).
8603
b497a269 86042008-08-29 Pavel Roskin <proski@gnu.org>
8605
e3925185 8606 * kern/powerpc/ieee1275/crt0.S: Rename to ...
8607 * kern/powerpc/ieee1275/startup.S: ... this.
8608 * conf/powerpc-ieee1275.rmk: Adjust for the above.
8609 * DISTLIST: Likewise.
8610
b497a269 8611 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
8612 grub/cpu/kernel.h. Add start label for consistency with other
8613 platforms. Add grub_prefix immediately after start. Add jump
8614 to the code after grub_prefix.
8615 * include/grub/powerpc/kernel.h: Provide valid values for
8616 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
8617
6e5a42fe 86182008-08-29 Bean <bean123ch@gmail.com>
8619
8620 * configure.ac: Change host_os to cygwin for mingw.
8621 (asprintf): New check for function.
8622
8623 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
8624 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
8625
8626 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
81a06771 8627 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
6e5a42fe 8628 sync, sleep and grub_util_get_disk_size for mingw.
8629
8630 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
8631 to get size in mingw.
8632 (open_device): Use flag O_BINARY if it's defined.
8633 (find_root_device): Add dummy code for mingw.
8634
8635 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
8636 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
8637 (get_scsi_disk_name): Return 0 for mingw.
8638
8639 * util/hostfs.c: #include <grub/util/misc.h>.
8640 (grub_hostfs_open): Use "rb" flag to open file, use
8641 grub_util_get_disk_size to get disk size for mingw.
8642
8643 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
8644 (asprintf): New function if HAVE_ASPRINTF is not set.
8645 (sync): New function for mingw.
8646 (sleep): Likewise.
8647 (grub_util_get_disk_size): Likewise.
8648
ab3f2673 86492008-08-28 Pavel Roskin <proski@gnu.org>
8650
8651 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
8652 kern/time.c.
8653
1c282483 86542008-08-28 Robert Millan <rmh@aybabtu.com>
8655
8656 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
8657
678e849c 86582008-08-28 Robert Millan <rmh@aybabtu.com>
8659
8660 Change find_grub_drive() syntax so it doesn't prevent it from
8661 detecting NULL names as errors.
8662
8663 * util/biosdisk.c (find_grub_drive): Move free slot search code
8664 from here ...
8665 (find_free_slot): ... to here.
8666 (read_device_map): Use find_free_slot() to search for free slots.
8667
965c75ca 86682008-08-27 Marco Gerards <marco@gnu.org>
8669
8670 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
8671 (scsi_mod_SOURCES): New variable.
8672 (scsi_mod_CFLAGS): Likewise
8673 (scsi_mod_LDFLAGS): Likewise.
8674
8675 * disk/scsi.c: New file.
8676
8677 * include/grub/scsi.h: Likewise.
8678
8679 * include/grub/scsicmd.h: Likewise.
8680
8681 * disk/ata.c: Include <grub/scsi.h>.
8682 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
8683 instead.
8684 (grub_ata_iterate): Skip ATAPI devices.
8685 (grub_ata_open): Only handle ATAPI devices.
8686 (struct grub_atapi_read): Removed.
8687 (grub_atapi_readsector): Likewise.
8688 (grub_ata_read): No longer handle ATAPI devices.
8689 (grub_ata_write): Likewise.
8690 (grub_atapi_iterate): New function.
8691 (grub_atapi_read): Likewise.
8692 (grub_atapi_write): Likewise.
8693 (grub_atapi_open): Likewise.
8694 (grub_atapi_close): Likewise.
8695 (grub_atapi_dev): New variable.
8696 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
8697 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
8698
8699 * include/grub/disk.h (enum grub_disk_dev_id): Add
8700 `GRUB_DISK_DEVICE_SCSI_ID'.
8701
c07ae501 87022008-08-26 Robert Millan <rmh@aybabtu.com>
8703
8704 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
8705 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
8706 descriptive.
8707
5ed20adc 87082008-08-23 Bean <bean123ch@gmail.com>
8709
8710 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
8711 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8712 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
8713 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
8714 dm_nv.mod.
8715 (raid5rec_mod_SOURCES): New macro.
8716 (raid5rec_mod_CFLAGS): Likewise.
8717 (raid5rec_mod_LDFLAGS): Likewise.
8718 (raid6rec_mod_SOURCES): Likewise.
8719 (raid6rec_mod_CFLAGS): Likewise.
8720 (raid6rec_mod_LDFLAGS): Likewise.
8721 (mdraid_mod_SOURCES): Likewise.
8722 (mdraid_mod_CFLAGS): Likewise.
8723 (mdraid_mod_LDFLAGS): Likewise.
8724 (dm_nv_mod_SOURCES): Likewise.
8725 (dm_nv_mod_CFLAGS): Likewise.
8726 (dm_nv_mod_LDFLAGS): Likewise.
8727
8728 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
8729 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8730 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8731
8732 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
8733 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8734
8735 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8736
8737 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
8738
8739 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8740
8741 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8742
8743 * disk/raid5_recover.c: New file.
8744
8745 * disk/raid6_recover.c: Likewise.
8746
8747 * disk/mdraid_linux.c: Likewise.
8748
8749 * disk/dmraid_nvidia.c: Likewise.
8750
8751 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
8752 ULONG_MAX.
8753
8754 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
8755 calculate the size of raid device.
8756 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
8757 different layout of raid5.
8758 (grub_raid_scan_device): Remove code specific to mdraid.
8759 (grub_raid_list): New variable.
8760 (free_array): New function.
8761 (grub_raid_register): Likewise.
8762 (grub_raid_unregister): Likewise.
8763 (grub_raid_rescan): Likewise.
8764 (GRUB_MOD_INIT): Don't iterate device here.
8765 (GRUB_MOD_FINI): Use free_array to release resource.
8766
8767 * include/grub/raid.h: Remove macro and structure specific to mdraid.
8768 (grub_raid5_recover_func_t): New function variable type.
8769 (grub_raid6_recover_func_t): Likewise.
8770 (grub_raid5_recover_func): New variable.
8771 (grub_raid6_recover_func): Likewise.
8772 (grub_raid_register): New function.
8773 (grub_raid_unregister): Likewise.
8774 (grub_raid_rescan): Likewise.
8775 (grub_raid_block_xor): Likewise.
8776
8777 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
8778 (CMD_CRC): New macro.
8779 (part): Removed.
8780 (read_file): Handle device as well as file.
8781 (cmd_crc): New function.
8782 (fstest): Handle multiple disks.
8783 (options): Remove part, raw and long, add root and diskcount.
8784 (usage): Add crc, remove -p, -r, -l, add -r and -c.
dba3f844 8785 (main): Find the first non option entry and ignore subsequent options,
5ed20adc 8786 add handling for the new options, support multiple disks.
8787
8788 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
8789
29c18915 87902008-08-23 Bean <bean123ch@gmail.com>
8791
8792 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
8793
8794 * genfslist.sh: Ignore kernel.mod.
8795
8796 * genpartmaplist.sh: Likewise.
8797
8415f261 87982008-08-23 Robert Millan <rmh@aybabtu.com>
8799
8800 * util/getroot.c (find_root_device): Skip anything that starts with
8801 a dot, not just directories. This avoids things like /dev/.tmp.md0.
8802
d5a7dc5b 88032008-08-22 Felix Zielcke <fzielcke@z-51.de>
81a06771 8804
d5a7dc5b 8805 * util/update-grub.in (GRUB_GFXMODE): Export variable.
8806 * util/grub.d/00_header.in: Allow the administrator to change default
8807 gfxmode via ${GRUB_GFXMODE}.
8808
380cfbb4 88092008-08-21 Felix Zielcke <fzielcke@z-51.de>
8810
8811 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
8812
c9baafe7 88132008-08-21 Robert Millan <rmh@aybabtu.com>
8814
8815 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
8816 loader.
8817 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
8818 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
8819
e290bef2 88202008-08-20 Carles Pina i Estany <carles@pina.cat>
8821
8822 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
8823 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
8824
f9dbfc96 88252008-08-19 Robert Millan <rmh@aybabtu.com>
8826
8827 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
8828 (struct grub_virtual_screen): Remove `cursor_color'.
8829 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
8830 initialization.
8831 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
8832
dd6bd6ab 88332008-08-18 Robert Millan <rmh@aybabtu.com>
8834
8835 Unify (identical) linux_normal.c files.
8836 * loader/i386/efi/linux_normal.c: Move from here ...
8837 * loader/linux_normal.c: ... to here. Update all users.
8838 * loader/i386/pc/linux_normal.c: Delete. Update all users.
8839 * loader/i386/ieee1275/linux_normal.c: Likewise.
8840
7f42f83e 88412008-08-18 Robert Millan <rmh@aybabtu.com>
8842
8843 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
8844 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
8845 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
8846 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
8847 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
8848 New macros.
8849 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
8850 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
8851 (GRUB_LINUX_CL_END_OFFSET): ... to here.
8852 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
8853 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
8854 (GRUB_EFI_CL_END_OFFSET): Rename to ...
8855 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
8856 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
8857 Initialize `params->video_cursor_x' and `params->video_cursor_y'
8858 portably using grub_getxy().
8859 Replace `-EFI' with `-bzImage' in boot message.
8860
38487ddb 88612008-08-17 Robert Millan <rmh@aybabtu.com>
8862
8863 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
8864
deceb3ec 88652008-08-17 Robert Millan <rmh@aybabtu.com>
8866
8867 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
8868
8869 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
8870 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
8871 (grub_machine_mmap_iterate): New function declaration.
8872 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
8873 structure.
8874 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
8875 macros.
8876
8877 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
8878 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
8879 Move e820 parsing from here ...
8880 * kern/i386/pc/mmap.c: New file.
8881 (grub_machine_mmap_iterate): ... to here.
8882
8883 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
8884 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
8885 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
8886 (grub_available_iterate): Redeclare to return `void', and redeclare
8887 its hook to use grub_uint64_t as addr and size parameters, and rename
8888 to ...
8889 (grub_machine_mmap_iterate): ... this. Update all users.
8890
8891 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
8892 to make it more readable. Rename to ...
8893 (grub_machine_mmap_iterate): ... this.
8894
8895 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
8896 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
8897 (grub_multiboot): Allocate an extra region after the payload, and fill
8898 it with a Multiboot memory map. Adjust a.out loader to calculate size
8899 with the extra space.
8900 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
8901 with the extra space.
8902
f8aa0f43 89032008-08-17 Carles Pina i Estany <carles@pina.cat>
8904
9807deb9 8905 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
f8aa0f43 8906
605f5bb6 89072008-08-17 Felix Zielcke <fzielcke@z-51.de>
8908
8909 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
8910 mdate-sh to the list `find' searches for.
8911 * DISTLIST: Regenerated.
8912
210db6c6 89132008-08-16 Felix Zielcke <fzielcke@z-51.de>
8914
8915 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
8916 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
48cdbfd4 8917 genmoddep.awk, gensymlist.sh.in.
8918 (DISTDIRS): Add bus, docs, hook, lib.
210db6c6 8919 * DISTLIST: Regenerated.
48cdbfd4 8920 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
210db6c6 8921
1082b929 89222008-08-16 Robert Millan <rmh@aybabtu.com>
8923
8924 * disk/raid.c (grub_raid_init): Handle/report errors set by
8925 grub_device_iterate().
8926 * disk/lvm.c (grub_lvm_init): Likewise.
8927
42ce5170 89282008-08-15 Bean <bean123ch@gmail.com>
8929
8930 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8931 and datehook.mod.
8932 (datetime_mod_SOURCES): New macro.
8933 (datetime_mod_CFLAGS): Likewise.
8934 (datetime_mod_LDFLAGS): Likewise.
8935 (date_mod_SOURCES): Likewise.
8936 (date_mod_CFLAGS): Likewise.
8937 (date_mod_LDFLAGS): Likewise.
8938 (datehook_mod_SOURCES): Likewise.
8939 (datehook_mod_CFLAGS): Likewise.
8940 (datehook_mod_LDFLAGS): Likewise.
8941
8942 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8943 and datehook.mod.
8944 (datetime_mod_SOURCES): New macro.
8945 (datetime_mod_CFLAGS): Likewise.
8946 (datetime_mod_LDFLAGS): Likewise.
8947 (date_mod_SOURCES): Likewise.
8948 (date_mod_CFLAGS): Likewise.
8949 (date_mod_LDFLAGS): Likewise.
8950 (datehook_mod_SOURCES): Likewise.
8951 (datehook_mod_CFLAGS): Likewise.
8952 (datehook_mod_LDFLAGS): Likewise.
8953
8954 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8955 and datehook.mod.
8956 (datetime_mod_SOURCES): New macro.
8957 (datetime_mod_CFLAGS): Likewise.
8958 (datetime_mod_LDFLAGS): Likewise.
8959 (date_mod_SOURCES): Likewise.
8960 (date_mod_CFLAGS): Likewise.
8961 (date_mod_LDFLAGS): Likewise.
8962 (datehook_mod_SOURCES): Likewise.
8963 (datehook_mod_CFLAGS): Likewise.
8964 (datehook_mod_LDFLAGS): Likewise.
8965
8966 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8967 and datehook.mod.
8968 (datetime_mod_SOURCES): New macro.
8969 (datetime_mod_CFLAGS): Likewise.
8970 (datetime_mod_LDFLAGS): Likewise.
8971 (date_mod_SOURCES): Likewise.
8972 (date_mod_CFLAGS): Likewise.
8973 (date_mod_LDFLAGS): Likewise.
8974 (datehook_mod_SOURCES): Likewise.
8975 (datehook_mod_CFLAGS): Likewise.
8976 (datehook_mod_LDFLAGS): Likewise.
8977
8978 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8979 and datehook.mod.
8980 (datetime_mod_SOURCES): New macro.
8981 (datetime_mod_CFLAGS): Likewise.
8982 (datetime_mod_LDFLAGS): Likewise.
8983 (date_mod_SOURCES): Likewise.
8984 (date_mod_CFLAGS): Likewise.
8985 (date_mod_LDFLAGS): Likewise.
8986 (datehook_mod_SOURCES): Likewise.
8987 (datehook_mod_CFLAGS): Likewise.
8988 (datehook_mod_LDFLAGS): Likewise.
8989
8990 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
8991
8992 * commands/date.c: New file.
8993
8994 * hook/datehook.c: Likewise.
8995
8996 * include/grub/lib/datetime.h: Likewise.
8997
8998 * include/grub/i386/cmos.h: Likewise.
8999
9000 * lib/datetime.c: Likewise.
9001
9002 * lib/i386/datetime.c: Likewise.
9003
9004 * lib/efi/datetime.c: Likewise.
9005
0e9242da 90062008-08-14 Robert Millan <rmh@aybabtu.com>
9007
9008 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
9009 (grub_mkelfimage_SOURCES): New variable.
9010 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
9011
9012 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
9013 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
9014 * conf/powerpc-ieee1275.rmk: Likewise.
9015 * conf/i386-ieee1275.rmk: Likewise.
9016
9017 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
9018 * kern/i386/coreboot/init.c: Likewise.
9019
9020 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
9021 with `<grub/cpu/kernel.h>'.
9022 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
9023 to ...
9024 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
9025 * kern/i386/coreboot/startup.S: Likewise.
9026
9027 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
9028 (GRUB_MOD_GAP): Remove.
9029 * include/grub/powerpc/kernel.h: New file.
9030 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
9031 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
9032 * include/grub/i386/kernel.h: New file.
9033 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
9034 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
9035 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
9036
9037 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
9038 `grub-mkelfimage'.
9039 Use --directory when invoking grub_mkimage.
9040
9041 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
9042 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
9043 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
9044 and GRUB_KERNEL_CPU_PREFIX.
9045
b86408f8 90462008-08-14 Felix Zielcke <fzielcke@z-51.de>
9047
d5e619ca 9048 * include/grub/err.h (grub_err_printf): New function prototype.
9049 * util/misc.c (grub_err_printf): New function.
9050 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
9051 grub_printf.
9052 * kern/err.c (grub_print_error): Use grub_err_printf.
b86408f8 9053
7161f0e0 90542008-08-13 Robert Millan <rmh@aybabtu.com>
9055
9056 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
9057
a1967522 90582008-08-13 Robert Millan <rmh@aybabtu.com>
9059
9060 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
9061 boot entry.
9062
371458b5 90632008-08-12 Robert Millan <rmh@aybabtu.com>
9064
9065 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
9066 of the relocation code from here ...
9067 (grub_multiboot): ... to here.
9068 (forward_relocator, backward_relocator): Move from here ...
9069 * kern/i386/loader.S (grub_multiboot_forward_relocator)
9070 (grub_multiboot_backward_relocator): ... to here.
9071 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
9072 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
9073 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
9074 (grub_multiboot_forward_relocator_end)
9075 (grub_multiboot_backward_relocator)
9076 (grub_multiboot_backward_relocator_end): New variables.
9077
05f9452b 90782008-08-12 Bean <bean123ch@gmail.com>
9079
9080 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
9081
20024ab0 90822008-08-11 Robert Millan <rmh@aybabtu.com>
9083
9084 * kern/i386/linuxbios/startup.S: Move from here ...
9085 * kern/i386/coreboot/startup.S: ... to here.
9086
9087 * kern/i386/linuxbios/init.c: Move from here ...
9088 * kern/i386/coreboot/init.c: ... to here.
9089
9090 * kern/i386/linuxbios/table.c: Move from here ...
9091 * kern/i386/coreboot/mmap.c: ... to here.
9092
9093 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
9094
e352e9cd 90952008-08-11 Robert Millan <rmh@aybabtu.com>
9096
9097 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
9098 errors. Leave it to the upper layer to handle them.
9099
2d05bc6a 91002008-08-09 Christian Franke <franke@computer.org>
9101
9102 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
9103 * conf/common.rmk: Install `grub-pe2elf' only if requested.
9104 Install `grub.d/10_windows' only on Cygwin.
9105 * configure.ac: Add subst of `target_os'.
9106 Check `target_os' also before setting TARGET_OBJ2ELF.
9107 Add `--enable-grub-pe2elf'.
9108
042bd419 91092008-08-08 Robert Millan <rmh@aybabtu.com>
9110
9111 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
9112 (grub_last_time): Change type to grub_uint64_t.
9113 (grub_disk_open): Migrate code from to using grub_get_time_ms().
9114 (grub_disk_close): Likewise.
9115
9116 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
9117 (run_menu): Migrate code from to using grub_get_time_ms().
9118
9119 * util/misc.c (grub_get_time_ms): New function.
9120
7f280db5 91212008-08-08 Marco Gerards <marco@gnu.org>
9122
9123 * disk/ata.c (grub_ata_regget): Change return type to
9124 `grub_uint8_t'.
9125 (grub_ata_regget2): Likewise.
9126 (grub_ata_wait_status): New function.
9127 (grub_ata_wait_busy): Removed function, updated all users to use
9128 `grub_ata_wait_status'.
9129 (grub_ata_wait_drq): Likewise.
9130 (grub_ata_cmd): New function.
9131 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
9132 error handling.
9133 (grub_ata_pio_write): Add error handling.
9134 (grub_atapi_identify): Likewise.
9135 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
9136 handling.
9137 (grub_ata_identify): Use `grub_ata_cmd' and improve error
9138 handling. Actually use the detected registers. Reorder the
9139 detection logic such that it is easier to read.
9140 (grub_ata_pciinit): Do not assign the same ID to each controller.
9141 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
9142 handling.
9143 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
9144
9145 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
9146
1fbc5e66 91472008-08-08 Marco Gerards <marco@gnu.org>
9148
9149 * NEWS: Update.
9150
819ce6c0 91512008-08-07 Bean <bean123ch@gmail.com>
9152
9153 * include/grub/x86_64/pci.h: New file.
9154
5c41d44d 91552008-08-07 Christian Franke <franke@computer.org>
9156
9157 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
9158 (TIMER2_GATE): Likewise.
9159 (grub_pit_wait): Add enable/disable of the timer2 gate
9160 bit of port 0x61. This fixes a possible infinite loop.
9161
5ebc275d 91622008-08-07 Bean <bean123ch@gmail.com>
9163
9164 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
9165 kern/i386/tsc.c and kern/i386/pit.c.
9166
9167 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
9168 x86_64 platform.
9169
9170 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
9171 <grub/i386/tsc.h>.
9172
9173 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
9174
e383b3d0 91752008-08-07 Bean <bean123ch@gmail.com>
9176
9177 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
9178
9179 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
9180
9181 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
9182 multiple inclusion. Add #include <grub/types.h>.
9183
1cbb58ac 91842008-08-06 Christian Franke <franke@computer.org>
9185
9186 * conf/common.rmk: Build and install `10_windows'.
9187 * util/grub.d/10_windows.in: New script.
9188
337f5a1e 91892008-08-06 Pavel Roskin <proski@gnu.org>
9190
9191 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
9192
057bc4ac 91932008-08-06 Robert Millan <rmh@aybabtu.com>
9194
9195 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
9196 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
9197
2b99f123 91982008-08-06 Bean <bean123ch@gmail.com>
9199
9200 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
9201 (grub_pxefs_fs_int): Remove dummy definition.
9202 (grub_pxefs_open): Use data->block_size to store the current block
9203 size setting.
9204 (grub_pxefs_read): Use block size stored in data->block_size. As the
9205 value of grub_pxe_blksize can be changed after the file is opened.
9206
9f0234cb 92072008-08-06 Bean <bean123ch@gmail.com>
9208
9209 * fs/i386/pc/pxe.c (curr_file): new variable.
9210 (grub_pxefs_open): Simply the handling of pxe file system. Don't
9211 require the dummy internal file system anymore.
9212 (grub_pxefs_read): Removed.
9213 (grub_pxefs_close): Likewise.
9214 (grub_pxefs_fs_int): Likewise.
9215 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
9216 connection when we switch file.
9217 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
9218
a55d42e0 92192008-08-06 Robert Millan <rmh@aybabtu.com>
9220
9221 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
9222 `halt.mod'.
9223 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
9224 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
9225
9226 * kern/i386/halt.c: New file.
9227 * kern/i386/reboot.c: Likewise.
9228 * include/grub/i386/reboot.h: Likewise.
9229 * include/grub/i386/halt.h: Likewise.
9230
9231 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
9232 Include `<grub/cpu/halt.h>'.
9233 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
9234 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
9235
9236 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
9237 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
9238 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
9239 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
9240 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
9241 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
9242 from here ...
9243 * include/grub/i386/at_keyboard.h: ... to here.
9244
24371d26 92452008-08-05 Robert Millan <rmh@aybabtu.com>
9246
9247 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
9248 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
9249 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
9250 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9251 `kern/generic/millisleep.c'.
9252
9253 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
9254 instead of grub_get_rtc().
9255 (grub_tsc_init): Initialize `tsc_boot_time'.
9256
9257 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
9258 (grub_machine_init): Use grub_tsc_init() rather than
9259 installing an RTC-based handler via grub_install_get_time_ms().
9260
9261 * kern/i386/pit.c: New file.
9262 * include/grub/i386/pit.h: Likewise.
9263
9e7007b3 92642008-08-05 Bean <bean123ch@gmail.com>
9265
9266 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
9267
9268 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
9269 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
9270 (pxe_mod_SOURCES): New macro.
9271 (pxe_mod_CFLAGS): Likewise.
9272 (pxe_mod_LDFLAGS): Likewise.
9273 (pxecmd_mod_SOURCES): Likewise.
9274 (pxecmd_mod_CFLAGS): Likewise.
9275 (pxecmd_mod_LDFLAGS): Likewise.
9276
9277 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
9278 (grub_pxe_call): Likewise.
9279
9280 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
9281
9282 * commands/i386/pc/pxecmd.c: New file.
9283
9f0234cb 9284 * fs/i386/pc/pxe.c: Likewise.
9e7007b3 9285
9286 * include/grub/i386/pc/pxe.h: Likewise.
9287
6977d49f 92882008-08-05 Bean <bean123ch@gmail.com>
9289
9290 * util/console.c (grub_console_cur_color): New variable.
9291 (grub_console_standard_color): Likewise.
9292 (grub_console_normal_color): Likewise.
9293 (grub_console_highlight_color): Likewise.
9294 (color_map): Likewise.
9295 (use_color): Likewise.
9296 (NUM_COLORS): New macro.
9297 (grub_ncurses_setcolorstate): Handle color properly.
9298 (grub_ncurses_setcolor): Don't change color here, just remember the
9299 settings, color will be set in grub_ncurses_setcolorstate.
9300 (grub_ncurses_getcolor): New function.
9301 (grub_ncurses_init): Initialize color pairs.
9302 (grub_ncurses_term): New member grub_ncurses_getcolor.
9303
9c2ff3ee 93042008-08-05 Colin D Bennett <colin@gibibit.com>
337f5a1e 9305
9c2ff3ee 9306 High resolution timer support. Implemented for x86 CPUs using TSC.
9307 Extracted generic grub_millisleep() so it's linked in only as needed.
9308 This requires a Pentium compatible CPU; if the RDTSC instruction is
9309 not supported, then it falls back on the generic grub_get_time_ms()
9310 implementation that uses the machine's RTC.
9311
9312 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
9313 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9314 `kern/generic/millisleep.c'.
9315
9316 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
9317 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
9318
9319 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
9320 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
9321
9322 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9323
9324 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
9325 `kern/generic/millisleep.c'.
9326
9327 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9328
9329 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
9330
9331 * kern/generic/rtc_get_time_ms.c: New file.
9332
9333 * kern/generic/millisleep.c: New file.
337f5a1e 9334
9c2ff3ee 9335 * kern/misc.c: Don't include
9336 <kern/time.h> anymore.
9337 (grub_millisleep_generic): Removed.
9338
9339 * commands/sleep.c (grub_interruptible_millisleep): Uses
9340 grub_get_time_ms() instead of grub_get_rtc().
9341
9342 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
9343 function.
9344 (grub_cpu_is_cpuid_supported): New inline function.
9345 (grub_cpu_is_tsc_supported): New inline function.
9346 (grub_tsc_init): New function prototype.
9347 (grub_tsc_get_time_ms): New function prototype.
9348
9349 * kern/i386/tsc.c (grub_get_time_ms): New file.
9350
9351 * include/grub/time.h: Include <grub/types.h.
9352 (grub_millisleep_generic): Removed.
9353 (grub_get_time_ms): New prototype.
9354 (grub_install_get_time_ms): New prototype.
9355 (grub_rtc_get_time_ms): New prototype.
9356
9357 * kern/time.c (grub_get_time_ms): New function.
9358 (grub_install_get_time_ms): New function.
9359
9360 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
9361 <grub/time.h> anymore.
9362 (grub_millisleep): Removed.
9363 (grub_machine_init): Call grub_tsc_init.
9364
9365 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
9366 get_time_ms() implementation.
9367
9368 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
9369 (ieee1275_get_time_ms): New function.
9370 (grub_machine_init): Install get_time_ms() implementation.
9371
9372 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
9373 (grub_machine_init): Call grub_tsc_init().
9374 (grub_millisleep): Removed.
bf06a93f 9375
9c2ff3ee 9376 * kern/ieee1275/init.c (grub_millisleep): Removed.
9377 (grub_machine_init): Install ieee1275_get_time_ms()
9378 implementation.
9379 (ieee1275_get_time_ms): New function.
9380 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
9381 real work.
9382
9ec92aaf 93832008-08-05 Marco Gerards <marco@gnu.org>
9384
9385 * disk/ata.c: Include <grub/pci.h>.
9386 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
9387 (grub_ata_initialize): Rewritten.
9388 (grub_ata_device_initialize): New function.
9389
8d23f507 93902008-08-04 Pavel Roskin <proski@gnu.org>
9391
9392 * kern/main.c: Include grub/mm.h.
9393
5e15ee3d 93942008-08-04 Robert Millan <rmh@aybabtu.com>
9395
9396 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
9397 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
9398 corruption problem).
9399
a9053f8f 94002008-08-04 Robert Millan <rmh@aybabtu.com>
9401
9402 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
9403 warnings introduced in my last commit.
9404
dd19c7d7 94052008-08-03 Robert Millan <rmh@aybabtu.com>
9406
9407 Make PCI available on all i386 architectures.
9408
9409 * include/grub/i386/pc/pci.h: Move from here ...
9410 * include/grub/i386/pci.h: ... to here.
9411
9412 * include/grub/i386/pc/pci.h: Remove.
9413 * include/grub/i386/efi/pci.h: Remove.
9414 * include/grub/x86_64/efi/pci.h: Remove.
9415
9416 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
9417 `<grub/cpu/pci.h>'.
9418
9419 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
9420 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
9421 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
9422
9423 * conf/i386-ieee1275.rmk: Likewise.
9424
e14a6184 94252008-08-03 Robert Millan <rmh@aybabtu.com>
9426
9427 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
9428 (grub_console_setcursor): Make it possible to set cursor off.
9429
52768e37 94302008-08-03 Robert Millan <rmh@aybabtu.com>
9431
9432 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
9433 of modules instead of assuming which platform provides what.
9434 * util/update-grub.in: Likewise.
9435
2d52f57f 94362008-08-03 Robert Millan <rmh@aybabtu.com>
9437
9438 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
9439 instead of `grub_install_dos_part' to determine whether a drive needs
9440 to be prepended to prefix (`grub_install_dos_part' is not reliable,
825aa57a 9441 because it can be overridden when loading GRUB via Multiboot).
2d52f57f 9442
2a5cd121 94432008-08-02 Robert Millan <rmh@aybabtu.com>
9444
9445 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
9446
93808428 94472008-08-02 Robert Millan <rmh@aybabtu.com>
9448
9449 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
9450 of informational grub_dprintf() calls.
9451
3bd0a12a 94522008-08-02 Robert Millan <rmh@aybabtu.com>
9453
9454 * disk/memdisk.c (memdisk_size): Don't initialize.
9455 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
9456
9457 * include/grub/i386/pc/kernel.h
9458 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
9459 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
9460 (grub_memdisk_image_size, grub_arch_memdisk_addr)
9461 (grub_arch_memdisk_size): Remove.
9462
9463 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
9464 field (was only used to transfer a constant). Add `type' field to
9465 support multiple module types.
9466 (grub_module_iterate): New function.
9467
9468 * kern/device.c (grub_device_open): Do not hide error messages
9469 when grub_disk_open() fails. Use grub_print_error() instead.
9470
9471 * kern/i386/pc/init.c (grub_arch_modules_addr)
9472 (grub_arch_memdisk_size): Remove functions.
9473 (grub_arch_modules_addr): Return the module address in high memory
9474 (now that it isn't copied anymore).
9475
9476 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
9477 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
9478 decompression routine (grub_total_module_size already includes that
9479 now). Don't copy modules back to low memory.
9480
9481 * kern/main.c: Include `<grub/mm.h>'.
9482 (grub_load_modules): Split out (and use) ...
9483 (grub_module_iterate): ... this function, which iterates through
9484 module objects and runs a hook.
9485 Comment out grub_mm_init_region() call, as it would cause non-ELF
9486 modules to be overwritten.
9487
9488 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
9489 the memdisk image in its own region, make it part of the module list.
9490 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
9491 (main): Parse --memdisk|-m option, and pass user-provided path as
9492 parameter to generate_image().
9493 (add_segments): Pass `memdisk_path' down to load_modules().
9494 (load_modules): Embed memdisk image in module section when requested.
9495 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
9496 `header.type' instead of `header.offset'.
9497
9498 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
9499 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
9500 (memdisk_mod_LDFLAGS): New variables.
9501 * conf/i386-coreboot.rmk: Likewise.
9502 * conf/i386-ieee1275.rmk: Likewise.
9503
a927cc73 95042008-08-02 Robert Millan <rmh@aybabtu.com>
9505
9506 * loader/i386/pc/multiboot.c (playground, forward_relocator)
9507 (backward_relocator): New variables. Used to allocate and relocate
9508 the payload, respectively.
9509 (grub_multiboot_load_elf32): Load into heap instead of requested
825aa57a 9510 address, install the appropriate relocator code in each bound of
a927cc73 9511 the payload, and set the entry point such that
9512 grub_multiboot_real_boot() will jump to one of them.
9513
9514 * kern/i386/loader.S (grub_multiboot_payload_size)
9515 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9516 (grub_multiboot_payload_entry_offset): New variables.
9517 (grub_multiboot_real_boot): Set cpu context to what the relocator
9518 expects, and jump to the relocator instead of the payload.
9519
9520 * include/grub/i386/loader.h (grub_multiboot_payload_size)
9521 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9522 (grub_multiboot_payload_entry_offset): Export.
9523
b15d8a0c 95242008-08-01 Bean <bean123ch@gmail.com>
9525
9526 * normal/menu_entry.c (editor_getline): Don't return the original
9527 string as result, as it will be released by lexer once it has done
9528 using it.
9529
cdfb3d22 95302008-08-01 Robert Millan <rmh@aybabtu.com>
9531
9532 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
9533 within menuentries, not before them.
9534 util/grub.d/10_hurd.in: Likewise.
9535
9175e93d 95362008-08-01 Bean <bean123ch@gmail.com>
9537
9538 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
9539 (bufio_mod_SOURCES): New macro.
9540 (bufio_mod_CFLAGS): Likewise.
9541 (bufio_mod_LDFLAGS): Likewise.
9542
9543 * include/grub/bufio.h: New file.
9544
9545 * io/bufio.c: Likewise.
9546
9547 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
9548 (grub_video_reader_png): Use grub_buffile_open to open file.
9549
9550 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
9551 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
9552
9553 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
9554 (grub_video_reader_tga): Use grub_buffile_open to open file.
9555
9556 * font/manager.c: Include <grub/bufio.h>.
9557 (add_font): Use grub_buffile_open to open file.
9558
3d8383e7 95592008-07-31 Robert Millan <rmh@aybabtu.com>
9560
9561 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
9562 ELF segments, use a macro for arbitrarily accessing any of them instead
9563 of preparing a pointer that allows access to one at a time.
9564 (grub_multiboot_load_elf64): Likewise.
9565
16e641b6 95662008-07-31 Bean <bean123ch@gmail.com>
9567
9568 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
9569 GRUB_KERNEL_MACHINE_DATA_END.
9570
59198b72 95712008-07-30 Robert Millan <rmh@aybabtu.com>
9572
9573 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
9574 Increase from 0x50 to 0x60.
9575 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
9576 use UUIDs to identify the root drive for them. If that's not
9577 possible, abort.
9578 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
9579 check, for cross-disk installs.
9580
ae88bca3 95812008-07-30 Robert Millan <rmh@aybabtu.com>
9582
9583 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
9584 is non-empty, use it to set the `prefix' environment variable instead
9585 of the usual approach.
9586 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
9587 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
9588 environment variable instead of dummy make_install_device().
9589
9590 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
9591 (start): Insert a data section, with `grub_prefix' variable.
825aa57a 9592 * kern/i386/linuxbios/startup.S: Likewise.
ae88bca3 9593
9594 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
9595 New variable reference.
9596 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
9597 New macro. Defines offset of `grub_prefix' within startup.S (relative
9598 to `start').
9599 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
9600 section within startup.S (relative to `start').
9601 * include/grub/i386/coreboot/kernel.h: Likewise.
9602
9603 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
9604 Overwrite grub_prefix with its contents, at the beginning of the
9605 first segment.
9606 (main): Understand -p|--prefix.
9607
14f41dd1 96082008-07-30 Robert Millan <rmh@aybabtu.com>
9609
9610 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
9611
4ca049a3 96122008-07-30 Robert Millan <rmh@aybabtu.com>
9613
9614 * term/i386/pc/vga_text.c (grub_console_cls): Use
9615 grub_console_gotoxy() to go back to beginning of the screen.
9616 Found by Patrick Georgi <patrick.georgi@coresystems.de>
9617
2921d337 96182008-07-29 Christian Franke <franke@computer.org>
9619
9620 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
9621 Add conversion of emulated mount points on Cygwin.
9622
b609876d 96232008-07-29 Christian Franke <franke@computer.org>
9624
9625 * util/update-grub.in: Add a check for admin
9626 group on Cygwin.
9627 Remove old `grub.cfg.new' before creation.
9628 Add `-f' to `mv' to handle the different filesystem
9629 semantics of Windows.
9630
e93e4679 96312008-07-29 Bean <bean123ch@gmail.com>
9632
9633 * normal/main.c (get_line): Fix buffer overflow bug.
9634
41694fd0 96352008-07-28 Robert Millan <rmh@aybabtu.com>
9636
9637 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
9638 (struct grub_apple_header): New struct. Describes the layout of
9639 the partmap header.
9640 (apple_partition_map_iterate): Check the header magic as well as the
9641 partition magic (which was already being checked).
9642
cfd0b4e6 96432008-07-28 Pavel Roskin <proski@gnu.org>
9644
9645 * genmk.rb: Add a warning to the beginning of the output that
9646 it's a generated file and should not be edited.
9647
93cce016 96482008-07-28 Robert Millan <rmh@aybabtu.com>
9649
9650 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
9651 with the same number are found, just use issue a warning with
9652 grub_dprintf(), as this error has been reported to be non-fatal.
c298def0 9653
cd1df915 96542008-07-27 Robert Millan <rmh@aybabtu.com>
9655
9656 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
9657 information.
9658
b70a8427 96592008-07-27 Bean <bean123ch@gmail.com>
9660
9661 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
9662 (grub_fat_find_dir): Ignore case when comparing filename.
9663
8f5e379f 96642008-07-27 Bean <bean123ch@gmail.com>
9665
9666 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
9667 smallino, as it's more descriptive, and i8count can be confused with
9668 the other field count.
9669 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
9670 inode type.
9671
a85cd5a0 96722008-07-27 Bean <bean123ch@gmail.com>
9673
9674 * commands/crc.c: New file.
9675
9676 * lib/crc.c: Likewise.
9677
9678 * include/grub/lib/crc.h: Likewise.
9679
9680 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
9681
9682 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
9683 (hexdump): Move this function to ...
9684
9685 * lib/hexdump.c: ... here.
9686
9687 * include/grub/hexdump.h: Renamed to ...
9688
9689 * include/grub/lib/hexdump.h: ... this.
9690
9691 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
9692
9693 * util/grub-editenv.c: Likewise.
9694
9695 * include/envblk.h: Renamed to ...
9696
9697 * include/lib/envblk.h: ... this.
9698
9699 * util/envblk.c: Renamed to ...
9700
9701 * lib/envblk.c: ... this.
9702
9703 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
9704 lib/hexdump.c.
9705 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
9706 (pkglib_MODULES): Add crc.mod.
9707 (hexdump_mod_SOURCES): Add lib/hexdump.c.
9708 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
9709 (crc_mod_SOURCES): New macro.
9710 (crc_mod_CFLAGS): Likewise.
9711 (crc_mod_LDFLAGS): Likewise.
9712
9713 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
9714
9715 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9716
9717 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
9718
9719 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9720
9721 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
9722
c298def0 97232008-07-27 Felix Zielcke <fzielcke@z-51.de>
8749e9e5 9724
9725 * commands/help.c: Include <grub/term.h>.
9726 (TERM_WIDTH): Removed. Updated all users.
9727
cc349fb3 97282008-07-27 Pavel Roskin <proski@gnu.org>
9729
9730 * util/getroot.c (find_root_device): Rephrase a comment to avoid
9731 spurious warnings about a comment within a comment.
9732
9051607e 97332008-07-25 Robert Millan <rmh@aybabtu.com>
9734
9735 * util/getroot.c (find_root_device): Skip devices that match
9736 /dev/dm-[0-9]. This lets the real device be found for any type of
9737 abstraction (LVM, EVMS, RAID..).
9738 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
9739 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
9740 device is found first, find_root_device() will now skip it.
9741
01453bfc 97422008-07-24 Pavel Roskin <proski@gnu.org>
9743
9744 * include/grub/types.h: Use __builtin_bswap32() and
9745 __builtin_bswap64() with gcc 4.3 and newer.
9746
6af9849f 97472008-07-24 Christian Franke <franke@computer.org>
9748
3a0fa256 9749 * util/i386/pc/grub-install.in: If `--debug' is specified,
9750 pass `--verbose' to grub-setup.
9751 Abort script if make_system_path_relative_to_its_root() fails.
9752
7810e747 97532008-07-24 Bean <bean123ch@gmail.com>
9754
9755 * configure.ac: Fixed a bug caused by the previous cygwin patch,
9756 variable `target_platform' should be `platform'.
9757
42290e17 97582008-07-24 Bean <bean123ch@gmail.com>
9759
51cc5193 9760 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
42290e17 9761 (grub_png_init_fixed_block): New function.
9762 (grub_png_decode_image_data): Handle fixed huffman code compression.
9763
2a8a80e4 97642008-07-24 Bean <bean123ch@gmail.com>
9765
9766 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
9767 (grub_pe2elf_SOURCES): New macro.
9768 (CLEANFILES): Add grub-pe2elf.
9769
9770 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
9771 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
9772 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
9773 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
9774 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
9775 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
9776 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
9777 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
9778 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
9779 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
9780 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
9781 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
9782 (GRUB_PE32_DT_FUNCTION): Likewise.
9783 (GRUB_PE32_REL_I386_DIR32): Likewise.
9784 (GRUB_PE32_REL_I386_REL32): Likewise.
9785 (grub_pe32_symbol): New structure.
9786 (grub_pe32_reloc): Likewise.
9787
9788 * util/grub-pe2elf.c: New file.
9789
9790 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
9791 start symbol in non pc platform.
9792
9793 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
9794
9795 The following patches are from Christian Franke.
9796
9797 * include/grub/dl.h: Remove .previous, gas supports this only
9798 for ELF format.
9799
9800 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
9801 Remove .type, gas supports this only for ELF format.
9802
9803 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
9804 nullbytes in symbol table. This fixes an infinite loop if table is
9805 zero filled.
9806
9807 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
9808 TARGET_IMG_LDFLAGS and EXEEXT.
9809
9810 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
9811 TARGET_IMG_LDFLAGS_AC.
9812 (grub_CHECK_STACK_ARG_PROBE): New function.
9813
9814 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
9815
9816 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
9817
9818 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
9819 to set TARGET_IMG_LD* accordingly.
9820 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
9821 Add call to grub_CHECK_STACK_ARG_PROBE.
9822 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
9823
9824 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
9825
9826 * genmk.rb: Add EXEEXT to CLEANFILES.
9827
12ccdb75 98282008-07-23 Robert Millan <rmh@aybabtu.com>
9829
9830 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
9831 define the codes for arrows and lines used for the menu).
9832 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
9833 as well.
9834
9835 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
9836 fonts, because the latter are too slow.
9837
18eeaf04 98382008-07-21 Bean <bean123ch@gmail.com>
9839
9840 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
9841 a20. Run keyboard test last, as it will cause macbook to halt.
9842
b095e2ad 98432008-07-18 Pavel Roskin <proski@gnu.org>
9844
9845 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
9846 load foreign architecture modules correctly anyway. Keep
9847 support for loading host architecture modules, whether we
9848 compile them or not.
9849
737feb35 98502008-07-17 Pavel Roskin <proski@gnu.org>
9851
3f4ce737 9852 * configure.ac: Use -m32 or -m64 regardless of whether we had to
9853 change target_cpu. The compiler default can mismatch target_cpu
9854 in any case.
9855
4ad2d049 9856 * disk/efi/efidisk.c: Fix format warnings on x86_64.
9857 * kern/efi/efi.c: Likewise.
9858
f6130a12 9859 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
9860 target compiler is functional.
9861 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
9862 are set up.
9863
58393a2d 9864 * configure.ac: Default to efi platform for x86_64-apple. Allow
9865 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
9866 adjustments from the rest, only do them if target is not
9867 explicitly given. Merge other adjustments with the final sanity
9868 check. Remove an extraneous check for supported CPU. Be
9869 specific which CPU and which platform is not supported.
9870
737feb35 9871 * configure.ac: Default to pc platform for x86_64.
9872
546f966a 98732008-07-17 Robert Millan <rmh@aybabtu.com>
9874
9875 Partial LinuxBIOS -> Coreboot rename.
9876
9877 * conf/i386-linuxbios.rmk: Renamed to ...
9878 * conf/i386-coreboot.rmk: ... this.
9879 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
9880 * configure.ac: Accept "coreboot" as input platform (but maintain
9881 compatibility with "linuxbios").
9882 * include/grub/i386/linuxbios: Renamed to ...
9883 * include/grub/i386/coreboot: ... this.
9884
20011694 98852008-07-17 Bean <bean123ch@gmail.com>
9886
9887 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
c11f6d16 9888 (appleldr_mod_SOURCE): New variable.
20011694 9889 (appleldr_mod_CFLAGS): Likewise.
9890 (appleldr_mod_LDFLAGS): Likewise.
9891 (pci_mod_SOURCES): Likewise.
9892 (pci_mod_CFLAGS): Likewise.
9893 (pci_mod_LDFLAGS): Likewise.
9894 (lspci_mod_SOURCES): Likewise.
9895 (lspci_mod_CFLAGS): Likewise.
9896 (lspci_mod_LDFLAGS): Likewise.
9897
9898 * conf/x86_64-efi.rmk: New file.
9899
9900 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
9901 macro.
9902 (grub_efidisk_write): Likewise.
9903
9904 * include/efi/api.h (efi_call_0): New macro.
9905 (efi_call_1): Likewise.
9906 (efi_call_2): Likewise.
9907 (efi_call_3): Likewise.
9908 (efi_call_4): Likewise.
9909 (efi_call_5): Likewise.
9910 (efi_call_6): Likewise.
9911
9912 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
9913 grub_rescue_cmd_chainloader.
9914
9915 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
9916 (grub_pe32_optional_header): Change some fields based on i386 or
9917 x86_64 platform.
9918 (GRUB_PE32_PE32_MAGIC): Likewise.
9919
9920 * include/grub/efi/uga_draw.h: New file.
9921
9922 * include/grub/elf.h (STN_ABS): New constant.
9923 (R_X86_64_NONE): Relocation constant for x86_64.
9924 (R_X86_64_64): Likewise.
9925 (R_X86_64_PC32): Likewise.
9926 (R_X86_64_GOT32): Likewise.
9927 (R_X86_64_PLT32): Likewise.
9928 (R_X86_64_COPY): Likewise.
9929 (R_X86_64_GLOB_DAT): Likewise.
9930 (R_X86_64_JUMP_SLOT): Likewise.
9931 (R_X86_64_RELATIVE): Likewise.
9932 (R_X86_64_GOTPCREL): Likewise.
9933 (R_X86_64_32): Likewise.
9934 (R_X86_64_32S): Likewise.
9935 (R_X86_64_16): Likewise.
9936 (R_X86_64_PC16): Likewise.
9937 (R_X86_64_8): Likewise.
9938 (R_X86_64_PC8): Likewise.
9939
9940 * include/grub/i386/efi/pci.h: New file.
9941
9942 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
9943 Change it value based on platform.
9944 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
9945 (GRUB_E820_RAM): Likewise.
9946 (GRUB_E820_RESERVED): Likewise.
9947 (GRUB_E820_ACPI): Likewise.
9948 (GRUB_E820_NVS): Likewise.
9949 (GRUB_E820_EXEC_CODE): Likewise.
9950 (GRUB_E820_MAX_ENTRY): Likewise.
9951 (grub_e820_mmap): New structure.
9952 (linux_kernel_header): Change the efi field according to different
9953 kernel version, also field from linux_kernel_header.
9954
9955 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
9956
9957 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
9958 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
9959 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
9960 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
9961 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
9962 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
9963 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
9964 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
9965 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
9966 (GRUB_PCI_ADDR_IO_MASK): Likewise.
9967
9968 * include/grub/x86_64/efi/kernel.h: New file.
9969
9970 * include/grub/x86_64/efi/loader.h: Likewise.
9971
9972 * include/grub/x86_64/efi/machine.h: Likewise.
9973
9974 * include/grub/x86_64/efi/pci.h: Likewise.
9975
9976 * include/grub/x86_64/efi/time.h: Likewise.
9977
9978 * include/grub/x86_64/linux.h: Likewise.
9979
9980 * include/grub/x86_64/setjmp.h: Likewise.
9981
9982 * include/grub/x86_64/time.h: Likewise.
9983
9984 * include/grub/x86_64/types.h: Likewise.
9985
9986 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
9987 GRUB_TARGET_SIZEOF_VOID_P.
9988
9989 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
9990 (grub_efi_locate_handle): Likewise.
9991 (grub_efi_open_protocol): Likewise.
9992 (grub_efi_set_text_mode): Likewise.
9993 (grub_efi_stall): Likewise.
9994 (grub_exit): Likewise.
9995 (grub_reboot): Likewise.
9996 (grub_halt): Likewise.
9997 (grub_efi_exit_boot_services): Likewise.
9998 (grub_get_rtc): Likewise.
9999
10000 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
10001 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
10002 (grub_efi_allocate_pages): Wrap efi calls.
10003 (grub_efi_free_pages): Wrap efi calls.
10004 (grub_efi_get_memory_map): Wrap efi calls.
10005
10006 * kern/x86_64/dl.c: New file.
10007
10008 * kern/x86_64/efi/callwrap.S: Likewise.
10009
10010 * kern/x86_64/efi/startup.S: Likewise.
10011
10012 * loader/efi/appleloader.c: Likewise.
10013
10014 * loader/efi/chainloader.c (cmdline): New variable.
10015 (grub_chainloader_unload): Wrap efi calls.
10016 (grub_chainloader_boot): Likewise.
10017 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
10018 command line.
10019
10020 * loader/efi/chainloader_normal.c (chainloader_command):
10021 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
10022 command line.
10023
10024 * loader/i386/efi/linux.c (allocate_pages): Change allocation
10025 method.
10026 (grub_e820_add_region): New function.
10027 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
10028 booting.
10029 (grub_find_video_card): New function.
10030 (grub_linux_setup_video): New function.
10031 (grub_rescue_cmd_linux): Probe for video information.
10032
10033 * normal/x86_64/setjmp.S: New file.
10034
10035 * term/efi/console.c (map_char): New function.
10036 (grub_console_putchar): Map unicode char.
10037 (grub_console_checkkey): Wrap efi calls.
10038 (grub_console_getkey): Likewise.
10039 (grub_console_getwh): Likewise.
10040 (grub_console_gotoxy): Likewise.
10041 (grub_console_cls): Likewise.
10042 (grub_console_setcolorstate): Likewise.
10043 (grub_console_setcursor): Likewise.
10044
10045 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
10046
59652a20 100472008-07-16 Pavel Roskin <proski@gnu.org>
10048
ef294055 10049 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
10050 format strings.
10051
59652a20 10052 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
10053 pointer, not an integer. This fixes a warning and prevents
10054 precision loss on 64-bit systems.
10055 (relocate_addresses): Remove unneeded cast.
10056
afc3b5d7 100572008-07-15 Pavel Roskin <proski@gnu.org>
10058
506b2b3e 10059 * kern/i386/ieee1275/init.c: Include grub/cache.h.
10060
62ead89c 10061 * term/ieee1275/ofconsole.c: Disable code unused on i386.
10062
c4cd51d7 10063 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
10064 Fix comparison between signed and unsigned.
10065
0d3d8f28 10066 * include/grub/i386/ieee1275/console.h: Declare
10067 grub_console_init() and grub_console_fini().
10068
8804b286 10069 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
10070 It's empty and unused.
10071
ee01cf35 10072 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
10073 beginning to avoid warnings with some compilers.
10074
afc3b5d7 10075 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
10076 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
10077
e4e8eaa5 100782008-07-14 Pavel Roskin <proski@gnu.org>
10079
407aceb4 10080 * kern/env.c (grub_register_variable_hook): Don't copy empty
10081 string, it leaks memory. Pass "" to grub_env_set(), it should
10082 handle constant strings.
10083
e4e8eaa5 10084 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
10085 * commands/cmp.c (grub_cmd_cmp): Likewise.
10086 * kern/dl.c (grub_dl_flush_cache): Likewise.
10087 (grub_dl_load_core): Likewise.
10088 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
10089 (grub_elf64_load_phdrs): Likewise.
10090
d4e2dad3 100912008-07-13 Pavel Roskin <proski@gnu.org>
10092
10093 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
10094 between signed and unsigned.
10095 (LzmaEnc_Finish): Fix warning about an unused parameter.
10096
aa24b516 100972008-07-13 Bean <bean123ch@gmail.com>
10098
10099 * Makefile.in (enable_lzo): New rule.
10100
10101 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
10102
10103 * configure.ac (ENABLE_LZO): New option --enable-lzo.
10104
10105 * boot/i386/pc/lnxboot.S: #include <config.h>.
10106
10107 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
fe987087 10108 its value according to the compression algorithm used, lzo or lzma.
aa24b516 10109
10110 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
10111 compression algorithm according to configure macro.
10112
10113 * kern/i386/pc/startup.S (codestart): Likewise.
10114
10115 * kern/i386/pc/lzma_decode.S: New file.
10116
10117 * include/grub/lib/LzFind.h: Likewise.
10118
10119 * include/grub/lib/LzHash.h: Likewise.
10120
10121 * include/grub/lib/LzmaDec.h: Likewise.
10122
10123 * include/grub/lib/LzmaEnc.h: Likewise.
10124
10125 * include/grub/lib/LzmaTypes.h: Likewise.
10126
10127 * lib/LzFind.c: Likewise.
10128
10129 * lib/LzmaDec.c: Likewise.
10130
10131 * lib/LzmaEnc.c: Likewise.
10132
4ae821ac 101332008-07-13 Bean <bean123ch@gmail.com>
10134
10135 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
10136 (grub_ext4_extent_header): New structure.
10137 (grub_ext4_extent): Likewise.
10138 (grub_ext4_extent_idx): Likewise.
10139 (grub_ext4_find_leaf): New function.
10140 (grub_ext2_read_block): Handle extents.
10141
9a745147 101422008-07-12 Robert Millan <rmh@aybabtu.com>
10143
10144 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
10145
d49a4cf6 101462008-07-11 Robert Millan <rmh@aybabtu.com>
10147
10148 * util/grub.d/40_custom.in: New file. Example on how to add custom
10149 entries to /etc/grub.d.
10150 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
10151 40_custom (implicitly, by merging all the grub.d rules).
10152
947414b4 101532008-07-11 Pavel Roskin <proski@gnu.org>
10154
0059cf6f 10155 * commands/read.c (grub_getline): Fix invalid memory access.
10156 Don't add newline to the variable value.
10157
947414b4 10158 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
10159 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
10160 (serial_hw_get_port): Check validity of the port number.
10161 (grub_cmd_serial): Check return value of serial_hw_get_port().
10162
62a02d00 101632008-07-07 Pavel Roskin <proski@gnu.org>
10164
10165 * boot/i386/pc/diskboot.S (notification_string): Replace
10166 "Loading kernel" with just "loading". This is shorter, less
10167 confusing and saves a few bytes for possible future changes.
10168
3e5581b0 101692008-07-05 Pavel Roskin <proski@gnu.org>
10170
ea387a48 10171 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
10172 size for ATAPI devices, they are undefined. Output sector
10173 number in decimal form.
10174
3e5581b0 10175 * disk/ata.c: Use named constants for status bits.
10176
fdecb8fd 101772008-07-04 Pavel Roskin <proski@gnu.org>
10178
bcd35b90 10179 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
10180 grub_addr_t before casting it to the void pointer to fix a
10181 warning. Non-addressable regions are discarded earlier.
10182 (grub_arch_modules_addr): Cast _end to grub_addr_t.
10183 * kern/i386/linuxbios/table.c: Include grub/misc.h.
10184 (check_signature): Don't shadow table_header.
10185 (grub_linuxbios_table_iterate): Cast numeric constants to
10186 grub_linuxbios_table_header_t.
10187 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
10188 grub_stop().
10189
af58ab3d 10190 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
10191 prevent warnings.
10192
1759aa57 10193 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
10194 pointer, which can cause warnings. Support 64-bit addresses.
10195
fdecb8fd 10196 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
10197 of sizeof(long). This fixes PowerPC image generation on x86_64.
10198
8516d2a8 101992008-07-04 Robert Millan <rmh@aybabtu.com>
10200
10201 This fixes a performance issue when pc & gpt partmap iterators
10202 didn't abort iteration even after our hook found what it was
fe987087 10203 looking for (often causing expensive probes of non-existent drives).
8516d2a8 10204
10205 Some callers relied on previous buggy behaviour, since they would
34c44600 10206 raise an error when their own hooks caused early abortion of its
8516d2a8 10207 iteration.
10208
10209 * kern/device.c (grub_device_open): Improve error message.
10210 * disk/lvm.c (grub_lvm_open): Likewise.
10211 * disk/raid.c (grub_raid_open): Likewise.
10212
10213 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
10214 when hook requests it, independently of grub_errno.
10215 (pc_partition_map_probe): Do not fail when find_func() caused
10216 early abortion of pc_partition_map_iterate().
10217
10218 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
10219 when hook requests it, independently of grub_errno.
10220 (gpt_partition_map_probe): Do not fail when find_func() caused
10221 early abortion of gpt_partition_map_iterate().
10222
10223 * kern/partition.c (grub_partition_iterate): Abort parent iteration
10224 when hook requests it, independently of grub_errno. Do not fail when
10225 part_map_iterate_hook() caused early abortion of p->iterate().
10226
10227 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
10228 when grub_partition_iterate() returned with non-zero.
10229
277d0de9 102302008-07-03 Pavel Roskin <proski@gnu.org>
10231
10232 * disk/ata.c (grub_ata_pio_write): Check status before writing,
10233 like we do in grub_ata_pio_read().
10234 (grub_ata_readwrite): Always write individual sectors. Fix the
10235 sector count for the remainder.
10236 (grub_ata_write): Enable writing to ATA devices. Correctly
10237 report error for ATAPI devices.
10238
d4c9b428 102392008-07-02 Pavel Roskin <proski@gnu.org>
10240
e43fc690 10241 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
10242 warning.
10243
f707af42 10244 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
10245 for every read sector, we already increment it for the whole
10246 batch. This fixes reading more than 256 sectors at once.
10247
11e16b15 10248 * util/grub-editenv.c (cmd_info): Cast argument to long
10249 explicitly. ptrdiff_t reduces to int on i386.
10250
cbabfdd4 10251 * util/grub-editenv.c (main): Be specific which parameter is
10252 missing.
10253
b8fbce0a 10254 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
10255 (memdisk): Make memdisk_orig_addr a pointer.
10256
c9c8e606 10257 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
10258 for file offsets, use grub_off_t instead. Fix printf format
10259 warnings.
10260
ca62e598 10261 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
10262 there. Real unexpected warnings should not drown in the noise
10263 about known problems.
10264
ce8d1766 10265 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
10266 grub_disk_addr_t for memory addresses.
10267
00c7a56a 10268 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
10269 explicitly to fix a warning.
10270
08d3ef09 10271 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
10272
cb71ba20 10273 * Makefile.in (MODULE_LDFLAGS): New variable.
10274 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
10275 the linker accepts --build-id=none.
10276 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
10277 MODULE_LDFLAGS.
10278 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
10279
d4c9b428 10280 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
10281 those in Linux XFS code. Provide a way to access 64-bit parent
10282 inode.
10283 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
10284 the end of struct grub_xfs_dir_header.
10285
d4156eee 102862008-07-02 Bean <bean123ch@gmail.com>
10287
10288 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
10289 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10290 and GRUB_IEEE1275_FLAG_NO_ANSI.
10291
10292 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
10293 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10294 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
10295
10296 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
10297 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
10298
10299 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
10300 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
10301
10302 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
10303 esc sequence on non ANSI terminal.
10304 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
10305
10306 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
10307 beginning of file.
10308
2270f77b 103092008-07-02 Bean <bean123ch@gmail.com>
10310
10311 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
10312 (grub_editenv_SOURCES): New variable.
10313 (pkglib_MODULES): Add loadenv.mod.
10314 (loadenv_mod_SOURCES): New variable.
10315 (loadenv_mod_CFLAGS): Likewise.
10316 (loadenv_mod_LDFLAGS): Likewise.
10317
10318 * include/grub/envblk.h: New file.
10319
10320 * util/envblk.c: New file.
10321
10322 * util/grub-editenv.c: New file.
10323
10324 * commands/loadenv.c: New file.
10325
0e9e51ec 103262008-07-01 Pavel Roskin <proski@gnu.org>
10327
d89b7634 10328 * include/multiboot2.h (struct multiboot_tag_module): Use char,
10329 not unsigned char. This fixes warnings and is consistent with
10330 other tags.
10331
bf1835b1 10332 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
10333
8222a04b 10334 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
10335
6a42d99d 10336 * term/tparm.c (analyze): Always set *popcount.
10337
10b159d1 10338 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
10339 cast to fix a warning.
10340
b8789f6c 10341 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
10342 cast to suppress a warning.
10343
29d7e38a 10344 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
10345 grub_fshelp_read_file() expects.
10346
f341f669 10347 * fs/fat.c: Fix UUID calculation on big-endian systems. We
10348 write uuid as a 32-bit value in CPU byte order, so declare and
10349 use it as such.
10350
0e9e51ec 10351 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
10352 long if the format specifier expects it.
10353 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
10354 * partmap/pc.c (pc_partition_map_iterate): Likewise.
10355 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
10356 long to fix a warning.
10357 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
10358 grub_dprintf() arguments to fix warnings.
10359
3aefa857 103602008-06-30 Pavel Roskin <proski@gnu.org>
10361
56c7668b 10362 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
10363 install_bsd_part immediately before core.img is embedded or
10364 modified on disk. This fixes core.img verification if core.img
10365 cannot be embedded.
10366
3aefa857 10367 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
10368 core_path to calculate the blocklist.
10369 Patch from Javier Martín <lordhabbit@gmail.com>
10370
5444088d 103712008-06-29 Robert Millan <rmh@aybabtu.com>
10372
10373 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
10374 block to disk block.
10375 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
10376 Patch from Niels Böhm <bitbucket@arcor.de>
10377
674835c8 103782008-06-29 Robert Millan <rmh@aybabtu.com>
10379
10380 * util/update-grub_lib.in (font_path): Search for fonts in
10381 /boot/grub first, which is more likely to be readable (we aren't
10382 deciding where fonts live, just looking for them).
10383
f527dbc8 103842008-06-26 Pavel Roskin <proski@gnu.org>
10385
6c2d8df6 10386 * util/biosdisk.c (read_device_map): Don't leave dead map
10387 entries for devices failing stat() check.
10388
f527dbc8 10389 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
10390 core_path_dev for the core.img path on the target device.
10391
aebe3d13 103922008-06-26 Robert Millan <rmh@aybabtu.com>
10393
10394 * disk/fs_uuid.c: New file.
10395 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
10396 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
10397 (fs_uuid_mod_LDFLAGS): New variables.
10398 * include/grub/disk.h (grub_disk_dev_id): Add
10399 `GRUB_DISK_DEVICE_UUID_ID'.
10400 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
10401 implement iterate().
10402
37aaf354 104032008-06-26 Robert Millan <rmh@aybabtu.com>
10404
10405 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
10406 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
10407 Linux image includes no initrd.
10408
25ff262a 104092008-06-21 Javier Martín <lordhabbit@gmail.com>
10410
10411 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
10412 call to resolve the core image location that effectively appended the
10413 name twice.
10414
76a2bd44 104152008-06-21 Robert Millan <rmh@aybabtu.com>
10416
10417 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
10418 call from here ...
10419
10420 * util/grub.d/10_hurd.in: ... to here ...
10421 * util/grub.d/10_linux.in: ... and here.
10422
650e1c79 104232008-06-19 Robert Millan <rmh@aybabtu.com>
10424
fe987087 10425 * kern/main.c (grub_main): Export `prefix' variable immediately
650e1c79 10426 after it has been set by grub_machine_set_prefix().
10427
6ce63911 104282008-06-19 Robert Millan <rmh@aybabtu.com>
10429
10430 * commands/search.c (search_label, search_fs_uuid, search_file): Print
10431 search result when not saving to variable, not the other way around.
10432 When saving to variable, abort iteration as soon as a match is found.
10433
73940cec 104342008-06-19 Robert Millan <rmh@aybabtu.com>
10435
10436 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
10437 check for partition that provides /boot/grub. Its logic is flawed,
10438 as it prevents prepare_grub_to_access_device() from being called
10439 multiple times.
10440
3c62a39d 104412008-06-19 Robert Millan <rmh@aybabtu.com>
10442
10443 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
10444 "insmod" command directly when abstraction modules are needed,
fe987087 10445 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
3c62a39d 10446 since it had already been processed).
10447
47395a42 104482008-06-19 Pavel Roskin <proski@gnu.org>
10449
10450 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
10451 changed. This is needed in case GRUB_LIBDIR changes.
10452 * conf/i386-ieee1275.rmk: Likewise.
10453 * conf/i386-linuxbios.rmk: Likewise.
10454 * conf/i386-pc.rmk: Likewise.
10455 * conf/powerpc-ieee1275.rmk: Likewise.
10456
a145ac2d 104572008-06-18 Pavel Roskin <proski@gnu.org>
10458
10459 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
10460 kernel_elf_symlist.c to symlist.c for consistency with other
10461 architectures. Update all users.
10462 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
10463
7847c51e 104642008-06-18 Robert Millan <rmh@aybabtu.com>
10465
10466 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
10467 it in prefix.
10468
10469 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
10470 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
10471 a RAID device, run setup() for all members independently on whether
10472 LVM abstraction is being used.
10473 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
10474 If grub-mkimage has set `*install_dos_part == -2', don't override this
10475 value.
10476 Perform *install_dos_part adjustments independently on whether
10477 we're embedding or not.
10478 Clarify error message when image is too big for embedding.
10479 Remove duplicate *install_dos_part stanza.
10480
b23e5644 104812008-06-17 Robert Millan <rmh@aybabtu.com>
10482
10483 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
10484 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
10485 variables.
10486 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
10487 values in grub_ofconsole_normal_color and
10488 grub_ofconsole_highlight_color (they're not directly related to
10489 background and foreground).
10490 (grub_ofconsole_setcolorstate): Extract background and foreground
10491 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
10492
0aac2f79 104932008-06-17 Robert Millan <rmh@aybabtu.com>
10494
10495 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
10496 /boot/grub for the check in last commit, not /boot (they could be
10497 different partitions).
10498
3cca7ef3 104992008-06-16 Robert Millan <rmh@aybabtu.com>
10500
10501 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
10502 asked to setup access for the same partition that provides /boot,
10503 don't bother using UUIDs since our root already has the value we
10504 want.
10505
347396d8 105062008-06-16 Robert Millan <rmh@aybabtu.com>
10507
10508 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
10509 I2O devices.
10510 Patch from Sven Mueller <sven@debian.org>.
10511
991477f8 105122008-06-16 Robert Millan <rmh@aybabtu.com>
10513
10514 * util/update-grub.in: Check for $EUID instead of $UID.
10515 Reported by Vincent Zweije.
10516
d31a32a1 105172008-06-16 Bean <bean123ch@gmail.com>
10518
fe987087 10519 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
d31a32a1 10520 (grub_ext2_read_block): Likewise.
10521 (grub_ext2_read_inode): Likewise.
10522 (grub_ext2_mount): Likewise.
10523 (grub_ext2_close): Likewise.
10524 (grub_ext3_get_journal): Removed.
10525
fe987087 10526 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
d31a32a1 10527 (grub_reiserfs_read_symlink): Likewise.
10528 (grub_reiserfs_mount): Likewise.
10529 (grub_reiserfs_open): Likewise.
10530 (grub_reiserfs_read): Likewise.
10531 (grub_reiserfs_close): Likewise.
10532 (grub_reiserfs_get_journal): Removed.
10533
10534 * fs/fshelp.c (grub_fshelp_read): Removed.
10535 (grub_fshelp_map_block): Likewise.
10536
10537 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
10538 (grub_fshelp_journal): Likewise.
10539 (grub_fshelp_read): Likewise.
10540 (grub_fshelp_map_block): Likewise.
10541
3540a760 105422008-06-16 Pavel Roskin <proski@gnu.org>
10543
10544 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
10545 floating point anymore.
10546 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
10547
95614c84 105482008-06-15 Pavel Roskin <proski@gnu.org>
10549
10550 * commands/ls.c (grub_ls_list_files): Use integer calculations
10551 for human readable format, avoid floating point use.
10552 * kern/misc.c (grub_ftoa): Remove.
10553 (grub_vsprintf): Remove floating point support.
10554
50465dd6 105552008-06-15 Robert Millan <rmh@aybabtu.com>
10556
fe6b695a 10557 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
50465dd6 10558 devices.
10559 Reported by Max Vozeler.
10560
a9207284 105612008-06-15 Robert Millan <rmh@aybabtu.com>
10562
10563 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
10564 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
10565 skipped later.
10566 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
10567 the beginning of the prefix.
10568
10569 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
10570 It is assumed that if we have a memdisk, grub-mkimage has set
10571 grub_prefix to include the "(memdisk)" drive in it.
10572
a7cbd45a 105732008-06-15 Robert Millan <rmh@aybabtu.com>
10574
10575 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
10576 Initialize keyboard controller after registering the terminal, so that
10577 grub_printf() can be called from grub_keyboard_controller_init().
10578
21cf716a 105792008-06-15 Robert Millan <rmh@aybabtu.com>
10580
10581 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
10582 extent-btree which is written as big endian on disk.
10583 Reported by Alain Greppin <al@chilibi.org>.
10584
23a64d8e 105852008-06-14 Robert Millan <rmh@aybabtu.com>
10586
10587 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
10588 * util/i386/pc/grub-install.in (modules): Likewise.
10589
d687651c 105902008-06-13 Pavel Roskin <proski@gnu.org>
10591
10592 * commands/ls.c (grub_ls_list_files): Fix format warnings.
10593
dfe9ddd4 105942008-06-13 Bean <bean123ch@gmail.com>
10595
10596 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
10597
10598 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
10599
10600 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
10601 to indicate sparse block.
10602
16ae7781 106032008-06-12 Pavel Roskin <proski@gnu.org>
10604
e6d1a308 10605 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
10606 number, grub_fshelp_read() does it for us.
10607
16ae7781 10608 * fs/fshelp.c (grub_fshelp_read): New function. Implement
10609 linear disk read with journal translation.
10610 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
10611 * include/grub/fshelp.h: Declare grub_fshelp_read().
10612
40fd3a2b 106132008-06-09 Pavel Roskin <proski@gnu.org>
10614
10615 * fs/minix.c (grub_minix_mount): Handle error reading
10616 superblock.
10617
f5679726 106182008-06-08 Robert Millan <rmh@aybabtu.com>
10619
10620 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
10621 don't append the RAID prefix afterwards.
10622 Reported by Clint Adams.
10623
ce525529 106242008-06-08 Robert Millan <rmh@aybabtu.com>
10625
10626 Based on description from Pavel:
10627 * kern/disk.c (grub_disk_check_range): Rename to ...
10628 (grub_disk_adjust_range): ... this. Add a comment explaining the
10629 tasks performed by this function.
10630
ad4936a0 106312008-06-08 Robert Millan <rmh@aybabtu.com>
10632
10633 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
10634 `num_serial' (for consistency with other variables).
10635 (struct grub_ntfs_data): Add `uuid' member.
10636 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
10637 (grub_ntfs_uuid): New function.
10638 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
10639
dc20b0f9 106402008-06-07 Pavel Roskin <proski@gnu.org>
10641
10642 * util/biosdisk.c (open_device): Revert last change to the
10643 function, it broke installation. The sector needs to be
10644 different dependent on which device is opened.
10645
c5e3cfba 106462008-06-06 Robert Millan <rmh@aybabtu.com>
10647
10648 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
10649 rest of GRUB, and breakage doesn't happen if its value were modified.
10650
10651 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
10652 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
10653 a constant (same value).
10654 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
10655 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
10656
26a1f8c4 106572008-06-06 Robert Millan <rmh@aybabtu.com>
10658
10659 * util/biosdisk.c (open_device): Do not modify sector offset when
10660 accessing a partition. kern/disk.c already handles this for us.
10661
25d6b327 106622008-06-06 Robert Millan <rmh@aybabtu.com>
10663
10664 * util/grub-emu.c (grub_machine_init): Move code in this function from
10665 here ...
10666 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
10667 segfault in case grub_printf() is called).
10668
10669 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
10670 grub_probe. Update all users not to explicitly add it again.
10671 (grub_device): New variable; contains corresponding device for grubdir.
10672 (fs_module, partmap_module, devabstraction_module): Pass
10673 `--device ${grub_device}' to grub_probe to avoid traversing /dev
10674 every time.
10675
9ece62fb 106762008-06-05 Robert Millan <rmh@aybabtu.com>
10677
10678 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
10679 is found, print it (same layout as with labels).
10680
1ad36d37 106812008-06-04 Robert Millan <rmh@aybabtu.com>
10682
10683 * util/biosdisk.c (get_drive): Rename to ...
10684 (find_grub_drive): ... this. Update all users.
10685
10686 (get_os_disk): Rename to ...
10687 (convert_system_partition_to_system_disk): ... this. Update all users.
10688
10689 (find_drive): Rename to ...
10690 (find_system_device): ... this. Update all users.
10691
e6a30859 106922008-06-04 Robert Millan <rmh@aybabtu.com>
10693
10694 * util/biosdisk.c (get_os_disk): Handle IDA devices.
10695 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10696 (make_device_map): Likewise.
10697
00c108a4 106982008-06-01 Robert Millan <rmh@aybabtu.com>
10699
10700 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
10701 before dereferencing it.
10702
10703 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
10704 union with fat12/fat16-specific ones. Add some new fields, including
10705 `num_serial' for both versions.
10706 (struct grub_fat_data): Add `uuid' member.
10707 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
10708 names. Initialize `data->uuid' using `num_serial'.
10709 (grub_fat_uuid): New function.
10710 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
10711
10712 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
10713 (grub_reiserfs_uuid): New function.
10714 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
10715 member.
10716
10717 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
10718 (grub_xfs_uuid): New function.
10719 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
10720
1385c5bb 107212008-06-01 Robert Millan <rmh@aybabtu.com>
10722
10723 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
10724 code that is backward compatible with pre-uuid search command.
10725
c682dfd7 107262008-05-31 Robert Millan <rmh@aybabtu.com>
10727
10728 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
10729 floppies after everything else, to ensure floppy drive isn't accessed
10730 unnecessarily (patch from Bean).
10731
b7db5d47 107322008-05-31 Robert Millan <rmh@aybabtu.com>
10733
10734 * commands/search.c (search_label, search_fs_uuid, search_file): Do
10735 not print device names when we were asked to set a variable.
10736
6e037aa9 107372008-05-31 Robert Millan <rmh@aybabtu.com>
10738
10739 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
10740 using "cursor-on" and "cursor-off" commands (understood at least by
10741 the Open Firmware flavour on OLPC).
10742
41305bc8 107432008-05-31 Michael Gorven <michael@gorven.za.net>
10744
10745 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
10746 on and off sequences.
10747
69ba137e 107482008-05-31 Robert Millan <rmh@aybabtu.com>
10749
10750 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
10751 * util/update-grub.in: Likewise.
10752
520ae21b 107532008-05-30 Pavel Roskin <proski@gnu.org>
10754
10755 * util/biosdisk.c (linux_find_partition): Simplify logic and
10756 make the code more universal. Keep special processing for
10757 devfs, but use a simple rule for all other devices. If the
10758 device ends with a number, append 'p' and the partition number.
10759 Otherwise, append only the partition number.
10760
5786569b 107612008-05-30 Robert Millan <rmh@aybabtu.com>
10762
10763 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
10764 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
10765 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
10766 the `root' parameter to Linux.
10767
51500452 107682008-05-30 Robert Millan <rmh@aybabtu.com>
10769
10770 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
10771 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
10772 --fs_uuid with --fs-uuid.
10773 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
10774 all filesystems support them).
10775
811d3878 107762008-05-30 Robert Millan <rmh@aybabtu.com>
10777
10778 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
f19dbdb7 10779 grub_printf() flags, since we're printing in units of 2 bytes.
811d3878 10780
cab63c95 107812008-05-30 Robert Millan <rmh@aybabtu.com>
10782
10783 * util/grub.d/00_header.in: Remove obsolete comment referencing
10784 convert_system_path_to_grub_path().
10785 * util/update-grub.in: Likewise.
10786 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
10787 (convert_system_path_to_grub_path): Add a warning message explaining
10788 that this function is deprecated. Rely on is_path_readable_by_grub()
10789 for the readability checks.
10790 (font_path): Use is_path_readable_by_grub() for the readability
10791 check rather than convert_system_path_to_grub_path().
10792
972e2f7a 107932008-05-30 Robert Millan <rmh@aybabtu.com>
10794
10795 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
10796 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
10797 converting it first.
10798 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
10799 grub.cfg for access to font file, and afterwards call it again to set
10800 the root device.
10801
62191274 108022008-05-30 Robert Millan <rmh@aybabtu.com>
10803
10804 * commands/search.c (options): Add --fs_uuid option.
10805 (search_fs_uuid): New function.
10806 (grub_cmd_search): Fix --set argument passing.
10807 Use search_fs_uuid() when requested via --fs_uuid.
10808 (grub_search_init): Update help message.
10809 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
10810 and redeclare it as an array of 16-bit words.
10811 (grub_ext2_uuid): New function.
10812 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
10813 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
10814 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
10815 (GRUB_DEVICE_BOOT_UUID): New variables.
10816 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
10817 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
10818 whenever possible.
10819 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
10820 just assume `root' variable has the right value.
10821 * util/grub.d/10_linux.in: Likewise.
10822 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
10823 via PRINT_FS_UUID.
10824 (main): Recognise `-t fs_uuid' argument.
10825
01b73ec8 108262008-05-30 Robert Millan <rmh@aybabtu.com>
10827
10828 * util/biosdisk.c (map): Redefine structure to hold information
10829 about GRUB drive name.
fe6b695a 10830 (get_drive): Reimplement without assuming (and verifying) BIOS-like
01b73ec8 10831 drive names.
10832 (call_hook): Remove.
10833 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
10834 member. Assume drive has partitions.
10835 (grub_util_biosdisk_open): Access device names via `.device' struct
10836 member.
10837 (open_device): Likewise.
10838 (find_drive): Likewise.
10839 (read_device_map): Adjust map[] usage to match the new struct
10840 definition. Don't check for duplicates (still possible, but not cheap
10841 anymore).
10842 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
10843 (make_device_name): Remove assumption of BIOS-like drive names.
10844
22f16596 108452008-05-30 Pavel Roskin <proski@gnu.org>
10846
10847 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
10848 compiling execute.c doesn't need grub_script.tab.h anymore.
10849 (normal/command.c_DEPENDENCIES): Likewise.
10850 (normal/function.c_DEPENDENCIES): Likewise.
10851 * conf/i386-ieee1275.rmk: Likewise.
10852 * conf/i386-linuxbios.rmk: Likewise.
10853 * conf/i386-pc.rmk: Likewise.
10854 * conf/powerpc-ieee1275.rmk: Likewise.
10855 * conf/sparc64-ieee1275.rmk: Likewise.
10856
528ad8f2 108572008-05-29 Pavel Roskin <proski@gnu.org>
10858
d1dff95d 10859 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
10860 when scanning metadata for volume group name.
10861
528ad8f2 10862 * include/grub/script.h: Don't include grub_script.tab.h. It's
10863 a generated file, which may only be included from the files with
10864 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
10865 use union YYSTYPE, as the later allows forward declaration.
10866 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
10867
47248e08 108682008-05-29 Robert Millan <rmh@aybabtu.com>
10869
10870 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
10871 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
10872 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
10873 (grub_console_checkkey): Add grub_dprintf() call to report unknown
10874 scan codes.
10875
ee632529 108762008-05-29 Robert Millan <rmh@aybabtu.com>
10877
10878 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
10879 control key combinations.
10880
eee96e08 108812008-05-29 Robert Millan <rmh@aybabtu.com>
10882
10883 * util/powerpc/ieee1275/grub-install.in: Move from here ...
10884 * util/ieee1275/grub-install.in: ... to here.
10885 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
10886 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
10887 (grub_install_SOURCES): Likewise.
10888
da9a6a94 108892008-05-29 Robert Millan <rmh@aybabtu.com>
10890
10891 * fs/affs.c: Update copyright year.
10892 * fs/ext2.c: Likewise.
10893 * fs/fshelp.c: Likewise.
10894 * fs/hfsplus.c: Likewise.
10895 * fs/ntfs.c: Likewise.
10896 * fs/xfs.c: Likewise.
10897 * include/grub/fshelp.h: Likewise.
10898 * util/grub-mkdevicemap.c: Likewise.
10899
12e65f3a 109002008-05-28 Robert Millan <rmh@aybabtu.com>
10901
10902 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
10903 might need to be fatfs to support some firmware implementations
10904 (e.g. OFW or EFI).
10905
23023641 109062008-05-28 Robert Millan <rmh@aybabtu.com>
10907
10908 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
10909 devices.
10910 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10911 (make_device_map): Likewise.
10912
887d2619 109132008-05-20 Bean <bean123ch@gmail.com>
10914
10915 * fs/fshelp.c (grub_fshelp_map_block): New function.
10916 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
10917 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
10918
10919 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
10920 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
10921 (grub_fshelp_journal): New structure.
10922 (grub_fshelp_map_block): New function prototype.
10923 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
10924 (grub_fshelp_map_block): Likewise.
10925
10926 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
10927 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
10928 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
10929 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
10930 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
10931 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
10932 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
10933 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
10934 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
10935 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
10936 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
10937 (grub_ext2_sblock): New members for journal support.
10938 (grub_ext3_journal_header): New structure.
10939 (grub_ext3_journal_revoke_header): Likewise.
10940 (grub_ext3_journal_block_tag): Likewise.
10941 (grub_ext3_journal_sblock): Likewise.
10942 (grub_fshelp_node): New members logfile and journal.
10943 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
10944 grub_fshelp_map_block to get real block number.
10945 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
10946 number.
10947 (grub_ext2_read_inode): Likewise.
10948 (grub_ext3_get_journal): New function.
10949 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
10950 (grub_ext2_close): Release memory used by journal.
10951
10952 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
10953 (REISERFS_MAGIC_DESC_BLOCK): New macro.
10954 (grub_reiserfs_transaction_header): Renamed to
10955 grub_reiserfs_description_block, replace field data with real_blocks.
10956 (grub_reiserfs_commit_block): New structure.
10957 (grub_reiserfs_data): New member journal.
10958 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
10959 number.
10960 (grub_reiserfs_read_symlink): Likewise.
10961 (grub_reiserfs_iterate_dir): Likewise.
10962 (grub_reiserfs_open): Likewise.
10963 (grub_reiserfs_read): Likewise.
10964 (grub_reiserfs_get_journal): New function.
10965 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
10966 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
10967 using grub_reiserfs_get_journal.
10968 (grub_reiserfs_close): Release memory used by journal.
10969
10970 * fs/affs.c (grub_affs_read_block): Change block type to
10971 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
10972
10973 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
10974
10975 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
10976
10977 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
10978
10979 * fs/udf.c (grub_udf_read_block): Change block type to
10980 grub_disk_addr_t. Use type cast to avoid warning.
10981
10982 * fs/xfs.c (grub_xfs_read_block): Likewise.
10983
b7c6bed5 109842008-05-16 Christian Franke <franke@computer.org>
10985
10986 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
10987 to ensure that break with ESC will always work.
10988 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
10989 Remove ESC from keyboard queue.
10990
eedf167f 109912008-05-16 Christian Franke <franke@computer.org>
10992
10993 * util/biosdisk.c: [__CYGWIN__] Add includes.
10994 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
10995 (get_os_disk): Move variable declarations to OS specific
10996 parts to avoid warning.
10997 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
10998 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
10999 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
11000 Cygwin.
11001 * util/getroot.c: [__CYGWIN__] Add includes.
11002 (strip_extra_slashes): Fix "/" case.
11003 [__CYGWIN__] (get_win32_path): New function.
11004 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
11005 [__CYGWIN__] (find_root_device): Disable.
11006 [__CYGWIN__] (get_bootsec_serial): New function.
11007 [__CYGWIN__] (find_cygwin_root_device): Likewise.
11008 [__linux__] (grub_guess_root_device): Add early returns to simplify
11009 structure.
11010 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
11011 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
11012 check for Linux only.
11013
a079699e 110142008-05-15 Bean <bean123ch@gmail.com>
11015
11016 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
11017 keyboard hang problem in apple's intel mac.
11018
1cf4059a 110192008-05-09 Robert Millan <rmh@aybabtu.com>
11020
11021 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
11022 devices.
11023 * util/grub-mkdevicemap.c (get_virtio_disk_name)
11024 (make_device_map): Likewise.
11025 Reported by Aurelien Jarno <aurel32@debian.org>
11026
ed759390 110272008-05-07 Ian Campbell <ijc@hellion.org.uk>
11028
11029 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
11030 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
11031 (make_device_map): Output entries for xvd type disks.
11032
b56c4eaa 110332008-05-07 Robert Millan <rmh@aybabtu.com>
11034
11035 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
11036 devices.
11037 * util/grub-mkdevicemap.c (get_cciss_disk_name)
11038 (make_device_map): Likewise.
11039 Reported by Roland Dreier <rdreier@cisco.com>
11040
7f8866ed 110412008-05-07 Robert Millan <rmh@aybabtu.com>
11042
11043 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
11044 grub_strstr() call. Correct a few mistakes in failure path handling.
11045
b0346e0f 110462008-05-06 Robert Millan <rmh@aybabtu.com>
11047
11048 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
11049 Do not print a trailing slash (therefore, the root directory is an
11050 empty string).
11051 (convert_system_path_to_grub_path): Do not remove trailing slash
11052 from make_system_path_relative_to_its_root() output.
11053
11054 * util/i386/pc/grub-install.in: Add trailing slash to output from
11055 make_system_path_relative_to_its_root().
11056
6cf12cbd 110572008-05-06 Robert Millan <rmh@aybabtu.com>
11058
11059 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
11060 ensures that output lines aren't intermangled with those sent to
11061 stderr (via grub_util_info()).
11062 * util/grub-probe.c (grub_refresh): Likewise.
11063 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
11064
0fbb3117 110652008-05-05 Christian Franke <franke@computer.org>
11066
11067 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
11068 Add Cygwin device names.
11069 (get_ide_disk_name) [__CYGWIN__]: Likewise.
11070 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
11071 (check_device): Return error instead of success on empty name.
11072 (make_device_map): Move label inside linux specific code to
11073 prevent compiler warning.
11074
8124cdb7 110752008-04-30 Robert Millan <rmh@aybabtu.com>
11076
11077 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
11078 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
11079 first boot option.
11080 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
11081
094c01d0 110822008-04-29 Robert Millan <rmh@aybabtu.com>
11083
11084 * docs/grub.cfg: New file (example GRUB configuration).
11085
f4b1fc02 110862008-04-26 Robert Millan <rmh@aybabtu.com>
11087
329ce2a5 11088 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
11089 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
11090 and `disk/ieee1275/nand.c'.
f4b1fc02 11091
25f16ec1 110922008-04-25 Bean <bean123ch@gmail.com>
f19dbdb7 11093
25f16ec1 11094 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
11095 i386-linuxbios.
11096
11097 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
11098 change the buffer size to 4096 for cdrom device.
11099
11100 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
11101 and nand.mod.
11102 (_linux_mod_SOURCES): New variable.
11103 (_linux_mod_CFLAGS): Likewise.
11104 (_linux_mod_LDFLAGS): Likewise.
11105 (linux_mod_SOURCES): Likewise.
11106 (linux_mod_CFLAGS): Likewise.
11107 (linux_mod_LDFLAGS): Likewise.
11108 (nand_mod_SOURCES): Likewise.
11109 (nand_mod_CFLAGS): Likewise.
11110 (nand_mod_LDFLAGS): Likewise.
11111
11112 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
11113 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
11114 type property. (nand device in olpc don't have this property)
11115
11116 * include/grub/disk.h (grub_disk_dev_id): New macro
11117 GRUB_DISK_DEVICE_NAND_ID.
11118
11119 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
11120 function prototype.
11121 (grub_rescue_cmd_initrd): Likewise.
11122
11123 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
11124 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
11125 ofw_cif_handler and ofw_idt, adjust padding number.
f19dbdb7 11126
25f16ec1 11127 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
11128 GRUB_MACHINE_IEEE1275 is defined.
11129
11130 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
11131 Use NESTED_FUNC_ATTR attribute on the hook parameter.
11132
11133 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
11134 on nested function heap_init.
11135 (grub_upper_mem): New variable for i386-ieee1275.
11136 (grub_get_extended_memory): New function for i386-ieee1275.
11137 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
11138
11139 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
11140 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
11141 property.
f19dbdb7 11142
25f16ec1 11143 * loader/i386/ieee1275/linux.c: New file.
11144
11145 * loader/i386/ieee1275/linux_normal.c: New file.
11146
11147 * disk/ieee1275/nand.c: New file.
11148
e89d61e9 111492008-04-18 Thomas Schwinge <tschwinge@gnu.org>
11150
11151 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
11152 value.
11153 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
11154
602566f6 111552008-04-18 Robert Millan <rmh@aybabtu.com>
11156
11157 Restructures early code path on ieee1275 to unify grub_main() as
11158 the first C function that is executed in every platform.
11159
11160 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
11161 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
11162 cmain().
11163 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
11164 * kern/ieee1275/cmain.c (cmain): Rename to ...
11165 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
11166 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
11167 at the beginning.
11168
57490c2b 111692008-04-18 Robert Millan <rmh@aybabtu.com>
11170
11171 * util/update-grub.in: Fix syntax error when setting
11172 `GRUB_PRELOAD_MODULES'.
11173 Reported by Stephane Chazelas <stephane@artesyncp.com>
11174
1977517d 111752008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
11176
11177 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
11178 section into account, newer toolchains generate unique build ids
11179 * configure.ac: remove the test for --build-id=none acceptance,
e0c5dacb 11180 we want build ids to be preserved
1977517d 11181 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
11182 far from other sections don't cause the raw binary images grow
11183 size
11184
bfb1f1a2 111852008-04-15 Robert Millan <rmh@aybabtu.com>
11186
11187 * disk/lvm.c: Update copyright year.
11188 * kern/misc.c: Likewise.
11189
01979850 111902008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11191
11192 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
f19dbdb7 11193 there is no memory left for physical volume name.
01979850 11194
0a1150e2 111952008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11196
11197 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
11198 volume name mapping to support bigger than 9 character names properly.
11199
82ead3fe 112002008-04-13 Robert Millan <rmh@aybabtu.com>
11201
11202 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
11203 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
11204
e54a72f5 112052008-04-13 Christian Franke <franke@computer.org>
11206
11207 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
11208 to create a floppy emulation boot CD when non emulation mode
11209 does not work.
11210 Enable Joliet CD filesystem extension.
11211
9fe86034 112122008-04-13 Robert Millan <rmh@aybabtu.com>
11213
11214 * kern/misc.c (grub_strncat): Fix off-by-one error.
11215 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
11216
11217 * kern/env.c (grub_env_context_close): Clear current context, not
11218 previous one.
11219 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
11220
11221 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
11222
7ceeee39 112232008-04-13 Robert Millan <rmh@aybabtu.com>
11224
11225 Improve robustness when handling LVM.
11226
11227 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
f19dbdb7 11228 (and leave `*p' unmodified).
7ceeee39 11229 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
11230 through it.
11231 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
11232 iterating through it.
11233 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
11234 through it.
fe6b695a 11235 (grub_lvm_scan_device): Check the return value (and fail gracefully
7ceeee39 11236 when due) on each grub_lvm_getvalue() or grub_strstr() call.
11237 Don't assume `vg->pvs != NULL' when iterating through it.
11238
58cd3d85 112392008-04-13 Robert Millan <rmh@aybabtu.com>
11240
11241 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
11242 * genmk.rb (partmap): New variable.
11243 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
11244 (#{partmap}): New target rule.
11245 * genpartmaplist.sh: New file.
11246 * Makefile.in (pkglib_DATA): Add partmap.lst.
11247 (partmap.lst): New target rule.
11248 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
11249 modules (including all partition maps), instead of preloading them.
11250
78b51059 112512007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
11252
11253 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
11254 `linux-boot-prober' (if installed) to detect other operating
11255 systems which are installed on the computer and add them to
11256 the boot menu.
11257 * conf/common.rmk: Build and install 30_os-prober.
11258
a91627b4 112592008-04-12 Robert Millan <rmh@aybabtu.com>
11260
11261 * kern/powerpc/ieee1275/init.c: Move from here ...
11262 * kern/ieee1275/init.c: ... to here. Update all users.
11263
11264 * kern/powerpc/ieee1275/cmain.c: Move from here ...
11265 * kern/ieee1275/cmain.c: ... to here. Update all users.
11266
11267 * kern/powerpc/ieee1275/openfw.c: Move from here ...
11268 * kern/ieee1275/openfw.c: ... to here. Update all users.
11269
11270 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
11271 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
11272
322562ea 112732008-04-10 Pavel Roskin <proski@gnu.org>
11274
11275 * configure.ac: Always use "_cv_" in cache variables for
11276 compatibility with Autoconf 2.62.
11277
a02a73c5 112782008-04-07 Robert Millan <rmh@aybabtu.com>
11279
11280 Revert grub/machine/init.h addition by Pavel (since it breaks on
11281 i386-ieee1275 and others):
11282 * util/i386/pc/misc.c: Remove grub/machine/init.h.
11283 * util/powerpc/ieee1275/misc.c: Likewise.
11284
25c024b1 112852008-04-07 Robert Millan <rmh@aybabtu.com>
11286
11287 * util/grub-probe.c (probe): Improve error message.
11288
3cbd2f98 112892008-04-07 Robert Millan <rmh@aybabtu.com>
11290
11291 * util/biosdisk.c (read_device_map): Skip devices that don't exist
11292 (this prevents the presence of a bogus entry from ruining the whole
11293 thing).
11294
87a297bf 112952008-04-06 Pavel Roskin <proski@gnu.org>
11296
36747a62 11297 * util/biosdisk.c: Include grub/util/biosdisk.h.
11298 * util/grub-fstest.c (execute_command): Make static.
11299 * util/grub-mkdevicemap.c (check_device): Likewise.
11300 * util/i386/pc/misc.c: Include grub/machine/init.h.
11301 * util/powerpc/ieee1275/misc.c: Likewise.
11302 * util/lvm.c: Include grub/util/lvm.h.
11303 * util/misc.c: Include grub/kernel.h, grub/misc.h and
11304 grub/cache.h.
11305 * util/raid.c: Include grub/util/raid.h.
11306 (grub_util_getdiskname): Make static.
11307
87a297bf 11308 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
11309 grub_hostfs_fini(), as they are called from grub_init_all() and
11310 grub_fini_all() respectively. This fixes an infinite loop in
11311 grub-fstest due to double registration of hostfs.
11312 Reported by Christian Franke <Christian.Franke@t-online.de>
11313
f6ce7629 113142008-04-05 Pavel Roskin <proski@gnu.org>
11315
11316 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
11317 all 8 functions. Otherwise, probe function 0 only.
11318
070e49e4 113192008-04-04 Pavel Roskin <proski@gnu.org>
11320
8b088a4c 11321 * commands/lspci.c (grub_lspci_iter): Print the bus number
11322 correctly.
11323
4f657021 11324 * commands/lspci.c (grub_pci_classes): Fix typos.
11325 (grub_lspci_iter): Don't print func twice. Print vendor ID
11326 before device ID, as it's normally done.
11327
070e49e4 11328 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
11329 Fix signedness warnings.
11330 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
11331 Likewise.
11332 * util/ieee1275/get_disk_name.c: Include config.h so that
11333 _GNU_SOURCE is defined and getline() is declared. Mark an
11334 unused argument as such. Fix a signedness warning.
11335
ba7328dc 113362008-04-02 Pavel Roskin <proski@gnu.org>
11337
26887f22 11338 * genkernsyms.sh.in: Use more robust assignments for CC and
11339 srcdir. Quote srcdir.
11340 * gensymlist.sh.in: Likewise. Assert at the compile time that
11341 the symbol table is not empty.
11342
ba7328dc 11343 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
11344 * fs/cpio.c (grub_cpio_read): Likewise.
11345
0f582c6b 113462008-04-01 Pavel Roskin <proski@gnu.org>
11347
4b6e1995 11348 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
11349 * disk/host.c (grub_host_open): Likewise.
11350 * disk/loopback.c (grub_loopback_open): Likewise.
11351 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
11352 disk->id as in disk/host.c, not a multi-character constant.
11353
828a2768 11354 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
11355 later is obsolete, potentially dangerous and sets a bad example.
11356 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
11357 * util/misc.c (grub_util_get_image_size): Likewise.
11358
2bb4fb47 11359 * disk/loopback.c (options): Improve help for "--partitions".
11360
0f582c6b 11361 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
11362 options to align them with the short options, e.g. "echo -e".
11363
a33224e0 113642008-03-31 Bean <bean123ch@gmail.com>
11365
11366 * video/reader/png.c (grub_png_data): New member is_16bit and
11367 image_data.
11368 (grub_png_decode_image_header): Detect 16 bit png image.
11369 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
11370 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
11371 (grub_video_reader_png): Release memory occupied by image_data.
11372
11373 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
11374 4096 bytes.
11375 (grub_nfs_mount): Skip the test for sector per cluster.
11376
11377 * include/grub/ntfs.h (MAX_SPC): Removed.
11378
86cb4f54 113792008-03-31 Bean <bean123ch@gmail.com>
11380
11381 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
11382 (grub_probe_SOURCES): Add fs/afs.c.
11383 (grub_fstest_SOURCES): Likewise.
11384 (afs_mod_SOURCES): New variable.
11385 (afs_mod_CFLAGS): Likewise.
11386 (afs_mod_LDFLAGS): Likewise.
11387
11388 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
11389 (grub_emu_SOURCES): Likewise.
11390
11391 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11392
11393 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11394
11395 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11396
11397 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11398
11399 * fs/afs.c: New file.
11400
17c74c21 114012008-03-30 Pavel Roskin <proski@gnu.org>
11402
4cb68e89 11403 * disk/host.c: Include grub/misc.h to fix a warning.
11404 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
11405 warnings about implicit declarations.
11406
8790bb04 11407 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
11408 variable.
11409 * include/grub/i386/loader.h: Change declaration of
11410 grub_linux_boot() to match what grub_loader_set() expects.
11411 * util/getroot.c (grub_guess_root_device): Return const char* to
11412 fix a warning.
11413 * util/grub-probe.c (probe): Fix a warning about uninitialized
11414 abstraction_name variable.
11415 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
11416 second argument as unused to fix a warning.
11417
9a3f3296 11418 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
11419 missing grub_error() call.
11420
0ecef90d 11421 * util/update-grub_lib.in: Define datarootdir, since Autoconf
11422 2.60 and newer uses it to define datadir.
11423
0bf6d401 11424 * commands/sleep.c: Fix warning about implicit declaration.
11425 * disk/memdisk.c: Likewise.
11426 * loader/aout.c: Likewise.
11427 * loader/i386/bsd_normal.c: Likewise.
11428 * util/grub-probe.c: Likewise.
11429
7cdacf97 11430 * commands/i386/cpuid.c (has_longmode): Make static.
11431 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
11432 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
11433
17c74c21 11434 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
11435 GDT. This is more robust, as %ds can change.
11436 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
11437 calling real_to_prot().
11438 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
11439
80a3e68b 114402008-03-28 Pavel Roskin <proski@gnu.org>
11441
11442 * kern/i386/pc/startup.S: Assert that uncompressed functions
11443 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
11444 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
11445 code, as they push parts of the code (error handlers) beyond
11446 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
11447 code as correctness and size.
11448
77bcd272 114492008-03-28 Pavel Roskin <proski@gnu.org>
11450
11451 * kern/i386/pc/startup.S
11452 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
11453 data block address to the real mode, keep offset minimal. This
11454 works around a bug in AWARD BIOS on old Athlon systems, which
11455 makes CD detection hang.
11456
c5dfd43b 114572008-03-26 Pavel Roskin <proski@gnu.org>
11458
11459 * normal/color.c (grub_parse_color_name_pair): Make `name' a
11460 const.
11461 * include/grub/normal.h: Add grub_parse_color_name_pair()
11462 declaration.
11463
bf962df2 114642008-03-24 Bean <bean123ch@gmail.com>
11465
11466 * disk/i386/pc/biosdisk.c (cd_start): Removed.
11467 (cd_count): Removed.
11468 (cd_drive): New variable.
11469 (grub_biosdisk_get_drive): Don't check for (cdN) device.
11470 (grub_biosdisk_call_hook): Likewise.
11471 (grub_biosdisk_iterate): Change cdrom detection method.
11472 (grub_biosdisk_open): Replace cd_start with cd_drive.
11473 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
11474 detect cdrom device.
11475
11476 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
11477 Removed.
11478 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
11479 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
11480 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
11481 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
11482 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
11483 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
11484 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
11485 (grub_biosdisk_cdrp): New structure.
11486 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
11487
11488 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
11489
11490 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
11491 device.
11492
11493 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
11494 New function.
11495
68e7fc7a 114962008-03-20 Robert Millan <rmh@aybabtu.com>
11497
11498 Remove 2 TiB limit in ata.mod.
11499 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
11500 (grub_ata_dumpinfo): Print sector count with 0x%llx.
11501 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
11502 grub_uint64_t instead of grub_uint32_t.
11503
38ad2cf5 115042008-03-05 Bean <bean123ch@gmail.com>
11505
11506 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
11507 (grub_multiboot): Set boot device.
11508
11509 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
11510
2b89344e 115112008-03-02 Bean <bean123ch@gmail.com>
11512
11513 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
11514 symlink_buffer.
11515
87a95d1f 115162008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
11517
11518 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
11519 texinfo.tex.
11520
11521 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
11522 modified.
11523
11524 * docs/fdl.texi: New file.
f19dbdb7 11525
87a95d1f 11526 * docs/mdate-sh: New file. Copied from gnulib.
11527 * docs/texinfo.tex: Likewise.
11528
11529 * config.guess: Updated from gnulib.
11530 * install-sh: Likewise.
11531
7dc15d8e 115322008-02-28 Robert Millan <rmh@aybabtu.com>
11533
11534 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
11535 (aout_mod_SOURCES): New variable.
11536 (aout_mod_CFLAGS): Likewise.
11537 (aout_mod_LDFLAGS): Likewise.
11538
11539 * conf/i386-ieee1275.rmk: Likewise.
11540
b00ab696 115412008-02-28 Robert Millan <rmh@aybabtu.com>
11542
11543 * util/update-grub.in: Reorganise terminal validity check. Accept
11544 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
11545 Based on suggestion by Franklin PIAT.
11546
79ca2d78 115472008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
11548
11549 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
11550 function.
11551 * util/getroot.c (grub_util_check_block_device): New function that
11552 returns the given argument if it is a block device and returns NULL else.
11553 * util/grub-probe.c (argument_is_device): New variable.
11554 (probe): Promote device_name from a variable to an argument. Receive
11555 device_name from grub_util_check_block_device() if path is NULL and from
11556 grub_guess_root_device() else. Do not free() device_name anymore.
f19dbdb7 11557 (options): Introduce new parameter '-d, --device'.
79ca2d78 11558 (main): Add description of the new parameter to the help screen.
11559 Rename path variable to argument. Set argument_is_device if the '-d'
11560 option is given. Pass argument to probe() depending on
11561 argument_is_device.
11562
0d16e571 115632008-02-24 Bean <bean123ch@gmail.com>
11564
11565 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
11566 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
11567 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
11568 (GRUB_ISO9660_VOLDESC_PART): Likewise.
11569 (GRUB_ISO9660_VOLDESC_END): Likewise.
11570 (grub_iso9660_primary_voldesc): New member escape.
11571 (grub_iso9660_data): New member joliet.
11572 (grub_iso9660_convert_string): New function.
11573 (grub_iso9660_mount): Detect joliet extension.
11574 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
11575 (grub_iso9660_iso9660_label): Likewise.
11576
11577 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
11578 (grub_setup_SOURCES): Add fs/udf.c.
11579 (grub_fstest_SOURCES): Likewise.
11580 (udf_mod_SOURCES): New variable.
11581 (udf_mod_CFLAGS): Likewise.
11582 (udf_mod_LDFLAGS): Likewise.
11583
11584 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
11585 (grub_emu_SOURCES): Likewise.
11586
11587 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11588
11589 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11590
11591 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11592
11593 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11594
11595 * fs/udf.c: New file.
11596
8a594a17 115972008-02-24 Robert Millan <rmh@aybabtu.com>
11598
11599 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
11600 (normal/lexer.c_DEPENDENCIES): New variables.
11601 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11602 (normal/lexer.c_DEPENDENCIES): Likewise.
11603 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
11604 (normal/lexer.c_DEPENDENCIES): Likewise.
11605 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
11606 (normal/lexer.c_DEPENDENCIES): Likewise.
11607 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11608 (normal/lexer.c_DEPENDENCIES): Likewise.
11609 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11610 (normal/lexer.c_DEPENDENCIES): Likewise.
11611
2dc33c03 116122008-02-23 Robert Millan <rmh@aybabtu.com>
11613
11614 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
11615 since they were intended to be in hex. This didn't break previously
11616 because of a bug in gpt_partition_map_iterate() (see below).
11617
11618 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
11619 when checking the validity of GPT header.
11620 Remove `partno', since it always provides the same information as `i'.
11621
f6f4cfb0 116222008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
11623
11624 * include/grub/efi/time.h: Fix a wrong comment.
11625
79ff665f 116262008-02-19 Pavel Roskin <proski@gnu.org>
11627
11628 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
11629 message.
11630
d38e24c2 116312008-02-19 Bean <bean123ch@gmail.com>
11632
11633 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
11634 (aout_mod_SOURCES): New variable.
11635 (aout_mod_CFLAGS): Likewise.
11636 (aout_mod_LDFLAGS): Likewise.
11637 (_bsd_mod_SOURCES): New variable.
11638 (_bsd_mod_CFLAGS): Likewise.
11639 (_bsd_mod_LDFLAGS): Likewise.
11640 (bsd_mod_SOURCES): New variable.
11641 (bsd_mod_CFLAGS): Likewise.
11642 (bsd_mod_LDFLAGS): Likewise.
11643
11644 * include/grub/aout.h: New file.
11645
11646 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
11647
11648 * include/grub/i386/bsd.h: New file.
11649
11650 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
11651 to make it public.
11652
11653 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
11654 function is called, so that it's possible to change it inside the hook.
11655 (grub_elf64_load): Likewise.
11656 (grub_elf_file): Don't close the file if elf header is not found.
11657 (grub_elf_close): Close the file if grub_elf_file fails (The new
11658 grub_elf_file won't close it).
11659 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
11660 (grub_elf64_size): Likewise.
11661
11662 * kern/i386/loader.S (grub_unix_real_boot): New function.
11663
11664 * loader/aout.c: New file.
11665
11666 * loader/i386/bsd.c: New file.
11667
11668 * loader/i386/bsd_normal.c: New file.
11669
11670 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
11671
11672 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
fe987087 11673 can test other formats.
d38e24c2 11674
b93bdb0f 116752008-02-19 Robert Millan <rmh@aybabtu.com>
11676
11677 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
11678 (grub_gpt_partition_type_empty): Redefine with macro from
11679 `<grub/gpt_partition.h>'.
11680 (gpt_partition_map_iterate): Adjust partition type comparison.
11681
11682 Export `entry' as partmap-specific `part.data' struct.
11683 (grub_gpt_header, grub_gpt_partentry): Move from here ...
11684
11685 * include/grub/gpt_partition.h (grub_gpt_header)
11686 (grub_gpt_partentry): ... to here (new file).
11687
11688 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
11689
11690 (grub_gpt_partition_type_bios_boot): New const variable, defined
11691 with macro from `<grub/gpt_partition.h>'.
11692
11693 (setup): Replace `first_start' with `embed_region', which keeps
11694 track of the embed region (and is partmap-agnostic).
11695
11696 Replace find_first_partition_start() with find_usable_region(),
11697 which finds a usable region for embedding using partmap-specific
11698 knowledge (supports PC/MSDOS and GPT).
11699
11700 Fix all assumptions that the embed region start at sector 1, using
11701 `embed_region.start' from now on. Similarly, use `embed_region.end'
11702 rather than `first_start' to calculate available size.
11703
11704 In grub_util_info() message, replace "into after the MBR" with an
11705 indication of the specific sector our embed region starts at.
11706
66cb40f6 117072008-02-19 Robert Millan <rmh@aybabtu.com>
11708
11709 * DISTLIST: Replace `commands/ieee1275/halt.c' and
11710 `commands/ieee1275/reboot.c' with `commands/halt.c' and
11711 `commands/reboot.c'.
11712 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11713 (halt_mod_SOURCES): Likewise.
11714 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11715 (halt_mod_SOURCES): Likewise.
11716
b7202015 117172008-02-17 Christian Franke <franke@computer.org>
11718
11719 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
11720
32b0fc49 117212008-02-17 Robert Millan <rmh@aybabtu.com>
11722
11723 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11724 set `first_start' to 0 for non-PC/MSDOS partition maps.
11725
aca63502 117262008-02-16 Robert Millan <rmh@aybabtu.com>
11727
11728 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11729 do not assume partition map is PC/MSDOS before performing checks that
11730 are specific to that layout.
11731
0de8be86 117322008-02-13 Robert Millan <rmh@aybabtu.com>
11733
11734 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
11735 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
11736 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
11737
c3db8364 117382008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
11739
11740 * configure.ac: Only a cosmetic change on the handling of
11741 -fno-stack-protector.
11742
f714229e 117432008-02-12 Alexandre Boeglin <alex@boeglin.org>
11744
c3db8364 11745 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
11746 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
11747 reboot.c.
f714229e 11748 (grub_install_SOURCES): Add halt.mod and reboot.mod.
11749 (halt_mod_SOURCES): New variable.
11750 (halt_mod_CFLAGS): Likewise.
11751 (halt_mod_LDFLAGS): Likewise.
11752 (reboot_mod_SOURCES): Likewise.
11753 (reboot_mod_CFLAGS): Likewise.
11754 (reboot_mod_LDFLAGS): Likewise.
11755
c3db8364 11756 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
11757 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
11758 reboot.c.
f714229e 11759 (halt_mod_SOURCES): Likewise.
11760 (reboot_mod_SOURCES): Likewise.
11761
c3db8364 11762 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
11763 commands/i386/pc/reboot.c by commands/reboot.c.
f714229e 11764 (reboot_mod_SOURCES): Likewise.
11765
11766 * commands/i386/pc/reboot.c: merge this file ...
11767
11768 * commands/ieee1275/reboot.c: ... and this file ...
11769
11770 * commands/reboot.c: ... to this file.
c3db8364 11771 Add some precompiler directive to include the correct header for
11772 each machine.
f714229e 11773
11774 * commands/ieee1275/halt.c: move this file ...
11775
11776 * commands/halt.c: ... to here.
c3db8364 11777 Add some precompiler directive to include the correct header for
11778 each machine.
f714229e 11779
11780 * include/grub/efi/efi.h (grub_reboot): New function declaration.
11781 (grub_halt): Likewise.
11782
11783 * kern/efi/efi.c (grub_reboot): New function.
11784 (grub_halt): Likewise.
11785
c74493e0 117862008-02-12 Robert Millan <rmh@aybabtu.com>
11787
11788 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
11789 /dev (like it is done for /dev/mapper). This doesn't provide support
11790 for EVMS, but at least it is now easy to identify the problem when it
11791 arises.
11792
d0db4b04 117932008-02-11 Robert Millan <rmh@aybabtu.com>
11794
11795 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
11796 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
11797 comparing it with -1, not 0.
11798
bf748642 117992008-02-10 Robert Millan <rmh@aybabtu.com>
11800
11801 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
11802 `disk/lvm.c'.
11803 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11804 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
11805
11806 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
11807 `disk/lvm.c' to the end of the list.
11808 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11809 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
11810
b5db202a 118112008-02-10 Robert Millan <rmh@aybabtu.com>
11812
11813 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
11814 grub_print_error() instead. This will let user know why we're entering
11815 rescue mode.
11816 Based on suggestions from Sam Morris.
11817
83abee31 118182008-02-10 Alexandre Boeglin <alex@boeglin.org>
11819
11820 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
11821 on remaining N args, instead of "--" arg N times.
11822
78d5a08b 118232008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
11824
11825 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
11826 (fill_with_default_glyph): Changed to use unknown_glyph for fill
11827 pattern for unknown glyphs.
11828
68807e5f 118292008-02-09 Robert Millan <rmh@aybabtu.com>
11830
11831 * configure.ac: Probe for `help2man'.
11832 * Makefile.in (builddir): New variable.
11833 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
11834 or otherwise add a few flags/options to it.
11835 (install-local): For every executable utility or script that is
11836 installed, invoke $(HELP2MAN) to install a manpage based on --help
11837 output.
11838
11839 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
11840 that it doesn't prevent --help from working in build tree.
11841
11842 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
11843 with `bug-grub@gnu.org'.
11844 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
11845 * util/update-grub.in (usage): New function.
11846 Implement proper argument check, with support for --help and --version
11847 (as well as existing -y).
11848
118492008-02-09 Christian Franke <franke@computer.org>
0d9ff7f0 11850
11851 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
11852 avoid overwriting previous output.
11853 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
11854
c1962162 118552008-02-09 Robert Millan <rmh@aybabtu.com>
11856
11857 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
11858 drawing the menu.
11859
3dac2e3f 118602008-02-09 Robert Millan <rmh@aybabtu.com>
11861
11862 * commands/sleep.c: New file.
11863 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
11864 (sleep_mod_SOURCES): New variable.
11865 (sleep_mod_CFLAGS): Likewise.
11866 (sleep_mod_LDFLAGS): Likewise.
11867
7a634e08 118682008-02-09 Robert Millan <rmh@aybabtu.com>
11869
11870 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
11871 situations in which we can deduce the RAID size and the superblock
11872 doesn't match it.
11873
b92f0c18 118742008-02-09 Robert Millan <rmh@aybabtu.com>
11875
11876 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
11877 and return a grub_diskmemberlist_t composed of LVM physical volumes.
11878 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
11879
11880 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
11881 and return a grub_diskmemberlist_t composed of physical array members.
11882 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
11883
11884 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
11885 prototype.
11886 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
11887 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
11888 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
11889
11890 * util/grub-probe.c (probe): Move partmap probing code from here ...
11891 (probe_partmap): ... to here.
11892 (probe): Use probe_partmap() once for the disk we're probing, and
11893 additionally, when such disk contains a memberlist() struct member,
11894 once for each disk that is contained in the structure returned by
11895 memberlist().
11896
91a4bf68 118972008-02-09 Robert Millan <rmh@aybabtu.com>
11898
11899 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
11900 environment variable to 'all' in order to obtain debug output from
11901 non-util/ code.
11902 * util/i386/pc/grub-setup.c (main): Likewise.
11903
a96f9caa 119042008-02-08 Robert Millan <rmh@aybabtu.com>
11905
11906 * disk/raid.c (grub_raid_scan_device): Check for
11907 `array->device[sb.this_disk.number]' rather than for
11908 `array->device[sb.this_disk.number]->name', since the latter is not
fe6b695a 11909 guaranteed to be accessible.
a96f9caa 11910
b37a9222 119112008-02-08 Robert Millan <rmh@aybabtu.com>
11912
11913 * disk/raid.c: Update copyright.
11914 * fs/cpio.c: Likewise.
11915 * include/grub/raid.h: Likewise.
11916 * loader/i386/pc/multiboot.c: Likewise.
11917 * util/hostfs.c: Likewise.
11918
5626aee1 119192008-02-08 Robert Millan <rmh@aybabtu.com>
11920
11921 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
11922 to a grub_disk_t array.
11923 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
11924 `device[x]'.
11925 (grub_raid_scan_device): Replace `device[x].name' accesses with
11926 `device[x]->name'. Simplify initialization of `array->device[x]'.
11927
554f0187 119282008-02-08 Robert Millan <rmh@aybabtu.com>
11929
11930 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
11931 grub_dprintf() calls.
11932 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
11933 error message.
11934
1ec8425d 119352008-02-07 Christian Franke <franke@computer.org>
11936
11937 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
11938 instead of fseek and ftell to support large files.
11939 (grub_hostfs_read): Likewise.
11940
f2156fda 119412008-02-07 Robert Millan <rmh@aybabtu.com>
11942
11943 Patch from Jeroen Dekkers.
11944 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
fe6b695a 11945 failure, since successfully reading all array members might not be
f2156fda 11946 required.
11947
9216e0e7 119482008-02-06 Robert Millan <rmh@aybabtu.com>
11949
11950 * util/grub-probe.c (probe): Simplify partmap probing (with the
11951 assumption that the first word up to the underscore equals to
11952 the module name).
11953
b0dfd29a 119542008-02-06 Christian Franke <franke@computer.org>
11955
11956 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
11957 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
11958 last block of a cpio or tar stream.
11959 Check for "TRAILER!!!" instead of any empty data
11960 block to detect last block of a cpio stream.
11961 (grub_cpio_dir): Fix constness of variable np.
11962 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
11963 cpio or tar trailer is detected. This fixes a crash
11964 on open of a non existing file.
11965
c32865bf 119662008-02-05 Bean <bean123ch@gmail.com>
11967
11968 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
11969 address of entry.
11970 (grub_multiboot_load_elf64): Likewise.
11971 (grub_multiboot): Initialize mbi structure.
11972
11973 * util/grub-fstest.c: Don't include unused header file script.h.
11974
fe6b695a 11975 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
c32865bf 11976 of file.
11977 (grub_fstest_SOURCES): Likewise.
11978
409480b7 119792008-02-05 Robert Millan <rmh@aybabtu.com>
11980
11981 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
11982 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
11983 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
11984 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
11985
11986 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
11987 (translation_table): Replace hardcoded values with macros
11988 provided by `<grub/term.h>'.
11989
11990 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
11991 (keyboard_map): Correct/add a few values, with macros provided
11992 by `<grub/term.h>'.
11993 (keyboard_map_shift): Zero values that don't differ from their
11994 `keyboard_map' equivalents.
11995 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
11996 Discard the second scan code that is always sent by Caps lock.
11997 Only use `keyboard_map_shift' when it provides a non-zero value,
11998 otherwise fallback to `keyboard_map'.
11999
99fadbaa 120002008-02-04 Bean <bean123ch@gmail.com>
12001
12002 * Makefile.in (enable_grub_fstest): New variable.
12003
12004 * conf/common.rmk (grub_fstest_init.lst): New rule.
12005 (grub_fstest_init.h): Likewise.
12006 (grub_fstest_init.c): Likewise.
12007 (util/grub-fstest.c_DEPENDENCIES): New variable.
12008 (grub_fstest_SOURCES): Likewise.
12009
12010 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
12011
12012 * util/grub-fstest.c: New file.
12013
bf567c50 120142008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
12015
12016 Make grub-setup handle a separate root device.
f19dbdb7 12017
bf567c50 12018 * util/i386/pc/grub-setup.c (setup): Always open the root device,
12019 so that the root device can be compared with the destination
12020 device.
12021 When embedding the core image, if the root and destination devices
12022 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
12023 0xFF.
12024 When not embedding, set ROOT_DRIVE to 0xFF.
f19dbdb7 12025
9be6b98b 120262008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
12027
12028 Add support for having a grub directory in a different drive. This
12029 is still only the data handling part.
f19dbdb7 12030
9be6b98b 12031 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
12032 (codestart): Save %dh in GRUB_ROOT_DRIVE.
12033 (grub_root_drive): New variable.
12034
12035 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
12036 instead of GRUB_BOOT_DRIVE to construct a device name. Set
12037 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
12038 as it was.
12039
12040 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
12041
12042 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
12043 macro.
12044 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
12045
12046 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
12047 is bogus, because PXE booting does not specify any drive
12048 correctly.
12049
12050 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
12051 am not sure if this is really correct.
12052
12053 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
12054 is always identical to the boot drive when booting from a CD.
12055
12056 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
12057 longer.
12058 (root_drive): New variable.
12059 (real_start): Unconditionally set %dh to ROOT_DRIVE.
12060 (setup_sectors): Push %dx right after popping it, because %dh will
12061 be modified later.
12062 (copy_buffer): Restore %dx.
12063
e0ca0677 120642008-02-03 Robert Millan <rmh@aybabtu.com>
12065
12066 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
12067 use `cdboot.img' for cdrom images.
12068
3b3f6629 120692008-02-03 Robert Millan <rmh@aybabtu.com>
12070
12071 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
12072 only setup gfxterm when `font' command has succeeded.
12073
d42b3672 120742008-02-03 Robert Millan <rmh@aybabtu.com>
12075
12076 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
12077 (grub_rescue_cmd_multiboot_loader)
12078 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
12079
fa370ea6 120802008-02-03 Pavel Roskin <proski@gnu.org>
12081
e0c5dacb 12082 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
fa370ea6 12083 %edx and %esi from stack only after grub_gate_a20() is called.
12084 grub_gate_a20() clobbers %edx.
12085
f2a76e1d 120862008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
12087
12088 * configure.ac (AC_INIT): Bumped to 1.96.
12089
12090 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
12091 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
12092 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
12093 video/readers/png.c.
12094
90fd32d1 120952008-02-03 Bean <bean123ch@gmail.com>
9be665dd 12096
12097 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
12098 (cdboot_img_SOURCES): New variable.
12099 (cdboot_img_ASFLAGS): New variable.
12100 (cdboot_img_LDFLAGS): New variable.
12101
12102 * boot/i386/pc/cdboot.S: New file.
12103
12104 * disk/i386/pc/biosdisk.c (cd_start): New variable.
12105 (cd_count): Likewise.
12106 (grub_biosdisk_get_drive): Add support for cd device.
12107 (grub_biosdisk_call_hook): Likewise.
12108 (grub_biosdisk_iterate): Likewise.
12109 (grub_biosdisk_open): Likewise.
12110 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
12111 (grub_biosdisk_rw): Support reading from cd device.
12112 (GRUB_MOD_INIT): Iterate cd devices.
12113
12114 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
12115 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
12116 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
12117
12118 * kern/i386/pc/init.c (make_install_device): Check for cd device.
12119
4020aa53 121202008-02-02 Robert Millan <rmh@aybabtu.com>
12121
12122 * commands/read.c: New file.
12123 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
12124 (read_mod_SOURCES): New variable.
12125 (read_mod_CFLAGS): Likewise.
12126 (read_mod_LDFLAGS): Likewise.
12127
e03a1132 121282008-02-02 Robert Millan <rmh@aybabtu.com>
12129
12130 * normal/main.c (grub_normal_execute): Check for `menu->size' when
12131 determining whether menu has to be displayed.
12132
58c69220 121332008-02-02 Marco Gerards <marco@gnu.org>
12134
12135 * bus/pci.c: New file.
12136
12137 * include/grub/pci.h: Likewise.
12138
12139 * include/grub/i386/pc/pci.h: Likewise.
12140
12141 * commands/lspci.c: Likewise.
12142
12143 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
12144 `lspci.mod'.
12145 (pci_mod_SOURCES): New variable.
12146 (pci_mod_CFLAGS): Likewise.
12147 (pci_mod_LDFLAGS): Likewise.
12148 (lspci_mod_SOURCES): Likewise.
12149 (lspci_mod_CFLAGS): Likewise.
f19dbdb7 12150 (lspci_mod_LDFLAGS): Likewise.
58c69220 12151
c004e1b4 121522008-02-02 Bean <bean123ch@gmail.com>
12153
12154 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
12155 (grub_ufs_get_file_block): Fix indirect block calculation problem.
12156
12157 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
12158 (grub_xfs_btree_node): New structure.
12159 (grub_xfs_btree_root): New structure.
12160 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
12161 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
12162 (GRUB_XFS_EXTENT_BLOCK): Likewise.
12163 (GRUB_XFS_EXTENT_SIZE): Likewise.
12164 (grub_xfs_read_block): Support btree format type.
12165 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
12166 Use directory block as basic unit.
12167
12168 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
12169
12170 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
12171 __attribute__ ((__regparm__ (1))).
12172
f95562bf 121732008-02-01 Robert Millan <rmh@aybabtu.com>
12174
12175 Correct a mistake in previous commit.
12176
12177 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
12178 top.
12179 (normal/command.c_DEPENDENCIES): New variable.
12180
7d31f41f 121812008-02-01 Robert Millan <rmh@aybabtu.com>
12182
12183 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
12184 top.
12185 (normal/command.c_DEPENDENCIES): New variable.
12186 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
12187 * conf/i386-ieee1275.rmk: Likewise.
12188 * conf/i386-linuxbios.rmk: Likewise.
12189 * conf/i386-pc.rmk: Likewise.
12190 * conf/sparc64-ieee1275.rmk: Likewise.
12191 * conf/powerpc-ieee1275.rmk: Likewise.
12192 (grub_emu_SOURCES): Add `fs/fshelp.c'.
12193
12194 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
12195
60b6be74 121962008-02-01 Robert Millan <rmh@aybabtu.com>
12197
12198 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
12199 call at beginning of function.
12200
078522ab 122012008-01-31 Pavel Roskin <proski@gnu.org>
12202
12203 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
d2c11005 12204 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
12205 (grub_mkrescue_SOURCES): Likewise.
078522ab 12206 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
12207
ccaa8a5f 122082008-01-30 Robert Millan <rmh@aybabtu.com>
12209
12210 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
12211 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
12212 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
12213 (grub_probe_SOURCES): ... to here.
12214
12215 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
12216 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
12217 * conf/i386-ieee1275.rmk: Likewise.
12218 * conf/i386-linuxbios.rmk: Likewise.
12219 * conf/powerpc-ieee1275.rmk: Likewise.
12220
ae5a9cd7 122212008-01-30 Tristan Gingold <gingold@free.fr>
12222
12223 * kern/rescue.c: Silently accept empty lines.
12224
70bc2ef2 122252008-01-29 Bean <bean123ch@gmail.com>
12226
12227 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
12228 (real_code_2): Code cleanup and change comment style.
12229 (move_memory): Avoid using 32-bit address mode.
12230
6a4d50ea 122312008-01-29 Bean <bean123ch@gmail.com>
12232
12233 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
12234 (png_mod_SOURCES): New variable.
12235 (png_mod_CFLAGS): Likewise.
12236 (png_mod_LDFLAGS): Likewise.
12237
12238 * video/readers/png.c: New file.
12239
11cc30ac 122402008-01-28 Robert Millan <rmh@aybabtu.com>
12241
12242 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
12243 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
12244 `ifndef GRUB_MOD_GAP' hack.
12245 * util/elf/grub-mkimage.c (add_segments): Likewise.
12246
3abc589f 122472008-01-27 Robert Millan <rmh@aybabtu.com>
12248
12249 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
12250 `GRUB_MOD_GAP' for platforms in which it's not defined.
962ca133 12251 * util/elf/grub-mkimage.c (add_segments): Likewise.
3abc589f 12252
e1907778 122532008-01-27 Robert Millan <rmh@aybabtu.com>
12254
12255 Get grub-emu to build again (including parallel builds).
12256
12257 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
12258 Split into ...
12259 (util/grub-emu.c_DEPENDENCIES): ... this, ...
12260 (normal/execute.c_DEPENDENCIES): ... this, ...
12261 (grub-emu_DEPENDENCIES): ... and this.
12262
12263 * conf/i386-efi.rmk: Likewise.
12264 * conf/i386-linuxbios.rmk: Likewise.
12265 * conf/i386-ieee1275.rmk: Likewise.
12266 * conf/powerpc-ieee1275.rmk: Likewise.
12267 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
12268
2216b101 122692008-01-27 Robert Millan <rmh@aybabtu.com>
12270
12271 * NEWS: Add a few items.
12272
f75172d9 122732008-01-27 Robert Millan <rmh@aybabtu.com>
12274
12275 Fix parallel builds with grub-emu. Based on earlier commit for
12276 grub-probe and grub-setup.
12277
12278 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12279 (util/grub-emu.c_DEPENDENCIES): ... this.
12280 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12281 (util/grub-emu.c_DEPENDENCIES): ... this.
12282 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12283 (util/grub-emu.c_DEPENDENCIES): ... this.
12284 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12285 (util/grub-emu.c_DEPENDENCIES): ... this.
12286 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12287 (util/grub-emu.c_DEPENDENCIES): ... this.
12288
3f51de77 122892008-01-27 Pavel Roskin <proski@gnu.org>
12290
12291 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
12292 to create a gap between _end and the modules added to the image
12293 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
12294 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
12295 * util/elf/grub-mkimage.c (add_segments): Likewise.
12296
2033f53e 122972008-01-26 Pavel Roskin <proski@gnu.org>
12298
12299 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
12300 just return an error.
12301
22da1f6f 123022008-01-26 Bean <bean123ch@gmail.com>
12303
12304 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
12305 (grub_reiserfs_get_item): Save offset of the next item.
12306 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
12307
2a9525e6 123082008-01-25 Robert Millan <rmh@aybabtu.com>
12309
12310 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
12311 make all filesystem sources appear together (possibly fixing omissions
12312 while at it).
12313 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
12314 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12315 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
12316 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12317
12318 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
12319 add `kern/file.c'.
12320 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
12321 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12322 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
12323 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12324
12325 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
12326 (probe): Add a sanity check to make sure of our ability to read
12327 requested files when probing for filesystem type.
12328
12329 * genmk.rb: Update copyright year (2007).
12330
12331 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
12332 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
12333 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
12334 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
12335 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
12336 : Remove function prototypes.
12337
b95f71b5 123382008-01-25 Robert Millan <rmh@aybabtu.com>
12339
12340 Revert my previous commits (based on wrong assumption of how grub_errno
12341 works).
12342
fe6b695a 12343 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
b95f71b5 12344 * kern/file.c (grub_file_open): Likewise.
12345
d08bbb49 123462008-01-24 Pavel Roskin <proski@gnu.org>
12347
12348 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
12349 that hang if GRUB tries to setup colors.
12350 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
12351 colors for firmwares that don't support it.
12352 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
12353 Recognize Open Hack'Ware, set flags to work around its
12354 limitations.
12355
605e36ed 123562008-01-24 Robert Millan <rmh@aybabtu.com>
12357
12358 * kern/file.c (grub_file_open): Do not account previous failures of
12359 unrelated functions when grub_errno is checked for.
12360 Reported by Oleg Strikov.
12361
bac332a1 123622008-01-24 Bean <bean123ch@gmail.com>
12363
12364 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
12365 (grub_ufs_sblock): New member volume name.
12366 (grub_ufs_find_file): Fix string copy bug.
12367 (grub_ufs_label): Implement this function properly.
12368
12369 * fs/hfs.c (grub_hfs_cnid_type): New enum.
12370 (grub_hfs_iterate_records): Use the correct file number for extents
12371 and catalog file. Fix problem in next index calculation.
12372 (grub_hfs_find_node): Replace recursive function call with loop.
12373 (grub_hfs_iterate_dir): Replace recursive function call with loop.
12374
15c80c09 123752008-01-23 Robert Millan <rmh@aybabtu.com>
12376
12377 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
12378 `<grub/symbol.h>' and `<grub/multiboot.h>'.
12379 (grub_multiboot2_real_boot): New function prototype.
12380
12381 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
12382 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
12383
12384 * kern/i386/ieee1275/init.c (grub_os_area_addr)
12385 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
12386
305338fd 123872008-01-23 Robert Millan <rmh@aybabtu.com>
12388
12389 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
12390 #ifdef'ed out grub_printf().
12391
3ea52685 123922008-01-23 Robert Millan <rmh@aybabtu.com>
12393
12394 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
12395 grub_dprintf calls, since they make "debug=all" mode unusable.
12396 (grub_console_checkkey): Likewise.
12397
5882ae4b 123982008-01-23 Robert Millan <rmh@aybabtu.com>
12399
12400 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
12401 `term/i386/pc/at_keyboard.c'.
12402 (pkglib_MODULES): Add `serial.mod'.
12403 (serial_mod_SOURCES): New variable.
12404 (serial_mod_CFLAGS): Likewise.
12405 (serial_mod_LDFLAGS): Likewise.
12406
12407 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
12408 `<grub/powerpc/ieee1275/console.h>'.
12409 (grub_keyboard_controller_init): New function prototype.
12410 (grub_console_checkkey): Likewise.
12411 (grub_console_getkey): Likewise.
12412
12413 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
12414 keyboard on i386.
12415
12416 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
12417 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
12418
06ab5303 124192008-01-23 Robert Millan <rmh@aybabtu.com>
12420
12421 * kern/i386/pc/init.c (make_install_device): When memdisk image is
12422 present, "(memdisk)/boot/grub" becomes the default prefix.
12423
12424 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
12425 a memdisk tarball with all the modules. Add --overlay=DIR option that
12426 allows users to overlay additional files into the image.
12427
dbb475a4 124282008-01-23 Robert Millan <rmh@aybabtu.com>
12429
12430 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
12431 and `machine/memory.h'.
12432 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
12433 (_multiboot_mod_SOURCES): New variable.
12434 (_multiboot_mod_CFLAGS): Likewise.
12435 (_multiboot_mod_LDFLAGS): Likewise.
12436 (multiboot_mod_SOURCES): Likewise.
12437 (multiboot_mod_CFLAGS): Likewise.
12438 (multiboot_mod_LDFLAGS): Likewise.
12439
12440 * include/grub/i386/ieee1275/loader.h: New file.
12441
12442 * include/grub/i386/ieee1275/machine.h: Likewise.
12443
12444 * include/grub/i386/ieee1275/memory.h: Likewise.
12445
12446 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
12447 variable declaration.
12448 (grub_os_area_size): Likewise.
12449
12450 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
12451 (grub_lower_mem, grub_upper_mem): New variables.
12452 (grub_stop_floppy): New function (just to make
12453 grub_multiboot2_real_boot() happy).
12454
12455 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
12456 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
12457 (grub_stop): New function.
12458 Include `"../realmode.S"' and `"../loader.S"'.
12459
12460 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
12461 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
12462
12463 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
12464 rely on grub_multiboot2_real_boot() for final boot.
12465
25638629 124662008-01-22 Robert Millan <rmh@aybabtu.com>
12467
12468 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
12469 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
12470 device that doesn't look like an SD card.
12471 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
12472 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
12473 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
12474 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
12475 found.
12476
9dad816d 124772008-01-22 Robert Millan <rmh@aybabtu.com>
12478
12479 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
12480 avoid claiming over our own code.
12481
34842f2d 124822008-01-22 Bean <bean123ch@gmail.com>
12483
12484 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
12485 (jpeg_mod_SOURCES): New variable.
12486 (jpeg_mod_CFLAGS): Likewise.
12487 (jpeg_mod_LDFLAGS): Likewise.
12488
12489 * video/readers/jpeg.c : New file.
12490
44023a28 124912008-01-22 Bean <bean123ch@gmail.com>
12492
12493 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
12494 there are no more items.
12495
bc2d8ac6 124962008-01-21 Robert Millan <rmh@aybabtu.com>
12497
12498 * kern/mm.c (grub_mm_init_region): Improve debug message.
12499
261bd4bc 125002008-01-21 Robert Millan <rmh@aybabtu.com>
12501
12502 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
12503 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
12504 address.
12505 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
12506 a C macro.
12507 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
12508 Indicates start of upper memory.
12509 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
12510 (generate_image): Abort when image size is big enough to corrupt
12511 upper memory.
12512
12513 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
12514 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
12515 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12516 instead of hardcoding 0xA0000.
12517 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
12518 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12519 instead of hardcoding 0xA0000.
12520
f970b55e 125212008-01-21 Robert Millan <rmh@aybabtu.com>
12522
12523 * disk/memdisk.c (memdisk_size): New variable.
12524 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
12525 `memdisk_size'.
12526 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
12527 image to dynamic memory.
12528 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
12529 `memdisk_size'. Free memdisk block.
12530
1a8b0526 125312008-01-21 Robert Millan <rmh@aybabtu.com>
12532
12533 Fix detection of very small filesystems (like tar).
12534
12535 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
12536 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
12537 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
12538 a problem with this disk).
12539
6e9b4aab 125402008-01-21 Robert Millan <rmh@aybabtu.com>
12541
12542 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
12543 on grub_biosdisk_rw_standard() error.
12544
0d8837b2 125452008-01-21 Robert Millan <rmh@aybabtu.com>
12546
12547 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
12548 recent changes.
12549 * kern/elf.c: Likewise.
12550 * kern/ieee1275/ieee1275.c: Likewise.
12551 * kern/powerpc/ieee1275/openfw.c: Likewise.
12552 * term/ieee1275/ofconsole.c: Likewise.
12553
ffd36e34 125542008-01-21 Robert Millan <rmh@aybabtu.com>
12555
12556 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
12557
3f0093d0 12558 * include/grub/kernel.h (grub_arch_memdisk_addr)
12559 (grub_arch_memdisk_size): Moved from here ...
ffd36e34 12560
3f0093d0 12561 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
12562 (grub_arch_memdisk_size): ... to here.
ffd36e34 12563
6c391b21 125642008-01-21 Robert Millan <rmh@aybabtu.com>
12565
12566 Mostly based on bugfix from Bean.
12567
12568 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
12569 attribute with hook() parameter.
12570 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
12571 declaration.
12572 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
12573 attribute with hook() parameter.
12574 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
12575 declaration.
12576
55a581dc 125772008-01-21 Robert Millan <rmh@aybabtu.com>
12578
12579 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
12580 (pkglib_MODULES): Add `memdisk.mod'.
12581 (memdisk_mod_SOURCES): New variable.
12582 (memdisk_mod_CFLAGS): Likewise.
12583 (memdisk_mod_LDFLAGS): Likewise.
12584
12585 * disk/memdisk.c: New file.
12586
12587 * include/grub/disk.h (grub_disk_dev_id): Add
12588 `GRUB_DISK_DEVICE_MEMDISK_ID'.
12589
12590 * include/grub/i386/pc/kernel.h
12591 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
12592 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
12593 (grub_kernel_image_size): New variable declaration.
12594 (grub_total_module_size): Likewise.
12595 (grub_memdisk_image_size): Likewise.
12596
12597 * include/grub/i386/pc/memory.h
12598 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
12599
12600 * include/grub/kernel.h: Include `<grub/symbol.h>'.
12601 (grub_arch_memdisk_addr): New variable declaration.
12602 (grub_arch_memdisk_size): Likewise.
12603
12604 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
12605 (grub_arch_memdisk_size): Likewise.
12606
12607 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
12608 (codestart): Replace hardcoded `0x100000' with
12609 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
12610
12611 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
12612 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
12613 not NULL, append the contents of the file it refers to, at the end of
12614 the compressed kernel image. Initialize `grub_memdisk_image_size'
12615 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
12616 (options): Add "memdisk"|'m' option.
12617 (main): Parse --memdisk|-m option, and pass user-provided path as
12618 parameter to generate_image().
12619
3d7f54c9 126202008-01-20 Robert Millan <rmh@aybabtu.com>
12621
12622 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
12623 grub_dprintf() calls from here ...
12624 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
12625
0bf74728 126262008-01-20 Robert Millan <rmh@aybabtu.com>
12627
12628 Fix detection of "real mode" when /options/real-mode? doesn't exist.
12629
12630 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
12631 declaration.
12632 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
12633 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
12634 `GRUB_IEEE1275_FLAG_REAL_MODE'.
fe6b695a 12635 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
0bf74728 12636 property).
12637 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
12638 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
12639
33bf70a7 126402008-01-19 Robert Millan <rmh@aybabtu.com>
12641
fe6b695a 12642 Get rid of confusing function (superseded by
33bf70a7 12643 `grub_ieee1275_get_integer_property')
12644 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
12645 prototype.
12646 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
12647 function.
12648 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
12649 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
fe987087 12650 in native endianness from grub_ieee1275_get_integer_property().
33bf70a7 12651
e2da7d26 126522008-01-19 Robert Millan <rmh@aybabtu.com>
12653
12654 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
12655 command after "shut-down", since implementations differ on which
12656 the command for halt is.
12657
59f1fd8d 126582008-01-19 Robert Millan <rmh@aybabtu.com>
12659
12660 * include/grub/i386/linuxbios/console.h: Add header protection.
12661 (grub_keyboard_controller_init): New function prototype.
12662 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
12663 (KEYBOARD_COMMAND_READ): Likewise.
12664 (KEYBOARD_COMMAND_WRITE): Likewise.
12665 (KEYBOARD_SCANCODE_SET1): Likewise.
12666 (grub_keyboard_controller_write): New function.
12667 (grub_keyboard_controller_read): Likewise.
12668 (grub_keyboard_controller_init): Likewise.
12669
12670 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
12671 (grub_console_init): On coreboot/LinuxBIOS, call
12672 grub_keyboard_controller_init().
12673
5f5a7c15 126742008-01-19 Robert Millan <rmh@aybabtu.com>
12675
12676 PowerPC changes provided by Pavel Roskin.
12677
12678 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
12679 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
12680 don't rely on cmain() doing it.
12681 * kern/i386/ieee1275/startup.S (_start): Store %eax in
12682 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
12683
1210e168 126842008-01-16 Robert Millan <rmh@aybabtu.com>
12685
12686 * include/grub/i386/linuxbios/memory.h
12687 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
12688 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
12689 receive `table_header' as argument. Instead, probe for it in the
12690 known memory ranges where it can be present.
12691 (grub_available_iterate): Do not pass a fixed `table_header' address
12692 to grub_linuxbios_table_iterate().
12693
3d04eab8 126942008-01-15 Robert Millan <rmh@aybabtu.com>
12695
12696 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
12697 * conf/i386-ieee1275.rmk: New file.
12698 * include/grub/i386/ieee1275/console.h: Likewise.
12699 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
12700 * include/grub/i386/ieee1275/kernel.h: Likewise.
12701 * include/grub/i386/ieee1275/time.h: Likewise.
12702 * kern/i386/ieee1275/init.c: Likewise.
12703 * kern/i386/ieee1275/startup.S: Likewise.
12704
d1bc1b73 127052008-01-15 Robert Millan <rmh@aybabtu.com>
12706
12707 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
12708 when pointers are 32-bit (but still do set it to one when they are
12709 64-bit).
12710
66a65807 127112008-01-15 Robert Millan <rmh@aybabtu.com>
12712
12713 * include/grub/ieee1275/ieee1275.h
12714 (grub_ieee1275_get_integer_property): New function prototype.
12715
12716 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
12717 (grub_ieee1275_get_integer_property): New function. Wraps around
fe987087 12718 grub_ieee1275_get_property() to handle endianness.
66a65807 12719
12720 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
12721 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
fe6b695a 12722 where appropriate.
66a65807 12723 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
12724 (grub_map): Likewise.
12725 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
12726
a83ccafd 127272008-01-15 Bean <bean123ch@gmail.com>
12728
12729 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
12730 (grub_script_execute_cmdline): Reset grub_errno.
12731
12732 * normal/main.c (read_config_file): Reset grub_errno.
12733
12734 * normal/parse.y (script_init): New.
12735 (script): Move function and menuentry here.
12736 (delimiter): New.
12737 (command): Add delimiter at the end of command.
12738 (commands): Adjust to match the new command.
12739 (commandblock): Remove grub_script_lexer_record_start.
f19dbdb7 12740 (menuentry): Add grub_script_lexer_record_start, use the new commands.
a83ccafd 12741 (if): Use the new commands.
12742
12743 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
12744
df6ecfc6 127452008-01-15 Robert Millan <rmh@aybabtu.com>
12746
12747 * normal/menu.c (run_menu): Move timeout message from here ...
12748 (print_timeout): ... to here.
12749 (run_menu): Use print_timeout() once during initial draw to print
12750 the whole message, and again in every clock tick to update only
12751 the number of seconds.
12752
87ae25eb 127532008-01-15 Robert Millan <rmh@aybabtu.com>
12754
12755 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
12756 actual size of `available' from grub_ieee1275_get_property(), and
12757 restrict parsing to that bound.
12758
47bf09a4 127592008-01-15 Christian Franke <franke@computer.org>
12760
12761 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
12762 (argp_program_version): Remove variable.
12763 (argp_program_bug_address): Likewise.
12764 (options): Convert from struct argp_option to struct option.
12765 (struct arguments): Remove.
12766 (parse_opt): Remove.
12767 (usage): New function.
12768 (main): Replace struct args members by simple variables.
12769 Replace argp_parse() by getopt_long().
12770 Add switch to evaluate options.
12771 Add missing "(...)" around root_dev in prefix string.
12772
c86f1469 127732008-01-14 Robert Millan <rmh@aybabtu.com>
12774
12775 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
12776 for grub_ieee1275_exit(), in order to improve portability.
12777
e622c559 127782008-01-14 Robert Millan <rmh@aybabtu.com>
12779
12780 * util/grub.d/10_linux.in (prefix): Define.
12781 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
12782
44cb1ec8 127832008-01-13 Pavel Roskin <proski@gnu.org>
12784
12785 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
12786 grub_errno if no errors have been detected.
12787
1eb8c802 127882008-01-12 Robert Millan <rmh@aybabtu.com>
12789
12790 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
12791 (grub_util_get_dev_abstraction): New function prototype.
12792
12793 * util/getroot.c: Include `<grub/util/getroot.h>'
12794 (grub_util_get_grub_dev): Move detection of abstraction type to ...
12795 (grub_util_get_dev_abstraction): ... here (new function).
12796
12797 * util/grub-probe.c: Convert PRINT_* to an enum. Add
12798 `PRINT_ABSTRACTION'.
12799 (probe): Probe for abstraction type when requested.
12800 (main): Understand `--target=abstraction'.
12801
12802 * util/i386/efi/grub-install.in: Add abstraction module to core
12803 image when it is found to be necessary.
12804 * util/i386/pc/grub-install.in: Likewise.
12805 * util/powerpc/ieee1275/grub-install.in: Likewise.
12806
12807 * util/update-grub_lib.in (font_path): Return system path without
12808 converting to GRUB path.
12809 * util/update-grub.in: Convert system path returned by font_path()
12810 to a GRUB path. Use `grub-probe -t abstraction' to determine what
12811 abstraction module is needed for loading fonts (if any). Export
12812 that as `GRUB_PRELOAD_MODULES'.
12813 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
12814 insmod commands).
12815
52bd3de9 128162008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
12817
12818 Remove some unused code from reiserfs.
f19dbdb7 12819
52bd3de9 12820 * fs/reiserfs.c (struct grub_reiserfs_key)
12821 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
12822 (struct grub_reiserfs_node_body): Removed.
12823 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12824 Likewise.
12825 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12826 Likewise.
12827 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12828 Likewise.
12829 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12830 Likewise.
12831 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12832 Likewise.
12833 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
12834 Likewise.
12835 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12836 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12837 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12838
2f80039d 128392008-01-10 Robert Millan <rmh@aybabtu.com>
12840
12841 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
12842 Determines if a file is garbage left by packaging systems, etc.
12843 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
12844 for processing /etc/grub.d scripts.
12845 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
12846 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
12847 as a condition for processing Linux images.
12848
87888032 128492008-01-10 Pavel Roskin <proski@gnu.org>
12850
12851 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
12852 to compile reiserfs.c on PowerPC.
12853
7e54fced 128542008-01-10 Robert Millan <rmh@aybabtu.com>
de9993e0 12855
12856 * kern/device.c (grub_device_iterate): Do not abort device iteration
12857 when one of the devices cannot be opened.
12858 * kern/disk.c (grub_disk_open): Do not account previous failures of
12859 unrelated functions when grub_errno is checked for.
12860
5aa541e6 128612008-01-08 Robert Millan <rmh@aybabtu.com>
12862
12863 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
12864 `! grub_linux_is_bzimage', change order of address comparison to make
12865 it more intuitive, and improve "too big zImage" error message.
12866
7076340d 128672008-01-08 Robert Millan <rmh@aybabtu.com>
12868
12869 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
12870 `$(update-grub_DATA)'.
12871 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
12872 targets.
12873
9ca70333 128742008-01-07 Robert Millan <rmh@aybabtu.com>
12875
12876 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
12877 which instruction is modified by grub-setup during installation
12878 (since it wasn't obvious by only looking at this file).
12879
38ccf575 128802008-01-07 Robert Millan <rmh@aybabtu.com>
12881
12882 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
12883 listing actual TODO items.
12884
f5db4291 128852008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12886
868967cf 12887 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
12888 correctly.
12889 (grub_reiserfs_get_key_offset): Likewise.
12890 (grub_reiserfs_set_key_offset): Likewise.
12891 (grub_reiserfs_set_key_type): Likewise.
fe6b695a 12892 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
868967cf 12893
12894 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
12895 better to remove the bitfield version completely.
f19dbdb7 12896
868967cf 128972008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 12898
f5db4291 12899 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
12900 allocated from the heap, due to the fshelp implementation.
12901 (grub_reiserfs_dir): Free NODE, due to the same reason.
12902
492e6d9d 129032008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12904
12905 Mostly from Vincent Pelletier:
f19dbdb7 12906
492e6d9d 12907 * fs/reiserfs.c: New file.
f19dbdb7 12908
492e6d9d 12909 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
12910 (reiserfs_mod_SOURCES): New variable.
12911 (reiserfs_mod_CFLAGS): Likewise.
12912 (reiserfs_mod_LDFLAGS): Likewise.
12913
12914 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
12915 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
12916 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
12917 normal/color.c.
12918
9ce3e7c1 129192008-01-06 Robert Millan <rmh@aybabtu.com>
12920
12921 * normal/color.c: Remove `<grub/env.h>'.
12922
f3b58148 129232008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
12924
12925 * include/grub/normal.h: Include <grub/env.h>.
12926
7ac3bcfa 129272008-01-05 Robert Millan <rmh@aybabtu.com>
12928
12929 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
12930 usage example with `(hd0,1)'.
fb358190 12931 Reported by Samuel Thibault.
7ac3bcfa 12932
c8ee99d7 129332008-01-05 Robert Millan <rmh@aybabtu.com>
12934
12935 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
12936 (grub_linux_boot_zimage): Rename to ...
12937 (grub_linux_boot): ... this.
12938 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
12939 (grub_linux_boot_zimage): Conditionalize zImage copy.
12940
12941 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
12942 (grub_linux_boot_bzimage): Remove prototype.
12943 (grub_linux_boot_zimage): Rename to ...
12944 (grub_linux_boot): ... this.
12945
12946 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
12947 (grub_linux_boot): Remove function.
12948
0ece25b1 129492008-01-05 Robert Millan <rmh@aybabtu.com>
12950
12951 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
12952 (grub_env_write_color_highlight): Likewise.
12953 (grub_wait_after_message): Likewise.
12954
12955 * normal/color.c: New file.
12956
12957 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12958 (normal_mod_DEPENDENCIES): Likewise.
12959
12960 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12961 (normal_mod_DEPENDENCIES): Likewise.
12962
12963 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12964 (normal_mod_DEPENDENCIES): Likewise.
12965
12966 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12967 (normal_mod_DEPENDENCIES): Likewise.
12968
12969 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
12970 for waiting after a message is printed.
12971 * normal/main.c (read_config_file): Likewise.
12972 (grub_normal_init): Register grub_env_write_color_normal() and
12973 grub_env_write_color_highlight() hooks. Mark `color_normal' and
12974 `color_highlight' variables as global.
12975
12976 * normal/menu.c (grub_wait_after_message): New function.
12977 (grub_color_menu_normal): New variable. Replaces ...
12978 (GRUB_COLOR_MENU_NORMAL): ... this macro.
12979 (grub_color_menu_highlight): New variable. Replaces ...
12980 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
12981 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
12982 `GRUB_TERM_COLOR_STANDARD'.
12983 (print_message): Use `grub_setcolorstate' to reload colors. Rename
12984 `normal_code' and `highlight_code' to `old_color_normal' and
12985 `old_color_highlight', respectively.
12986 (grub_menu_init_page): Update colors when drawing the menu, based on
12987 `menu_color_normal' and `menu_color_highlight' variables.
12988 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
12989 a message is printed.
12990
182dd4e5 129912008-01-05 Robert Millan <rmh@aybabtu.com>
12992
12993 * kern/env.c (grub_env_context_open): Propagate hooks for global
12994 variables to new context.
12995
12996 * kern/main.c (grub_set_root_dev): Export `root' variable.
12997
ddf8f6ad 129982008-01-05 Robert Millan <rmh@aybabtu.com>
12999
13000 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
fe6b695a 13001 discs unconditionally, since udev and others have options to provide
ddf8f6ad 13002 them.
13003
d8b43d9b 130042008-01-05 Robert Millan <rmh@aybabtu.com>
13005
13006 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
13007
2bff2de3 130082008-01-04 Christian Franke <franke@computer.org>
13009
13010 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
13011 of eisa_mmap.
13012
97eab917 130132008-01-03 Pavel Roskin <proski@gnu.org>
13014
13015 * kern/i386/linuxbios/init.c: Put "void" to all function
13016 declarations with no arguments.
13017 * kern/powerpc/ieee1275/init.c: Likewise.
13018 * term/i386/pc/at_keyboard.c: Likewise.
13019 * term/i386/pc/vga_text.c: Likewise.
13020 * util/grub-mkdevicemap.c: Likewise.
13021
b9416d00 130222008-01-02 Robert Millan <rmh@aybabtu.com>
13023
13024 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
13025 message when loaded image is out of bounds.
13026 (grub_multiboot_load_elf64): Likewise.
13027
92695df9 130282008-01-02 Pavel Roskin <proski@gnu.org>
13029
13030 * util/grub.d/10_linux.in: Try version without ".old" when
13031 looking for initrd. It's better to use initrd from the newer
13032 kernel of the same version than no initrd at all.
13033
d98d9cad 130342008-01-01 Robert Millan <rmh@aybabtu.com>
13035
13036 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
13037
dbfdce36 130382008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
13039
f19dbdb7 13040 * include/grub/video.h: Added grub_video_unmap_color and
dbfdce36 13041 grub_video_get_active_render_target.
13042 (grub_video_adapter): Added unmap_color and get_active_render_target.
13043
f19dbdb7 13044 * video/video.c: Added grub_video_unmap_color and
dbfdce36 13045 grub_video_get_active_render_target.
13046 (grub_video_get_info): Changed method to accept NULL pointer as an
13047 argument to allow detection of active video adapter.
13048
13049 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
13050 grub_video_vbe_unmap_color_int.
13051 Added grub_video_vbe_unmap_color and
13052 grub_video_vbe_get_active_render_target.
13053 (grub_video_vbe_adapter): Added unmap_color and
13054 get_active_render_target.
13055
f19dbdb7 13056 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
dbfdce36 13057 with grub_video_vbe_unmap_color_int.
13058
13059 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
13060 (DEFAULT_NORMAL_COLOR): Likewise.
13061 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
13062 (DEFAULT_FG_COLOR): Removed.
13063 (DEFAULT_BG_COLOR): Likewise.
13064 (DEFAULT_CURSOR_COLOR): Changed value.
13065 (grub_virtual_screen): Added standard_color_setting,
13066 normal_color_setting, highlight_color_setting and term_color.
13067 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
13068 (bitmap_width): Added.
13069 (bitmap_height): Likewise.
13070 (bitmap): Likewise.
13071 (set_term_color): Likewise.
13072 (grub_virtual_screen_setup): Changed to use new terminal coloring
13073 settings.
13074 (grub_gfxterm_init): Added init for bitmap.
13075 (grub_gfxterm_fini): Added destroy for bitmap.
13076 (redraw_screen_rect): Updated to use background bitmap and new
13077 terminal coloring.
13078 (scroll_up): Added optimization for case when there is no bitmap.
13079 (grub_gfxterm_cls): Fixed to use correct background color.
13080 (grub_virtual_screen_setcolorstate): Changed to use new terminal
13081 coloring.
13082 (grub_virtual_screen_setcolor): Likewise.
13083 (grub_virtual_screen_getcolor): Added.
13084 (grub_gfxterm_background_image_cmd): Likewise.
13085 (grub_video_term): Added setcolor and getcolor.
13086 (MOD_INIT): Added registration of background_image command.
13087 (MOD_TERM): Added unregistration for background_image command.
13088
c3c20931 130892007-12-30 Pavel Roskin <proski@gnu.org>
13090
13091 * loader/multiboot_loader.c: Fix multiboot command
13092 unregistration. Fix all typos in the word "multiboot".
13093
df266716 130942007-12-29 Pavel Roskin <proski@gnu.org>
94239199 13095
13096 * util/grub.d/10_linux.in: Refactor search for initrd. Add
13097 support for initrd names used in Fedora.
13098
fc6e896c 130992007-12-26 Bean <bean123ch@gmail.com>
13100
13101 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
13102 (cpio_mod_SOURCES): New variable.
13103 (cpio_mod_CFLAGS): Likewise.
13104 (cpio_mod_LDFLAGS): Likewise.
13105
13106 * fs/cpio.c: New file.
13107
13108 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
13109
13110 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
13111
13112 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
13113
13114 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13115
533110ad 131162007-12-25 Robert Millan <rmh@aybabtu.com>
13117
13118 * include/grub/term.h (struct grub_term): Add `getcolor' function.
13119 (grub_getcolor): New function.
13120
13121 * kern/term.c (grub_getcolor): New function.
13122 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
13123 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
13124 (print_entry): Set normal and highlight colors to
13125 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
13126 respectively, before printing and restore them to old
13127 values afterwards.
13128 (grub_menu_init_page): Likewise. Fill an additional colored space
13129 that would otherwise be left blank.
13130
13131 * term/efi/console.c (grub_console_getcolor): New function.
13132 (struct grub_console_term.getcolor): New variable.
13133 * term/i386/pc/console.c (grub_console_getcolor): New function.
13134 (struct grub_console_term.getcolor): New variable.
13135 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
13136 (struct grub_console_term.getcolor): New variable.
13137
13138 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
13139 (struct grub_console_term.setcolor): Remove variable.
13140 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
13141 (struct grub_console_term.setcolor): Remove variable.
13142 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
13143 (struct grub_console_term.setcolor): Remove variable.
13144 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
13145 (struct grub_console_term.setcolor): Remove variable.
13146
4931827f 131472007-12-25 Robert Millan <rmh@aybabtu.com>
13148
13149 * configure.ac: Search for possible unifont.hex locations, and
13150 define UNIFONT_HEX if found.
13151
13152 * Makefile.in (UNIFONT_HEX): Define variable.
13153 (DATA): Rename to ...
13154 (PKGLIB): ... this. Update all users.
13155 (PKGDATA): New variable.
13156 (pkgdata_IMAGES): Rename to ...
13157 (pkglib_IMAGES): ... this. Update all users.
13158 (pkgdata_MODULES): Rename to ...
13159 (pkglib_MODULES): ... this. Update all users.
13160 (pkgdata_PROGRAMS): Rename to ...
13161 (pkglib_PROGRAMS): ... this. Update all users.
13162 (pkgdata_DATA): Rename to ...
13163 (pkglib_DATA): ... this. Update all users.
13164 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
13165 (unicode.pff, ascii.pff): New rules.
13166 (all-local): Add `$(PKGDATA)' dependency.
13167 (install-local): Process `$(PKGDATA)'.
13168
13169 * util/update-grub_lib.in (font_path): Search for *.pff files in
13170 a few more locations, including `${pkgdata}'.
13171
57e57e31 131722007-12-23 Robert Millan <rmh@aybabtu.com>
13173
13174 Patch from Bean <bean123ch@gmail.com>:
13175 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
13176 `size'.
13177
4bc72aa9 131782007-12-21 Bean <bean123ch@gmail.com>
13179
13180 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
13181 (ntfscomp_mod_SOURCES): New variable.
13182 (ntfscomp_mod_CFLAGS): Likewise.
13183 (ntfscomp_mod_LDFLAGS): Likewise.
13184
13185 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
13186 (grub_probe_SOURCES): Likewise.
13187 (grub_emu_SOURCES): Likewise.
13188
13189 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13190 (grub_emu_SOURCES): Likewise.
13191
13192 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13193 (grub_emu_SOURCES): Likewise.
13194
13195 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13196 (grub_emu_SOURCES): Likewise.
13197
13198 * fs/ntfs.c (grub_ntfscomp_func): New variable.
13199 (read_run_list): Renamed to grub_ntfs_read_run_list.
13200 (decomp_nextvcn): Moved to ntfscomp.c.
13201 (decomp_getch): Likewise.
13202 (decomp_get16): Likewise.
13203 (decomp_block): Likewise.
13204 (read_block): Likewise.
13205 (read_data): Partially moved to ntfscomp.c.
13206 (fixup): Change unsigned to grub_uint16_t.
13207 (read_mft): Change unsigned long to grub_uint32_t.
13208 (read_attr): Likewise.
13209 (read_data): Likewise.
13210 (read_run_data): Likewise.
13211 (read_run_list): Likewise.
13212 (read_mft): Likewise.
13213
13214 * fs/ntfscomp.c: New file.
13215
13216 * include/grub/ntfs.h: New file.
13217
af680a87 132182007-12-16 Robert Millan <rmh@aybabtu.com>
13219
13220 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
13221 IDE disk check, since Linux is known to support 20 IDE disks.
13222 Reported by Colin Watson.
13223
84be7599 132242007-12-15 Bean <bean123ch@gmail.com>
13225
13226 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
13227 (lnxboot_img_SOURCES): New variable.
13228 (lnxboot_img_ASFLAGS): Likewise.
13229 (lnxboot_img_LDFLAGS): Likewise.
13230
13231 * boot/i386/pc/lnxboot.S: New file.
13232
6af9db01 132332007-11-24 Pavel Roskin <proski@gnu.org>
13234
13235 * configure.ac: Test if '--build-id=none' is supported by the
13236 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
13237 objcopy to generate incorrect binary files (binutils
13238 2.17.50.0.18-1 as shipped by Fedora 8).
13239 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
13240 linking, so that build ID doesn't break the test.
13241
7361cfe6 132422007-11-24 Pavel Roskin <proski@gnu.org>
13243
13244 * include/grub/i386/time.h: use "void" in the argument list
13245 of grub_cpu_idle().
13246 * include/grub/powerpc/time.h: Likewise.
13247 * include/grub/sparc64/time.h: Likewise.
13248
1593e10c 132492007-11-18 Christian Franke <franke@computer.org>
13250
13251 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
13252 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
13253 This fixes the problem that function keys did not work in grub-emu.
13254
3b8db1a8 132552007-11-18 Christian Franke <franke@computer.org>
13256
13257 * disk/host.c (grub_host_open): Remove attribute unused from
13258 name parameter. Add check for "host". This fixes the problem
13259 that grub-emu does not find partitions.
13260
2e29408d 132612007-11-18 Christian Franke <franke@computer.org>
13262
13263 * util/hostfs.c (is_dir): New function.
13264 (grub_hostfs_dir): Handle missing dirent.d_type case.
13265 (grub_hostfs_read): Add missing fseek().
13266 (grub_hostfs_label): Clear label pointer. This fixes a crash
13267 of grub-emu on "ls (host)".
13268
398cd047 132692007-11-18 Christian Franke <franke@computer.org>
13270
13271 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
13272 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
13273 to 64 bit boundary by default.
13274
c405c391 132752007-11-18 Bean <bean123ch@gmail.com>
13276
13277 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
13278 (hexdump_mod_SOURCES): New variable.
13279 (hexdump_mod_CFLAGS): Likewise.
13280 (hexdump_mod_LDFLAGS): Likewise.
f19dbdb7 13281
c405c391 13282 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13283
13284 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13285
13286 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13287
13288 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13289
13290 * include/grub/hexdump.h: New file.
13291
13292 * commands/hexdump.c: New file.
13293
5cced7fd 132942007-11-10 Robert Millan <rmh@aybabtu.com>
13295
13296 * commands/i386/pc/play.c (beep_off): Switch order of arguments
13297 in grub_outb() calls.
13298 (beep_on): Likewise.
13299
8b714eb0 133002007-11-10 Christian Franke <franke@computer.org>
13301
13302 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
13303 (grub_menu_run): Likewise.
13304
ce0f1839 133052007-11-10 Robert Millan <rmh@aybabtu.com>
13306
13307 * include/grub/i386/efi/machine.h: New file.
13308 * include/grub/i386/linuxbios/machine.h: Likewise.
13309 * include/grub/i386/pc/machine.h: Likewise.
13310 * include/grub/powerpc/ieee1275/machine.h: Likewise.
13311 * include/grub/sparc64/ieee1275/machine.h: Likewise.
13312
13313 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
13314 (serial_hw_io_addr): New variable.
13315 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
13316 instead of `(unsigned short *) 0x400'.
13317
270c237d 133182007-11-10 Bean <bean123ch@gmail.com>
13319
13320 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
13321
a87783bf 133222007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13323
13324 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
13325 (vga_mod_SOURCES): Added.
13326 (vga_mod_CFLAGS): Likewise.
13327 (vga_mod_LDFLAGS): Likewise.
13328
13329 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
13330 grub_outb() calls.
13331 (set_map_mask): Likewise.
13332 (set_read_map): Likewise.
13333 (set_read_address): Likewise.
13334 (vga_font): Removed variable.
13335 (get_vga_glyph): Removed function.
13336 (invalidate_char): Likewise.
13337 (write_char): Changed to use grub_font_get_glyph() for font
13338 information.
13339 (grub_vga_putchar): Likewise.
13340 (grub_vga_getcharwidth): Likewise.
13341
6433b448 133422007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13343
13344 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
13345 flags.
13346 (pxeboot_img_LDFLAGS): Likewise.
13347 (diskboot_img_LDFLAGS): Likewise.
13348 (kernel_img_LDFLAGS): Likewise.
13349
49178511 133502007-11-06 Robert Millan <rmh@aybabtu.com>
13351
13352 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
13353 in grub_outb() calls.
13354 (serial_hw_init): Likewise.
13355
53b052de 133562007-11-05 Robert Millan <rmh@aybabtu.com>
13357
13358 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
13359 spaces. Skip non-regular files.
13360
5ab33bba 133612007-11-05 Robert Millan <rmh@aybabtu.com>
13362
13363 * kern/disk.c (grub_disk_firmware_fini)
13364 (grub_disk_firmware_is_tainted): New variables.
13365
13366 * include/grub/disk.h (grub_disk_firmware_fini)
13367 (grub_disk_firmware_is_tainted): Likewise.
13368
13369 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
13370 (grub_disk_biosdisk_fini): ... to here.
13371 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
13372 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
13373 is set. Register grub_disk_biosdisk_fini() in
13374 `grub_disk_firmware_fini'.
13375
13376 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
13377 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
13378 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
13379 to finish existing firmware disk interface.
13380
13381 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
13382 (ata_mod_SOURCES): New variable.
13383 (ata_mod_CFLAGS): Likewise.
13384 (ata_mod_LDFLAGS): Likewise.
13385
0149ab7c 133862007-11-05 Robert Millan <rmh@aybabtu.com>
13387
13388 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
13389 (grub_ata_wait): Reimplement using grub_millisleep().
13390
13391 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
13392 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
13393
be7ac41e 133942007-11-03 Marco Gerards <marco@gnu.org>
13395
13396 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
13397 (CRTC_ADDR_PORT): New macro.
13398 (CRTC_DATA_PORT): Likewise.
13399 (CRTC_CURSOR): Likewise.
13400 (CRTC_CURSOR_ADDR_HIGH): Likewise.
13401 (CRTC_CURSOR_ADDR_LOW): Likewise.
13402 (update_cursor): New function.
13403 (grub_console_real_putchar): Call `update_cursor'.
13404 (grub_console_gotoxy): Likewise.
13405 (grub_console_cls): Set the default color when clearing the
13406 screen.
13407 (grub_console_setcursor): Implemented.
13408
bb06ab2e 134092007-11-03 Marco Gerards <marco@gnu.org>
13410
13411 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
13412 become activate.
13413 (grub_ata_pio_write): Likewise.
13414
13415 (grub_atapi_identify): Wait after issuing an ATA command.
13416 (grub_atapi_packet): Likewise.
13417 (grub_ata_identify): Likewise.
13418 (grub_ata_readwrite): Likewise.
13419
cf8f780b 134202007-11-03 Marco Gerards <marco@gnu.org>
13421
13422 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
13423 (grub_ata_pio_write): Likewise.
13424 (grub_ata_readwrite): Use `grub_error', instead of
13425 returning `grub_errno'.
13426
ed649e54 134272007-11-03 Marco Gerards <marco@gnu.org>
13428
13429 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
13430 grub_ata_pio_write once for every single sector, instead of for
13431 multiple sectors.
13432
ca25d8f0 134332007-10-31 Robert Millan <rmh@aybabtu.com>
13434
13435 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
13436
13437 * conf/i386-linuxbios.rmk: New file.
13438
13439 * kern/i386/pc/hardware.c: Likewise.
13440 * term/i386/pc/at_keyboard.c: Likewise.
13441 * term/i386/pc/vga_text.c: Likewise.
13442
13443 * include/grub/i386/linuxbios/boot.h: Likewise.
13444 * include/grub/i386/linuxbios/console.h: Likewise.
13445 * include/grub/i386/linuxbios/init.h: Likewise.
13446 * include/grub/i386/linuxbios/kernel.h: Likewise.
13447 * include/grub/i386/linuxbios/loader.h: Likewise.
13448 * include/grub/i386/linuxbios/memory.h: Likewise.
13449 * include/grub/i386/linuxbios/serial.h: Likewise.
13450 * include/grub/i386/linuxbios/time.h: Likewise.
13451
13452 * kern/i386/linuxbios/init.c: Likewise.
13453 * kern/i386/linuxbios/startup.S: Likewise.
13454 * kern/i386/linuxbios/table.c: Likewise.
13455
e911ecc1 134562007-10-31 Marco Gerards <marco@gnu.org>
13457
13458 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
13459 (ata_mod_SOURCES): New variable.
13460 (ata_mod_CFLAGS): Likewise.
13461 (ata_mod_LDFLAGS): Likewise.
13462
13463 * disk/ata.c: New file.
13464
13465 * include/grub/disk.h (grub_disk_dev_id): Add
13466 `GRUB_DISK_DEV_ATA_ID'.
f19dbdb7 13467
7f66d0e0 134682007-10-31 Robert Millan <rmh@aybabtu.com>
13469
13470 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
13471 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
13472
13473 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
13474 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
13475
13476 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
13477 `<grub/types.h>'.
13478
13479 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
13480
5cd7dd46 134812007-10-27 Robert Millan <rmh@aybabtu.com>
13482
3236ca65 13483 * include/grub/types.h (ULONG_MAX): Define macro.
5cd7dd46 13484
2ebfc90f 134852007-10-22 Robert Millan <rmh@aybabtu.com>
13486
13487 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
13488 `"../realmode.S"'.
13489 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
13490
73fcb0f3 134912007-10-22 Robert Millan <rmh@aybabtu.com>
13492
13493 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
13494 (pkgdata_MODULES): Add `biosdisk.mod'.
13495 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
13496 variables.
13497
13498 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
13499 (grub_biosdisk_init): Replace with ...
13500 (GRUB_MOD_INIT(biosdisk)): ... this.
13501 (grub_biosdisk_fini): Replace with ...
13502 (GRUB_MOD_FINI(biosdisk)): ... this.
13503
13504 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
13505 (grub_machine_init): Remove call to grub_biosdisk_init().
13506 (grub_machine_fini): Remove call to grub_machine_fini().
13507
13508 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
13509
3381d274 135102007-10-22 Robert Millan <rmh@aybabtu.com>
13511
13512 * include/grub/time.h: New file.
13513 * include/grub/i386/time.h: Likewise.
13514 * include/grub/powerpc/time.h: Likewise.
13515 * include/grub/sparc64/time.h: Likewise.
13516
13517 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
13518 instances to ...
13519 (KERNEL_MACHINE_TIME_HEADER): ... this.
13520 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13521 instances to ...
13522 (KERNEL_MACHINE_TIME_HEADER): ... this.
13523 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13524 instances to ...
13525 (KERNEL_MACHINE_TIME_HEADER): ... this.
13526
13527 * kern/i386/efi/init.c: Include `<grub/time.h>'.
13528 (grub_millisleep): New function.
13529 * kern/i386/pc/init.c: Include `<grub/time.h>'.
13530 (grub_millisleep): New function.
13531 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
13532 Remove `grub/machine/time.h' include.
13533 (grub_millisleep): New function.
13534 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
13535 Remove `grub/machine/time.h' include.
13536 (grub_millisleep): New function.
13537
13538 * include/grub/misc.h (grub_div_roundup): New function.
13539
13540 * kern/misc.c: Include `<grub/time.h>'.
13541 (grub_millisleep_generic): New function.
13542
13543 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
13544 Add `time.h'.
13545 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
13546 Add `time.h'.
13547 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
13548 `machine/time.h'. Add `time.h'.
13549 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
13550
a39a0312 135512007-10-21 Robert Millan <rmh@aybabtu.com>
13552
13553 * include/grub/misc.h (grub_max): New function.
13554
2aad70e2 135552007-10-21 Robert Millan <rmh@aybabtu.com>
13556
13557 * util/misc.c (grub_util_info): Call fflush() before returning.
13558
54b71c4b 135592007-10-20 Robert Millan <rmh@aybabtu.com>
13560
13561 * genmk.rb (Image): Copy `extra_flags' from here ...
13562 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
13563
13564 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
13565 to `argc' and `args' arguments.
13566
a979f513 135672007-10-17 Robert Millan <rmh@aybabtu.com>
13568
13569 * kern/i386/loader.S: New file.
13570
13571 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
13572 * kern/i386/loader.S (grub_linux_prot_size)... to here.
13573 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
13574 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
13575 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
13576 * kern/i386/loader.S (grub_linux_real_addr)... to here.
13577 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
13578 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
13579 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
13580 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
13581 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
13582 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
13583 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
13584 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
13585
13586 * kern/i386/realmode.S: New file.
13587
13588 * kern/i386/pc/startup.S (protstack): Moved from here ...
13589 * kern/i386/realmode.S (protstack)... to here.
13590 * kern/i386/pc/startup.S (gdt): Moved from here ...
13591 * kern/i386/realmode.S (gdt)... to here.
13592 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
13593 * kern/i386/realmode.S (prot_to_real)... to here.
13594
13595 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
13596 `kern/i386/realmode.S'.
13597
825fc8fd 135982007-10-17 Robert Millan <rmh@aybabtu.com>
13599
13600 * include/grub/i386/loader.h: New file.
13601
13602 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
13603 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13604 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13605 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13606 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
13607 * include/grub/i386/loader.h (grub_linux_prot_size)
13608 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13609 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13610 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13611 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
13612
13613 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
13614
e179b2f4 136152007-10-15 Robert Millan <rmh@aybabtu.com>
13616
13617 * normal/misc.c (grub_normal_print_device_info): Do not probe for
13618 filesystem when dev->disk is unset.
13619 Do probe for filesystem even when dev->disk->has_partitions is set.
13620 In case a filesystem is found, always report it.
13621 In case it isn't, if dev->disk->has_partitions is set, report that
13622 a partition table was found instead of reporting that no filesystem
13623 could be identified.
13624
5db82af6 136252007-10-12 Robert Millan <rmh@aybabtu.com>
13626
13627 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
13628 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
13629
68f6ac74 13630 * include/grub/types.h (grub_host_to_target16): New macro.
13631 (grub_host_to_target32): Likewise.
13632 (grub_host_to_target64): Likewise.
13633 (grub_target_to_host16): Likewise.
13634 (grub_target_to_host32): Likewise.
13635 (grub_target_to_host64): Likewise.
5db82af6 13636
13637 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
13638 Renamed from to ...
13639 (GRUB_MOD_ALIGN): ...this. Update all users.
13640
68f6ac74 13641 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
13642 grub_host_to_target32.
13643 Replace grub_be_to_cpu32 with grub_target_to_host32.
13644 (load_modules): Likewise.
13645 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
13646 Replace grub_be_to_cpu32 with grub_target_to_host32.
13647 Replace grub_cpu_to_be16 with grub_host_to_target16.
13648 Replace grub_cpu_to_be32 grub_host_to_target32.
5db82af6 13649
3cf497cc 136502007-10-12 Robert Millan <rmh@aybabtu.com>
13651
13652 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
13653 * util/elf/grub-mkimage.c: ... here.
13654
13655 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
13656 `util/powerpc/ieee1275/grub-mkimage.c'.
13657
c8cc3692 136582007-10-07 Robert Millan <rmh@aybabtu.com>
adbc4c9d 13659
c8cc3692 13660 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
13661 and make it easier to figure out.
13662 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
13663 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
13664 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
13665 leave us with less than HEAP_MIN_SIZE total heap.
13666 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
adbc4c9d 13667
5c58b791 136682007-10-03 Robert Millan <rmh@aybabtu.com>
13669
13670 * include/grub/i386/io.h: New file.
13671 * commands/i386/pc/play.c (inb): Removed.
13672 (outb): Removed.
13673 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13674 with grub_outb().
afcd2ef8 13675 * term/i386/pc/serial.c (inb): Removed.
13676 (outb): Removed.
13677 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13678 with grub_outb().
13679 * term/i386/pc/vga.c (inb): Removed.
13680 (outb): Removed.
13681 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13682 with grub_outb().
5c58b791 13683
1a477ed6 136842007-10-02 Robert Millan <rmh@aybabtu.com>
13685
13686 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
13687 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13688 Reported by Marcin Kurek.
13689
6b5d80fa 136902007-09-07 Robert Millan <rmh@aybabtu.com>
13691
13692 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
13693 SmartFirmware version updates (as released by Sven Luther), and avoid
13694 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
13695 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
13696 known broken.
13697
5618afbf 136982007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13699
13700 From Hitoshi Ozeki:
13701 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
13702 when merging two regions.
13703
6139dcd9 137042007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13705
508e39ee 13706 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
13707 * normal/completion.c (grub_normal_do_completion): Likewise.
13708 Reported by Hitoshi Ozeki.
13709
137102007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 13711
6139dcd9 13712 Do not use devices at boot in chainloading.
f19dbdb7 13713
6139dcd9 13714 * loader/i386/pc/chainloader.c (boot_drive): New variable.
13715 (boot_part_addr): Likewise.
13716 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
13717 with BOOT_DRIVE and BOOT_PART_ADDR.
13718 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
13719 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
13720
38da6516 137212007-08-29 Robert Millan <rmh@aybabtu.com>
13722
13723 Patch from Simon Peter <dn.tlp@gmx.net>:
13724 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
13725 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
13726 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
13727 util/i386/pc/grub-setup.c_DEPENDENCIES.
13728 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
13729 util/grub-probe.c_DEPENDENCIES.
13730 * conf/powerpc-ieee1275.rmk: Likewise.
13731
29d0928c 137322007-08-28 Robert Millan <rmh@aybabtu.com>
13733
13734 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
13735 to tell grub-mkdevicemap how to name devices.
13736 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
13737 feature).
13738
13739 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
13740 util/i386/get_disk_name.c.
13741 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
13742 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
13743 util/ieee1275/get_disk_name.c.
13744
13745 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
13746
13747 * DISTLIST: Add util/i386/get_disk_name.c and
13748 util/ieee1275/get_disk_name.c.
13749
13750 * util/grub-mkdevicemap.c: Replace device naming logic with
13751 grub_util_get_disk_name() calls.
13752
5a0d3cca 137532007-08-20 Robert Millan <rmh@aybabtu.com>
13754
13755 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
13756 (so that it works for both plural and singular quantities).
13757
8b72db2f 137582007-08-05 Robert Millan <rmh@aybabtu.com>
13759
13760 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
13761 so that [xz] isn't taken into account when determining order.
13762
352466bf 137632007-08-02 Marco Gerards <marco@gnu.org>
13764
13765 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
13766 `include/multiboot2.h', `include/grub/elfload.h',
13767 `include/multiboot.h', `include/grub/multiboot.h',
13768 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
13769 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
13770 `kern/elf.c', `loader/multiboot_loader.c',
13771 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
13772 `loader/i386/pc/multiboot2.c',
13773 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
13774 `util/i386/pc/grub-mkrescue.in'. Remove
13775 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
13776 `include/grub/i386/pc/util/biosdisk.h' and
13777 `include/grub/powerpc/ieee1275/multiboot.h'.
13778
8f096014 137792007-08-02 Bean <bean123ch@gmail.com>
13780
13781 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
13782 (ntfs_mod_SOURCES): New variable.
13783 (ntfs_mod_CFLAGS): Likewise.
13784 (ntfs_mod_LDFLAGS): Likewise.
13785
13786 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
13787 (grub_probe_SOURCES): Likewise.
13788 (grub_emu_SOURCES): Likewise.
13789
13790 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13791 (grub_emu_SOURCES): Likewise.
13792
13793 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13794 (grub_emu_SOURCES): Likewise.
f19dbdb7 13795
8f096014 13796 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
13797
13798 * fs/ntfs.c: New file.
13799
9959f7db 138002007-08-02 Bean <bean123ch@gmail.com>
13801
13802 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
13803
13804 * file.h (grub_file): Likewise.
13805
13806 * fshelp.h (grub_fshelp_read_file): Likewise.
13807
13808 * util/i386/pc/grub-setup.c (setup): Likewise.
13809 (save_first_sector): Likewise.
13810 (save_blocklists): Likewise.
f19dbdb7 13811
9959f7db 13812 * fs/affs.c (grub_affs_read_file): Likewise.
13813
13814 * fs/ext2.c (grub_ext2_read_file): Likewise.
13815
13816 * fs/fat.c (grub_fat_read_data): Likewise.
13817
13818 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
13819
13820 * fs/hfs.c (grub_hfs_read_file): Likewise.
13821
13822 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
13823
13824 * fs/jfs.c (grub_jfs_read_file): Likewise.
13825
13826 * fs/minix.c (grub_minix_read_file): Likewise.
13827
13828 * fs/sfs.c (grub_sfs_read_file): Likewise.
13829
13830 * fs/ufs.c (grub_ufs_read_file): Likewise.
f19dbdb7 13831
9959f7db 13832 * fs/xfs.c (grub_xfs_read_file): Likewise.
13833
13834 * command/blocklist.c (read_blocklist): Likewise.
13835 (print_blocklist): Likewise.
13836
0a203f83 138372007-08-02 Marco Gerards <marco@gnu.org>
13838
13839 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
13840 `util/hostfs.c'.
13841
13842 * disk/host.c: New file.
13843
13844 * util/hostfs.c: Likewise.
13845
13846 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
13847 return `GRUB_ERR_BAD_FS'.
13848 * fs/sfs.c (grub_sfs_mount): Likewise.
13849 * fs/xfs.c (grub_xfs_mount): Likewise.
13850
13851 * include/grub/disk.h (enum grub_disk_dev_id): Add
13852 `GRUB_DISK_DEVICE_HOST_ID'.
13853
13854 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
13855
e5dfe777 138562007-07-24 Jerone Young <jerone@gmail.com>
13857
f19dbdb7 13858 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
e5dfe777 13859 modules for compilation.
13860 * conf/powerpc-ieee1275.rmk: Likewise.
13861
13862 * include/multiboot.h: Move multiboot definitions to one file. Rename
13863 many definitions to not get grub specific.
13864 * include/multiboot2.h: Create header with multiboot 2 definitions.
13865 * include/grub/multiboot.h: Header for grub specific function
13866 prototypes and definitions.
13867 * include/grub/multiboot2.h: Likewise.
13868 * include/grub/multiboot_loader.h: Likewise.
13869 * include/grub/i386/pc/multiboot.h: Removed.
13870 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
13871
13872 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
13873 and 2 to allow for one multiboot and module commands.
13874 * loader/multiboot2.c: Add multiboot2 functionality.
13875 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
13876 and definition names.
13877 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
13878 2 functions.
13879 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
13880 ieee1275 specific multiboot2 code.
13881
13882 * kern/i386/pc/startup.S: Change headers and definition names for
13883 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
13884
daf0f0ba 138852007-07-22 Robert Millan <rmh@aybabtu.com>
13886
13887 * geninitheader.sh: Process file specified in first parameter rather
13888 than hardcoding grub_modules_init.lst.
fe6b695a 13889 * geninit.sh: Likewise. Also, construct header name dynamically rather
daf0f0ba 13890 than hardcoding grub_modules_init.h.
13891
13892 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
13893 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
13894 grub_probe_init.[ch] and grub_setup_init.[ch].
13895
13896 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
13897 grub_modules_init.h with grub_emu_init.h.
13898 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
13899 grub_probe_init.[ch] files.
13900 * conf/i386-efi.rmk: Likewise.
13901 * conf/i386-pc.rmk: Likewise.
13902 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
13903 grub_setup_init.[ch] files.
13904
13905 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
13906 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
13907 to initialize modules rather than a list of hardcoded functions.
13908 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
13909 grub_init_all() to initialize modules rather than a list of hardcoded
13910 functions.
13911
54cdc1cc 139122007-07-22 Robert Millan <rmh@aybabtu.com>
13913
13914 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
13915 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
13916
ad0686cc 139172007-07-22 Robert Millan <rmh@aybabtu.com>
13918
13919 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
13920 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
13921 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
13922 flag when running on SmartFirmware.
13923 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
13924 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
13925 was set.
13926
13927 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
13928 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
13929 rather than decreasing it.
13930
13931 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
13932 there's not enough space to do it, fail in the same way as when it
13933 can't be done because there are no partitions.
13934
13935 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
13936 when nvsetenv failed.
13937
969c02ec 139382007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13939
13940 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
13941 because this rule is automatically generated.
13942 (grub-mkrescue): Removed for the same reason as above.
13943
5a79f472 139442007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13945
13946 Migrate to GNU General Public License Version 3.
f19dbdb7 13947
5a79f472 13948 * COPYING: Replaced with the plain text version of GPLv3.
13949
13950 * config.guess: Updated from gnulib.
13951 * config.sub: Likewise.
13952
13953 * geninit.sh: Output a GPLv3 copyright notice.
13954 * geninitheader.sh: Likewise.
13955 * genmodsrc.sh: Likewise.
13956 * gensymlist.sh.in: Likewise.
13957
13958 * boot/i386/pc/boot.S: Upgraded to GPLv3.
13959 * boot/i386/pc/diskboot.S: Likewise.
13960 * boot/i386/pc/pxeboot.S: Likewise.
13961 * commands/blocklist.c: Likewise.
13962 * commands/boot.c: Likewise.
13963 * commands/cat.c: Likewise.
13964 * commands/cmp.c: Likewise.
13965 * commands/configfile.c: Likewise.
13966 * commands/echo.c: Likewise.
13967 * commands/help.c: Likewise.
13968 * commands/ls.c: Likewise.
13969 * commands/search.c: Likewise.
13970 * commands/terminal.c: Likewise.
13971 * commands/test.c: Likewise.
13972 * commands/videotest.c: Likewise.
13973 * commands/i386/cpuid.c: Likewise.
13974 * commands/i386/pc/halt.c: Likewise.
13975 * commands/i386/pc/play.c: Likewise.
13976 * commands/i386/pc/reboot.c: Likewise.
13977 * commands/i386/pc/vbeinfo.c: Likewise.
13978 * commands/i386/pc/vbetest.c: Likewise.
13979 * commands/ieee1275/halt.c: Likewise.
13980 * commands/ieee1275/reboot.c: Likewise.
13981 * commands/ieee1275/suspend.c: Likewise.
13982 * disk/loopback.c: Likewise.
13983 * disk/lvm.c: Likewise.
13984 * disk/raid.c: Likewise.
13985 * disk/efi/efidisk.c: Likewise.
13986 * disk/i386/pc/biosdisk.c: Likewise.
13987 * disk/ieee1275/ofdisk.c: Likewise.
13988 * font/manager.c: Likewise.
13989 * fs/affs.c: Likewise.
13990 * fs/ext2.c: Likewise.
13991 * fs/fat.c: Likewise.
13992 * fs/fshelp.c: Likewise.
13993 * fs/hfs.c: Likewise.
13994 * fs/hfsplus.c: Likewise.
13995 * fs/iso9660.c: Likewise.
13996 * fs/jfs.c: Likewise.
13997 * fs/minix.c: Likewise.
13998 * fs/sfs.c: Likewise.
13999 * fs/ufs.c: Likewise.
14000 * fs/xfs.c: Likewise.
14001 * hello/hello.c: Likewise.
14002 * include/grub/acorn_filecore.h: Likewise.
14003 * include/grub/arg.h: Likewise.
14004 * include/grub/bitmap.h: Likewise.
14005 * include/grub/boot.h: Likewise.
14006 * include/grub/cache.h: Likewise.
14007 * include/grub/device.h: Likewise.
14008 * include/grub/disk.h: Likewise.
14009 * include/grub/dl.h: Likewise.
14010 * include/grub/elfload.h: Likewise.
14011 * include/grub/env.h: Likewise.
14012 * include/grub/err.h: Likewise.
14013 * include/grub/file.h: Likewise.
14014 * include/grub/font.h: Likewise.
14015 * include/grub/fs.h: Likewise.
14016 * include/grub/fshelp.h: Likewise.
14017 * include/grub/gzio.h: Likewise.
14018 * include/grub/hfs.h: Likewise.
14019 * include/grub/kernel.h: Likewise.
14020 * include/grub/loader.h: Likewise.
14021 * include/grub/lvm.h: Likewise.
14022 * include/grub/misc.h: Likewise.
14023 * include/grub/mm.h: Likewise.
14024 * include/grub/net.h: Likewise.
14025 * include/grub/normal.h: Likewise.
14026 * include/grub/parser.h: Likewise.
14027 * include/grub/partition.h: Likewise.
14028 * include/grub/pc_partition.h: Likewise.
14029 * include/grub/raid.h: Likewise.
14030 * include/grub/rescue.h: Likewise.
14031 * include/grub/script.h: Likewise.
14032 * include/grub/setjmp.h: Likewise.
14033 * include/grub/symbol.h: Likewise.
14034 * include/grub/term.h: Likewise.
14035 * include/grub/terminfo.h: Likewise.
14036 * include/grub/tparm.h: Likewise.
14037 * include/grub/types.h: Likewise.
14038 * include/grub/video.h: Likewise.
14039 * include/grub/efi/api.h: Likewise.
14040 * include/grub/efi/chainloader.h: Likewise.
14041 * include/grub/efi/console.h: Likewise.
14042 * include/grub/efi/console_control.h: Likewise.
14043 * include/grub/efi/disk.h: Likewise.
14044 * include/grub/efi/efi.h: Likewise.
14045 * include/grub/efi/pe32.h: Likewise.
14046 * include/grub/efi/time.h: Likewise.
14047 * include/grub/i386/linux.h: Likewise.
14048 * include/grub/i386/setjmp.h: Likewise.
14049 * include/grub/i386/types.h: Likewise.
14050 * include/grub/i386/efi/kernel.h: Likewise.
14051 * include/grub/i386/efi/loader.h: Likewise.
14052 * include/grub/i386/efi/time.h: Likewise.
14053 * include/grub/i386/pc/biosdisk.h: Likewise.
14054 * include/grub/i386/pc/boot.h: Likewise.
14055 * include/grub/i386/pc/chainloader.h: Likewise.
14056 * include/grub/i386/pc/console.h: Likewise.
14057 * include/grub/i386/pc/init.h: Likewise.
14058 * include/grub/i386/pc/kernel.h: Likewise.
14059 * include/grub/i386/pc/loader.h: Likewise.
14060 * include/grub/i386/pc/memory.h: Likewise.
14061 * include/grub/i386/pc/multiboot.h: Likewise.
14062 * include/grub/i386/pc/serial.h: Likewise.
14063 * include/grub/i386/pc/time.h: Likewise.
14064 * include/grub/i386/pc/vbe.h: Likewise.
14065 * include/grub/i386/pc/vbeblit.h: Likewise.
14066 * include/grub/i386/pc/vbefill.h: Likewise.
14067 * include/grub/i386/pc/vbeutil.h: Likewise.
14068 * include/grub/i386/pc/vga.h: Likewise.
14069 * include/grub/ieee1275/ieee1275.h: Likewise.
14070 * include/grub/ieee1275/ofdisk.h: Likewise.
14071 * include/grub/powerpc/libgcc.h: Likewise.
14072 * include/grub/powerpc/setjmp.h: Likewise.
14073 * include/grub/powerpc/types.h: Likewise.
14074 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
14075 * include/grub/powerpc/ieee1275/console.h: Likewise.
14076 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
14077 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
14078 * include/grub/powerpc/ieee1275/loader.h: Likewise.
14079 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
14080 * include/grub/powerpc/ieee1275/time.h: Likewise.
14081 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
14082 * include/grub/sparc64/libgcc.h: Likewise.
14083 * include/grub/sparc64/setjmp.h: Likewise.
14084 * include/grub/sparc64/types.h: Likewise.
14085 * include/grub/sparc64/ieee1275/console.h: Likewise.
14086 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
14087 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
14088 * include/grub/sparc64/ieee1275/time.h: Likewise.
14089 * include/grub/util/biosdisk.h: Likewise.
14090 * include/grub/util/getroot.h: Likewise.
14091 * include/grub/util/lvm.h: Likewise.
14092 * include/grub/util/misc.h: Likewise.
14093 * include/grub/util/raid.h: Likewise.
14094 * include/grub/util/resolve.h: Likewise.
14095 * io/gzio.c: Likewise.
14096 * kern/device.c: Likewise.
14097 * kern/disk.c: Likewise.
14098 * kern/dl.c: Likewise.
14099 * kern/elf.c: Likewise.
14100 * kern/env.c: Likewise.
14101 * kern/err.c: Likewise.
14102 * kern/file.c: Likewise.
14103 * kern/fs.c: Likewise.
14104 * kern/loader.c: Likewise.
14105 * kern/main.c: Likewise.
14106 * kern/misc.c: Likewise.
14107 * kern/mm.c: Likewise.
14108 * kern/parser.c: Likewise.
14109 * kern/partition.c: Likewise.
14110 * kern/rescue.c: Likewise.
14111 * kern/term.c: Likewise.
14112 * kern/efi/efi.c: Likewise.
14113 * kern/efi/init.c: Likewise.
14114 * kern/efi/mm.c: Likewise.
14115 * kern/i386/dl.c: Likewise.
14116 * kern/i386/efi/init.c: Likewise.
14117 * kern/i386/efi/startup.S: Likewise.
14118 * kern/i386/pc/init.c: Likewise.
14119 * kern/i386/pc/lzo1x.S: Likewise.
14120 * kern/i386/pc/startup.S: Likewise.
14121 * kern/ieee1275/ieee1275.c: Likewise.
14122 * kern/powerpc/cache.S: Likewise.
14123 * kern/powerpc/dl.c: Likewise.
14124 * kern/powerpc/ieee1275/cmain.c: Likewise.
14125 * kern/powerpc/ieee1275/crt0.S: Likewise.
14126 * kern/powerpc/ieee1275/init.c: Likewise.
14127 * kern/powerpc/ieee1275/openfw.c: Likewise.
14128 * kern/sparc64/cache.S: Likewise.
14129 * kern/sparc64/dl.c: Likewise.
14130 * kern/sparc64/ieee1275/init.c: Likewise.
14131 * kern/sparc64/ieee1275/openfw.c: Likewise.
14132 * loader/efi/chainloader.c: Likewise.
14133 * loader/efi/chainloader_normal.c: Likewise.
14134 * loader/i386/efi/linux.c: Likewise.
14135 * loader/i386/efi/linux_normal.c: Likewise.
14136 * loader/i386/pc/chainloader.c: Likewise.
14137 * loader/i386/pc/chainloader_normal.c: Likewise.
14138 * loader/i386/pc/linux.c: Likewise.
14139 * loader/i386/pc/linux_normal.c: Likewise.
14140 * loader/i386/pc/multiboot.c: Likewise.
14141 * loader/i386/pc/multiboot_normal.c: Likewise.
14142 * loader/powerpc/ieee1275/linux.c: Likewise.
14143 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
14144 * normal/arg.c: Likewise.
14145 * normal/cmdline.c: Likewise.
14146 * normal/command.c: Likewise.
14147 * normal/completion.c: Likewise.
14148 * normal/execute.c: Likewise.
14149 * normal/function.c: Likewise.
14150 * normal/lexer.c: Likewise.
14151 * normal/main.c: Likewise.
14152 * normal/menu.c: Likewise.
14153 * normal/menu_entry.c: Likewise.
14154 * normal/misc.c: Likewise.
14155 * normal/parser.y: Likewise.
14156 * normal/script.c: Likewise.
14157 * normal/i386/setjmp.S: Likewise.
14158 * normal/powerpc/setjmp.S: Likewise.
14159 * normal/sparc64/setjmp.S: Likewise.
14160 * partmap/acorn.c: Likewise.
14161 * partmap/amiga.c: Likewise.
14162 * partmap/apple.c: Likewise.
14163 * partmap/gpt.c: Likewise.
14164 * partmap/pc.c: Likewise.
14165 * partmap/sun.c: Likewise.
14166 * term/gfxterm.c: Likewise.
14167 * term/terminfo.c: Likewise.
14168 * term/efi/console.c: Likewise.
14169 * term/i386/pc/console.c: Likewise.
14170 * term/i386/pc/serial.c: Likewise.
14171 * term/i386/pc/vesafb.c: Likewise.
14172 * term/i386/pc/vga.c: Likewise.
14173 * term/ieee1275/ofconsole.c: Likewise.
14174 * util/biosdisk.c: Likewise.
14175 * util/console.c: Likewise.
14176 * util/genmoddep.c: Likewise.
14177 * util/getroot.c: Likewise.
14178 * util/grub-emu.c: Likewise.
14179 * util/grub-mkdevicemap.c: Likewise.
14180 * util/grub-probe.c: Likewise.
14181 * util/lvm.c: Likewise.
14182 * util/misc.c: Likewise.
14183 * util/raid.c: Likewise.
14184 * util/resolve.c: Likewise.
14185 * util/update-grub.in: Likewise.
14186 * util/update-grub_lib.in: Likewise.
14187 * util/grub.d/00_header.in: Likewise.
14188 * util/grub.d/10_hurd.in: Likewise.
14189 * util/grub.d/10_linux.in: Likewise.
14190 * util/i386/efi/grub-install.in: Likewise.
14191 * util/i386/efi/grub-mkimage.c: Likewise.
14192 * util/i386/pc/grub-install.in: Likewise.
14193 * util/i386/pc/grub-mkimage.c: Likewise.
14194 * util/i386/pc/grub-mkrescue.in: Likewise.
14195 * util/i386/pc/grub-setup.c: Likewise.
14196 * util/i386/pc/misc.c: Likewise.
14197 * util/powerpc/ieee1275/grub-install.in: Likewise.
14198 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
14199 * util/powerpc/ieee1275/misc.c: Likewise.
14200 * video/bitmap.c: Likewise.
14201 * video/video.c: Likewise.
14202 * video/i386/pc/vbe.c: Likewise.
14203 * video/i386/pc/vbeblit.c: Likewise.
14204 * video/i386/pc/vbefill.c: Likewise.
14205 * video/i386/pc/vbeutil.c: Likewise.
14206 * video/readers/tga.c: Likewise.
14207
3572d015 142082007-07-02 Robert Millan <rmh@aybabtu.com>
14209
14210 * conf/i386-efi.rmk: Replace obsolete reference to
14211 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
14212 with util/getroot.c.
14213 * conf/powerpc-ieee1275.rmk: Likewise.
14214 * conf/sparc64-ieee1275.rmk: Likewise.
14215
14216 * util/grub-emu.c (main): Fix unchecked pointer handling.
14217
2c2a681b 142182007-07-02 Robert Millan <rmh@aybabtu.com>
14219
14220 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
14221 invocation to fail, in order to support partition-less media.
14222
14223 * util/i386/pc/grub-install.in: Likewise.
14224
14225 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
14226 which fs or partmap modules are needed (akin to its sister scripts).
14227
14228 Also use grub-probe to get rid of unportable /proc/mounts check.
14229
14230 Print the same informational message that the other scripts do, before
fe6b695a 14231 exiting.
2c2a681b 14232
6193defe 142332007-06-23 Robert Millan <rmh@aybabtu.com>
14234
fe6b695a 14235 * util/update-grub_lib.in (font_path): New function. Determine whether
6193defe 14236 a font file can be found and, if so, echo the GRUB path to it.
14237
14238 * util/update-grub.in: Handle multiple terminals depending on user
14239 input, platform availability and font file presence. Propagate
14240 variables of our findings to /etc/grub.d/ children.
14241
14242 * util/grub.d/00_header.in: Handle multiple terminals, based on
14243 environment setup by update-grub.
14244
eface1dc 142452007-06-23 Robert Millan <rmh@aybabtu.com>
14246
ba50d28f 14247 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
eface1dc 14248
bf697e28 142492007-06-21 Robert Millan <rmh@aybabtu.com>
14250
14251 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
14252 indicate end of data section in kernel image.
14253 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
14254 GRUB_KERNEL_MACHINE_DATA_END.
14255
14256 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
14257 space for it.
14258 * kern/i386/efi/startup.S: Likewise.
14259
14260 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
14261 during image generation. Implement --prefix option to override this
14262 patch.
14263 * util/i386/efi/grub-mkimage.c: Likewise.
14264
14265 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
14266 code to make path relative to its root into a separate function.
14267
14268 * util/i386/pc/grub-install.in: Use newly provided
14269 make_system_path_relative_to_its_root() to convert ${grubdir}, then
14270 pass the result to grub-install --prefix.
14271
baa574b4 142722007-06-13 Robert Millan <rmh@aybabtu.com>
14273
14274 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
14275 DEFAULT_DEVICE_MAP.
14276 * util/grub-emu.c: Use above definitions from misc.h instead of
14277 defining them.
14278 * util/grub-mkdevicemap.c: Likewise.
14279 * util/i386/pc/grub-setup.c: Likewise.
14280 * util/grub-probe.c: Likewise.
14281 (probe): Abort with grub_util_error() when either
14282 grub_guess_root_device or grub_util_get_grub_dev fails.
14283
0215dcbf 142842007-06-12 Robert Millan <rmh@aybabtu.com>
14285
14286 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
14287 "pager" assignment.
14288 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
14289 "pcdata".
14290 * util/grub-probe.c (probe): Likewise for "drive_name".
14291
8af2ab7b 142922007-06-11 Robert Millan <rmh@aybabtu.com>
14293
14294 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
14295 not just the cdrom one.
14296
59d31694 142972007-06-11 Robert Millan <rmh@aybabtu.com>
14298
14299 * util/i386/pc/grub-mkrescue.in: Add "set -e".
14300 Add --pkglibdir=DIR option to override pkglibdir.
14301 Mention --image-type=TYPE in help output.
14302 Fix --grub-mkimage (it was a no-op).
fe6b695a 14303 Abort gracefully when no parameter is given.
59d31694 14304
7ee367e4 143052007-06-11 Robert Millan <rmh@aybabtu.com>
14306
14307 * util/i386/pc/grub-mkrescue.in: New file.
14308 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
14309 * Makefile.in: Handle bin_SCRIPTS.
14310
29b0ed46 143112007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
14312
14313 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
14314 list of video modes.
14315
c0f90770 143162007-06-06 Robert Millan <rmh@aybabtu.com>
14317
14318 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
14319 file doesn't exist, or if it is in a filesystem grub can't read.
14320
14321 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
14322 not abort if GRUB_DRIVE could not be defined. Rearrange generated
14323 header comment to fit in 80 columns when the variables are resolved.
14324
14325 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
14326 could be identified by update-grub. Remove redundant check for
fe6b695a 14327 unifont.pff existence (since convert_system_path_to_grub_path now
c0f90770 14328 handles that).
14329
fb36dc26 143302007-06-04 Robert Millan <rmh@aybabtu.com>
14331
14332 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
14333
14334 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
14335
14336 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
14337
0c68c93e 143382007-06-04 Robert Millan <rmh@aybabtu.com>
14339
14340 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
14341
14342 * include/grub/partition.h: Declare grub_apple_partition_map_init and
14343 grub_apple_partition_map_fini.
14344
14345 * util/biosdisk.c
14346 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
14347 to access >2 TiB disks).
14348
14349 Print disk->total_sectors with %llu instead of %lu, since this
14350 variable is always 64-bit (prevents wrong disk size from being displayed
14351 on either >2 TiB disk or big-endian CPU).
14352
14353 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
14354 into a generic case that supports all (sane) partition maps.
14355
14356 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
14357 breaks big-endian.
14358
14359 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
14360 and grub_apple_partition_map_fini() after that.
14361
0f23eb74 143622007-06-01 Robert Millan <rmh@aybabtu.com>
14363
14364 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
14365
14366 * util/grub.d/00_header.in: Only enable gfxterm when
14367 convert_system_path_to_grub_path() succeeds.
14368
42c71976 143692007-05-20 Robert Millan <rmh@aybabtu.com>
14370
14371 * util/update-grub_lib.in: New file.
14372 * DISTLIST: Add update-grub_lib.in.
14373 * conf/common.rmk: Generate update-grub_lib and install it in
14374 $(lib_DATA).
14375 * Makefile.in: Add install routine for $(lib_DATA).
14376
14377 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
14378 function provided by update-grub_lib to support arbitrary paths of
14379 unifont.pff.
14380 * util/update-grub.in: Use convert_system_path_to_grub_path() to
14381 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
14382
5beb2291 143832007-05-19 Robert Millan <rmh@aybabtu.com>
14384
14385 * commands/i386/cpuid.c: New module.
14386 * DISTLIST: Add it.
14387 * conf/i386-efi.rmk: Enable cpuid.mod.
14388 * conf/i386-pc.rmk: Likewise.
14389
7262eca1 143902007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14391
14392 * kern/disk.c (grub_disk_read): Check return value of
14393 grub_realloc().
14394
260ba823 143952007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14396
14397 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
14398 arrays.
14399 * disk/raid.c (grub_raid_open): Likewise.
14400
1ecb6cf2 144012007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14402
14403 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
14404 stack instead of on the heap.
14405
14406 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
14407 before doing a read on it.
14408
14409 * configure.ac: Only use -fno-stack-protector for the target
14410 environment.
f19dbdb7 14411
21c8cbb1 144122007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14413
14414 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
14415 __attribute_ ((unused)) to mode_type argument.
14416
14417 * util/getroot.c (grub_guess_root_device): Fix #endif.
f19dbdb7 14418
21c8cbb1 14419 * kern/misc.c (memcmp): Fix prototype.
14420
14421 * include/grub/partition.h [GRUB_UTIL]
14422 (grub_gpt_partition_map_init): Add prototype.
14423 (grub_gpt_partition_map_fini): Likewise.
14424
14425 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
14426 at the right place.
14427
14428 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
14429 (grub_fat_read_data): Likewise.
14430 (grub_fat_find_dir): Likewise.
14431
14432 * font/manager.c (find_glyph): Make table a const.
14433 (grub_font_get_glyph): Remove bitmap from if statement.
f19dbdb7 14434
849d55d3 144352007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
14436
14437 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
14438 code, first search for device in /dev/mapper, then in /dev.
14439 (grub_util_get_grub_dev): New function.
14440 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
14441 prototype.
14442 * util/grub-probe.c (probe): Remove check for RAID, call
14443 grub_util_get_grub_dev() instead of
14444 grub_util_biosdisk_get_grub_dev().
14445 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
14446 grub_util_biosdisk_get_grub_dev().
14447 * util/i386/pc/grub-setup.c (main): Likewise.
14448
8fff7c2f 144492007-05-16 Robert Millan <rmh@aybabtu.com>
14450
14451 * DISTLIST: Update for the latest changes.
14452 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
14453 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
14454 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
14455 grub/util/biosdisk.h.
14456 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
14457 grub/util/biosdisk.h.
14458
48e12b52 144592007-05-16 Robert Millan <rmh@aybabtu.com>
14460
14461 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
14462
46b9d128 144632007-05-16 Robert Millan <rmh@aybabtu.com>
14464
14465 * util/i386/efi/grub-install.in: New.
14466 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
14467 newly added grub-install.
14468 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
14469 include.
14470 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
14471 grub/util/biosdisk.h.
14472 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
14473 grub/util/biosdisk.h.
14474
2d1a40a9 144752007-05-16 Robert Millan <rmh@aybabtu.com>
14476
14477 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
14478 * include/grub/util/biosdisk.h: ... here.
14479 * util/i386/pc/biosdisk.c: Moved to ...
14480 * util/biosdisk.c: ... here.
14481 * util/i386/pc/getroot.c: Moved to ...
14482 * util/getroot.c: ... here.
14483 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
14484 * util/grub-mkdevicemap.c: ... here.
14485 * util/i386/pc/grub-probe.c: Moved to ...
14486 * util/grub-probe.c: ... here.
14487
9e26e3bc 144882007-05-15 Robert Millan <rmh@aybabtu.com>
14489
14490 * util/update-grub.in: Remove duplicated line in grub.cfg header
14491 message.
14492
57f96397 144932007-05-13 Robert Millan <rmh@aybabtu.com>
14494
14495 * util/update-grub.in: Fix a few assumptions about the devices holding
14496 /, /boot and /boot/grub being the same.
14497 * util/grub.d/00_header.in: Likewise.
14498 * util/grub.d/10_hurd.in: Likewise.
14499 * util/grub.d/10_linux.in: Likewise.
14500
14501 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
14502 patterns. Use that to define the `.old' suffix as older than `'.
14503
14504 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
14505
14506 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
14507 the grub.cfg header message.
14508
2e610d62 145092007-05-11 Robert Millan <rmh@aybabtu.com>
14510
14511 * util/update-grub.in: Create device.map if it doesn't already exist,
14512 before attempting to run grub-probe.
14513 Check for grub-probe and grub-mkdevicemap with the same code
14514 grub-install is using.
14515 Remove test mode.
14516
3f6a10ef 145172007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
14518
14519 * Makefile.in: Add the datarootdir autoconf variable.
14520
02e7b75e 145212007-05-09 Robert Millan <rmh@aybabtu.com>
14522
14523 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
f19dbdb7 14524 fail gracefully if dev->disk->partition == NULL.
02e7b75e 14525
75f396cc 145262007-05-07 Robert Millan <rmh@aybabtu.com>
14527
14528 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
14529 determine partition map module.
14530 * util/i386/pc/grub-install.in: Use this feature to decide which
14531 partition module to load, instead of hardcoding pc and gpt.
14532
da65cb36 145332007-05-07 Robert Millan <rmh@aybabtu.com>
14534
14535 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
14536 source directory differs from build directory.
14537
b57d6a91 145382007-05-05 Robert Millan <rmh@aybabtu.com>
14539
14540 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
14541 initialisation.
14542
509d00f1 145432007-05-05 Robert Millan <rmh@aybabtu.com>
14544
14545 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
14546
c48f23ef 145472007-05-05 Robert Millan <rmh@aybabtu.com>
14548
14549 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
14550 command-line arguments via ${GRUB_CMDLINE_LINUX}.
14551
20b97658 145522007-05-05 Robert Millan <rmh@aybabtu.com>
14553
14554 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
14555 (grub_probe_SOURCES): Likewise.
14556 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
14557 GPT and initialize dos_part and bsd_part accordingly.
14558 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
14559 install_bsd_part.
14560 (main): Activate gpt module for use during partition identification,
14561 and deactivate it afterwards.
14562 * util/i386/pc/grub-install.in: Add gpt module to core.img.
14563 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
14564 partition identification, and deactivate it afterwards.
14565
99123174 145662007-05-05 Robert Millan <rmh@aybabtu.com>
14567
14568 * term/i386/pc/console.c (grub_console_fini): Call
14569 grub_term_set_current() before grub_term_unregister().
14570
ebd97f6e 145712007-05-04 Robert Millan <rmh@aybabtu.com>
14572
14573 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
14574 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
14575 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
14576 and update-grub_DATA.
14577 * conf/common.rmk: Build and install update-grub components.
14578 * conf/common.mk: Regenerate.
14579 * util/update-grub.in: New. Core of update-grub.
14580 * util/grub.d/00_header.in: New. Generates grub.cfg header.
14581 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
14582 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
14583 * util/grub.d/README: New. Document grub.d directory layout.
14584
b06a264d 145852007-05-01 Robert Millan <rmh@aybabtu.com>
14586
14587 * util/grub-emu.c: Move initialization functions
14588 grub_util_biosdisk_init() and grub_init_all() before
14589 grub_util_biosdisk_get_grub_dev(), which relies on them.
14590
41f0050e 145912007-04-19 Robert Millan <rmh@aybabtu.com>
14592
14593 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
14594 it is used later.
14595
04582bb3 145962007-04-18 Jerone Young <jerone@gmail.com>
14597
f19dbdb7 14598 * kernel/elf.c: Add missing parenthesis for conditional statement
04582bb3 14599 stanza.
14600
08db4632 146012007-04-10 Jerone Young <jerone@gmail.com>
49892fdf 14602
08db4632 14603 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
14604 continue on and look for device node with real device name.
14605
801b76be 146062007-04-10 Jerone Young <jerone@gmail.com>
f19dbdb7 14607
fe6b695a 14608 * configure.ac: Add argument for autoconf to use transformation
1d543c3e 14609 ability.
14610 * Makefile.in: Add autoconf package transformation code.
14611 * util/i386/pc/grub-install.in: Likewise.
14612 * util/powerpc/ieee1275/grub-install.in: Likewise.
14613
6795c4e1 146142007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
14615
14616 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
14617 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
14618 (EXT2_REVISION): Likewise.
14619 (EXT2_INODE_SIZE): Likewise.
14620 (struct grub_ext2_block_group): Added a missing member
14621 "used_dirs".
14622 (grub_ext2_read_inode): Divide by the inode size in a superblock
14623 instead of 128 to obtain INODES_PER_BLOCK.
14624 Use the macro EXT2_INODE_SIZE instead of directly using
14625 SBLOCK->INODE_SIZE.
14626
d70af616 146272007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
14628
14629 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
14630 superblock instead of the structure size to compute an
14631 offset. This fixes the problem that GRUB could not read a
14632 filesystem when inode size is different from 128-byte.
14633
3b801603 146342007-03-05 Marco Gerards <marco@gnu.org>
14635
14636 * normal/main.c (read_config_file): When "menu" is not set, create
14637 an initial context.
14638
4785bfe4 146392007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14640
14641 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
14642 (HEAP_LIMIT): New macro.
14643 (grub_claim_heap): Claim memory up to `heaplimit'.
14644
a0cbb023 146452007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14646
14647 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
14648 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
14649 (_start): Likewise.
14650 (grub_arch_modules_addr): Return address after `_end'.
14651 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
14652 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
14653 (add_segments): Calculate `_end' from phdr size and location.
14654 (ALIGN_UP): Moved to ...
14655 * include/grub/misc.h: here.
14656 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
14657 New macro.
14658 (GRUB_IEEE1275_MODULE_BASE): Removed.
14659
fd7d8eba 146602007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14661
14662 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
14663 loop boundary.
14664
9b09e6fc 146652007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14666
14667 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
14668 All users updated.
14669 (grub_elf64_load_hook_t): Likewise.
14670 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
14671 debug output.
14672
3ce27299 146732007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14674
14675 * kern/mm.c: Update copyright.
14676 (grub_mm_debug): Correct syntax error.
14677 (grub_mm_dump_free): New function.
14678 (grub_debug_free): Call `grub_free'.
14679 * include/grub/mm.h: Update copyright.
14680 (grub_mm_dump_free): Add declaration.
14681
077d5fee 146822007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14683
14684 * include/grub/ieee1275/ieee1275.h: Update copyright.
14685 * kern/powerpc/ieee1275/init.c: Likewise.
14686 * kern/powerpc/ieee1275/openfw.c: Likewise.
14687
14688 * loader/powerpc/ieee1275/linux.c: Likewise.
14689 * include/grub/elfload.h: Likewise.
14690 * kern/elf.c: Likewise.
14691 (grub_elf32_load): Pass `base' and `size' parameters. Update all
14692 callers.
14693 (grub_elf64_load): Likewise.
14694 (grub_elf32_load_segment): Move to a nested function.
14695 (grub_elf64_load_segment): Likewise.
14696
dc946850 146972007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14698
14699 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
14700 prototype.
14701 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
14702 (grub_heap_len): Likewise.
14703 (HEAP_SIZE): New macro.
14704 (grub_claim_heap): New function.
14705 (grub_machine_init): Don't claim heap directly. Call
14706 `grub_claim_heap'.
14707 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
14708 (grub_available_iterate): New function.
14709
baa2a121 147102007-02-03 Thomas Schwinge <tschwinge@gnu.org>
14711
14712 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
14713 * configure.ac: Use it for testing the HOST and TARGET compilers.
14714
4fe9862e 147152006-12-13 Thomas Schwinge <tschwinge@gnu.org>
14716
14717 * Makefile.in (enable_grub_emu): New variable.
14718 * configure.ac (--enable-grub-emu): New option.
14719 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
14720 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
14721 * conf/i386-pc.rmk: Likewise.
14722 * conf/powerpc-ieee1275.rmk: Likewise.
14723 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
14724
a8aa5762 147252006-12-12 Marco Gerards <marco@gnu.org>
14726
14727 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
14728
14729 * kern/env.c (grub_env_unset): Don't free the member `value' when
14730 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
14731 pointer.
14732
14733 * normal/main.c (current_menu): Removed.
14734 (free_menu): Unset the `menu' environment variable.
14735 (grub_normal_menu_addentry): Make use of the environment variable
14736 `menu', instead of using the global `current_menu'. Allocate
14737 memory for the sourcecode of this entry.
14738 (read_config_file): New argument `nested', changed all callers.
14739 Only in the case of a new context, initialize a new menu. Set the
14740 `menu' environment variable.
14741 (grub_normal_execute): Don't set and unset the environment
14742 variable `menu' here anymore. Only free the menu when leaving the
14743 context.
14744
14745 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
14746 leak.
14747
957b3a3e 147482006-12-11 Marco Gerards <marco@gnu.org>
14749
14750 * normal/menu_entry.c (run): Fix off by one bug so the last line
14751 is executed. Move the loader check to outside the loop.
14752
ef875714 147532006-12-08 Hollis Blanchard <hollis@penguinppc.org>
14754
14755 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
14756
4e739985 147572006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
14758
14759 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
14760 the number of sectors. Reported by Andrey Shuvikov
14761 <mr_hyro@yahoo.com>.
f19dbdb7 14762
790707f2 147632006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
14764
14765 * kern/disk.c (grub_disk_read): When there is a read error, always
14766 try to read only the necessary data.
f19dbdb7 14767
790707f2 14768 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
14769 disk/raid.c.
14770 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
14771 prototype.
14772 [GRUB_UTIL] (grub_raid_fini): Likewise.
14773 [GRUB_UTIL] (grub_lvm_init): Likewise.
f19dbdb7 14774 [GRUB_UTIL] (grub_lvm_fini): Likewise.
790707f2 14775 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
14776 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
14777 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
14778 and grub_raid_fini().
f19dbdb7 14779
03e58196 147802006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
14781
14782 * include/grub/types.h (__unused): Rename to UNUSED.
14783 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
14784 (grub_elf64_size): Likewise.
f19dbdb7 14785
ae4f23bf 147862006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14787
14788 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
14789 grub_error_push and grub_error_pop in the error-handling path.
14790 (grub_elf32_load_segment): Only call grub_file_read with non-zero
14791 length.
14792
2166cc83 147932006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14794
14795 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
14796 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
14797 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
14798 (kernel_elf_SOURCES): Likewise.
14799 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
14800 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
14801 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14802 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14803 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
14804 (elf_mod_SOURCES): New variable.
14805 (elf_mod_CFLAGS): Likewise.
14806 (elf_mod_LDFLAGS): Likewise.
14807 * include/grub/types.h (__unused): New macro.
14808 * include/grub/elfload.h: New file.
14809 * kern/elf.c: Likewise.
14810 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
14811 (ELF32_LOADMASK): New macro.
14812 (ELF64_LOADMASK): Likewise.
14813 (vmlinux): Removed.
14814 (grub_linux_load32): New function.
14815 (grub_linux_load64): Likewise.
14816 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
14817 Use grub_elf_t instead of grub_file_t.
14818
a09d5aa5 148192006-11-02 Hollis Blanchard <hollis@penguinppc.org>
14820
14821 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
14822 `catch_result' to struct set_color_args.
14823
d976fc51 148242006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
14825
14826 * normal/menu.c: Include grub/script.h.
14827 * normal/menu_entry.c: Likewise.
14828 * include/grub/normal.h: Do not include grub/script.h.
14829
67507549 148302006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14831
14832 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
14833
69203a99 148342006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14835
14836 * kern/disk.c (grub_disk_open): Print debug messages when opening a
14837 disk.
14838 (grub_disk_close): Print debug messages when closing a disk.
14839 (grub_disk_read): Print debug messages when disk read fails.
14840 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
14841 filesystem type.
14842 * kern/partition.c: Include misc.h.
14843 (grub_partition_iterate): Print debug messages when detecting
14844 partition type.
14845
e2b8278c 148462006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14847
14848 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
14849 is negative.
14850 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
14851
97b2f2ff 148522006-10-26 Hollis Blanchard <hollis@penguinppc.org>
14853
14854 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
14855 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
14856
6555d655 148572006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
14858
14859 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
14860 instead of sizeof(lv). Patch by Michael Guntsche.
14861
4d42b77f 148622006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
14863
14864 * disk/lvm.c: Rename VGS to VG_LIST.
14865 (grub_lvm_iterate): Change VGS->LV to VG-LV.
14866 (grub_lvm_open): Likewise.
14867 Thanks to Michael Guntsche for finding this bug.
14868
5d74d927 148692006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14870
14871 * configure.ac (AC_INIT): Bumped to 1.95.
14872
a1bb27e4 148732006-10-14 Robert Millan <rmh@aybabtu.com>
14874
14875 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
14876 with "/dev/.static/dev/md".
14877
e0994b8b 148782006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14879
14880 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
14881 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
14882 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
14883 DRIVE_NAME are always freed.
14884
14885 * util/i386/pc/biosdisk.c (make_device_name): Add one into
14886 DOS_PART, as a DOS partition is counted from one instead of zero
14887 now. Reported by Robert Millan.
14888
ddd5cee9 148892006-10-14 Robert Millan <rmh@aybabtu.com>
14890
14891 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
14892 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
14893 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
14894 string returned by grub_guess_root_device.
14895 * util/i386/pc/grub-setup.c: Likewise.
14896 * util/i386/pc/grub-probefs.c: Likewise.
14897
14898 * util/i386/pc/grub-probefs.c: Rename to ...
14899 * util/i386/pc/grub-probe.c: ... this.
14900 * DISTLIST: Remove grub-probefs, add grub-probe.
14901 * conf/i386-efi.rmk: Likewise.
14902 * conf/i386-pc.rmk: Likewise.
14903 * util/i386/pc/grub-install.in: Likewise.
14904
14905 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
14906 choose which information we want to print.
14907
2b002173 149082006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14909
14910 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
14911 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
14912 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
14913 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
14914 video/readers/tga.c and video/i386/pc/vbeutil.c.
14915
149162006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
14917
14918 Added support for RAID and LVM.
f19dbdb7 14919
2b002173 14920 * disk/lvm.c: New file.
14921 * disk/raid.c: Likewise.
14922 * include/grub/lvm.h: Likewise.
f19dbdb7 14923 * include/grub/raid.h: Likewise.
2b002173 14924 * include/grub/util/lvm.h: Likewise.
14925 * include/grub/util/raid.h: Likewise.
14926 * util/lvm.c: Likewise.
14927 * util/raid.c: Likewise.
14928
14929 * include/grub/disk.h (grub_disk_dev_id): Add
14930 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
14931 (grub_disk_get_size): New prototype.
14932 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
14933 returns a partition.
14934 (grub_disk_get_size): New function.
f19dbdb7 14935
2b002173 14936 * kern/i386/pc/init.c (make_install_device): Copy the prefix
14937 verbatim if grub_install_dos_part is -2.
14938
14939 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
14940 and LVM devices.
14941
14942 * util/i386/pc/grub-setup.c (setup): New argument
14943 MUST_EMBED. Force embedding of GRUB when the argument is
14944 true. Close FILE before returning.
14945 (main): Add support for RAID and LVM.
f19dbdb7 14946
2b002173 14947 * conf/common.rmk: Add RAID and LVM modules.
14948 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
14949 util/lvm.c.
14950 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
14951
14952 * kern/misc.c (grub_strstr): New function.
14953 * include/grub/misc.h (grub_strstr): New prototype.
14954
050548d0 149552006-10-10 Tristan Gingold <tristan.gingold@bull.net>
14956
14957 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
14958
da849d2d 149592006-10-05 Tristan Gingold <tristan.gingold@bull.net>
14960
14961 * kern/misc.c (grub_strtoull): Guess the base only if not
14962 specified.
14963
97b2f2ff 149642006-10-01 Hollis Blanchard <hollis@penguinppc.org>
4f0acd39 14965
14966 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
14967 PowerMac support.
14968
97b2f2ff 149692006-10-01 Hollis Blanchard <hollis@penguinppc.org>
fba51f48 14970
14971 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
14972
14973 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
14974 Remove `flags' argument. All callers changed.
14975 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
14976 (IEEE1275_IHANDLE_INVALID): New variable.
14977 (IEEE1275_CELL_INVALID): New variable.
14978 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
14979 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
14980 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
14981 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
14982 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
14983 codes from Open Firmware. All callers updated.
14984 (grub_ieee1275_next_property): Directly return Open Firmware return
14985 code.
14986 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
14987 Standardize error checking from `grub_ieee1275_get_property'.
14988 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
14989 `devalias' to `aliases'. Correct comments. Consolidate error paths.
14990
97b2f2ff 149912006-10-01 Hollis Blanchard <hollis@penguinppc.org>
cc6d3df3 14992
14993 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
14994 `instance_to_package_args' to `instance_to_path_args'.
14995
14996 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
14997 `grub_ieee1275_chosen'.
14998
14999 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
15000 `grub_ieee1275_interpret'.
15001
97b2f2ff 150022006-09-25 Hollis Blanchard <hollis@penguinppc.org>
02bb8acc 15003
15004 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
15005
97b2f2ff 150062006-09-25 Hollis Blanchard <hollis@penguinppc.org>
663b72f0 15007
15008 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
15009 (__cmpdi): Likewise.
15010
15011 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
15012 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
15013 `grub_ssize_t'.
15014
02bb8acc 15015 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
663b72f0 15016
15017 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
15018 to type `grub_ssize_t'.
15019 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
15020
7f9a8531 150212006-09-22 Marco Gerards <marco@gnu.org>
15022
15023 * normal/script.c (grub_script_create_cmdmenu): Skip leading
15024 newlines.
15025
b5ef1102 150262006-09-22 Marco Gerards <marco@gnu.org>
15027
15028 * commands/echo.c: New file.
15029
15030 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
15031
15032 * conf/common.rmk (echo_mod_SOURCES): New variable.
15033 (echo_mod_CFLAGS): Likewise.
15034 (echo_mod_LDFLAGS): Likewise.
15035
2cff3677 150362006-09-22 Marco Gerards <marco@gnu.org>
15037
15038 * normal/main.c (get_line): Malloc memory instead of using
15039 preallocated memory. Removed the arguments `cmdline' and
15040 `max_len'. Updated all callers.
15041
6ba4688b 150422006-09-22 Marco Gerards <marco@gnu.org>
15043
15044 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
15045 (normal_mod_DEPENDENCIES): Likewise.
15046
15047 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
15048 (normal_mod_DEPENDENCIES): Likewise.
15049
15050 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
15051
e02ac02c 150522006-09-22 Johan Rydberg <jrydberg@gnu.org>
15053
15054 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
15055 programs.
15056 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
15057 (normal_mod_DEPENDENCIES): Likewise.
15058 * conf/i386-pc.mk: Regenerate.
15059 * conf/i386-efi.mk: Likewise
15060 * conf/common.mk: Likewise.
15061 * conf/powerpc-ieee1275.mk: Likewise.
15062 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 15063
8d252e44 150642006-09-22 Robert Millan <rmh@aybabtu.com>
15065
15066 Sync with i386 version.
15067 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
15068 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
15069
209bf7ac 150702006-09-21 Robert Millan <rmh@aybabtu.com>
15071
15072 Import from GRUB Legacy (lib/device.c):
15073 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
15074 (init_device_map) [__linux__]: Add support for I2O devices.
15075
6b146090 150762006-09-14 Marco Gerards <marco@gnu.org>
15077
15078 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
15079 `-melf_i386'.
15080
e38600a8 150812006-09-14 Robert Millan <rmh@aybabtu.com>
2952da5d 15082
15083 * util/i386/pc/grub-install.in: Skip menu.lst when removing
15084 /boot/grub/*.lst.
78fa1790 15085
2952da5d 15086 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
6b146090 15087
2952da5d 15088 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
15089 before adding it to device.map.
15090
01b82a64 150912006-08-15 Johan Rydberg <jrydberg@gnu.org>
15092
fe6b695a 15093 * genmk.rb: Let GCC generate dependencies the first time it
01b82a64 15094 compiles a file; using the -MD option.
15095 * conf/common.mk: Regenerate.
15096 * conf/i386-pc.mk: Likewise.
15097 * conf/i386-efi.mk: Likewise.
15098 * conf/powerpc-ieee1275.mk: Likewise.
15099 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 15100
1064790d 151012006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
15102
15103 Move the prototypes of grub_setjmp and grub_longjmp to
15104 cpu/setjmp.h, so that each architecture may specify different
15105 attributes.
f19dbdb7 15106
1064790d 15107 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
15108 (grub_longjmp): Likewise.
15109 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
15110 (grub_longjmp): Likewise.
15111 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
15112 (grub_longjmp): Likewise.
15113
15114 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
15115 [!GRUB_UTIL] (grub_longjmp): Removed.
15116
29dda3ed 151172006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
15118
15119 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
15120 "color!" method does not return any value.
15121
ad2a06ed 151222006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15123
15124 * include/grub/bitmap.h: New file.
15125
15126 * include/grub/i386/pc/vbeutil.h: Likewise.
15127
15128 * video/bitmap.c: Likewise.
15129
15130 * video/readers/tga.c: Likewise.
15131
15132 * video/i386/pc/vbeutil.c: Likewise.
15133
15134 * commands/videotest.c: Code cleanup and updated to reflect to new
15135 video API.
15136
15137 * term/gfxterm.c: Likewise.
15138
15139 * video/video.c: Likewise.
15140
15141 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
15142 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
15143 (bitmap_mod_SOURCES): New entry.
15144 (bitmap_mod_CFLAGS): Likewise.
15145 (bitmap_mod_LDFLAGS): Likewise.
15146 (tga_mod_SOURCES): Likewise.
15147 (tga_mod_CFLAGS): Likewise.
15148 (tga_mod_LDFLAGS): Likewise.
15149
15150 * include/grub/video.h (grub_video_blit_operators): New enum type.
15151 (grub_video_render_target): Changed as forward declaration and moved
15152 actual definition to be video driver specific.
15153 (grub_video_adapter.blit_bitmap): Added blitting operator.
15154 (grub_video_adapter.blit_render_target): Likewise.
15155 (grub_video_blit_bitmap): Likewise.
15156 (grub_video_blit_render_target): Likewise.
15157
15158 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
15159 driver specific render target definition.
15160 (grub_video_vbe_map_rgba): Added driver internal helper.
15161 (grub_video_vbe_unmap_color): Updated to use
15162 grub_video_i386_vbeblit_info.
15163 (grub_video_vbe_get_video_ptr): Likewise.
15164
15165 * include/grub/i386/pc/vbeblit.h
15166 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
15167 grub_video_i386_vbeblit_info.
15168 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
15169 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
15170 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
15171 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
15172 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
15173 (grub_video_i386_vbeblit_index_index): Likewise.
15174 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
15175 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
15176 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
15177 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
15178 operator.
15179 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
15180 operator.
15181
15182 * video/i386/pc/vbeblit.c: Updated to reflect changes on
15183 include/grub/i386/pc/vbeblit.h.
15184
15185 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
15186 Updated to use grub_video_i386_vbeblit_info.
15187 (grub_video_i386_vbefill_R8G8B8): Likewise.
15188 (grub_video_i386_vbefill_index): Likewise.
15189 (grub_video_i386_vbefill): Added generic filler.
15190
15191 * video/i386/pc/vbefill.c: Updated to reflect changes on
15192 include/grub/i386/pc/vbefill.h.
15193
15194 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
15195 grub_video_i386_vbeblit_info.
15196 (grub_video_vbe_unmap_color): Likewise.
15197 (grub_video_vbe_blit_glyph): Likewise.
15198 (grub_video_vbe_scroll): Likewise.
15199 (grub_video_vbe_draw_pixel): Removed function.
15200 (grub_video_vbe_get_pixel): Likewise.
15201 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
15202 updated code to use it.
15203 (common_blitter): Added common blitter for render target and bitmap.
15204 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
15205 (grub_video_vbe_blit_render_target): Likewise.
15206
bc8c036d 152072006-07-30 Johan Rydberg <jrydberg@gnu.org>
15208
15209 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
15210 is in text mode if there is no console control protocol instance
15211 available.
15212
684a8eff 152132006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15214
15215 * include/grub/video.h: Code cleanup.
15216
15217 * include/grub/i386/pc/vbe.h: Likewise.
15218
15219 * video/i386/pc/vbe.c: Likewise.
15220
15221 * video/i386/pc/vbeblit.c: Likewise.
15222
15223 * video/i386/pc/vbefill.c: Likewise.
15224
15225 * video/video.c: Likewise. Also added more comments.
15226
5915059b 152272006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15228
15229 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
15230 (struct grub_biosdisk_dap): Likewise.
15231
15232 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
15233 linkage settings for all functions.
15234
90ce5d56 152352006-07-12 Marco Gerards <marco@gnu.org>
15236
15237 * configure.ac (--enable-mm-debug): Fix typo.
15238
15239 * genkernsyms.sh.in: Use proper quoting for `CC'.
15240
43e7f879 152412006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
15242
15243 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
15244 (normal_mod_ASFLAGS): Remove "-m32".
15245
4889bdec 152462006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
15247
15248 * util/misc.c: Include config.h.
15249 [!HAVE_MEMALIGN]: Do not include malloc.h.
15250 (grub_memalign): Use posix_memalign, if present. Then, use
15251 memalign, if present. Otherwise, emit an error.
15252
15253 * util/grub-emu.c: Do not include malloc.h.
15254
15255 * include/grub/util/misc.h: Include unistd.h. This is required for
15256 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
15257 D. Eades III <hde@foobar-qux.org>.
15258
15259 * configure.ac (AC_GNU_SOURCE): Added.
15260 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
15261 type.
15262
fd39d4da 152632006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
15264
15265 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
15266 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
15267
b786f3b5 152682006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
15269
15270 * include/grub/types.h (grub_host_addr_t): Rename to
15271 grub_target_addr_t.
15272 (grub_host_off_t): Rename to grub_target_off_t.
15273 (grub_host_size_t): Rename to grub_target_size_t.
15274 (grub_host_ssize_t): Rename to grub_target_ssize_t.
15275 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
15276
15277 * include/grub/kernel.h (struct grub_module_header): Change type
15278 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
15279 (grub_module_info): Likewise.
f19dbdb7 15280
051988bb 152812006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15282
15283 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
15284 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
15285 Velazquez <jesus.velazquez@gmail.com>.
15286
deae281b 152872006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15288
15289 Count partitions from 1 instead of 0 in the string representation
15290 of partitions. Still use 0-based internally.
f19dbdb7 15291
deae281b 15292 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
15293 (sun_partition_map_iterate): Use grub_partition_t instead of
15294 struct grub_partition *. Cast DESC->START_CYLINDER to
15295 grub_uint64_t after converting the endian.
15296 (sun_partition_map_probe): Subtract 1 for PARTNUM.
15297 (sun_partition_map_get_name): Add 1 to P->INDEX.
15298
15299 * partmap/pc.c (grub_partition_parse): Subtract 1 for
15300 PCDATA->DOS_PART.
15301 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
15302
15303 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
15304 zero instead of one.
15305 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
15306 (gpt_partition_map_get_name): Add 1 into P->INDEX.
15307
15308 * partmap/apple.c (apple_partition_map_iterate): Change the type
15309 of POS to unsigned.
15310 (apple_partition_map_probe): Subtract 1 for PARTNUM.
15311 (apple_partition_map_get_name): Add 1 into P->INDEX.
15312
15313 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
15314 of POS to unsigned.
15315 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
15316 calculate the offset of a partition.
15317 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
15318 (amiga_partition_map_get_name): Add 1 into P->INDEX.
15319
15320 * partmap/acorn.c (acorn_partition_map_find): Change the type of
15321 SECTOR to grub_disk_addr_t.
15322 (acorn_partition_map_iterate): Likewise.
15323 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
15324 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
15325 top.
15326 (acorn_partition_map_get_name): Add 1 into P->INDEX.
15327
15328 * kern/i386/pc/init.c (make_install_device): Add 1 into
15329 GRUB_INSTALL_DOS_PART.
15330
15331 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
15332 conditional.
15333
524a1e6a 153342006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15335
15336 Clean up the code to support 64-bit addressing in disks and
15337 files. This change is not enough for filesystems yet.
f19dbdb7 15338
524a1e6a 15339 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
15340 type of "start" to grub_uint64_t.
15341 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
15342 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
15343 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
15344 convert addresses.
15345
15346 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
15347 to grub_disk_addr_t.
15348
15349 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
15350 string.
15351
15352 * partmap/pc.c (pc_partition_map_iterate): Likewise.
15353
15354 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
15355 to char *.
15356
15357 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
15358
15359 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
15360
15361 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
15362
15363 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
15364 to grub_off_t, to detect an error from grub_file_seek.
15365 (grub_multiboot_load_elf32): Likewise.
15366
15367 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
15368 maximum unsigned long value when an overflow is detected.
15369 (grub_strtoull): New function.
15370 (grub_divmod64): Likewise.
15371 (grub_lltoa): use grub_divmod64.
15372
15373 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
15374 grub_disk_addr_t.
15375 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
15376 the pointer to next character. Use grub_strtoull instead of
15377 grub_strtoul.
15378 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
15379 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
15380 respectively.
15381
fe6b695a 15382 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
524a1e6a 15383 return value is signed.
15384 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
15385 test if OFFSET is less than zero, as OFFSET is unsigned now.
15386
15387 * kern/disk.c (struct grub_disk_cache): Change the type of
15388 "sector" to grub_disk_addr_t.
15389 (grub_disk_cache_get_index): Change the type of SECTOR to
15390 grub_disk_addr_t. Calculate the hash with SECTOR casted to
15391 unsigned after shifting.
15392 (grub_disk_cache_invalidate): Change the type of SECTOR to
15393 grub_disk_addr_t.
15394 (grub_disk_cache_unlock): Likewise.
15395 (grub_disk_cache_store): Likewise.
15396 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
15397 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
15398 grub_disk_addr_t and grub_uint64_t, respectively.
15399 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
15400 body, as the value of OFFSET is tweaked by
15401 grub_disk_check_range. Change the types of START_SECTOR, LEN and
15402 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
15403 respectively.
15404 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
15405 body, as the value of OFFSET is tweaked by
15406 grub_disk_check_range. Change the types of LEN and N to
15407 grub_size_t.
15408
15409 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
15410 and "saved_offset" to grub_off_t.
15411 (test_header): Cast BUF to char *.
15412 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
15413 to char *.
15414 (grub_gzio_read): Change the types of OFFSET and SIZE to
15415 grub_off_t and grub_size_t, respectively.
15416
15417 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
15418 Removed.
15419 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
15420 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
15421 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
15422 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
15423 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
15424
15425 * include/grub/types.h (grub_off_t): Unconditionally set to
15426 grub_uint64_t.
15427 (grub_disk_addr_t): Changed to grub_uint64_t.
15428
15429 * include/grub/partition.h (struct grub_partition): Change the
15430 types of "start", "len" and "offset" to grub_disk_addr_t,
15431 grub_uint64_t and grub_disk_addr_t, respectively.
15432 (grub_partition_get_start): Return grub_disk_addr_t.
15433 (grub_partition_get_len): Return grub_uint64_t.
15434
15435 * include/grub/misc.h (grub_strtoull): New prototype.
15436 (grub_divmod64): Likewise.
15437
15438 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
15439 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
15440 grub_off_t, respectively.
15441 All callers and references changed.
15442
15443 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
15444 grub_size_t in "read".
15445 All callers and references changed.
15446
15447 * include/grub/file.h (struct grub_file): Change the types of
15448 "offset" and "size" to grub_off_t and grub_off_t,
15449 respectively. Change the type of SECTOR to grub_disk_addr_t in
15450 "read_hook".
15451 (grub_file_read): Change the type of LEN to grub_size_t.
15452 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
15453 grub_off_t.
15454 (grub_file_size): Return grub_off_t.
15455 (grub_file_tell): Likewise.
15456 All callers and references changed.
15457
15458 * include/grub/disk.h (struct grub_disk_dev): Change the types of
15459 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
15460 "write".
15461 (struct grub_disk): Change the type of "total_sectors" to
15462 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
f19dbdb7 15463 "read_hook".
524a1e6a 15464 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
15465 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
15466 (grub_disk_write): Likewise.
15467 All callers and references changed.
15468
15469 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
15470 char * for grub_strncmp to silence gcc.
15471 (grub_iso9660_mount): Likewise.
15472 (grub_iso9660_mount): Likewise.
15473 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
15474 return statement.
15475 (grub_iso9660_iterate_dir): Likewise.
15476 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
15477
15478 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
15479 LEN to grub_disk_addr_t and grub_size_t, respectively.
15480
15481 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
15482
15483 * fs/jfs.c (grub_jfs_read_file): Likewise.
15484
15485 * fs/minix.c (grub_jfs_read_file): Likewise.
15486
15487 * fs/sfs.c (grub_jfs_read_file): Likewise.
15488
15489 * fs/ufs.c (grub_jfs_read_file): Likewise.
15490
15491 * fs/xfs.c (grub_jfs_read_file): Likewise.
15492
15493 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
15494 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
15495 respectively.
15496
15497 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
15498 BLKNR to -1 instead of returning GRUB_ERRNO.
15499 (grub_ext2_read_file): Change the types of SECTOR and
15500 LEN to grub_disk_addr_t and grub_size_t, respectively.
15501
15502 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
15503 LEN to grub_disk_addr_t and grub_size_t, respectively.
15504
15505 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
15506 grub_file_read.
15507
15508 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
15509 string. Do not cast SECTOR explicitly.
15510
15511 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
15512 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
15513 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
15514 grub_disk_addr_t and grub_size_t, respectively. If the sector is
15515 over 2TB and LBA mode is not supported, raise an error.
15516 (get_safe_sectors): New function.
15517 (grub_biosdisk_read): Use get_safe_sectors.
15518 (grub_biosdisk_write): Likewise.
15519
15520 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
15521 (grub_efidisk_write): Likewise.
15522
15523 * disk/loopback.c (delete_loopback): Cosmetic changes.
15524 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
15525 correctly.
15526 (grub_loopback_open): Likewise.
15527 (grub_loopback_read): Likewise. Also, change the type of POS to
15528 grub_off_t, and fix the usage of grub_memset.
15529
15530 * commands/i386/pc/play.c: Include grub/machine/time.h.
15531
15532 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
15533 print FILE->SIZE.
15534
15535 * commands/configfile.c: Include grub/env.h.
15536
15537 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
15538 GRUB_ERRNO directly instead. Change the type of POS to
15539 grub_off_t. Follow the coding standard.
15540
15541 * commands/blocklist.c: Include grub/partition.h.
15542 (grub_cmd_blocklist): Return an error if the underlying device is
15543 not a disk. Take the starting sector of a partition into account,
15544 if a partition is used.
15545
15546 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
15547 a length field.
15548 (lba_mode): Support 64-bit addresses.
15549 (chs_mode): Likewise.
15550 (copy_buffer): Adapted to the new offsets of a length field and a
15551 segment field.
15552 (blocklist_default_start): Allocate 64-bit space.
15553
15554 * boot/i386/pc/boot.S (force_lba): Removed.
15555 (boot_drive): Moved to under KERNEL_SECTOR.
fe987087 15556 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
524a1e6a 15557 space.
15558 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
15559 is useless.
15560 (lba_mode): Refactored to support a 64-bit address. More size
15561 optimization.
15562 (setup_sectors): Likewise.
15563
53af98ad 155642006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15565
15566 * DISTLIST: Added include/grub/i386/linux.h. Removed
15567 include/grub/i386/pc/linux.h
15568
15569 * configure.ac (AC_INIT): Bumped to 1.94.
15570
15571 * config.guess: Updated from gnulib.
15572 * config.sub: Likewise.
15573 * install-sh: Likewise.
15574 * mkinstalldirs: Likewise.
15575
b4c1940a 155762006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15577
15578 * conf/common.rmk (grub_modules_init.lst): Depended on
15579 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
15580 MODSRCFILES.
15581
15582 * genmk.rb (PModule::rule): Reverted the previous change.
15583
cfca1cfd 155842006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15585
15586 * conf/common.rmk (grub_modules_init.lst): Depends on
15587 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
15588 that the target does not exist before producing.
15589 (grub_modules_init.h): Remove the target before generating.
15590 (grub_emu_init.c): Likewise.
15591
15592 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
15593
aa6d7826 155942006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
15595
15596 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
15597 for the target-specific tests. Make sure that we also have the
15598 up-to-date target variables for those tests.
15599
26c607b9 156002006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15601
15602 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
15603 (PModule::rule): Likewise.
15604
0162321a 156052006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15606
15607 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
15608 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
15609 target-specific flags should be prefixed.
15610 (PModule::rule): Likewise.
15611
6c826348 156122006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
15613
15614 * configure.ac (CMP): Check if cmp is available explicitly.
15615
b977bf01 156162006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
15617
15618 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
15619 (target_cpu): New variable.
15620 (pkglibdir): Use target_cpu instead of host_cpu.
f19dbdb7 15621
b977bf01 15622 * util/i386/pc/grub-install.in (host_cpu): Removed.
15623 (target_cpu): New variable.
15624 (pkglibdir): Use target_cpu instead of host_cpu.
15625
15626 * util/genmoddep.c: Removed.
f19dbdb7 15627
b977bf01 15628 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
15629 instead of GRUB_HOST_SIZEOF_VOID_P.
15630 * kern/dl.c: Likewise.
15631
15632 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
15633 ...
15634 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15635 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15636 (GRUB_TARGET_SIZEOF_LONG): ... this.
15637 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15638 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15639 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15640 to ...
15641 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15642 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15643 (GRUB_TARGET_SIZEOF_LONG): ... this.
15644 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15645 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15646 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15647 to ...
15648 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15649 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15650 (GRUB_TARGET_SIZEOF_LONG): ... this.
15651 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15652 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15653
15654 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
15655 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
15656 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
15657 instead of GRUB_HOST_SIZEOF_LONG.
15658 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
15659 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
15660 GRUB_CPU_WORDS_BIGENDIAN.
15661 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
15662 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
15663 grub_host_ssize_t.
15664
15665 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
15666 (genmoddep_SOURCES): Likewise.
15667 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
15668 (genmoddep_SOURCES): Likewise.
15669 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
15670 (genmoddep_SOURCES): Likewise.
15671 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
15672 Likewise.
15673 (genmoddep_SOURCES): Likewise.
15674
15675 * genmoddep.awk: New file.
15676
15677 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
15678 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
15679 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
15680 (PModule::rule): Likewise.
15681 (Program::rule): Likewise.
15682 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
15683 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
15684 respectively.
15685
15686 * configure.ac: Rewritten intensively to use host and target
15687 instead of build and host, respectively.
15688
15689 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
15690 (host_cpu): Removed.
15691 (target_cpu): New variable.
15692 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
15693 (BUILD_CC): Removed.
15694 (BUILD_CFLAGS): Likewise.
15695 (BUILD_CPPFLAGS): Likewise.
15696 (TARGET_CC): New variable.
15697 (TARGET_CFLAGS): Likewise.
15698 (TARGET_CPPFLAGS): Likewise.
15699 (TARGET_LDFLAGS): Likewise.
15700 (AWK): Likewise.
15701 (include): Use target_cpu instead of host_cpu.
15702 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
f19dbdb7 15703
b977bf01 15704 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
15705
f09771a1 157062006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
15707
15708 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
15709 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
15710 field 'false' to 'exec_on_false'.
15711 (grub_script_create_cmdif): Renamed argument names to reflect above
15712 changes.
15713
15714 * normal/execute.c (grub_script_execute_cmdif): Likewise.
15715
15716 * normal/script.c (grub_script_create_cmdif): Likewise.
15717
118f4fb3 157182006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
15719
15720 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
15721 top.
15722 (grub_hfsplus_btree_recptr): Likewise.
15723 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
15724 FILEBLOCK both to pass a block number and store next block
15725 number.
15726 (grub_hfsplus_read_block): Rewritten heavily to support an extent
15727 overflow file correctly. Specify errors appropriately, because
15728 fshelp expects that GRUB_ERRNO is set when fails. Reuse
15729 grub_hfsplus_btree_recptr to get the pointer to a found key.
15730 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
15731 is found.
15732
15733 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
15734 linux.mod.
15735 (_linux_mod_SOURCES): New variable.
15736 (_linux_mod_CFLAGS): Likewise.
15737 (_linux_mod_LDFLAGS): Likewise.
15738 (linux_mod_SOURCES): Likewise.
15739 (linux_mod_CFLAGS): Likewise.
15740 (linux_mod_LDFLAGS): Likewise.
15741
15742 * DISTLIST: Added loader/i386/efi/linux.c,
15743 loader/i386/efi/linux_normal.c and
15744 include/grub/i386/efi/loader.h.
15745
15746 * loader/i386/efi/linux.c: New file.
15747 * loader/i386/efi/linux_normal.c: Likewise.
15748 * include/grub/i386/efi/loader.h: Likewise.
15749
89a7d726 157502006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
15751
15752 * commands/blocklist.c: New file.
15753
15754 * DISTLIST: Added commands/blocklist.c.
15755
15756 * term/efi/console.c (grub_console_highlight_color): Use a lighter
43b553ad 15757 color for the background, and a darker color for the foreground.
89a7d726 15758 (grub_console_checkkey): Return READ_KEY.
15759 (grub_console_cls): Set the background to
15760 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
15761
15762 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
15763
15764 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
15765 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
15766
15767 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
15768 prototype.
15769
15770 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
15771 BG. The spec is wrong again.
15772
15773 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
15774 prototype.
15775 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
15776
15777 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
15778 commands/blocklist.c.
15779 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
f19dbdb7 15780
89a7d726 15781 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
15782 (blocklist_mod_SOURCES): New variable.
15783 (blocklist_mod_CFLAGS): Likewise.
15784 (blocklist_mod_LDFLAGS): Likewise.
15785
75c8f258 157862006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
15787
15788 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
15789 duplication.
15790 (lba_mode): Use %eax more intensively to reduce the code size.
15791
da2eb181 157922006-05-20 Marco Gerards <marco@gnu.org>
15793
15794 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
15795
15796 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
15797 for `menuentry'.
15798 (script): Accept leading newlines.
15799 (newlines): New rule to describe 0 or more newlines.
15800 (commands): Accept `command' with trailing newline. Fixed the
15801 order in which arguments were passed to `grub_script_add_cmd'.
15802 Accept commands separated by newlines.
15803 (function): Changed to accept newlines.
15804 (menuentry) Rewritten.
15805
15806 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
15807 front of the list, instead of to the end.
15808
577b4050 158092006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
15810
15811 * util/i386/pc/grub-install.in (bindir): New variable.
15812 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
15813 Shaver <lbgwjl@gmail.com>.
15814
0d6e1189 158152006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
15816
15817 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
15818 grub/machine/linux.h
15819 * loader/i386/pc/linux.c: Likewise.
15820
15821 * include/grub/i386/pc/linux.h: Moved to ...
15822 * include/grub/i386/linux.h: ... here.
15823
15824 * include/grub/i386/linux.h (struct linux_kernel_params): New
15825 struct.
f19dbdb7 15826
31b86e9f 158272006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
15828
15829 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
15830 checking.
15831 (grub_video_vbe_blit_glyph): Likewise.
15832 (grub_video_vbe_blit_bitmap): Likewise.
15833 (grub_video_vbe_blit_render_target): Likewise.
15834
83b984de 158352006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
15836
15837 * configure.ac (--with-platform): Properly quote the square
15838 brackets.
15839
5f0413bd 158402006-05-08 Marco Gerards <marco@gnu.org>
15841
15842 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
15843 this...
15844 (kernel_elf_HEADERS): ...to this. Updated all users.
15845 (grubof_symlist.c): Renamed from this...
15846 (kernel_elf_symlist.c): ...to this. Updated all users.
15847 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15848 (grubof_SOURCES): Renamed from this...
15849 (kernel_elf_SOURCES): ...to this.
15850 (grubof_HEADERS): Renamed from this...
15851 (kernel_elf_HEADERS): ...to this.
15852 (grubof_CFLAGS): Renamed from this...
15853 (kernel_elf_CFLAGS): ...to this.
15854 (grubof_ASFLAGS): Renamed from this...
15855 (kernel_elf_ASFLAGS): ...to this.
15856 (grubof_LDFLAGS): Renamed from this...
15857 (kernel_elf_LDFLAGS): ...to this.
15858
15859 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
15860 this...
15861 (kernel_elf_HEADERS): ...to this. Updated all users.
15862 (grubof_symlist.c): Renamed from this...
15863 (kernel_elf_symlist.c): ...to this. Updated all users.
15864 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15865 (grubof_SOURCES): Renamed from this...
15866 (kernel_elf_SOURCES): ...to this.
15867 (grubof_HEADERS): Renamed from this...
15868 (kernel_elf_HEADERS): ...to this.
15869 (grubof_CFLAGS): Renamed from this...
15870 (kernel_elf_CFLAGS): ...to this.
15871 (grubof_ASFLAGS): Renamed from this...
15872 (kernel_elf_ASFLAGS): ...to this.
15873 (grubof_LDFLAGS): Renamed from this...
15874 (kernel_elf_LDFLAGS): ...to this.
15875
15876 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
15877 `kernel.elf' instead of `grubof'.
15878
05568c2e 158792006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
15880
15881 Add --with-platform to configure. Use pkglibdir instead of
15882 pkgdatadir. This is reported by Roger Leigh.
15883
15884 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
15885 (host_vendor): Likewise.
15886 (host_os): Likewise.
15887 (pkgdatadir): Likewise.
15888 (platform): New variable.
15889 (pkglibdir): Likewise.
15890 Use PKGLIBDIR instead of PKGDATADIR.
f19dbdb7 15891
05568c2e 15892 * util/i386/pc/grub-install.in (datadir): Removed.
15893 (host_vendor): Likewise.
15894 (host_os): Likewise.
15895 (pkgdatadir): Likewise.
15896 (platform): New variable.
15897 (pkglibdir): Likewise.
15898 Use PKGLIBDIR instead of PKGDATADIR.
15899
15900 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
15901 instead of GRUB_DATADIR.
15902 (main): Likewise.
15903 * util/i386/pc/grub-mkimage.c (usage): Likewise.
15904 (main): Likewise.
15905 * util/i386/efi/grub-mkimage.c (usage): Likewise.
15906 (main): Likewise.
15907
15908 * configure.ac (--with-platform): New option.
15909 Use PLATFORM instead of HOST_VENDOR to specify a platform.
15910
15911 * Makefile.in: Include a makefile based on PLATFORM instead of
15912 HOST_VENDOR.
15913 (pkgdatadir): Not appended by the machine type.
15914 (pkglibdir): Appended by the machine type.
15915 (host_vendor): Removed.
15916 (platform): New variable.
15917 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
15918 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
15919 (uninstall): Likewise.
15920
4e93851c 159212006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
15922
15923 Use the environment context in the menu. Remove the commands
15924 "default" and "timeout", and use variables instead.
f19dbdb7 15925
4e93851c 15926 * normal/menu.c: Include grub/env.h.
15927 (print_entry): Cast TITLE to silence gcc.
15928 (get_timeout): New function.
15929 (set_timeout): Likewise.
15930 (get_entry_number): Likewise.
15931 (run_menu): Use a default entry, a fallback entry and a timeout
15932 in the environment variables "default", "fallback" and
15933 "timeout". Also, tweak the default entry if it is not within the
15934 current menu entries.
15935 (grub_menu_run): Use a fallback entry in the environment variable
15936 "fallback".
15937
15938 * normal/main.c (read_config_file): Do not initialize
15939 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
15940 NEWMENU->TIMEOUT.
15941 (grub_normal_execute): Use a data slot to store the menu.
15942
15943 * include/grub/normal.h (struct grub_menu): Removed default_entry,
15944 fallback_entry and timeout.
15945 (struct grub_menu_list): Removed.
15946 (grub_menu_list_t): Likewise.
15947 (struct grub_context): Likewise.
15948 (grub_context_t): Likewise.
15949 (grub_context_get): Likewise.
15950 (grub_context_get_current_menu): Likewise.
15951 (grub_context_push_menu): Likewise.
15952 (grub_context_pop_menu): Likewise.
15953 (grub_default_init): Likewise.
15954 (grub_default_fini): Likewise.
15955 (grub_timeout_init): Likewise.
15956 (grub_timeout_fini): Likewise.
15957
15958 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
15959 and timeout.mod.
15960 (normal_mod_SOURCES): Removed normal/context.c.
15961
15962 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
15963 commands/default.c, commands/timeout.c and normal/context.c.
15964 (normal_mod_SOURCES): Removed normal/context.c.
15965
15966 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
15967 commands/timeout.c and normal/context.c.
15968 (normal_mod_SOURCES): Removed normal/context.c.
15969
15970 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
15971 commands/default.c, commands/timeout.c and normal/context.c.
15972 (normal_mod_SOURCES): Removed normal/context.c.
15973
15974 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
15975 timeout.mod.
15976 (default_mod_SOURCES): Removed.
15977 (default_mod_CFLAGS): Likewise.
15978 (default_mod_LDFLAGS): Likewise.
15979 (timeout_mod_SOURCES): Removed.
15980 (timeout_mod_CFLAGS): Likewise.
15981 (timeout_mod_LDFLAGS): Likewise.
15982
15983 * DISTLIST: Removed commands/default.c, commands/timeout.c and
15984 normal/context.c.
15985
15986 * commands/default.c: Removed.
15987 * commands/timeout.c: Likewise.
15988 * normal/context.c: Likewise.
15989
1eb9cc1d 159902006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
15991
15992 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
15993
385bd9c1 159942006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
15995
15996 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
15997 "next" to "prev" for readability.
15998 (struct grub_env_sorted_var): New struct.
15999 (grub_env_context): Renamed to ...
16000 (initial_context): ... this.
16001 (grub_env_var_context): Renamed to ...
16002 (current_context): ... this.
16003 (grub_env_find): Look only at CURRENT_CONTEXT.
16004 (grub_env_context_open): Rewritten to copy exported variables from
16005 previous context.
16006 (grub_env_context_close): Rewritten according to the new
16007 scheme. Also, add an assertion to prevent the initial context from
16008 removed.
16009 (grub_env_insert): Removed the code for the sorted list.
16010 (grub_env_remove): Likewise.
16011 (grub_env_export): Simply mark the variable with
16012 GRUB_ENV_VAR_GLOBAL.
16013 (grub_env_set): A cosmetic change for naming consistency.
16014 (grub_env_get): Likewise.
16015 (grub_env_unset): Likewise.
16016 (grub_env_iterate): Rewritten to sort variables within this
16017 function.
16018 (grub_register_variable_hook): Fixed for naming consistency. Call
16019 grub_env_find again, only if NAME is not found at the first time.
16020 (mangle_data_slot_name): New function.
16021 (grub_env_set_data_slot): Likewise.
16022 (grub_env_get_data_slot): Likewise.
16023 (grub_env_unset_data_slot): Likewise.
16024
16025 * include/grub/env.h (grub_env_var_type): New enum.
16026 (GRUB_ENV_VAR_LOCAL): New constant.
16027 (GRUB_ENV_VAR_GLOBAL): Likewise.
16028 (GRUB_ENV_VAR_DATA): Likewise.
16029 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
16030 "type".
16031 (grub_env_set): Replace VAR with NAME for consistency.
16032 (grub_register_variable_hook): Likewise.
16033 (grub_env_export): Specify the name of the argument.
16034 (grub_env_set_data_slot): New prototype.
16035 (grub_env_get_data_slot): Likewise.
16036 (grub_env_unset_data_slot): Likewise.
16037
7f362539 160382006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
16039
16040 Extend the loader so that GRUB can accept a loader which comes
16041 back to GRUB when a loaded image exits. Also, this change adds
16042 support for a chainloader on EFI.
f19dbdb7 16043
7f362539 16044 * term/efi/console.c: Include grub/misc.h.
16045 (grub_console_checkkey): Display a scan code on the top for
16046 debugging. This will be removed once the EFI port gets stable.
16047 Correct the scan code mapping.
16048
16049 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
16050 allocate memory from larger regions, in order to reduce the number
16051 of allocated regions. Otherwise, the MacOSX loader panics.
16052 (filter_memory_map): Avoid less than 1MB for compatibility with
16053 other loaders.
16054 (add_memory_regions): Allocate from the tail of a region, if
16055 possible, to avoid allocating a region near to 1MB, for the MacOSX
16056 loader.
16057
16058 * kern/efi/init.c (grub_efi_set_prefix): Specify
16059 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
16060
16061 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
16062 argument IMAGE_HANDLE and specify it to get a loaded image.
16063 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
16064 grub_efi_get_loaded_image.
fe6b695a 16065 (grub_efi_get_filename): Divide the length by the size of
7f362539 16066 grub_efi_char16_t.
16067 (grub_efi_get_device_path): New function.
16068 (grub_efi_print_device_path): Print End Device Path nodes. Divide
16069 the length by the size of grub_efi_char16_t for a file path device
16070 path node.
16071
16072 * kern/loader.c (grub_loader_noreturn): New variable.
16073 (grub_loader_set): Accept a new argument NORETURN. Set
16074 GRUB_LOADER_NORETURN to NORETURN.
16075 All callers changed.
16076 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
16077 grub_machine_fini.
16078
16079 * include/grub/efi/efi.h (grub_efi_get_device_path): New
16080 prototype.
16081 (grub_efi_get_loaded_image): Take an argument to specify an image
16082 handle.
16083
16084 * include/grub/loader.h (grub_loader_set): Added one more argument
16085 NORETURN.
16086
16087 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
16088 instead of grub_efi_open_protocol.
16089 (grub_efidisk_get_device_name): Likewise.
16090 (grub_efidisk_close): Print a newline.
16091 (grub_efidisk_get_device_handle): Fixed to use
16092 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
16093 GRUB_EFI_DEVICE_PATH_TYPE.
16094
16095 * disk/efi/efidisk.c (device_path_guid): Moved to ...
16096 * kern/efi/efi.c (device_path_guid): ... here.
16097
16098 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
16099 chain.mod.
16100 (kernel_mod_HEADERS): Added efi/disk.h.
16101 (_chain_mod_SOURCES): New variable.
16102 (_chain_mod_CFLAGS): Likewise.
16103 (_chain_mod_LDFLAGS): Likewise.
16104 (chain_mod_SOURCES): Likewise.
16105 (chain_mod_CFLAGS): Likewise.
16106 (chain_mod_LDFLAGS): Likewise.
16107
16108 * DISTLIST: Added include/grub/efi/chainloader.h,
16109 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
16110
16111 * include/grub/efi/chainloader.h: New file.
16112 * loader/efi/chainloader.c: Likewise.
16113 * loader/efi/chainloader_normal.c: Likewise.
16114
c0111d6e 161152006-04-30 Marco Gerards <marco@gnu.org>
16116
16117 * commands/configfile.c (grub_cmd_source): New function.
16118 (GRUB_MOD_INIT): Register the commands `source' and `.'.
16119 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
16120
df5341da 161212006-04-30 Marco Gerards <marco@gnu.org>
16122
16123 * normal/execute.c (grub_script_execute_cmd): Change the return
16124 type to `grub_err_t'. Correctly return the error.
16125 (grub_script_execute_cmdline): In case a command line is not a
16126 command or a function, try to interpret it as an assignment.
16127
f85934bd 161282006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
16129
16130 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
16131 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
16132 skip a node whose name is obviously invalid as UTF-16,
16133 i.e. contains a NUL character. Stop the iteration when the last
16134 directory entry is found. Instead of using the return value of
16135 grub_hfsplus_btree_iterate_node, store the value in RET and use
16136 it, because the iterator can be stopped by the last directory
16137 entry.
16138
8f8a2cf8 161392006-04-30 Marco Gerards <marco@gnu.org>
16140
16141 * include/grub/env.h (grub_env_export): New prototype. Reported
16142 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
16143
a27e84ce 161442006-04-30 Marco Gerards <marco@gnu.org>
16145
16146 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
16147 size of the extents in a catalog file record.
16148
eaef0553 161492006-04-29 Marco Gerards <marco@gnu.org>
16150
16151 * commands/configfile.c (grub_cmd_configfile): Execute the
16152 configfile within its own context.
16153
16154 * include/grub/env.h (grub_env_context_open): New prototype.
16155 (grub_env_context_close): Likewise.
16156
16157 * kern/env.c (grub_env): Removed.
16158 (grub_env_sorted): Likewise.
16159 (grub_env_context): New variable.
16160 (grub_env_var_context): Likewise.
16161 (grub_env_find): Search both the active context and the global
16162 context.
16163 (grub_env_context_open): New function.
16164 (grub_env_context_close): Likewise.
16165 (grub_env_insert): Likewise.
16166 (grub_env_remove): Likewise.
16167 (grub_env_export): Likewise.
16168 (grub_env_set): Changed to use helper functions to avoid code
16169 duplication.
16170 (grub_env_iterate): Rewritten so both the current context and the
16171 global context are being used.
16172
16173 * normal/command.c (export_command): New function.
16174 (grub_command_init): Register the `export' function.
16175
7b455f4d 161762006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
16177
16178 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
16179 explicitly to suppress gcc's warnings.
16180 * fs/fat.c (grub_fat_find_dir): Likewise.
16181 (grub_fat_label): Likewise.
16182 * fs/xfs.c (grub_xfs_read_inode): Likewise.
16183 (grub_xfs_mount): Likewise.
16184 (grub_xfs_label): Likewise.
16185 * fs/affs.c (grub_affs_mount): Likewise.
16186 (grub_affs_label): Likewise.
16187 (grub_affs_iterate_dir): Likewise.
16188 * fs/sfs.c (grub_sfs_mount): Likewise.
16189 (grub_sfs_iterate_dir): Likewise.
16190 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
16191 * fs/hfs.c (grub_hfs_mount): Likewise.
16192 (grub_hfs_cmp_catkeys): Likewise.
16193 (grub_hfs_find_dir): Likewise.
16194 (grub_hfs_dir): Likewise.
16195 (grub_hfs_label): Likewise.
16196 * fs/jfs.c (grub_jfs_mount): Likewise.
16197 (grub_jfs_opendir): Likewise.
16198 (grub_jfs_getent): Likewise.
16199 (grub_jfs_lookup_symlink): Likewise.
16200 (grub_jfs_label): Likewise.
16201 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
16202 (grub_hfsplus_iterate_dir): Likewise.
16203 (grub_hfsplus_btree_iterate_node): Made static.
16204
16205 * util/grub-emu.c (prefix): New variable.
16206 (grub_machine_set_prefix): New function.
16207 (main): Do not set the environment variable "prefix" here. Only
16208 set PREFIX, which is used later by grub_machine_set_prefix.
16209
16210 * include/grub/video.h: Do not include grub/symbol.h.
16211 (grub_video_register): Not exported. This symbol is not defined in
16212 the kernel.
16213 (grub_video_unregister): Likewise.
16214 (grub_video_iterate): Likewise.
16215 (grub_video_setup): Likewise.
16216 (grub_video_restore): Likewise.
16217 (grub_video_get_info): Likewise.
16218 (grub_video_get_blit_format): Likewise.
16219 (grub_video_set_palette): Likewise.
16220 (grub_video_get_palette): Likewise.
16221 (grub_video_set_viewport): Likewise.
16222 (grub_video_get_viewport): Likewise.
16223 (grub_video_map_color): Likewise.
16224 (grub_video_map_rgb): Likewise.
16225 (grub_video_map_rgba): Likewise.
16226 (grub_video_fill_rect): Likewise.
16227 (grub_video_blit_glyph): Likewise.
16228 (grub_video_blit_bitmap): Likewise.
16229 (grub_video_blit_render_target): Likewise.
16230 (grub_video_scroll): Likewise.
16231 (grub_video_swap_buffers): Likewise.
16232 (grub_video_create_render_target): Likewise.
16233 (grub_video_delete_render_target): Likewise.
16234 (grub_video_set_active_render_target): Likewise.
16235
16236 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
16237 Undefined.
16238 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
16239
16240 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
16241 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16242 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16243 instead of $(srcdir)/genkernsyms.sh.
16244
16245 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
16246 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16247 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16248 instead of $(srcdir)/genkernsyms.sh.
16249
16250 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
16251 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16252 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16253 instead of $(srcdir)/genkernsyms.sh.
16254
16255 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
16256 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16257 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16258 instead of $(srcdir)/genkernsyms.sh.
16259
16260 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
16261 genkernsyms.sh.
16262
16263 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
16264 genkernsyms.sh.
16265 (gensymlist.sh): New target.
16266 (genkernsyms.sh): Likewise.
16267
16268 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
16269 genkernsyms.sh.in and gensymlist.sh.in.
16270
16271 * genkernsyms.sh: Removed.
16272 * gensymlist.sh: Likewise.
f19dbdb7 16273
7b455f4d 16274 * genkernsyms.sh.in: New file.
16275 * gensymlist.sh.in: Likewise.
16276
1885bb27 162772006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16278
16279 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
16280 clobber "prefix", since we may have already set it manually.
16281
71538dff 162822006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16283
16284 * kern/misc.c (abort): New alias for grub_abort.
16285
2965c7cc 162862006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
16287
16288 A new machine-specific function "grub_machine_set_prefix" is
16289 defined. This is called after loading modules, so that a prefix
16290 initialization can use modules. Also, this change adds an
16291 intensive debugging feature for the memory manager via the
16292 configure option "--enable-mm-debug".
f19dbdb7 16293
2965c7cc 16294 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
16295 PART.LEN.
16296
16297 * kern/sparc64/ieee1275/init.c (abort): Removed.
16298 (grub_stop): Likewise.
16299 (grub_exit): New function.
16300 (grub_set_prefix): Renamed to ...
16301 (grub_machine_set_prefix): ... this.
16302 (grub_machine_init): Do not call grub_set_prefix.
16303
16304 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
16305 (grub_machine_set_prefix): ... this.
16306 (grub_machine_init): Do not call grub_set_prefix.
16307
16308 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
16309 (grub_machine_init): Do not set the prefix here.
16310
16311 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
16312
16313 * kern/efi/init.c: Include grub/mm.h.
16314 (grub_efi_set_prefix): New function.
16315
16316 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
16317 (grub_efi_get_filename): New function.
16318 (grub_print_device_path): Renamed to ...
16319 (grub_efi_print_device_path): ... this.
16320
16321 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
16322 [MM_DEBUG] (grub_realloc): Likewise.
16323 [MM_DEBUG] (grub_free): Likewise.
16324 [MM_DEBUG] (grub_memalign): Likewise.
16325 [MM_DEBUG] (grub_mm_debug): New variable.
16326 [MM_DEBUG] (grub_debug_malloc): New function.
16327 [MM_DEBUG] (grub_debug_free): New function.
16328 [MM_DEBUG] (grub_debug_realloc): New function.
16329 [MM_DEBUG] (grub_debug_memalign): New function.
16330
16331 * kern/misc.c (grub_abort): Print a newline to distinguish
16332 the message.
16333
16334 * kern/main.c (grub_main): Call grub_machine_set_prefix and
16335 grub_set_root_dev after loading modules. This is necessary when
16336 setting a prefix depends on modules.
16337
16338 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
16339 (grub_efi_print_device_path): ... this.
16340 (grub_efi_get_filename): New prototype.
16341 (grub_efi_set_prefix): Likewise.
16342
16343 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
16344 and grub/disk.h.
16345 (grub_efidisk_get_device_handle): New prototype.
16346 (grub_efidisk_get_device_name): Likewise.
16347
16348 * include/grub/mm.h: Include config.h.
16349 (MM_DEBUG): Removed.
16350 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
16351 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
16352 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
16353 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
16354 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
16355 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
16356 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
16357 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
16358 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
16359
16360 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
16361
16362 * disk/efi/efidisk.c: Include grub/partition.h.
16363 (iterate_child_devices): New function.
16364 (add_device): First, compare only last device path nodes, so that
16365 devices are sorted by the types.
16366 (grub_efidisk_get_device_handle): New function.
16367 (grub_efidisk_get_device_name): Likewise.
16368
16369 * configure.ac (--enable-mm-debug): New option to enable the
16370 memory manager debugging feature. This makes the binary much
16371 bigger, so is disabled by default.
16372
9cacaa17 163732006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
16374
16375 Use grub_abort instead of grub_stop, and grub_exit must be
16376 define in each architecture now. Also, this change adds support
16377 for EFI disks.
f19dbdb7 16378
9cacaa17 16379 * util/i386/pc/grub-probefs.c: Include grub/term.h.
16380 (grub_getkey): New function.
16381 (grub_term_get_current): Likewise.
16382
16383 * util/i386/pc/grub-setup.c: Include grub/term.h.
16384 (grub_getkey): New function.
16385 (grub_term_get_current): Likewise.
16386
16387 * util/misc.c (grub_stop): Renamed to ...
16388 (grub_exit): ... this.
16389
16390 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
16391 (grub_exit): ... this.
16392 (grub_machine_init): Use grub_abort instead of abort.
16393 (grub_stop): Removed.
16394
16395 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
16396 abort.
16397
16398 * kern/i386/pc/startup.S (grub_exit): New function.
16399 (cold_reboot): New label.
16400
16401 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
16402 (grub_efi_init): Call grub_efidisk_init.
16403 (grub_efi_fini): Call grub_efidisk_fini.
16404
16405 * kern/efi/efi.c: Include grub/mm.h.
16406 (grub_efi_console_control_guid): Renamed to ...
16407 (console_control_guid): ... this.
16408 (grub_efi_loaded_image_guid): Renamed to ...
16409 (loaded_image_guid): ... this.
16410 (grub_efi_locate_handle): New function.
16411 (grub_efi_open_protocol): Likewise.
16412 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
16413 GRUB_EFI_CONSOLE_CONTROL_GUID.
16414 (grub_efi_exit): Removed.
16415 (grub_stop): Likewise.
16416 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
16417 (grub_exit): New function.
16418 (grub_print_device_path): Likewise.
16419
16420 * kern/rescue.c (grub_rescue_cmd_exit): New function.
16421 (grub_enter_rescue_mode): Register "exit".
16422
16423 * kern/misc.c (grub_real_dprintf): A cosmetic change.
16424 (grub_abort): New function.
16425
16426 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
16427
16428 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
16429
16430 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
16431
16432 * include/grub/efi/efi.h (grub_efi_exit): Removed.
16433 (grub_print_device_path): New prototype.
16434 (grub_efi_locate_handle): Likewise.
16435 (grub_efi_open_protocol): Likewise.
16436
16437 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
16438 * disk/efi/efidisk.c: Likewise.
16439
16440 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
16441
16442 * include/grub/efi/console_control.h
16443 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
16444
16445 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
16446 last 8 bytes as an array.
16447 (GRUB_EFI_DISK_IO_GUID): New macro.
16448 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
16449 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
16450 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
16451 grub_uint8_t.
16452 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
16453 (struct grub_efi_device_path): Rename the member "sub_type" to
16454 "subtype".
16455 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
16456 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
16457 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
16458 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
16459 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
16460 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
16461 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
16462 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
16463 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
16464 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
16465 (struct grub_efi_pci_device_path): New structure.
16466 (grub_efi_pci_device_path_t): New type.
16467 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
16468 (struct grub_efi_pccard_device_path): New structure.
16469 (grub_efi_pccard_device_path_t): New type.
16470 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
16471 (struct grub_efi_memory_mapped_device_path): New structure.
16472 (grub_efi_memory_mapped_device_path_t): New type.
16473 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
16474 (struct grub_efi_vendor_device_path): New structure.
16475 (grub_efi_vendor_device_path_t): New type.
16476 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
16477 (struct grub_efi_controller_device_path): New structure.
16478 (grub_efi_controller_device_path_t): New type.
16479 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
16480 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
16481 (struct grub_efi_acpi_device_path): New structure.
16482 (grub_efi_acpi_device_path_t): New type.
16483 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
16484 (struct grub_efi_expanded_acpi_device_path): New structure.
16485 (grub_efi_expanded_acpi_device_path_t): New type.
16486 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
16487 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
16488 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
16489 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
16490 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
16491 (struct grub_efi_atapi_device_path): New structure.
16492 (grub_efi_atapi_device_path_t): New type.
16493 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
16494 (struct grub_efi_fibre_channel_device_path): New structure.
16495 (grub_efi_fibre_channel_device_path_t): New type.
16496 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
16497 (struct grub_efi_1394_device_path): New structure.
16498 (grub_efi_1394_device_path_t): New type.
16499 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
16500 (struct grub_efi_usb_device_path): New structure.
16501 (grub_efi_usb_device_path_t): New type.
16502 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
16503 (struct grub_efi_usb_class_device_path): New structure.
16504 (grub_efi_usb_class_device_path_t): New type.
16505 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
16506 (struct grub_efi_i2o_device_path): New structure.
16507 (grub_efi_i2o_device_path_t): New type.
16508 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
16509 (struct grub_efi_mac_address_device_path): New structure.
16510 (grub_efi_mac_address_device_path_t): New type.
16511 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
16512 (struct grub_efi_ipv4_device_path): New structure.
16513 (grub_efi_ipv4_device_path_t): New type.
16514 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
16515 (struct grub_efi_ipv6_device_path): New structure.
16516 (grub_efi_ipv6_device_path_t): New type.
16517 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
16518 (struct grub_efi_infiniband_device_path): New structure.
16519 (grub_efi_infiniband_device_path_t): New type.
16520 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
16521 (struct grub_efi_uart_device_path): New structure.
16522 (grub_efi_uart_device_path_t): New type.
16523 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
16524 (struct grub_efi_vendor_messaging_device_path): New structure.
16525 (grub_efi_vendor_messaging_device_path_t): New type.
16526 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
16527 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
16528 (struct grub_efi_hard_drive_device_path): New structure.
16529 (grub_efi_hard_drive_device_path_t): New type.
16530 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
16531 (struct grub_efi_cdrom_device_path): New structure.
16532 (grub_efi_cdrom_device_path_t): New type.
16533 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
16534 (struct grub_efi_vendor_media_device_path): New structure.
16535 (grub_efi_vendor_media_device_path_t): New type.
16536 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
16537 (struct grub_efi_file_path_device_path): New structure.
16538 (grub_efi_file_path_device_path_t): New type.
16539 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
16540 (struct grub_efi_protocol_device_path): New structure.
16541 (grub_efi_protocol_device_path_t): New type.
16542 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
16543 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
16544 (struct grub_efi_bios_device_path): New structure.
16545 (grub_efi_bios_device_path_t): New type.
16546 (struct grub_efi_disk_io): New structure.
16547 (grub_efi_disk_io_t): New type.
16548 (struct grub_efi_block_io_media): New structure.
16549 (grub_efi_block_io_media_t): New type.
16550 (struct grub_efi_block_io): New structure.
16551 (grub_efi_block_io_t): New type.
16552
16553 * include/grub/misc.h (grub_stop): Removed.
16554 (grub_exit): New prototype.
16555 (grub_abort): Likewise.
16556
16557 * include/grub/disk.h (enum grub_disk_dev_id): Added
16558 GRUB_DISK_DEVICE_EFIDISK_ID.
16559
16560 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
16561 disk/efi/efidisk.c.
16562 (kernel_syms.lst): Remove the target if an error occurs.
16563
49986a9f 165642006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
16565
16566 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
16567 as it was simply too buggy.
16568
970d3b8a 165692006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
16570
16571 * kern/misc.c (grub_lltoa): New function.
16572 (grub_vsprintf): Added support for the long long suffix,
16573 i.e. "ll".
16574
ff04ec24 165752006-04-20 Hollis Blanchard <hollis@penguinppc.org>
16576
16577 * Makefile.in (LDFLAGS): Add variable.
16578 (LD): Remove variable.
16579 * configure.ac: Add -m32 to LDFLAGS.
16580 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
16581 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
16582 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
16583 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
16584 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
16585 variables.
16586 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
16587 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
16588 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
16589
37e5e1a4 165902006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
16591
16592 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
16593 length for unknown glyph.
16594
c352d8dd 165952006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
16596
2eab1c0d 16597 Add support for pre-loaded modules into the EFI port.
f19dbdb7 16598
2eab1c0d 16599 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
16600 completely. Accept one more argument DIR. The caller has changed.
16601
16602 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
16603
16604 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
16605 (grub_efi_loaded_image_guid): New variable.
16606 (grub_efi_get_loaded_image): New function.
16607 (grub_arch_modules_addr): Likewise.
16608
16609 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
16610 prototype.
16611
16612 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
16613 (struct grub_efi_loaded_image): New structure.
16614 (grub_efi_loaded_image_t): New type.
16615
166162006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 16617
c352d8dd 16618 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
16619 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
16620 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
16621
6d01d6b4 166222006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
16623
16624 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
16625
976a4ea0 166262006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
16627
16628 * DISTLIST: Added include/grub/efi/console.h,
16629 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
16630 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16631
16632 * include/grub/efi/console.h: New file.
16633 * include/grub/efi/time.h: Likewise.
16634 * include/grub/i386/efi/kernel.h: Likewise.
16635 * kern/efi/init.c: Likewise.
16636 * kern/efi/mm.c: Likewise.
16637 * term/efi/console.c: Likewise.
f19dbdb7 16638
976a4ea0 16639 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
16640 (grub_stop): Removed.
16641 (grub_get_rtc): Likewise.
16642 (grub_machine_init): Simply call grub_efi_init.
16643 (grub_machine_fini): Call grub_efi_fini.
16644
16645 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
16646 (grub_efi_output_string): Removed.
16647 (grub_efi_stall): New function.
16648 (grub_stop): Likewise.
16649 (grub_get_rtc): Likewise.
16650
16651 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
16652 (grub_efi_stall): New prototype.
16653 (grub_efi_allocate_pages): Likewise.
16654 (grub_efi_free_pages): Likewise.
16655 (grub_efi_get_memory_map): Likewise.
16656 (grub_efi_mm_init): Likewise.
16657 (grub_efi_mm_fini): Likewise.
16658 (grub_efi_init): Likewise.
16659 (grub_efi_fini): Likewise.
16660
16661 * include/grub/i386/efi/time.h: Do not include
16662 grub/symbol.h. Include grub/efi/time.h.
16663 (GRUB_TICKS_PER_SECOND): Removed.
16664 (grub_get_rtc): Likewise.
16665
16666 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
16667 Added padding. The EFI spec is buggy.
16668 (GRUB_EFI_BLACK): New macro.
16669 (GRUB_EFI_BLUE): Likewise.
16670 (GRUB_EFI_GREEN): Likewise.
16671 (GRUB_EFI_CYAN): Likewise.
16672 (GRUB_EFI_RED): Likewise.
16673 (GRUB_EFI_MAGENTA): Likewise.
16674 (GRUB_EFI_BROWN): Likewise.
16675 (GRUB_EFI_LIGHTGRAY): Likewise.
16676 (GRUB_EFI_BRIGHT): Likewise.
16677 (GRUB_EFI_DARKGRAY): Likewise.
16678 (GRUB_EFI_LIGHTBLUE): Likewise.
16679 (GRUB_EFI_LIGHTGREEN): Likewise.
16680 (GRUB_EFI_LIGHTCYAN): Likewise.
16681 (GRUB_EFI_LIGHTRED): Likewise.
16682 (GRUB_EFI_LIGHTMAGENTA): Likewise.
16683 (GRUB_EFI_YELLOW): Likewise.
16684 (GRUB_EFI_WHITE): Likewise.
16685 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
16686 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
16687 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
16688 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
16689 (GRUB_EFI_BACKGROUND_RED): Likewise.
16690 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
16691 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
16692 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
16693 (GRUB_EFI_TEXT_ATTR): Likewise.
16694
16695 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
16696 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16697 (kernel_mod_HEADERS): Added efi/time.h.
16698
83709125 166992006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
16700
16701 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
16702 include/grub/efi/api.h, include/grub/efi/console_control.h,
16703 include/grub/efi/efi.h, include/grub/efi/pe32.h,
16704 include/grub/i386/efi/time.h, kern/efi/efi.c,
16705 kern/i386/efi/init.c, kern/i386/efi/startup.S,
16706 and util/i386/efi/grub-mkimage.c.
16707
16708 * Makefile.in (RMKFILES): Added i386-efi.rmk.
16709
16710 * genmk.rb (PModule#rule): Do not export symbols if
16711 #{prefix}_EXPORTS is set to "no".
16712
16713 * conf/i386-efi.mk: New file.
16714 * conf/i386-efi.rmk: Likewise.
16715 * include/grub/efi/api.h: Likewise.
16716 * include/grub/efi/console_control.h: Likewise.
16717 * include/grub/efi/efi.h: Likewise.
16718 * include/grub/efi/pe32.h: Likewise.
16719 * include/grub/i386/efi/time.h: Likewise.
16720 * kern/efi/efi.c: Likewise.
16721 * kern/i386/efi/init.c: Likewise.
16722 * kern/i386/efi/startup.S: Likewise.
16723 * util/i386/efi/grub-mkimage.c: Likewise.
16724
167252006-04-17 Marco Gerards <marco@gnu.org>
bfa2bd9e 16726
16727 * include/grub/script.h: Include <grub/parser.h> and
16728 "grub_script.tab.h".
16729 (struct grub_lexer_param): New struct.
16730 (struct grub_parser_param): Likewise.
16731 (grub_script_create_arglist): Pass the state in an argument.
16732 (grub_script_add_arglist): Likewise.
16733 (grub_script_create_cmdline): Likewise.
16734 (grub_script_create_cmdblock): Likewise.
16735 (grub_script_create_cmdif): Likewise.
16736 (grub_script_create_cmdmenu): Likewise.
16737 (grub_script_add_cmd): Likewise.
16738 (grub_script_arg_add): Likewise.
16739 (grub_script_lexer_ref): Likewise.
16740 (grub_script_lexer_deref): Likewise.
16741 (grub_script_lexer_record_start): Likewise.
16742 (grub_script_lexer_record_stop): Likewise.
16743 (grub_script_mem_record): Likewise.
16744 (grub_script_mem_record_stop): Likewise.
16745 (grub_script_malloc): Likewise.
16746 (grub_script_yylex): Likewise.
16747 (grub_script_yyparse): Likewise.
16748 (grub_script_yyerror): Likewise.
16749 (grub_script_yylex): Likewise.
16750 (grub_script_lexer_init): Return the state.
16751
16752 * normal/lexer.c (grub_script_lexer_state): Removed variable.
16753 (grub_script_lexer_done): Likewise.
16754 (grub_script_lexer_getline): Likewise.
16755 (grub_script_lexer_refs): Likewise.
16756 (script): Likewise.
16757 (newscript): Likewise.
16758 (record): Likewise.
16759 (recording): Likewise.
16760 (recordpos): Likewise.
16761 (recordlen): Likewise.
16762 (grub_script_lexer_init): Return the state instead of setting
16763 global variables.
16764 (grub_script_lexer_ref): Use the newly added argument for state
16765 instead of globals.
16766 (grub_script_lexer_deref): Likewise.
16767 (grub_script_lexer_record_start): Likewise.
16768 (grub_script_lexer_record_stop): Likewise.
16769 (recordchar): Likewise.
16770 (nextchar): Likewise.
16771 (grub_script_yylex2): Likewise.
16772 (grub_script_yylex): Likewise.
16773 (grub_script_yyerror): Likewise.
16774
16775 * normal/parser.y (func_mem): Removed variable.
16776 (menu_entry): Likewise.
16777 (err): Likewise.
16778 (%lex-param): New parser option.
16779 (%parse-param): Likewise.
16780 (script): Always return the AST.
16781 (argument): Pass the state around.
16782 (arguments): Likewise.
16783 (grubcmd): Likewise.
16784 (commands): Likewise.
16785 (function): Likewise.
16786 (menuentry): Likewise.
16787 (if_statement): Likewise.
16788 (if): Likewise.
16789
16790 * normal/script.c (grub_script_memused): Removed variable.
16791 (grub_script_parsed): Likewise.
16792 (grub_script_malloc): Added a state argument. Use that instead of
16793 global variables.
16794 (grub_script_mem_record): Likewise.
16795 (grub_script_mem_record_stop): Likewise.
16796 (grub_script_arg_add): Likewise.
16797 (grub_script_add_arglist): Likewise.
16798 (grub_script_create_cmdline): Likewise.
16799 (grub_script_create_cmdif): Likewise.
16800 (grub_script_create_cmdmenu): Likewise.
16801 (grub_script_add_cmd): Likewise.
16802 (grub_script_parse): Setup the state before calling the parser.
f19dbdb7 16803
e2a8c904 168042006-04-16 Marco Gerards <marco@gnu.org>
6de2ee99 16805
16806 * normal/command.c (grub_command_init): Remove the title command.
16807
16808 * normal/lexer.c (grub_script_yylex): Renamed from this...
16809 (grub_script_yylex2): ... to this.
16810 (grub_script_yylex): New function. Temporary
16811 introduced to filter some tokens.
16812 (grub_script_yyerror): Print a newline.
16813
16814 * normal/main.c (read_config_file): Output information about the
16815 lines that contain errors. Wait for a key after all lines have
16816 been processed. Don't return an empty menu.
16817
16818 * normal/parser.y (func_mem): Don't initialize.
16819 (menu_entry): Likewise.
16820 (err): New variable.
16821 (script): Don't return anything when an error was encountered.
16822 (ws, returns): Removed rules.
16823 (argument): Disabled concatenated variable support.
16824 (arguments): Remove explicit separators.
16825 (grubcmd): Likewise.
16826 (function): Likewise.
16827 (menuentry): Likewise.
16828 (if): Likewise.
16829 (commands): Likewise. Add error handling.
16830
16831 * normal/script.c (grub_script_create_cmdline): If
16832 `grub_script_parsed' is 0, assume the parser encountered an error.
16833
c9a86192 168342006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
16835
16836 * configure.ac: Add support for EFI. Fix the typo
16837 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
16838
70f3b243 168392006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16840
16841 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
16842 foreign multibyte characters should be shown correctly.
16843
65f201ad 168442006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16845
16846 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
16847 calculation.
16848 (read_config_file): Made it to close file before returning.
16849
b4b93674 168502006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
16851
16852 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
16853 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
16854 video/i386/pc/vbefill.c.
16855
16856 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
16857 video/i386/pc/vbefill.c.
16858
16859 * include/grub/video.h (grub_video_blit_format): New enum.
16860 (grub_video_mode_info): Added new member blit_format.
16861 (grub_video_get_blit_format): New function prototype.
16862
16863 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
16864 function prototype.
16865 (grub_video_vbe_map_rgb): Likewise.
16866 (grub_video_vbe_unmap_color): Likewise.
16867
16868 * include/grub/i386/pc/vbeblit.h: New file.
16869
16870 * include/grub/i386/pc/vbefill.h: New file.
16871
16872 * video/video.c (grub_video_get_blit_format): New function.
16873 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
16874 (grub_video_vbe_map_rgb): Likewise.
16875 (grub_video_vbe_unmap_color): Likewise.
16876
16877 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
16878 optimized fills.
16879 (grub_video_vbe_blit_render_target): Changed to use more optimized
16880 blits.
16881 (grub_video_vbe_setup): Added detection for optimized settings.
16882 (grub_video_vbe_create_render_target): Likewise.
16883
16884 * video/i386/pc/vbeblit.c: New file.
16885
16886 * video/i386/pc/vbefill.c: New file.
16887
c2379b9c 168882006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
16889
16890 * font/manager.c (grub_font_get_glyph): Removed font fixup from
16891 here...
16892
16893 * util/unifont2pff.rb: ... and moved it to here. Improved argument
16894 parsing to support both hex and dec ranges. If filename was missing
16895 show usage information.
16896
bd0d7896 168972006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
16898
16899 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
16900 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
16901
16902 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
16903 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
16904 (video_mod_SOURCES): Added.
16905 (video_mod_CFLAGS): Likewise.
16906 (video_mod_LDFLAGS): Likewise.
16907 (gfxterm_mod_SOURCES): Likewise.
16908 (gfxterm_mod_CFLAGS): Likewise.
16909 (gfxterm_mod_LDFLAGS): Likewise.
16910 (videotest_mod_SOURCES): Likewise.
16911 (videotest_mod_CFLAGS): Likewise.
16912 (videotest_mod_LDFLAGS): Likewise.
16913 (vesafb_mod_SOURCES): Removed.
16914 (vesafb_mod_CFLAGS): Likewise.
16915 (vesafb_mod_LDFLAGS): Likewise.
16916 (vga_mod_SOURCES): Likewise.
16917 (vga_mod_CFLAGS): Likewise.
16918 (vga_mod_LDFLAGS): Likewise.
16919
16920 * commands/videotest.c: New file.
16921
16922 * font/manager.c (fill_with_default_glyph): Modified to use
16923 grub_font_glyph.
16924 (grub_font_get_glyph): Likewise.
16925 (fontmanager): Renamed from this...
16926 (font_manager): ... to this.
16927
16928 * include/grub/font.h (grub_font_glyph): Added new structure.
16929 (grub_font_get_glyph): Modified to use grub_font_glyph.
16930
16931 * include/grub/misc.h (grub_abs): Added as inline function.
16932
16933 * include/grub/video.h: New file.
16934
16935 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
16936 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
16937 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
16938 (grub_vbe_get_controller_info): Renamed from this...
16939 (grub_vbe_bios_get_controller_info): ... to this.
16940 (grub_vbe_get_mode_info): Renamed from this...
16941 (grub_vbe_bios_get_mode_info): ... to this.
16942 (grub_vbe_set_mode): Renamed from this...
16943 (grub_vbe_bios_set_mode): ... to this.
16944 (grub_vbe_get_mode): Renamed from this...
16945 (grub_vbe_bios_get_mode): ... to this.
16946 (grub_vbe_set_memory_window): Renamed from this...
16947 (grub_vbe_bios_set_memory_window): ... to this.
16948 (grub_vbe_get_memory_window): Renamed from this...
16949 (grub_vbe_bios_get_memory_window): ... to this.
16950 (grub_vbe_set_scanline_length): Renamed from this...
16951 (grub_vbe_set_scanline_length): ... to this.
16952 (grub_vbe_get_scanline_length): Renamed from this...
16953 (grub_vbe_bios_get_scanline_length): ... to this.
16954 (grub_vbe_set_display_start): Renamed from this...
16955 (grub_vbe_bios_set_display_start): ... to this.
16956 (grub_vbe_get_display_start): Renamed from this...
16957 (grub_vbe_bios_get_display_start): ... to this.
16958 (grub_vbe_set_palette_data): Renamed from this...
16959 (grub_vbe_bios_set_palette_data): ... to this.
16960 (grub_vbe_set_pixel_rgb): Removed.
16961 (grub_vbe_set_pixel_index): Likewise.
16962
16963 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
16964 from this...
16965 (grub_vbe_bios_get_controller_info): ... to this.
16966 (grub_vbe_get_mode_info): Renamed from this...
16967 (grub_vbe_bios_get_mode_info): ... to this.
16968 (grub_vbe_set_mode): Renamed from this...
16969 (grub_vbe_bios_set_mode): ... to this.
16970 (grub_vbe_get_mode): Renamed from this...
16971 (grub_vbe_bios_get_mode): ... to this.
16972 (grub_vbe_set_memory_window): Renamed from this...
16973 (grub_vbe_bios_set_memory_window): ... to this.
16974 (grub_vbe_get_memory_window): Renamed from this...
16975 (grub_vbe_bios_get_memory_window): ... to this.
16976 (grub_vbe_set_scanline_length): Renamed from this...
16977 (grub_vbe_set_scanline_length): ... to this.
16978 (grub_vbe_get_scanline_length): Renamed from this...
16979 (grub_vbe_bios_get_scanline_length): ... to this.
16980 (grub_vbe_set_display_start): Renamed from this...
16981 (grub_vbe_bios_set_display_start): ... to this.
16982 (grub_vbe_get_display_start): Renamed from this...
16983 (grub_vbe_bios_get_display_start): ... to this.
16984 (grub_vbe_set_palette_data): Renamed from this...
16985 (grub_vbe_bios_set_palette_data): ... to this.
16986 (grub_vbe_bios_get_controller_info): Fixed problem with registers
16987 getting corrupted after calling it. Added more pushes and pops.
16988 (grub_vbe_bios_set_mode): Likewise.
16989 (grub_vbe_bios_get_mode): Likewise.
16990 (grub_vbe_bios_get_memory_window): Likewise.
16991 (grub_vbe_bios_set_scanline_length): Likewise.
16992 (grub_vbe_bios_get_scanline_length): Likewise.
16993 (grub_vbe_bios_get_display_start): Likewise.
16994 (grub_vbe_bios_set_palette_data): Likewise.
16995
16996 * normal/cmdline.c (cl_set_pos): Refresh the screen.
16997 (cl_insert): Likewise.
16998 (cl_delete): Likewise.
16999
17000 * term/gfxterm.c: New file.
17001
17002 * term/i386/pc/vesafb.c: Removed file.
17003
17004 * video/video.c: New file.
17005
17006 * video/i386/pc/vbe.c (real2pm): Added new function.
17007 (grub_video_vbe_draw_pixel): Likewise.
17008 (grub_video_vbe_get_video_ptr): Likewise.
17009 (grub_video_vbe_get_pixel): Likewise
17010 (grub_video_vbe_init): Likewise.
17011 (grub_video_vbe_fini): Likewise.
17012 (grub_video_vbe_setup): Likewise.
17013 (grub_video_vbe_get_info): Likewise.
17014 (grub_video_vbe_set_palette): Likewise.
17015 (grub_video_vbe_get_palette): Likewise.
17016 (grub_video_vbe_set_viewport): Likewise.
17017 (grub_video_vbe_get_viewport): Likewise.
17018 (grub_video_vbe_map_color): Likewise.
17019 (grub_video_vbe_map_rgb): Likewise.
17020 (grub_video_vbe_map_rgba): Likewise.
17021 (grub_video_vbe_unmap_color): Likewise.
17022 (grub_video_vbe_fill_rect): Likewise.
17023 (grub_video_vbe_blit_glyph): Likewise.
17024 (grub_video_vbe_blit_bitmap): Likewise.
17025 (grub_video_vbe_blit_render_target): Likewise.
17026 (grub_video_vbe_scroll): Likewise.
17027 (grub_video_vbe_swap_buffers): Likewise.
17028 (grub_video_vbe_create_render_target): Likewise.
17029 (grub_video_vbe_delete_render_target): Likewise.
17030 (grub_video_vbe_set_active_render_target): Likewise.
17031 (grub_vbe_set_pixel_rgb): Remove function.
17032 (grub_vbe_set_pixel_index): Likewise.
17033 (index_color_mode): Remove static variable.
17034 (active_mode): Likewise.
17035 (framebuffer): Likewise.
17036 (bytes_per_scan_line): Likewise.
17037 (grub_video_vbe_adapter): Added new static variable.
17038 (framebuffer): Likewise.
17039 (render_target): Likewise.
17040 (initial_mode): Likewise.
17041 (mode_in_use): Likewise.
17042 (mode_list): Likewise.
17043
5f97350b 170442006-03-10 Marco Gerards <marco@gnu.org>
17045
17046 * configure.ac (AC_INIT): Bumped to 1.93.
17047
17048 * DISTLIST: Added `include/grub/hfs.h'.
17049
a3c5c6f8 170502006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
17051
17052 * boot/i386/pc/boot.S (general_error): Before looping, try INT
17053 18H, which might help the BIOS falling back to next boot media.
17054
6de53d26 170552006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
17056
17057 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
17058 Poe Chen <poe.poechen@gmail.com>.
17059
77c4a393 170602006-01-17 Marco Gerards <marco@gnu.org>
17061
17062 * include/grub/normal.h: Include <grub/script.h>.
17063 (grub_command_list): Removed struct.
17064 (grub_command_list_t): Removed type.
17065 (grub_menu_entry): Remove members `num' and `command_list'. Add
17066 members `commands' and `sourcecode'.
17067 * include/grub/script.h: Add inclusion guards.
17068 (grub_script_cmd_menuentry): New struct.
17069 (grub_script_execute_menuentry): New prototype.
17070 (grub_script_lexer_record_start): Likewise.
17071 (grub_script_lexer_record_stop): Likewise.
17072 * normal/execute.c (grub_script_execute_menuentry): New function.
17073 * normal/lexer.c (record, recording, recordpos, recordlen): New
17074 variables.
17075 (grub_script_lexer_record_start): New function.
17076 (grub_script_lexer_record_stop): Likewise.
17077 (recordchar): Likewise.
17078 (nextchar): Likewise.
17079 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
17080 2048 as the buffer size. Add the tokens `menuentry' and `@'.
17081 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
17082 (current_menu): New variable.
17083 (free_menu): Mainly rewritten.
17084 (grub_normal_menu_addentry): New function.
17085 (read_config_file): Rewritten.
17086 * normal/menu.c (run_menu_entry): Mainly rewritten.
fe987087 17087 * normal/menu_entry.c (make_screen): Rewritten the code to insert
77c4a393 17088 the menu entry.
17089 (run): Mainly rewritten.
17090 * normal/parser.y (menu_entry): New variable.
17091 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
17092 (menuentry): New rule.
17093 (command): Add `menuentry'.
17094 (if_statement): Allow additional returns before `fi'.
17095 * normal/script.c (grub_script_create_cmdmenu): New function.
17096
144f1f98 170972006-01-03 Marco Gerards <marco@gnu.org>
17098
17099 * INSTALL: GNU Bison is required.
17100 * configure.ac: Rewritten the test to detect Bison.
17101 * Makefile.in (YACC): New variable. Reported by Xun Sun
17102 <xun.sun.cn@gmail.com>.
17103
af4b2d89 171042006-01-03 Marco Gerards <marco@gnu.org>
17105
17106 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
17107 the HFS+ filesystem to filesystem blocks.
17108 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
17109 GCC warning is silenced.
17110
15643b71 171112006-01-03 Marco Gerards <marco@gnu.org>
17112
17113 * partmap/apple.c (apple_partition_map_iterate): Convert the data
17114 read from disk from big endian to host byte order.
17115
00905879 171162006-01-03 Hollis Blanchard <hollis@penguinppc.org>
17117
17118 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
17119 documentation.
17120 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
17121 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
17122 embedded HFS+ filesystem.
17123 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
17124 (grub_hfs_sblock): Move from here...
17125 * include/grub/hfs.h: To here... New file.
17126 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
17127 documentation.
17128 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
17129 New macros.
17130 (grub_hfsplus_volheader): Change type of member `magic' to
17131 `grub_uint16_t'.
17132 (grub_hfsplus_data): Add new member `embedded_offset'.
17133 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
17134 returned block.
17135 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
17136 Calculate the offset.
17137
8899bc3e 171382005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17139
17140 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
17141 Removed.
17142 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
17143
ae8c0277 171442005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17145
17146 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
17147 ENV->NAME is NULL after allocating ENV->VALUE.
17148
07084456 171492005-12-25 Marco Gerards <marco@gnu.org>
17150
17151 * kern/env.c (grub_env_set): Rewritten the error handling code.
17152
4750f5f1 171532005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17154
17155 * geninit.sh: Made more robust, and more portable.
17156
50214199 171572005-12-25 Marco Gerards <marco@gnu.org>
17158
17159 Add support for Apple HFS+ filesystems.
f19dbdb7 17160
50214199 17161 * fs/hfsplus.c: New file.
17162
17163 * DISTLIST: Added `fs/hfsplus.c'.
17164
17165 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
17166 (hfsplus_mod_SOURCES): New variable.
17167 (hfsplus_mod_CFLAGS): Likewise.
17168 (hfsplus_mod_LDFLAGS): Likewise.
17169 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
17170 (grub_setup_SOURCES): Likewise.
17171 (grub_mkdevicemap_SOURCES): Likewise.
17172 (grub_emu_SOURCES): Likewise.
17173 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
17174
17175 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
17176
17177 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
17178
befaed6c 171792005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17180
17181 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
17182 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
17183 include/grub/parser.h, include/grub/script.h, kern/parser.c,
17184 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
17185 normal/lexer.c, normal/parser.y, normal/script.c, and
17186 partmap/gpt.c.
17187 Removed kern/sparc64/cache.c.
17188
17189 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
17190 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
17191 grub_emu_init.c.
17192
17193 * configure.ac (AC_INIT): Bumped to 1.92.
17194
6a124103 171952005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
17196
17197 * kern/err.c (grub_error_push): Added new function to support error
17198 stacks.
17199 (grub_error_pop): Likewise.
17200 (grub_error_stack_items): New local variable to support error stacks.
17201 (grub_error_stack_pos): Likewise.
17202 (grub_error_stack_assert): Likewise.
17203 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
17204 stack depth.
17205 (grub_print_error): Added support to print errors from error stack.
17206
17207 * include/grub/err.h (grub_error_push): Added function prototype.
17208 (grub_error_pop): Likewise.
17209
be973c1b 172102005-12-09 Hollis Blanchard <hollis@penguinppc.org>
17211
17212 * configure.ac: Accept `powerpc64' as host_cpu.
17213 (amd64): Rename to `biarch32'.
17214
17215 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
17216 non-cacheline-aligned addresses.
17217
17218 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
17219 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
17220 if `size' is non-zero.
17221
b04216ab 172222005-12-03 Marco Gerards <mgerards@xs4all.nl>
17223
17224 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
17225 and `cd' to make sure the filename is not prefixed with a
17226 directory name.
17227 (pkgdata_MODULES): Add `gpt.mod'.
17228 (gpt_mod_SOURCES): New variable.
17229 (gpt_mod_CFLAGS): Likewise.
17230 (gpt_mod_LDFLAGS): Likewise.
17231
17232 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
17233
17234 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
17235 New macro.
17236
17237 * partmap/gpt.c: New file.
17238
17239 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
17240 GPT partition map is detected.
17241
41730ed9 172422005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
17243
17244 * commands/i386/pc/play.c: New file.
17245 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
17246 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
17247 macros.
f19dbdb7 17248
95dc3643 172492005-11-27 Marco Gerards <mgerards@xs4all.nl>
17250
17251 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
17252 ((unused))' to silence gcc warning.
17253
1569ec51 172542005-11-26 Hollis Blanchard <hollis@penguinppc.org>
17255
17256 * configure.ac: Correct `AC_PROG_YACC' test.
17257
9abde152 172582005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17259
17260 * util/powerpc/ieee1275/grub-install.in: Run the mount point
17261 check before installing files.
17262
44b83271 172632005-11-22 Mike Small <smallm@panix.com>
17264
17265 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
17266 number regex so multidigit numbers are recognized correctly.
17267
172682005-11-22 Mike Small <smallm@panix.com>
17269
17270 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
17271 debugging message before attempting to claim memory.
17272 (grub_rescue_cmd_initrd): Add a claim debugging message and try
17273 multiple addresses in case of failure.
17274
9c12956b 172752005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17276
17277 * term/tparm.c (get_space): Remove empty `if' statement.
17278
17279 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
17280
17281 * kern/parser.c (check_varstate): Rename `state' to 's'.
17282
aeaf81d9 172832005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17284
17285 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
17286 variable definitions to the beginning of each function. Sort stack
17287 variables by size.
17288 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
17289 `buf' argument to `char *'.
17290
79bbb63f 172912005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17292
17293 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
17294 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17295 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
79bbb63f 17296 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17297 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17298 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17299 configfile.mod, search.mod, gzio.mod and test.mod.
17300 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17301 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17302 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17303 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17304 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17305 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17306 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17307 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17308 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17309 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17310 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17311 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17312 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17313 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17314 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17315 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17316 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17317 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17318 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17319 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17320 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17321 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17322 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
17323
17324 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
17325 `grep --include'.
17326 (pkgdata_MODULES): Add test.mod.
17327
233b1628 173282005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17329
17330 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
17331 appending to variables with "+=".
17332 (PModule): Use full pathname to generate *.lst filenames.
17333
17334 * Makefile.in: Fixed list rules moved from genmk.rb.
17335 (.DELETE_ON_ERROR): New special target.
17336 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
17337
17338 * conf/i386-pc.rmk: Include conf/common.mk.
17339 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17340 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
233b1628 17341 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17342 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17343 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17344 configfile.mod, search.mod, gzio.mod and test.mod.
17345 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17346 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17347 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17348 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17349 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17350 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17351 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17352 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17353 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17354 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17355 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17356 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17357 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17358 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17359 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17360 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17361 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17362 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17363 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17364 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17365 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17366 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17367 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
17368 here...
17369 * conf/common.rmk: ... to here. New file.
17370
17371 * conf/common.mk: New file.
17372
16f820c8 173732005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
17374
17375 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
17376 (grub_script.tab.c): ... here.
17377
17378 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
17379 (grub_script.tab.c): ... here.
17380
17381 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
17382 (grub_script.tab.c): ... here.
17383
17384 * normal/command.c (grub_command_find): Fixed a memory leak of
17385 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
17386
63ba1554 173872005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17388
17389 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
17390 "@" which marks the start of a comment on ARM.
17391 (VARIABLE): Likewise.
17392
7f67dc13 173932005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17394
79bbb63f 17395 Add support for Linux/ADFS partition tables.
7f67dc13 17396
17397 * partmap/acorn.c: New file.
17398
17399 * include/grub/acorn_filecore.h: Likewise.
17400
17401 * DISTLIST: Added `partmap/acorn.c' and
17402 `include/grub/acorn_filecore.h'.
f19dbdb7 17403
7f67dc13 17404 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17405 `partmap/acorn.c'.
17406 (pkgdata_MODULES): Add `acorn.mod'.
17407 (acorn_mod_SOURCES): New variable.
17408 (acorn_mod_CFLAGS): Likewise.
17409
17410 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17411 `partmap/acorn.c'.
17412 (pkgdata_MODULES): Add `acorn.mod'.
17413 (acorn_mod_SOURCES): New variable.
17414 (acorn_mod_CFLAGS): Likewise.
17415
17416 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
17417 (pkgdata_MODULES): Add `acorn.mod'.
17418 (acorn_mod_SOURCES): New variable.
17419 (acorn_mod_CFLAGS): Likewise.
17420 (acorn_mod_LDFLAGS): Likewise.
17421
17422 * include/types.h (grub_disk_addr_t): New typedef.
17423
6d099807 174242005-11-13 Marco Gerards <mgerards@xs4all.nl>
17425
17426 * geninit.sh: New file.
17427
17428 * geninitheader.sh: Likewise.
17429
17430 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
17431 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
17432 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
17433 * commands/configfile.c (grub_configfile_init)
17434 (grub_configfile_fini): Likewise.
17435 * commands/default.c (grub_default_init, grub_default_fini):
17436 Likewise.
17437 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
17438 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
17439 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
17440 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
17441 Likewise.
17442 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
17443 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
17444 Likewise.
17445 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
fe6b695a 17446 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
6d099807 17447 Likewise.
17448 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
17449 Likewise.
fe6b695a 17450 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
6d099807 17451 Likewise.
17452 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
17453 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
17454 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
17455 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
17456 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
17457 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
17458 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
17459 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
17460 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
17461 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
17462 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
17463 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
17464 * partmap/amiga.c (grub_amiga_partition_map_init)
17465 (grub_amiga_partition_map_fini): Likewise.
17466 * partmap/apple.c (grub_apple_partition_map_init)
17467 (grub_apple_partition_map_fini): Likewise.
17468 * partmap/pc.c (grub_pc_partition_map_init)
17469 (grub_pc_partition_map_fini): Likewise.
17470 * partmap/sun.c (grub_sun_partition_map_init,
17471 grub_sun_partition_map_fini): Likewise.
17472 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
17473 Likewise.
17474
17475 * util/grub-emu.c: Include <grub_modules_init.h>.
17476 (main): Don't initialize and de-initialize any modules directly,
17477 use `grub_init_all' and `grub_fini_all' instead.
17478
17479 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
17480 `grub_vesafb_mod_init'.
17481 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
17482 all users.
17483 * term/i386/pc/vga.c (grub_vga_init): Renamed to
17484 `grub_vga_mod_init'. Updated all users.
17485 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
f19dbdb7 17486
6d099807 17487 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
17488 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
17489 rules.
17490
17491 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
17492 Generate a function to initialize the module in utilities.
17493 Updated all callers.
17494 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
17495 initialize the module in utilities. Updated all callers.
17496
9046bcf0 174972005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17498
17499 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
17500 escape sequence and a literal ^L to clear the screen.
17501
17502 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
17503 when returning from Open Firmware.
17504
d13ea639 175052005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17506
17507 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
17508 (grub_ofconsole_height): Likewise.
17509 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
17510 manually insert a '\n'.
17511 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
17512 `grub_ofconsole_height'. Return early if these are already set.
17513
a8fcf206 175142005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
17515
17516 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17517 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
17518 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
17519 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
17520 and `normal/script.c'.
17521 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17522 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17523 (test_mod_SOURCES): New variable.
17524 (test_mod_CFLAGS): Likewise.
17525 (test_mod_LDFLAGS): Likewise.
17526 (pkgdata_MODULES): Add `test.mod'.
17527 (grub_script.tab.c): New rule.
17528 (grub_script.tab.h): Likewise.
17529
b6b32745 175302005-11-07 Marco Gerards <mgerards@xs4all.nl>
17531
17532 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17533 `commands/test.c', `normal/execute.c', `normal/lexer.c',
17534 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17535 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17536 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17537 (test_mod_SOURCES): New variable.
17538 (test_mod_CFLAGS): Likewise.
17539 (pkgdata_MODULES): Add `test.mod'.
17540 (grub_script.tab.c): New rule.
17541 (grub_script.tab.h): Likewise.
17542
daac212a 175432005-11-06 Marco Gerards <mgerards@xs4all.nl>
17544
17545 Add initial scripting support.
17546
17547 * commands/test.c: New file.
17548 * include/grub/script.h: Likewise.
17549 * normal/execute.c: Likewise.
17550 * normal/function.c: Likewise.
17551 * normal/lexer.c: Likewise.
17552 * normal/parser.y: Likewise.
17553 * normal/script.c: Likewise.
17554
17555 * configure.ac: Add `AC_PROG_YACC' test.
f19dbdb7 17556
daac212a 17557 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
17558 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
17559 `normal/function.c' and `normal/script.c'.
17560 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17561 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
b6b32745 17562 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
17563 variables.
daac212a 17564 (pkgdata_MODULES): Add `test.mod'.
17565 (grub_script.tab.c): New rule.
17566 (grub_script.tab.h): Likewise.
17567
17568 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
17569
17570 * include/grub/normal.h (grub_test_init): New prototype.
17571 (grub_test_fini): Likewise.
f19dbdb7 17572
daac212a 17573 * normal/command.c: Include <grub/script.h>.
17574 (grub_command_execute): Rewritten.
f19dbdb7 17575
daac212a 17576 * util/grub-emu.c (main): Call `grub_test_init' and
17577 `grub_test_fini'.
17578
77500b2b 175792005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17580
17581 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
17582 to 0.
17583 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
17584 there are no pending characters.
17585
e45deb9e 175862005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17587
17588 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
17589 `grub_strndup' to drop device arguments. Replace unnecessary
17590 `grub_strndup' with `grub_strdup'.
17591
4ce32619 175922005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17593
17594 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
17595 `debug' environment variable has been set.
17596
175972005-11-02 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 17598
4ce32619 17599 * Makefile.in (install-local): Use $(DATA).
17600 (uninstall): Likewise.
17601 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
17602 (sbin_UTILITIES): ... to here.
17603 (sbin_SCRIPTS): New variable.
17604 (grub_install_SOURCES): New variable.
17605 * util/powerpc/ieee1275/grub-install.in: New file.
17606 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
17607 variable.
17608 (add_segments): Call `grub_util_get_path'.
17609
25fe6f03 176102005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
17611
17612 From Timothy Baldwin:
17613 * commands/ls.c (grub_ls_list_files): Close FILE with
17614 grub_file_close.
17615 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
17616
04ccf3ec 176172005-10-24 Marco Gerards <mgerards@xs4all.nl>
17618
17619 * include/grub/parser.h: New file.
17620
17621 * kern/parser.c: Likewise.
17622
17623 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
17624 (grub_setup_SOURCES): Likewise.
17625 (grub_probefs_SOURCES): Likewise.
17626 (grub_emu_SOURCES): Likewise.
17627 (kernel_img_HEADERS): Add `parser.h'.
17628
17629 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17630 (grub_emu_SOURCES): Add `kern/parser.c'.
17631 (grubof_SOURCES): Likewise.
17632
17633 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17634 (grubof_SOURCES): Add `kern/parser.c'.
17635
17636 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
17637
17638 * kern/misc.c (grub_split_cmdline): Removed function.
17639
17640 * kern/rescue.c: Include <grub/parser.h>.
17641 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
17642 of `grub_split_cmdline'.
17643
17644 * normal/command.c: Include <grub/parser.h>.
17645 (grub_command_execute): Use `grub_parser_split_cmdline' instead
17646 of `grub_split_cmdline'.
17647
17648 * normal/completion.c: Include <grub/parser.h>.
17649 (cmdline_state): New variable.
17650 (iterate_dir): End the filename with a quote depending on the
17651 command line state.
17652 (get_state): new function.
17653 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
17654 split the arguments and determine the current argument. When the
17655 argument string is not quoted, escape all spaces.
17656
6d8f4b0e 176572005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17658
17659 * normal/sparc64/setjmp.S: New file.
17660
15cf03ed 176612005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17662
17663 * include/grub/sparc64/libgcc.h: New file.
17664 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
17665 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
17666 normal/sparc64/setjmp.c.
17667
03e8661a 176682005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17669
17670 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
17671 * kern/sparc64/cache.S: New file.
17672 * kern/sparc64/cache.c: Removed.
17673 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
17674 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
17675 -mtune=ultrasparc.
17676 (COMMON_LDFLAGS): Add -melf64_sparc.
17677 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
17678 (grubof_SOURCES): Use cache.S instead of cache.c.
17679 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
17680 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
17681 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
17682 commented though.
17683 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
17684 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
17685 (linux_mod_CFLAGS): Commented out.
17686 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
17687 out because module isn't built.
17688 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
17689 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
17690 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
17691 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
17692 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
17693 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17694 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17695 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
17696 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
17697 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
17698 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17699 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17700 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
17701 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
17702
34eeec8a 177032005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
17704
17705 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
17706 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
17707 longer, because HFS should not be used on PC.
17708
708367a3 177092005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17710
17711 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
17712 consistently within the loop.
17713
6fa1251a 177142005-10-15 Marco Gerards <mgerards@xs4all.nl>
17715
17716 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
17717 directory can not be read.
17718
4801580b 177192005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17720
17721 * configure.ac (AC_INIT): Increase the version number to 1.91.
17722
17723 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
17724 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
17725 term/i386/pc/serial.c.
17726
219ad426 177272005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17728
17729 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
17730 file size must be permitted.
17731
17732 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
17733 between %ah and %al.
17734
688e5699 177352005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17736
17737 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
17738 grub_uint64_t.
17739 Call the hook with a NUL-terminated filename.
17740 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
17741 grub_cpu_to_be32.
17742
17743 * kern/term.c (cursor_state): New variable.
17744 (grub_term_set_current): Reset the cursor state on a new
17745 terminal.
17746 (grub_setcursor): Rewritten to use CURSOR_STATE.
17747 (grub_getcursor): New function.
17748
17749 * include/grub/term.h (grub_getcursor): New prototype.
17750
17751 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
17752 integers on ARM. Reported by Timothy Baldwin
17753 <T.E.Baldwin99@members.leeds.ac.uk>.
17754
bb34586c 177552005-10-11 Marco Gerards <mgerards@xs4all.nl>
17756
17757 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
17758 allocated.
17759 (grub_sfs_dir): Likewise.
17760
9a909877 177612005-10-09 Marco Gerards <mgerards@xs4all.nl>
17762
17763 Add support for the SFS filesystem.
17764
17765 * fs/sfs.c: New file.
17766
17767 * DISTLIST: Added `fs/sfs.c'.
17768
17769 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
17770 (grub_probefs_SOURCES): Likewise.
17771 (grub_emu_SOURCES): Likewise.
17772 (pkgdata_MODULES): Add `sfs.mod'.
17773 (sfs_mod_SOURCES): New variable.
17774 (sfs_mod_CFLAGS): Likewise.
17775 (sfs_mod_LDFLAGS): Likewise.
17776
17777 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
17778 (pkgdata_MODULES): Add `sfs.mod'.
17779 (sfs_mod_SOURCES): New variable.
17780 (sfs_mod_CFLAGS): Likewise.
17781
17782 * util/grub-emu.c (main): Call `grub_sfs_init' and
17783 `grub_sfs_fini'.
17784
17785 * include/grub/fs.h (grub_sfs_init): New prototype.
17786 (grub_sfs_fini): Likewise.
17787
57bdbde3 177882005-10-07 Marco Gerards <mgerards@xs4all.nl>
17789
17790 Add support for the AFFS filesystem.
17791
17792 * fs/affs.c: New file.
17793
17794 * DISTLIST: Added `fs/affs.c'.
17795
17796 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
17797 (grub_probefs_SOURCES): Likewise.
17798 (grub_emu_SOURCES): Likewise.
17799 (pkgdata_MODULES): Add `affs.mod'.
17800 (affs_mod_SOURCES): New variable.
17801 (affs_mod_CFLAGS): Likewise.
17802 (affs_mod_LDFLAGS): Likewise.
17803
17804 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
17805 (pkgdata_MODULES): Add `affs.mod'.
17806 (affs_mod_SOURCES): New variable.
17807 (affs_mod_CFLAGS): Likewise.
17808
17809 * util/grub-emu.c (main): Call `grub_affs_init' and
17810 `grub_affs_fini'.
17811
17812 * include/grub/fs.h (grub_affs_init): New prototype.
17813 (grub_affs_fini): Likewise.
17814
047b67e0 178152005-10-01 Marco Gerards <mgerards@xs4all.nl>
17816
17817 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
17818
59b8208a 178192005-10-01 Marco Gerards <mgerards@xs4all.nl>
17820
17821 * configure.ac: Accept `x86_64' as host_cpu. In that case add
17822 `-m32' to CFLAGS.
17823
17824 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
17825 linking.
f19dbdb7 17826
59b8208a 17827 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
17828 (COMMON_LDFLAGS): New variable.
17829 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
17830 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
17831 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
17832 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
17833 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
17834 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
17835 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
17836 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
17837 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
17838 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
17839 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17840 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17841 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
17842 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
17843 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
17844 variables.
17845 (normal_mod_ASFLAGS): Add `-m32'.
17846
17847 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
17848 (grub_host_size_t, grub_host_ssize_t): New types.
17849 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
fe6b695a 17850 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
59b8208a 17851 `GRUB_HOST_SIZEOF_VOID_P'.
17852
17853 * include/grub/kernel.h (struct grub_module_header): Type of
17854 member offset changed to `grub_host_off_t'. Type of member size
17855 changed to `grub_host_size_t'.
17856 (struct grub_module_info): Type of member offset changed to
17857 `grub_host_off_t'. Type of member size changed to
17858 `grub_host_size_t'.
17859
b4093103 178602005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
17861
17862 Make GRUB's kernel compliant to Multiboot Specification.
f19dbdb7 17863
b4093103 17864 * kern/i386/pc/startup.S (multiboot_header): New label.
17865 (multiboot_entry): Likewise.
17866 (multiboot_trampoline): Likewise.
17867
17868 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
17869 Increased to 0x4A0.
17870
17871 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
17872 put parentheses after a question mark.
17873 [!GRUB_UTIL] (my_mod): New variable.
17874
17875 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
17876
b2499b29 178772005-09-28 Marco Gerards <mgerards@xs4all.nl>
17878
17879 Adds support for the XFS filesystem. Btrees are not supported
17880 yet.
17881
17882 * fs/xfs.c: New file.
17883
17884 * DISTLIST: Added `fs/xfs.c'.
17885
17886 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
17887 (grub_probefs_SOURCES): Likewise.
17888 (grub_emu_SOURCES): Likewise.
17889 (pkgdata_MODULES): Add `xfs.mod'.
17890 (xfs_mod_SOURCES): New variable.
17891 (xfs_mod_CFLAGS): Likewise.
17892
17893 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
17894 (pkgdata_MODULES): Add `xfs.mod'.
17895 (xfs_mod_SOURCES): New variable.
17896 (xfs_mod_CFLAGS): Likewise.
17897
17898 * util/grub-emu.c (main): Call `grub_xfs_init' and
17899 `grub_xfs_fini'.
17900
17901 * include/grub/fs.h (grub_xfs_init): New prototype.
17902 (grub_xfs_fini): Likewise.
17903
f19dbdb7 17904
83d37a62 179052005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
17906
17907 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
17908 color modes, allow greater than 16 colors to be configured as
17909 a default palette.
17910
47d2d65e 179112005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
17912
17913 * normal/completion.c (complete_arguments): Add the qualifier
17914 const into OPTIONS.
17915
17916 From Omniflux <omniflux+lists@omniflux.com>:
17917 * include/grub/terminfo.h: New file.
17918 * include/grub/tparm.h: Likewise.
17919 * include/grub/i386/pc/serial.h: Likewise.
17920 * term/terminfo.c: Likewise.
17921 * term/tparm.c: Likewise.
17922 * term/i386/pc/serial.c: Likewise.
17923 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
17924 serial.mod.
17925 (terminfo_mod_SOURCES): New variable.
17926 (terminfo_mod_CFLAGS): Likewise.
17927 (serial_mod_SOURCES): Likewise.
17928 (serial_mod_CFLAGS): Likewise.
17929
48b671ff 179302005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
17931
17932 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
17933 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
17934 and kern/powerpc/ieee1275/cmain.c, respectively.
17935
17936 * boot/powerpc/ieee1275/crt0.S: Moved to ...
17937 * kern/powerpc/ieee1275/crt0.S: ... here.
17938
17939 * boot/powerpc/ieee1275/cmain.c: Moved to ...
17940 * kern/powerpc/ieee1275/cmain.c: ... here.
f19dbdb7 17941
48b671ff 17942 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
17943 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
17944 instead of boot/powerpc/ieee1275/crt0.S and
17945 boot/powerpc/ieee1275/cmain.c, respectively.
17946
17947 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
17948 sectors. It was not used anyway.
17949
09fc77a7 179502005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17951
17952 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
17953 `unused parameter' warning.
17954
003789c7 179552005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17956
17957 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
17958 function.
17959 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
17960 getcharwidth.
17961
67f44c86 179622005-08-28 Marco Gerards <metgerards@student.han.nl>
17963
17964 * include/grub/normal.h (enum grub_completion_type): Added
17965 `GRUB_COMPLETION_TYPE_ARGUMENT'.
17966
17967 * normal/cmdline.c (print_completion): Handle
17968 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
17969 * normal/menu_entry.c (store_completion): Likewise.
17970
17971 * normal/completion.c (complete_arguments): New function.
17972 (grub_normal_do_completion): Call `complete_arguments' when the
17973 current words start with a dash.
17974
0b5abe02 179752005-08-27 Marco Gerards <metgerards@student.han.nl>
17976
17977 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
17978 `gzio.mod' instead of `io.mod').
17979
d9864ee1 179802005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
17981
17982 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
17983 (DISTDIRS): Added io and video.
17984 Rewrite the search routine to make an output consistently.
17985
17986 * DISTLIST: Added conf/sparc64-ieee1275.mk,
17987 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
17988 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
17989 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
17990 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
17991 util/powerpc/ieee1275/misc.c.
f19dbdb7 17992
d9864ee1 17993 * include/grub/gzio.h: New file.
17994 * io/gzio.c: Likewise.
f19dbdb7 17995
d9864ee1 17996 * kern/file.c (grub_file_close): Call grub_device_close only if
17997 FILE->DEVICE is not NULL.
17998
17999 * include/grub/mm.h [!NULL] (NULL): New macro.
18000
18001 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
18002
18003 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
18004 (pkgdata_MODULES): Added gzio.mod.
18005 (gzio_mod_SOURCES): New variable.
18006 (gzio_mod_CFLAGS): Likewise.
18007
18008 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
18009 (pkgdata_MODULES): Added gzio.mod.
18010 (gzio_mod_SOURCES): New variable.
18011 (gzio_mod_CFLAGS): Likewise.
18012
18013 * commands/cat.c: Include grub/gzio.h.
18014 (grub_cmd_cat): Use grub_gzfile_open instead of
18015 grub_file_open.
f19dbdb7 18016
d9864ee1 18017 * commands/cmp.c: Include grub/gzio.h.
18018 (grub_cmd_cmp): Use grub_gzfile_open instead of
18019 grub_file_open.
18020
18021 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
18022 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
18023 grub_file_open.
18024 (grub_rescue_cmd_module): Likewise.
18025
fa46f4b5 180262005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
18027
18028 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
18029 kern/sparc64/ieee1275/init.c because it contains _start.
18030 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
18031
e9211b5d 180322005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
18033
18034 * configure.ac: Add support for sparc64 host with ieee1275
18035 firmware.
18036 * configure: Generated from configure.ac.
18037 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
18038 instead of int.
18039 (grub_ofdisk_read): Likewise.
18040 (grub_ofdisk_open): Use %p to print pointer values, and cast the
18041 pointers as (void *) to remove a warning.
18042 (grub_ofdisk_close): Likewise.
18043 (grub_ofdisk_read): Likewise.
18044 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
18045 returns, so make it return void to remove a warning.
18046 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
18047 Corresponding prototype change.
18048 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
18049 values, and cast the pointers as (void *) to remove a warning.
18050 (grub_mm_dump): Likewise.
18051 * conf/sparc64-ieee1275.mk: New file.
18052 * conf/sparc64-ieee1275.rmk: Likewise.
18053 * include/grub/sparc64/setjmp.h: Likewise.
18054 * include/grub/sparc64/types.h: Likewise.
18055 * include/grub/sparc64/ieee1275/console.h: Likewise.
18056 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
18057 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
18058 * include/grub/sparc64/ieee1275/time.h: Likewise.
18059 * kern/sparc64/cache.c: Likewise.
18060 * kern/sparc64/dl.c: Likewise.
18061 * kern/sparc64/ieee1275/init.c: Likewise.
18062 * kern/sparc64/ieee1275/openfw.c: Likewise.
18063
385c6a92 180642005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
18065
18066 * util/console.c (grub_ncurses_putchar): If C is greater than
18067 0x7f, set C to a question mark.
18068 (grub_ncurses_getcharwidth): New function.
18069 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
18070 getcharwidth.
18071
18072 * normal/menu.c (print_entry): Made aware of Unicode. First,
18073 convert TITLE to UCS-4, and predict the cursor position by
18074 grub_getcharwidth.
18075
18076 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
18077 const to SRC.
18078 * kern/misc.c (grub_utf16_to_utf8): Likewise.
18079
16ccb8b1 180802005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
18081
18082 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
18083 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
18084 grub_strcat.
18085
18086 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
18087 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
18088 grub_strcpy and grub_strlen. Take it into account that a space
18089 character is inserted as a delimiter.
18090
6a85ce79 180912005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
18092
18093 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
fe6b695a 18094 invalid magic in the error.
6a85ce79 18095
18096 * commands/search.c: New file.
f19dbdb7 18097
6a85ce79 18098 * util/grub-emu.c (main): Call grub_search_init and
18099 grub_search_fini.
18100
18101 * kern/rescue.c (grub_rescue_print_disks): Removed.
18102 (grub_rescue_print_devices): New function.
18103 (grub_rescue_cmd_ls): Use grub_device_iterate with
18104 grub_rescue_print_devices instead of grub_disk_dev_iterate with
18105 grub_rescue_print_disks.
18106
18107 * kern/partition.c (grub_partition_iterate): Return the result of
18108 PARTMAP->ITERATE instead of GRUB_ERRNO.
18109
18110 * kern/device.c: Include grub/partition.h.
18111 (grub_device_iterate): New function.
18112
18113 * include/grub/partition.h (grub_partition_iterate): Return int
18114 instead of grub_err_t.
18115
18116 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
18117 prototype.
18118 [GRUB_UTIL] (grub_search_fini): Likewise.
18119
18120 * include/grub/device.h (grub_device_iterate): New prototype.
18121
18122 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18123 commands/search.c.
18124 (pkgdata_MODULES): Added search.mod.
18125 (search_mod_SOURCES): New variable.
18126 (search_mod_CFLAGS): Likewise.
18127
18128 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
18129 (pkgdata_MODULES): Added search.mod.
18130 (search_mod_SOURCES): New variable.
18131 (search_mod_CFLAGS): Likewise.
18132
18133 * commands/ls.c (grub_ls_list_disks): Renamed to ...
18134 (grub_ls_list_devices): ... this, and use grub_device_iterate.
18135 All callers changed.
18136
18137 * DISTLIST: Added commands/search.c.
18138
ef095434 181392005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
18140
18141 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
18142 conversion.
18143 (grub_getcharwidth): New function.
18144
18145 * kern/misc.c (grub_utf8_to_ucs4): New function.
18146
18147 * include/grub/term.h (struct grub_term): Added a new member
18148 "getcharwidth".
18149 (grub_getcharwidth): New prototype.
18150
18151 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
18152
18153 * term/i386/pc/console.c (map_char): New function. Segregated from
18154 grub_console_putchar.
18155 (grub_console_putchar): Use map_char.
18156 (grub_console_getcharwidth): New function.
18157 (grub_console_term): Specified grub_console_getcharwidth as
18158 getcharwidth.
18159
18160 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
18161 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
18162
18163 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
18164 GRUB_ERRNO.
18165 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
18166 on grub_strtoul completely.
18167 (write_char): Declare local variables in the beginning of the
18168 function.
18169 (grub_vesafb_getcharwidth): New function.
18170 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
18171 getcharwidth.
18172
1f0a95e4 181732005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
18174
18175 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
18176 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
18177 commands/i386/pc/vbetest.c.
18178
18179 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
18180 call grub_vbe_get_controller_info again, because the returned
18181 information is volatile.
18182 (grub_vbe_set_video_mode): Mostly rewritten.
18183 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
18184 grub_vbe_status_t correctly.
18185 (grub_vbe_get_video_mode_info): Likewise.
18186 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
18187 several if statements.
18188
18189 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
18190 * commands/i386/pc/vbeinfo.c: ... this.
18191
18192 * commands/i386/pc/vbe_test.c: Renamed to ...
18193 * commands/i386/pc/vbetest.c: ... this.
18194
18195 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
18196 ...
18197 (grub_cmd_vbeinfo): ... this. Save video modes before
18198 iterating. Skip a video mode, if it is not available, not enough
18199 information is given or it is monochrome. Show the memory
18200 model. Leave the interpretation of MODEVAR to grub_strtoul
18201 completely.
18202 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
18203 (GRUB_MOD_FINI): Likewise.
18204
18205 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
18206 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
18207 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
18208 duplicated grub_env_get. Leave the interpretation of MODEVAR to
18209 grub_strtoul completely.
18210 (real2pm): Removed.
18211 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
18212 (GRUB_MOD_FINI): Likewise.
18213
18214 * normal/misc.c: Include grub/mm.h.
18215
18216 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
18217 vbe_list_modes with vbetest.mod and vbeinfo.mod.
18218 (vbe_list_modes_mod_SOURCES): Removed.
18219 (vbe_list_modes_mod_CFLAGS): Likewise.
18220 (vbe_test_mod_SOURCES): Likewise.
18221 (vbe_test_mod_CFLAGS): Likewise.
18222 (vbeinfo_mod_SOURCES): New variable.
18223 (vbeinfo_mod_CFLAGS): Likewise.
18224 (vbetest_mod_SOURCES): Likewise.
18225 (vbetest_mod_CFLAGS): Likewise.
18226
992ffbbe 182272005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
18228
18229 * normal/misc.c: New file.
18230
18231 * DISTLIST: Added normal/misc.c.
f19dbdb7 18232
992ffbbe 18233 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
18234 DISK to HOOK. Call HOOK with DISK.
18235 * partmap/apple.c (apple_partition_map_iterate): Likewise.
18236 * partmap/pc.c (pc_partition_map_iterate): Likewise.
18237 * partmap/sun.c (sun_partition_map_iterate): Likewise.
18238
18239 * normal/menu_entry.c (struct screen): Added a new member
18240 "completion_shown".
18241 (completion_buffer): New global variable.
18242 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
18243 (store_completion): New function.
18244 (complete): Likewise.
18245 (clear_completions): Likewise.
18246 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
18247 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
18248 a tab, call complete.
18249
18250 * normal/completion.c (disk_dev): Removed.
18251 (print_simple_completion): Likewise.
18252 (print_partition_completion): Likewise.
18253 (print_func): New global variable.
18254 (add_completion): Do not take the arguments WHAT or PRINT any
18255 longer. Added a new argument TYPE. Instead of printing directly,
18256 call PRINT_FUNC if not NULL.
18257 All callers changed.
18258 (complete_device): Use a local variable DEV instead of
18259 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
18260 (grub_normal_do_completion): Take a new argument HOOK. Do not
18261 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
18262 empty string, return NULL instead.
18263 All callers changed.
18264
18265 * normal/cmdline.c (print_completion): New function.
18266
18267 * kern/partition.c (grub_partition_iterate): Add an argument DISK
18268 to HOOK.
18269 All callers changed.
18270
18271 * kern/disk.c (grub_print_partinfo): Removed.
18272
18273 * include/grub/partition.h (struct grub_partition_map): Add a new
18274 argument DISK into HOOK of ITERATE.
18275 (grub_partition_iterate): Add a new argument DISK to HOOK.
18276
18277 * include/grub/normal.h (enum grub_completion_type): New enum.
18278 (grub_completion_type_t): New type.
18279 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
18280 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
18281 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
18282 (GRUB_COMPLETION_TYPE_FILE): Likewise.
18283 (grub_normal_do_completion): Added a new argument HOOK.
18284 (grub_normal_print_device_info): New prototype.
18285
18286 * include/grub/disk.h (grub_print_partinfo): Removed.
18287
18288 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
18289 (normal_mod_SOURCES): Likewise.
18290 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
18291 (normal_mod_SOURCES): Likewise.
18292
18293 * commands/ls.c (grub_ls_list_disks): Use
18294 grub_normal_print_device_info instead of grub_print_partinfo. Free
18295 PNAME.
18296 (grub_ls_list_files): Use grub_normal_print_device_info instead of
18297 duplicating the code.
18298
0bd41162 182992005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18300
18301 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
f19dbdb7 18302 follow GCS more precisely.
18303 * commands/i386/pc/vbe_test.c: Likewise.
18304 * include/grub/i386/pc/vbe.h: Likewise.
18305 * term/i386/pc/vesafb.c: Likewise.
18306 * video/i386/pc/vbe.c: Likewise.
0bd41162 18307
6323696a 183082005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18309
18310 * DISTLIST: Added term/i386/pc/vesafb.c
18311 DISTLIST: Added video/i386/pc/vbe.c
18312 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
18313 DISTLIST: Added commands/i386/pc/vbe_test.c.
18314 * commands/i386/pc/vbe_list_modes.c: New file.
18315 * commands/i386/pc/vbe_test.c: Likewise.
18316 * term/i386/pc/vesafb.c: Likewise.
18317 * video/i386/pc/vbe.c: Likewise.
18318 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
18319 (grub_vbe_probe) Added prototype.
18320 (grub_vbe_set_video_mode) Likewise.
18321 (grub_vbe_get_video_mode) Likewise.
18322 (grub_vbe_get_video_mode_info) Likewise.
18323 (grub_vbe_set_pixel_rgb) Likewise.
18324 (grub_vbe_set_pixel_index) Likewise.
18325 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
18326 (pkgdata_MODULES): Added vesafb.mod.
18327 (pkgdata_MODULES): Added vbe_list_modes.mod.
18328 (pkgdata_MODULES): Added vbe_test.mod.
18329 (vbe_mod_SOURCES): Added.
18330 (vbe_mod_CFLAGS): Likewise.
18331 (vesafb_mod_SOURCES): Likewise.
18332 (vesafb_mod_CFLAGS): Likewise.
18333 (vbe_list_modes_mod_SOURCES): Likewise.
18334 (vbe_list_modes_mod_CFLAGS): Likewise.
18335 (vbe_test_mod_SOURCES): Likewise.
18336 (vbe_test_mod_CFLAGS): Likewise.
18337
0a74e62f 183382005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
18339
0a74e62f 18340 * normal/command.c (grub_command_execute): If INTERACTIVE is
18341 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
18342 CMDLINE. Disable the pager if INTERACTIVE is true.
18343 All callers are changed.
18344
18345 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
18346 before reading a config file.
18347 * normal/main.c (read_config_file): Even if a command is not
18348 found, register it if it is within an entry.
18349
18350 * util/grub-emu.c: Include sys/types.h and unistd.h.
18351 (options): Added --hold.
18352 (struct arguments): Added a new member "hold".
18353 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
18354 missing.
18355 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
18356 cleared by a debugger, if it is not zero.
18357
18358 * include/grub/normal.h (grub_command_execute): Add an argument
18359 INTERACTIVE.
18360
e51f85ae 183612005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
18362
18363 * DISTLIST: Added include/grub/i386/pc/vbe.h.
18364
e9c6f39b 183652005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
18366
18367 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
18368 program with another one, because the old one didn't detect a bug
18369 in gcc-3.4. Always use regparm 2, because the new test is still
18370 not enough for gcc-4.0. Someone must investigate a simple test
18371 case which detects a bug in gcc-4.0.
18372
8de3495c 183732005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
18374
18375 * DISTLIST: Added normal/completion.c.
18376
18377 * normal/completion.c: New file.
f19dbdb7 18378
8de3495c 18379 * term/i386/pc/console.c (grub_console_getwh): New function.
18380 (grub_console_term): Assign grub_console_getwh to getwh.
18381
18382 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
18383 function is defined in normal/completion.c as
18384 grub_normal_do_completion.
18385 (grub_cmdline_get): Use grub_normal_do_completion instead of
18386 grub_tab_complete.
18387
18388 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
18389 returns non-zero, otherwise return 0.
18390 (grub_partition_iterate): First, probe the partition map. Then,
18391 call ITERATE only for this partition map.
18392
18393 * kern/misc.c (grub_strncmp): Rewritten.
18394
18395 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
18396 returns non-zero. Otherwise return 0.
18397
18398 * include/grub/partition.h (grub_partition_map_iterate): Return
18399 int instead of void.
18400
18401 * include/grub/normal.h (grub_normal_do_completion): New prototype.
18402
18403 * include/grub/misc.h (grub_strncmp): Change the type of N to
18404 grub_size_t.
18405
18406 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
18407 of void.
18408
18409 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
fe6b695a 18410 unsigned explicitly before comparing it with I.
8de3495c 18411
18412 * kern/main.c (grub_env_write_root): Add the attribute unused into
18413 VAR.
18414
18415 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18416 normal/completion.c.
18417 (normal_mod_SOURCES): Likewise.
18418 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
18419 (normal_mod_SOURCES): Likewise.
18420
18421 * normal/command.c (grub_iterate_commands): If ITERATE returns
18422 non-zero, return one immediately.
18423
e85e144b 184242005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
18425
18426 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
18427 * kern/i386/pc/startup.S: Updated Global Descriptor table's
18428 descriptions.
18429 (grub_vbe_get_controller_info): New function.
18430 (grub_vbe_get_mode_info): Likewise.
18431 (grub_vbe_set_mode): Likewise.
18432 (grub_vbe_get_mode): Likewise.
18433 (grub_vbe_set_memory_window): Likewise.
18434 (grub_vbe_get_memory_window): Likewise.
18435 (grub_vbe_set_scanline_length): Likewise.
18436 (grub_vbe_get_scanline_length): Likewise.
18437 (grub_vbe_set_display_start): Likewise.
18438 (grub_vbe_get_display_start): Likewise.
18439 (grub_vbe_set_palette_data): Likewise.
18440 * include/grub/i386/pc/vbe.h: New file.
18441
c46153d2 184422005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18443
18444 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18445 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
18446 * DISTLIST: Likewise.
18447 * kern/ieee1275/of.c: Moved to ...
18448 * kern/ieee1275/ieee1275.c: ... here.
18449
0cb90c45 184502005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18451
18452 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
18453 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
18454 Pass 0 as `end' parameter to grub_strtoul().
18455
a19fb360 184562005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18457
18458 * include/grub/powerpc/ieee1275/console.h: Do not include
18459 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
18460 ifdef.
18461 (grub_console_cur_color): Remove i386-specific prototype.
18462 (grub_console_real_putchar): Likewise.
18463 (grub_console_checkkey): Likewise.
18464 (grub_console_getkey): Likewise.
18465 (grub_console_getxy): Likewise.
18466 (grub_console_gotoxy): Likewise.
18467 (grub_console_cls): Likewise.
18468 (grub_console_setcursor): Likewise.
18469 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
18470 Include <grub/machine/console.h>.
18471 * term/ieee1275/ofconsole.c: Likewise.
18472
4ac9bd04 184732005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
18474
18475 * Makefile.in (LIBLZO): New variable.
18476
18477 * configure.ac: Check for LZO version 2.
18478
18479 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
18480 lzo/lzo1x.h instead of lzo1x.h.
18481
18482 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
18483 of -llzo.
18484
18485 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
18486 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
18487
18488 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
18489 copying the data from PARTITION to P.
18490
f4917dfd 184912005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18492
18493 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
18494 negative, unload the module.
18495
18496 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
18497 map is "pc_partition_map" but not "pc".
18498 (usage): Fix the description. The options are --boot-image and
18499 --core-image but not --boot-file or --core-file.
18500 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
18501 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
18502 DEFAULT_DIRECTORY.
18503
18504 * util/i386/pc/grub-install.in: Do not specify --boot-file or
18505 --core-file. Specify INSTALL_DEVICE as an argument.
18506
18507 * util/console.c: Include config.h.
18508 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
18509 [HAVE_NCURSES_H]: Include ncurses.h.
18510 [HAVE_CURSES_H]: Include curses.h.
18511 [!A_NORMAL] (A_NORMAL): Defined as zero.
18512 [!A_STANDOUT] (A_STANDOUT): Likewise.
18513
18514 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
18515 -lncurses.
18516 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
18517
18518 * configure.ac: Check for curses libraries and headers.
18519
18520 * Makefile.in (LIBCURSES): New variable.
18521
18522 * genmk.rb (Script::rule): Set the executable bits.
18523
18524 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
18525 name of the PC partition map is "pc_partition_map" but not "pc".
18526
0e143073 185272005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18528
18529 * util/i386/pc/grub-install.in (grub_probefs): New variable.
18530 (modules): Likewise.
18531 (usage): Added descriptions for --modules and --grub-probefs.
18532 Handle --modules and --grub-probefs. Save the arguments in MODULES
18533 and GRUB_PROBEFS, respectively.
18534 Auto-detect a filesystem module against GRUBDIR. If the result is
18535 empty and modules are not specified explicitly, abort the
18536 installation. Add the result to MODULES.
18537
18538 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
18539 disk/powerpc/ieee1275/ofdisk.c,
18540 include/grub/powerpc/ieee1275/init.h and
18541 term/powerpc/ieee1275/ofconsole.c.
18542 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
18543 term/ieee1275/ofconsole.c.
18544
18545 * include/grub/powerpc/ieee1275/console.h: Resurrected.
18546
18547 * COPYING: Upgraded to the latest version. Only the address of the
18548 FSF office has changed.
f19dbdb7 18549
efd6e6d5 185502005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18551
18552 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18553 kern/ieee1275.c with kern/ieee1275/of.c.
18554
18555 * kern/ieee1275.c: Moved to ...
18556 * kern/ieee1275/of.c: ... here.
18557
8ceafda2 185582005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
18559
18560 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
fe6b695a 18561 readability.
8ceafda2 18562
18563 * config.guess: Updated to the latest version from gnulib.
18564 * config.sub: Likewise.
18565 * install.sh: Likewise.
18566 * mkinstalldirs: Likewise.
18567
18568 * include/grub/console.h: Removed. This file is arch-specific. Do
18569 not put this in include/grub.
18570
18571 * include/grub/i386/pc/console.h: Resurrected.
18572
18573 * util/console.c: Include grub/machine/console.h instead of
18574 grub/console.h.
18575 * util/grub-emu.c: Likewise.
18576
267f6cd9 185772005-08-04 Marco Gerards <metgerards@student.han.nl>
18578
18579 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
18580 hardcoded value.
f19dbdb7 18581
267f6cd9 18582 From Vincent Pelletier <subdino2004@yahoo.fr>
18583 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
18584 Redefined to use grub_getwh.
18585 (grub_term): New member named getwh.
18586 (grub_getwh): New prototype.
18587 * kern/term.c (grub_getwh): New function.
18588 * term/i386/pc/console.c (grub_console_getwh): New function.
18589 (grub_console_term): New member `getwh'.
18590 * term/i386/pc/vga.c (grub_vga_getwh): New function.
18591 (grub_vga_term): New member `getwh'.
0b5abe02 18592 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
267f6cd9 18593 grub_ssize_t.
18594 (grub_ofconsole_getw): New function.
18595 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
18596 (grub_ofconsole_term): New field named getwh and new initial
18597 value.
18598
3be7266d 185992005-08-03 Hollis Blanchard <hollis@penguinppc.org>
18600
18601 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
18602 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
18603 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
18604 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
18605 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
18606 of <grub/machine/ieee1275.h>.
18607 * commands/ieee1275/reboot.c: Likewise.
18608 * boot/powerpc/ieee1275/ieee1275.c: Move ...
18609 * kern/ieee1275.c: ... to here. All users updated. Change all
18610 parameter structs to use new type `grub_ieee1275_cell_t'.
18611 * term/powerpc/ieee1275/ofconsole.c: Move ...
18612 * term/ieee1275/ofconsole.c: ... to here. All users updated.
18613 * disk/powerpc/ieee1275/ofdisk.c: Move ...
18614 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
18615 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
18616 to return int.
18617 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
18618 Remove unused prototypes. All users updated.
18619 * include/grub/powerpc/ieee1275/console.h: Removed.
18620 * include/grub/powerpc/ieee1275/ieee1275.h: Define
18621 `grub_ieee1275_cell_t'.
18622 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
18623 Cast comparisons with -1 to the correct type.
18624 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
18625 type to match `grub_ieee1275_entry_fn'.
18626
8b5f3938 186272005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
18628
18629 * DISTLIST: Added util/i386/pc/grub-probefs.c.
18630
18631 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
18632 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
18633 partmap/sun.c.
18634 (grub_probefs_SOURCES): New variable.
18635
18636 * util/i386/pc/grub-probefs.c: New file.
18637
18638 * util/i386/pc/grub-setup.c (main): Call
18639 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
18640 grub_hfs_init and grub_jfs_init to initialize the system. Call
18641 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
18642 grub_pc_partition_map_fini to finish the system.
18643
ea409713 186442005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
18645
18646 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
18647 function.
18648 (grub_multiboot_load_elf32): Likewise.
18649 (grub_multiboot_is_elf64): Likewise.
18650 (grub_multiboot_load_elf64): Likewise.
18651 (grub_multiboot_load_elf): Likewise.
18652 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
18653 an ELF32 or ELF64 file.
18654 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
18655
18656 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
18657 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
18658 NULL before calling FS->LABEL.
18659 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
18660 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
18661 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
18662 before calling FS->LABEL.
18663
141a288b 186642005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
18665
18666 * util/i386/pc/grub-install.in (datadir): New variable.
18667 (libdir): Removed.
18668 (pkgdatadir): New variable.
18669 (pkglibdir): Removed.
18670
0d5f8a54 186712005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
18672
18673 * DISTLIST: Added util/i386/pc/grub-install.in.
18674
18675 * util/i386/pc/grub-install.in: New file.
18676
18677 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
18678 (grub_install_SOURCES): Likewise.
18679
18680 * genmk.rb: Added support for scripts.
18681 (Script): New class.
18682 (scripts): New variable.
18683
18684 * Makefile.in (install-local): Install sbin_SCRIPTS by
18685 INSTALL_SCRIPT.
18686 (uninstall): Remove sbin_SCRIPTS.
18687
18688 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
18689 device, try to get a GRUB device by
18690 grub_util_biosdisk_get_grub_dev.
18691 Free DEST_DEV.
18692
18693 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
18694 description for --device-map.
18695
5f968e1e 186962005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18697
18698 Change the semantics of variable hooks. They now return strings
18699 instead of error values.
f19dbdb7 18700
5f968e1e 18701 * util/i386/pc/grub-setup.c: Include grub/env.h.
18702 (setup): Use grub_device_set_root instead of grub_env_set.
18703
18704 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
18705 grub_env_get instead of grub_device_set_root and
18706 grub_device_get_root, respectively.
18707
18708 * kern/main.c (grub_env_write_root): New function.
18709 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
18710 grub_env_set instead of grub_device_set_root.
18711
18712 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
18713 many variables.
18714 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
18715 rather than calling ENV->WRITE_HOOK afterwards.
18716 (grub_env_get): Return the result of ENV->READ_HOOK rather than
18717 passing a pointer of a pointer.
18718 (grub_register_variable_hook): Change the types of "read_hook" and
18719 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
18720 respectively.
18721 Allocate the default empty string on the heap, because this string
18722 may be freed later.
18723
18724 * kern/device.c: Include grub/env.h.
18725 (grub_device_set_root): Removed.
18726 (grub_device_get_root): Likewise.
18727 (grub_device_open): Use grub_env_get instead of
18728 grub_device_get_root.
18729
18730 * include/grub/env.h (grub_env_read_hook_t): New type.
18731 (grub_env_write_hook_t): Likewise.
18732 (grub_env_var): Change the types of "read_hook" and "write_hook"
18733 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
18734 (grub_register_variable_hook): Likewise.
18735
18736 * include/grub/device.h (grub_device_set_root): Removed.
18737 (grub_device_set_root): Likewise.
18738
18739 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
18740 make sure that DIRNAME terminates with '/', so that
18741 grub_fat_find_dir will fail if PATH is not a directory.
18742
18743 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
18744 from DIRNAME.
18745 Use the qualifier auto for print_files and print_files_long.
18746 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
18747 as a regular file.
18748 Put a newline only if there is no error.
18749 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
18750 used.
18751
896f0afd 187522005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18753
18754 * kern/partition.c (grub_partition_probe): Initialize PART to
18755 NULL. Otherwise, when no partition map is registered, this returns
18756 a garbage.
18757
b28b81b2 187582005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
18759
18760 * partmap/apple.c (apple_partition_map_iterate): Check if POS
18761 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
18762 valid.
18763
5f3607e0 187642005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
18765
18766 * commands/ls.c (grub_ls_list_disks): Print the filesystem
18767 information on each device, if it does not have partitions. Print
18768 "Device" instead of "Disk", because this function is not specific
18769 to disk devices.
18770
18771 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
18772 static to ensure that it is put on the memory rather than a
18773 register.
18774
502c87e8 187752005-07-17 Yoshinori Okuji <okuji@enbug.org>
18776
18777 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
18778 (grub_cat_init): Likewise.
18779 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
18780 (options): Likewise.
18781 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
18782 (grub_configfile_init): Likewise.
18783 * font/manager.c (GRUB_MOD_INIT): Likewise.
18784 * commands/help.c (GRUB_MOD_INIT): Likewise.
18785 (grub_help_init): Likewise.
18786 * normal/command.c (grub_command_init): Likewise.
18787 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
18788 * disk/loopback.c (grub_loop_init): Likewise.
18789 (GRUB_MOD_INIT): Likewise.
18790 * commands/ls.c (grub_ls_init): Likewise.
18791 (GRUB_MOD_INIT): Likewise.
18792 (options): Likewise.
18793 * commands/boot.c (grub_boot_init): Likewise.
18794 (GRUB_MOD_INIT): Likewise.
18795 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
18796 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
18797 (GRUB_MOD_INIT): Likewise.
18798 * commands/cmp.c (grub_cmp_init): Likewise.
18799 (GRUB_MOD_INIT): Likewise.
18800
18801 * normal/arg.c: Use <> instead of "" to include header files.
18802 (SHORT_ARG_HELP): New macro.
18803 (SHORT_ARG_USAGE): Likewise.
18804 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
18805 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
18806 descriptions.
18807 (find_short): Check if C is 'h' or 'u' explicitly.
18808 (grub_arg_show_help): Use space characters instead of tabs. Treat
18809 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
18810 are shown with --help and --usage only if they are not used for
18811 the command itself.
18812 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
18813 'h' and 'u'.
18814
18815 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
18816 const into "longarg". Change the type of "shortarg" to int.
18817
f806d18e 188182005-07-17 Yoshinori Okuji <okuji@enbug.org>
18819
18820 * boot/i386/pc/boot.S (boot_drive_check): New label.
18821
18822 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
18823 macro.
18824
18825 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
18826 which do not pass a boot drive correctly. Copied from GRUB Legacy.
18827
e293232b 188282005-07-17 Yoshinori Okuji <okuji@enbug.org>
18829
18830 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
18831 When turning off Gate A20, skip the check and return immediately,
18832 because this is not fatal usually.
18833
ebedfd00 188342005-07-17 Yoshinori Okuji <okuji@enbug.org>
18835
18836 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
18837 be 0x7C00 instead of 0x8000.
18838
18839 * boot/i386/pc/pxeboot.S: Rewritten.
18840
18841 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
18842 EXT_C.
18843 (gate_a20_check_state): Read a byte from 0x108000. Invert the
18844 result.
18845
654fc59f 188462005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
18847
18848 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
18849 robustness. This routine now supports a BIOS call and System
18850 Control Port A to modify the gate A20.
18851
18852 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
18853 Increased to 0x440.
18854
09f9923f 188552005-07-12 Hollis Blanchard <hollis@penguinppc.org>
18856
18857 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
18858 device path and resulting ihandle.
18859 (grub_ofdisk_close): dprintf the ihandle being closed.
18860 (grub_ofdisk_read): dprintf function parameters.
18861 * kern/mm.c (grub_mm_init_region): Likewise.
18862 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
18863 (grub_linux_boot): dprintf the Linux entry point, initrd address and
18864 size, and boot arguments.
18865 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
18866 before loading into memory.
18867 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
18868 before loading into memory.
18869
7ef504d8 188702005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
18871
18872 * kern/mm.c: Added much documentation.
18873 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
18874 8, set to 5 instead of 8.
18875
e0f050c2 188762005-07-10 Yoshinori Okuji <okuji@enbug.org>
18877
18878 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
18879
18880 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
18881 (grub_mkdevicemap_SOURCES): New variable.
18882
18883 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
18884 lib/device.c of GRUB Legacy.
18885
7224189a 188862005-07-10 Yoshinori Okuji <okuji@enbug.org>
18887
18888 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
18889 instead of PATH is NULL.
18890
68c864eb 188912005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
18892
18893 * commands/cmp.c (BUFFER_SIZE): New macro.
18894 (grub_cmd_cmp): Close the right file at the right time. Compare
18895 only data just read. Don't report files of different size as
18896 identical. Dynamically allocate buffers. Move variable
18897 declarations at the beginning of function.
18898
e6f3e614 188992005-07-09 Yoshinori Okuji <okuji@enbug.org>
18900
18901 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
18902 reverse.
18903
f8f1559a 189042004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
18905
18906 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
18907 when backspace is pressed at beginning of line.
18908
39c9d41d 189092005-07-03 Yoshinori Okuji <okuji@enbug.org>
18910
18911 * DISTLIST: Added genfslist.sh.
18912
18913 * normal/main.c (fs_module_list): New variable.
18914 (autoload_fs_module): New function.
18915 (read_fs_list): Likewise.
18916 (grub_normal_execute): Call read_fs_list.
18917
18918 * kern/fs.c (grub_fs_autoload_hook): New variable.
18919 (grub_fs_probe): Added support for auto-loading.
18920
18921 * include/grub/normal.h (struct grub_fs_module_list): New struct.
18922 (grub_fs_module_list_t): New type.
18923
18924 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
18925 (grub_fs_autoload_hook): New prototype.
18926
18927 * genfslist.sh: New file.
f19dbdb7 18928
39c9d41d 18929 * genmk.rb: Added a rule to generate a filesystem list.
18930
121c1d83 189312005-06-30 Marco Gerards <metgerards@student.han.nl>
18932
18933 * configure.ac: Fix the test for cross-compiling.
18934
18935 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
18936 define GRUB_UTIL anymore.
18937
18938 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
18939 so this function works on other systems than just big endian.
18940 (load_modules): Likewise.
18941 (add_segments): Likewise.
18942
e75d76e1 189432005-06-23 Hollis Blanchard <hollis@penguinppc.org>
18944
18945 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
18946 contains `l' modifier, get a long from va_arg().
18947
50b5a0a7 189482005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
18949
18950 * kern/mm.c (grub_free): If the next free block which is being
18951 merged is the first free block, set the first block to the block
18952 being freed.
18953 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
18954
89371b20 189552005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18956
18957 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
18958 `grub_ieee1275_chosen'.
18959
168d6e58 189602005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18961
18962 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
18963 (grub_ieee1275_chosen): New variable.
18964 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
18965 `chosen'.
18966 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
18967 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
18968 Rename first argument to `phandle' for consistency.
18969 (grub_ieee1275_get_property_length): Likewise.
18970 (grub_ieee1275_next_property): Likewise. Change type of first argument
18971 to grub_ieee1275_phandle_t.
18972 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
18973 Move export next to declaration.
18974 (grub_ieee1275_chosen): New variable.
18975 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
18976 Correct cosmetic typo.
18977 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
18978 `grub_ieee1275_chosen'.
18979 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
18980 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
18981 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
18982 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
18983 `grub_ieee1275_chosen'.
18984
ca5baa3f 189852005-05-10 Hollis Blanchard <hollis@penguinppc.org>
18986
18987 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
18988 /chosen/bootargs.
18989 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
18990 /chosen/bootargs as "variable=value" pairs.
18991
708b345f 189922005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
18993
18994 * include/grub/misc.h (grub_dprintf): New macro.
18995 (grub_real_dprintf): New prototype.
18996 (grub_strword): Likewise.
18997 (grub_iswordseparator): Likewise.
18998 * kern/misc.c (grub_real_dprintf): New function.
18999 (grub_strword): Likewise.
19000 (grub_iswordseparator): Likewise.
19001
f4c5e67c 190022005-04-30 Hollis Blanchard <hollis@penguinppc.org>
19003
19004 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
19005 (roundup): Remove macro.
19006 (grub_ieee1275_flags): Make static.
19007 (grub_ieee1275_realmode): Remove.
19008 (grub_ieee1275_test_flag): New function.
19009 (grub_ieee1275_set_flag): Likewise.
19010 (find_options): Rename to `grub_ieee1275_find_options'; update
19011 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
19012 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
19013 (cmain): New prototype.
19014 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
19015 `grub_ieee1275_flags' directly.
19016 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
19017 machine/biosdisk.h.
19018 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
19019 Don't include grub/machine/init.h.
19020 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
19021 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
19022 Remove prototype.
19023 (grub_ieee1275_realmode): Likewise.
19024 (grub_ieee1275_flag): New enum.
19025 (grub_ieee1275_test_flag): New prototype.
19026 (grub_ieee1275_set_flag): New prototype.
19027 * include/grub/powerpc/ieee1275/init.h: Remove file.
19028 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
19029 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
19030 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
19031 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
19032 comment.
19033 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
19034 `grub_ieee1275_test_flag'.
19035 (grub_ieee1275_encode_devname): Likewise.
19036
ed16607e 190372005-04-21 Hollis Blanchard <hollis@penguinppc.org>
19038
19039 * include/grub/powerpc/ieee1275/ieee1275.h
19040 (grub_ieee1275_encode_devname): New prototype.
19041 (grub_ieee1275_get_filename): Likewise.
19042 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
19043 function.
19044 (grub_set_prefix): Likewise.
19045 (grub_machine_init): Call grub_set_prefix.
19046 * kern/powerpc/ieee1275/openfw.c: Fix typos.
19047 (grub_parse_type): New enum.
19048 (grub_ieee1275_get_devargs): New function.
19049 (grub_ieee1275_get_devname): Likewise.
19050 (grub_ieee1275_parse_args): Likewise.
19051 (grub_ieee1275_get_filename): Likewise.
19052 (grub_ieee1275_encode_devname): Likewise.
19053
be369920 190542005-03-30 Marco Gerards <metgerards@student.han.nl>
19055
19056 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
19057 `grub_loader_unset'.
19058
a5ce3a4a 190592005-03-26 Hollis Blanchard <hollis@penguinppc.org>
19060
19061 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
19062 instead of grub_ieee1275_interpret.
19063 (grub_halt_init): New function.
19064 (grub_halt_fini): Likewise.
19065 (GRUB_MOD_INIT): Correct message grammar.
19066 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
19067 instead of grub_ieee1275_interpret.
19068 (grub_reboot_init): New function.
19069 (grub_reboot_fini): Likewise.
19070 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
19071 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
19072 util/i386/pc/misc.c with commands/ieee1275/halt.c,
19073 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
19074 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
19075 function.
19076 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
19077 Add prototype.
19078 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
19079 prototype.
19080 (grub_halt): Likewise.
19081 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
19082 (cmain): Remove __attribute__((unused)).
19083 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
19084 (grub_heap_len): Likewise.
19085 (grub_machine_fini): New function.
19086 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
19087 (grub_halt): Likewise.
19088 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
19089 function.
19090 * util/powerpc/ieee1275/misc.c: New file.
19091
0058f771 190922005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
19093
19094 * DISTLIST: New file.
19095 * gendistlist.sh: Likewise.
f19dbdb7 19096
0058f771 19097 * Makefile.in (COMMON_DISTFILES): Removed.
19098 (BOOT_DISTFILES): Likewise.
19099 (CONF_DISTFILES): Likewise.
19100 (DISK_DISTFILES): Likewise.
19101 (FS_DISTFILES): Likewise.
19102 (INCLUDE_DISTFILES): Likewise.
19103 (KERN_DISTFILES): Likewise.
19104 (LOADER_DISTFILES): Likewise.
19105 (TERM_DISTFILES): Likewise.
19106 (UTIL_DISTFILES): Likewise.
19107 (DISTFILES): Likewise.
19108 (uninstall): Uninstall files in $(pkgdata_DATA).
19109 (DISTLIST): New target.
19110 (distdir): Use the contents of the file DISTLIST to get a list of
19111 distributed files.
19112
46b3b8a5 191132005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
19114
19115 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
19116 descriptor. This is ported from GRUB Legacy.
19117
19118 * gencmdlist.sh: Added an extra semicolon to make it work with
19119 old sed versions. Reported by Robert Bihlmeyer
19120 <robbe@orcus.priv.at>.
19121
5822ff87 191222005-03-08 Yoshinori Okuji <okuji@enbug.org>
19123
19124 Automatic loading of commands is supported.
f19dbdb7 19125
5822ff87 19126 * normal/main.c (read_command_list): New function.
19127 (grub_normal_execute): Call read_command_list.
19128
19129 * normal/command.c (grub_register_command): Return zero or CMD.
19130 Allocate CMD->NAME from the heap.
19131 Initialize CMD->MODULE_NAME to zero.
19132 Find the same name as well. If the same command is found and it is
19133 a dummy command, overwrite members. If it is not a dummy command,
19134 return zero.
19135 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
19136 (grub_command_find): If a dummy command is found, load a module
19137 and retry to find a command only once.
19138
19139 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
19140 make sure that each command is loaded.
19141
19142 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
19143 macro.
19144 (struct grub_command): Remove const from the member `name'.
19145 Add a new member `module_name'.
19146 (grub_register_command): Return grub_command_t.
19147
19148 * commands/help.c (grub_cmd_help): Call grub_command_find to make
19149 sure that each command is loaded.
19150
19151 * genmk.rb (PModule::rule): Specify a module name without the
19152 suffix ".mod" to gencmdlist.sh.
19153
7b1f4b57 191542005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19155
19156 * gencmdlist.sh: New file.
f19dbdb7 19157
7b1f4b57 19158 * genmk.rb (PModule::rule): Generate a rule for a command list.
19159 Clean command.lst.
19160 Generate command.lst from $(COMMANDFILES).
19161
19162 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
19163 (DATA): Added $(pkgdata_DATA).
19164 (install-local): Install files in $(pkgdata_DATA).
19165
062aaf39 191662005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19167
19168 * term/i386/pc/vga.c (debug_command): Removed.
19169 (GRUB_MOD_INIT): Do not register the command "debug".
19170
19171 From Hollis Blanchard:
19172 * commands/configfile.c: New file.
19173 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19174 commands/configfile.c.
19175 (pkgdata_MODULES): Added configfile.mod.
19176 (configfile_mod_SOURCES): New variable.
19177 (configfile_mod_CFLAGS): Likewise.
19178 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
19179 commands/configfile.c.
19180 (pkgdata_MODULES): Added configfile.mod.
19181 (configfile_mod_SOURCES): New variable.
19182 (configfile_mod_CFLAGS): Likewise.
19183 * util/grub-emu.c (main): Call grub_configfile_init and
19184 grub_configfile_fini.
19185 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
19186 prototype.
19187 [GRUB_UTIL] (grub_configfile_fini): Likewise.
f19dbdb7 19188
cee01aa6 191892005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19190
19191 * normal/arg.c (grub_arg_show_help): Do not show the bug report
19192 address.
19193
19194 * commands/help.c (grub_cmd_help): Do not print newlines after
19195 the last command in print_command_help.
19196
93f3a1d8 191972005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19198
19199 * commands/default.h: New file.
19200 * commands/timeout.h: Likewise.
19201 * normal/context.c: Likewise.
f19dbdb7 19202
93f3a1d8 19203 * util/misc.c: Do not include sys/times.h.
19204 Include sys/time.h and grub/machine/time.h.
19205 (grub_get_rtc): Rewritten with gettimeofday.
19206
19207 * util/grub-emu.c (main): Call grub_default_init and
19208 grub_timeout_init before grub_normal_init, and call
19209 grub_timeout_fini and grub_default_fini after grub_main.
19210
19211 * util/console.c (grub_ncurses_checkkey): Return the read
19212 character or -1.
19213
19214 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
19215 timeouts.
19216
19217 * normal/main.c (read_config_file): Push MENU. If this fails,
19218 print an error and wait for a user input.
19219 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
19220 If a menu is empty or an error occurs, pop MENU.
19221 (grub_normal_execute): Pop and free MENU after grub_menu_run
19222 returns.
19223
19224 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
19225
19226 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
19227 include time.h.
19228 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19229 without GRUB_UTIL.
19230 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
19231 time.h.
19232 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19233 without GRUB_UTIL.
19234
19235 * include/grub/normal.h (struct grub_menu_list): New struct.
19236 (grub_menu_list_t): New type.
19237 (struct grub_context): New struct.
19238 (grub_context_t): New type.
19239 (grub_register_command): Got rid of EXPORT_FUNC.
19240 (grub_unregister_command): Likewise.
19241 (grub_context_get): New prototype.
19242 (grub_context_get_current_menu): Likewise.
19243 (grub_context_push_menu): Likewise.
19244 (grub_context_pop_menu): Likewise.
19245 [GRUB_UTIL] (grub_default_init): Likewise.
19246 [GRUB_UTIL] (grub_default_fini): Likewise.
19247 [GRUB_UTIL] (grub_timeout_init): Likewise.
19248 [GRUB_UTIL] (grub_timeout_fini): Likewise.
19249
19250 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
19251 commands/timeout.c and normal/context.c.
19252 (pkgdata_MODULES): Added default.mod and timeout.mod.
19253 (normal_mod_SOURCES): Added normal/context.c.
19254 (default_mod_SOURCES): New variable.
19255 (default_mod_CFLAGS): Likewise.
19256 (timeout_mod_SOURCES): Likewise.
19257 (timeout_mod_CFLAGS): Likewise.
19258 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
19259 conf/i386-pc.rmk.
19260 (pkgdata_MODULES): Added default.mod and timeout.mod.
19261 (normal_mod_SOURCES): Added normal/context.c.
19262 (default_mod_SOURCES): New variable.
19263 (default_mod_CFLAGS): Likewise.
19264 (timeout_mod_SOURCES): Likewise.
19265 (timeout_mod_CFLAGS): Likewise.
19266
19267 * Makefile.in (all-local): Added $(MKFILES).
19268
4ed2e1dd 192692005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
19270
19271 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
19272 (grub_emu_SOURCES): Likewise.
19273 (pkgdata_MODULES): Add `sun.mod'.
19274 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19275 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19276 `partmap/sun.c'.
19277 (pkgdata_MODULES): Add `sun.mod'.
19278 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19279 * include/grub/partition.h (grub_sun_partition_map_init): New
19280 prototype.
19281 (grub_sun_partition_map_fini): Likewise.
19282 * partmap/sun.c: New file.
19283 * util/grub-emu.c (main): Initialize and de-initialize the sun
19284 partitionmap support.
19285
4d4e372e 192862005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
19287
19288 This implements an Emacs-like menu entry editor.
f19dbdb7 19289
4d4e372e 19290 * normal/menu_entry.c: New file.
f19dbdb7 19291
4d4e372e 19292 * util/console.c (grub_ncurses_putchar): Translate some Unicode
19293 characters to ASCII.
19294 (saved_char): New variable.
19295 (grub_ncurses_checkkey): Rewritten completely.
19296 (grub_ncurses_getkey): Likewise.
19297 (grub_ncurses_init): Call raw instead of cbreak.
19298
19299 * normal/menu.c (print_entry): Do not put a space.
19300 (init_page): Renamed to ...
19301 (grub_menu_init_page): ... this. All callers changed.
19302 (edit_menu_entry): Removed.
19303 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
19304
19305 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
19306
19307 * kern/misc.c (grub_vprintf): Call grub_refresh.
19308
19309 * normal/menu.c (DISP_LEFT): Renamed to ...
19310 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
19311 * normal/menu.c (DISP_UP): Renamed to ...
19312 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
19313 * normal/menu.c (DISP_RIGHT): Renamed to ...
19314 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
19315 * normal/menu.c (DISP_DOWN): Renamed to ...
19316 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
19317 * normal/menu.c (DISP_HLINE): Renamed to ...
19318 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
19319 * normal/menu.c (DISP_VLINE): Renamed to ...
19320 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
19321 * normal/menu.c (DISP_UL): Renamed to ...
19322 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
19323 * normal/menu.c (DISP_UR): Renamed to ...
19324 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
19325 * normal/menu.c (DISP_LL): Renamed to ...
19326 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
19327 * normal/menu.c (DISP_LR): Renamed to ...
19328 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
19329 * normal/menu.c (TERM_WIDTH): Renamed to ...
19330 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
19331 * normal/menu.c (TERM_HEIGHT): Renamed to ...
19332 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
19333 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
19334 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
19335 * normal/menu.c (TERM_MARGIN): Renamed to ...
19336 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
19337 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
19338 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
19339 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
19340 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
19341 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
19342 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
19343 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
19344 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
19345 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
19346 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
19347 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
19348 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
19349 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
19350 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
19351 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
19352 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
19353 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
19354 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
19355 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
19356 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
19357 All callers changed.
19358
19359 * include/grub/normal.h: New prototype.
19360
19361 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19362 normal/menu_entry.c.
19363 (normal_mod_SOURCES): Likewise.
19364 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
19365 (normal_mod_SOURCES): Likewise.
19366
e6b92c8a 193672005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
19368
19369 * include/grub/normal.h (grub_halt_init): New prototype.
19370 (grub_halt_fini): Likewise.
19371 (grub_reboot_init): Likewise.
19372 (grub_reboot_fini): Likewise.
19373
19374 * util/grub-emu.c: Include signal.h.
19375 (main_env): New global variable.
19376 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
19377 catch C-c.
19378 (grub_machine_fini): New function.
19379 (main): Call grub_halt_init and grub_reboot_init before
19380 grub_main, and grub_reboot_fini and grub_halt_fini after it.
19381 Call setjmp with MAIN_ENV to go back afterwards.
19382 Call grub_machine_fini right before return.
19383
19384 * include/grub/util/misc.h: Include setjmp.h.
19385 (main_env): New prototype.
19386
19387 * include/grub/kernel.h (grub_machine_fini): New prototype.
19388 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
19389 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
19390
19391 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
19392 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
19393 * term/i386/pc/console.c (grub_console_fini): Likewise.
f19dbdb7 19394
e6b92c8a 19395 * util/i386/pc/misc.c: New file.
f19dbdb7 19396
e6b92c8a 19397 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19398 util/i386/pc/misc.c, commands/i386/pc/halt.c and
19399 commands/i386/pc/reboot.c.
19400
c642636f 194012005-02-14 Guillem Jover <guillem@hadrons.org>
19402
19403 * include/grub/dl.h (grub_dl_check_header): New prototype.
19404 (grub_arch_dl_check_header): Change return type to grub_err_t,
19405 remove size parameter and export function. Update all callers.
19406 * kern/dl.c (grub_dl_check_header): New function.
19407 (grub_dl_load_core): Use `grub_dl_check_header' instead of
19408 `grub_arch_dl_check_header'. Check ELF type. Check if sections
19409 are inside the core.
19410 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
19411 independent ELF header checks.
19412 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19413 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
19414 `grub_dl_check_header' instead of explicit checks. Check for the
19415 ELF type.
19416 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
19417 `grub_dl_check_header' instead of explicit checks. Remove arch
19418 specific ELF header checks.
19419
e6b92c8a 19420 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
19421 argument SIZE.
19422
5eabe94b 194232005-02-13 Hollis Blanchard <hollis@penguinppc.org>
19424
19425 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
19426 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
19427
1b14a681 194282005-02-12 Hollis Blanchard <hollis@penguinppc.org>
19429
19430 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
f19dbdb7 19431 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
1b14a681 19432 (part_map_iterate): Clear `grub_errno' and return 0 if
f19dbdb7 19433 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
1b14a681 19434 * partmap/amiga.c (amiga_partition_map_iterate): Return
19435 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
19436 * partmap/apple.c (apple_partition_map_iterate): Likewise.
19437
aca108aa 194382005-02-01 Guillem Jover <guillem@hadrons.org>
19439
19440 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
19441 help info.
19442
c9f9c556 194432005-01-31 Marco Gerards <metgerards@student.han.nl>
19444
19445 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
19446 Removed prototype.
19447 (grub_rescue_cmd_linux): New prototype.
19448 (grub_rescue_cmd_initrd): Likewise.
19449 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
19450 `bi_rec'.
19451 (grub_linux_release_mem): Release the memory for the initrd.
19452 (grub_load_linux): Renamed from this...
19453 (grub_rescue_cmd_linux): ...To this. Changed all callers.
19454 Changed `entry' not to be static. Loop over memory regions to
19455 find another one when the default fails.
19456 (grub_rescue_cmd_initrd): New function.
19457 (grub_linux_init): Remove function.
19458 (grub_linux_fini): Likewise.
19459 (GRUB_MOD_INIT): Register `initrd'.
19460 (GRUB_MOD_FINI): Unregister `initrd'.
19461 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
19462 Function removed.
19463 (grub_linux_normal_fini): Likewise.
19464 (GRUB_MOD_INIT): Register `initrd'.
19465 (GRUB_MOD_FINI): Unregister `initrd'.
19466
990cf3aa 194672005-01-31 Marco Gerards <metgerards@student.han.nl>
19468
19469 * commands/help.c: New file.
19470 * normal/arg.c (show_help): Renamed to...
19471 (grub_arg_show_help): ... this.
19472 * commands/i386/pc/halt.c: New file.
19473 * commands/i386/pc/reboot.c: Likewise.
19474 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
19475 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
19476 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
19477 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
19478 variables.
19479 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19480 `commands/help.c'.
19481 (pkgdata_MODULES): Add `help.mod'.
19482 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
19483 * grub/i386/pc/init.h (grub_reboot): New prototype.
19484 (grub_halt): Likewise.
19485 * include/grub/normal.h (grub_arg_show_help): New prototype.
19486 (grub_help_init): Likewise.
19487 (grub_help_fini): Likewise.
19488 * util/grub-emu.c (main): Initialize and deinitialize the help
19489 command.
19490
19491 * normal/cmdline.c (grub_cmdline_get): Doc fix.
19492
19493 * normal/command.c (grub_command_init): Fixed the description of
19494 the `set' and `unset' commands.
19495
194962005-01-31 Marco Gerards <metgerards@student.han.nl>
0f79cdc1 19497
19498 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
19499 function.
19500 * commands/ieee1275/halt.c: New file.
19501 * commands/ieee1275/reboot.c: Likewise.
19502 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
19503 `__attribute__ ((unused))'. Some GCS related fixed.
19504 (grub_suspend_init) [GRUB_UTIL]: Function removed.
19505 (grub_suspend_fini): Likewise.
19506 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
19507 and `halt.mod'.
19508 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
19509 (halt_mod_CFLAGS): New variables.
19510 * include/grub/powerpc/ieee1275/ieee1275.h
19511 (grub_ieee1275_interpret): New prototype.
19512
1ab09cc7 195132005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
19514
19515 * include/grub/misc.h (memmove): New prototype.
19516 (memcpy): Likewise.
19517
8b8cbdb2 195182005-01-22 Hollis Blanchard <hollis@penguinppc.org>
19519
19520 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
19521 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
19522
e3741a27 195232005-01-22 Marco Gerards <metgerards@student.han.nl>
19524
19525 * kern/misc.c (grub_strndup): Function rewritten.
19526
776bd780 195272005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
19528
19529 * normal/menu.c (TERM_WIDTH): Macro redefined.
19530 (TERM_TOP_BORDER_Y): Likewise.
19531 (draw_border): Replaced while-loop by a for-loop. Make the number
19532 of lines consistent with the number of lines displayed in
19533 print_entries. Added a margin below the rectangle.
19534 (print_entry): Make the entry fit in the rectangle.
19535 (print_entries): Display the scroll arrows next to the right
19536 border.
19537
78026bce 195382005-01-21 Marco Gerards <metgerards@student.han.nl>
19539
19540 * fs/minix.c (grub_minix_find_file): Reserve more space for
19541 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
19542 `grub_strncpy' to copy `path' into it.
19543
67bbaf0f 195442005-01-21 Marco Gerards <metgerards@student.han.nl>
19545
19546 Add the loopback device, a device via which files can be accessed
19547 as devices.
f19dbdb7 19548
67bbaf0f 19549 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
19550 (pkgdata_MODULES): Add loopback.mod.
19551 (loopback_mod_SOURCES): New variable.
19552 (loopback_mod_CFLAGS): Likewise.
19553 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19554 `disk/loopback.c'.
19555 (pkgdata_MODULES): Add loopback.mod.
19556 (loopback_mod_SOURCES): New variable.
19557 (loopback_mod_CFLAGS): Likewise.
19558 * disk/loopback.c: new file.
19559 * include/grub/normal.h (grub_loop_init): New prototype.
19560 (grub_loop_fini): New prototype.
19561 * util/grub-emu.c (main): Initialize and de-initialize loopback
19562 support.
19563 * include/grub/disk.h (grub_disk_dev_id): Add
19564 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
19565
6f1c18bd 195662005-01-20 Hollis Blanchard <hollis@penguinppc.org>
19567
19568 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
19569 function.
19570 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
19571 (suspend_mod_SOURCES): New variable.
19572 (suspend_mod_CFLAGS): Likewise.
19573 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
19574 New prototype.
19575 * commands/ieee1275/suspend.c: New file.
19576
b38551da 195772005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
19578
19579 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
f19dbdb7 19580 ((unused))' to `__attribute__ ((used))'.
b38551da 19581 (GRUB_MOD_FINI): Likewise.
19582 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
19583 * genmk.rb (PModule): Assign space to common symbols when linking
19584 modules.
19585
777aff39 195862005-01-20 Marco Gerards <metgerards@student.han.nl>
19587
19588 * include/grub/mm.h (grub_mm_init_region): Change the type of the
19589 `unsigned' arguments to `grub_size_t'.
19590 (grub_malloc): Likewise.
19591 (grub_realloc): Likewise.
19592 (grub_memalign): Likewise.
19593 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
19594 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19595 * util/misc.c (grub_malloc): Likewise.
19596 (grub_realloc): Likewise.
19597 * kern/mm.c (get_header_from_pointer): Change the casts to
19598 `unsigned' into a cast to `grub_size_t'.
19599
19600 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
19601 point to `currnode' when `currnode' is changed.
19602
19603 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
19604 Schottelius <nico-linux@schottelius.org>.
19605
d0ff18e1 196062005-01-09 Hollis Blanchard <hollis@penguinppc.org>
19607
19608 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
19609 (note_path): Remove variable.
19610 (GRUB_IEEE1275_NOTE_NAME): New macro.
19611 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
19612 (grub_ieee1275_note_hdr): New structure.
19613 (grub_ieee1275_note_desc): Likewise.
19614 (grub_ieee1275_note): Likewise.
19615 (load_note): Remove `dir' argument. All callers updated. Remove
19616 `note_img' and `path'. Do not load a file from `note_path'.
19617 Initialize a struct grub_ieee1275_note and write that to `out'.
19618 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
19619
4ca7004c 196202005-01-05 Marco Gerards <metgerards@student.han.nl>
19621
19622 * util/misc.c (grub_util_read_image): Revert last change. It
19623 called `grub_util_read_at', which seeks from the beginning of the
19624 file.
19625
0b412211 196262005-01-04 Hollis Blanchard <hollis@penguinppc.org>
19627
19628 * TODO: Add note about endianness in grub-mkimage.
19629 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
19630 section.
19631 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
19632 (grub_mkimage_SOURCES): New target.
19633 * include/grub/kernel.h (grub_start_addr): Remove variable.
19634 (grub_end_addr): Likewise.
19635 (grub_total_module_size): Likewise.
19636 (grub_kernel_image_size): Likewise.
19637 (GRUB_MODULE_MAGIC): New constant.
19638 (grub_module_info): New structure.
19639 (grub_arch_modules_addr): New prototype.
19640 (grub_get_end_addr): Remove prototype.
19641 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
19642 * include/grub/powerpc/ieee1275/kernel.h: New file.
19643 * include/grub/util/misc.h (grub_util_get_fp_size): New
19644 prototype.
19645 (grub_util_read_at): Likewise.
19646 (grub_util_write_image_at): Likewise.
19647 * kern/main.c (grub_get_end_addr): Remove function.
19648 (grub_load_modules): Call grub_arch_modules_addr instead of using
19649 grub_end_addr. Look for a grub_module_info struct in memory. Use
19650 the grub_module_info fields instead of calling grub_get_end_addr
19651 as loop conditions. Move grub_add_unused_region code here.
19652 (grub_add_unused_region): Remove function.
19653 * kern/i386/pc/init.c: Include grub/cache.h.
19654 (grub_machine_init): Remove call to grub_get_end_addr. Remove
19655 one call to add_mem_region.
19656 (grub_arch_modules_addr): New function.
19657 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
19658 (grub_total_module_size): Likewise.
19659 Include grub/machine/kernel.h.
19660 (grub_arch_modules_addr): New function.
19661 * util/grub-emu.c (grub_end_addr): Remove variable.
19662 (grub_total_module_size): Likewise.
19663 (grub_arch_modules_addr): New function.
19664 * util/misc.c: Include unistd.h.
19665 (grub_util_get_fp_size): New function.
19666 (grub_util_read_at): Likewise.
19667 (grub_util_write_image_at): Likewise.
19668 (grub_util_read_image): Call grub_util_read_at.
19669 (grub_util_write_image): Call grub_util_write_image_at.
19670 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
19671 additional memory in kernel_img for a struct grub_module_info.
19672 Fill in that grub_module_info.
19673 * util/powerpc/ieee1275/grub-mkimage.c: New file.
19674
458786f8 196752005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19676
19677 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
19678 New function.
19679 * include/grub/powerpc/ieee1275/ieee1275.h
19680 (grub_ieee1275_milliseconds): New prototype.
19681 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
19682 Change to 1000.
19683 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
19684 grub_ieee1275_milliseconds.
19685
ac507d1b 196862005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19687
19688 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
19689 variable.
19690 (find_options): New function.
19691 (cmain): Call find_options.
19692 * include/grub/powerpc/ieee1275/ieee1275.h
19693 (grub_ieee1275_realmode): New extern variable.
19694 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
19695 grub_map if grub_ieee1275_realmode is false.
19696
6b8fd1c4 196972004-12-29 Marco Gerards <metgerards@student.han.nl>
19698
19699 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
19700 lines are inserted and make it work like readline. Reported by
19701 Vincent Pelletier <subdino2004@yahoo.fr>.
19702
8514a1e0 197032004-12-28 Marco Gerards <metgerards@student.han.nl>
19704
19705 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
19706
19707 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
19708 `kern/powerpc/cache.S'.
19709
924b6140 197102004-12-27 Marco Gerards <metgerards@student.han.nl>
19711
19712 * genmk.rb: Handle the `Program' class in the main loop. Written
19713 by Johan Rydberg <jrydberg@gnu.org>.
19714 (Program): New class.
19715 (programs): New variable.
19716 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
19717 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
19718 instead of "grub/kernel.h". Include <grub/machine/init.h>.
19719 (help_arch): Function removed.
19720 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
19721 `powerpc/libgcc.h' and `loader.h'.
19722 (pkgdata_PROGRAMS): New variable.
19723 (sbin_UTILITIES): Variable removed.
19724 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
19725 (grubof_SOURCES): Variable re-defined so it only includes the
19726 core functionality.
19727 (grubof_CFLAGS): Remove `-DGRUBOF'.
19728 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
19729 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
19730 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
19731 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
19732 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
19733 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
19734 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
19735 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
19736 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
19737 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
19738 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
19739 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
19740 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
19741 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
19742 (pc_mod_CFLAGS): New variables.
19743 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
19744 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
19745 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
19746 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
19747 Moved from here...
19748 * include/grub/i386/pc/init.h (grub_os_area_addr)
19749 (rub_os_area_size): ... to here.
19750 * include/grub/powerpc/ieee1275/ieee1275.h
19751 (grub_ieee1275_entry_fn): Export symbol.
19752 * include/grub/powerpc/ieee1275/init.h: New file.
19753 * include/grub/powerpc/libgcc.h: Likewise.
19754 * include/grub/cache.h: Likewise.
19755 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
19756 <hollis@penguinppc.org>.
19757 * kern/dl.c: Include <grub/cache.h>.
19758 (grub_dl_flush_cache): New function.
19759 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
19760 for this module.
19761 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
19762 (grub_console_init): Removed prototypes.
19763 (grub_machine_init): Don't initialize the modules anymore.
19764 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
19765 static.
19766 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
19767 Macro undef removed.
19768 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
19769 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
19770 relocation `R_PPC_REL32'. Return an error when the relocation is
19771 unknown.
19772 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
19773 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
19774 * util/misc.c (grub_arch_sync_caches): Likewise.
19775
e4b47e0c 197762004-12-19 Marco Gerards <metgerards@student.han.nl>
19777
19778 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
19779 `symlist.c', add `grubof_symlist.c'.
19780 (symlist.c): Variable removed.
19781 (grubof_HEADERS): Variable added.
19782 (grubof_symlist.c): New target.
19783 (kernel_syms.lst): Use `grubof_HEADERS' instead of
19784 `kernel_img_HEADERS'.
19785 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
19786 * kern/powerpc/dl.c: New file.
19787 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
19788 Function removed.
19789 (grub_arch_dl_relocate_symbols): Likewise.
19790 (grub_register_exported_symbols): Likewise.
19791
4ceb3636 197922004-12-13 Marco Gerards <metgerards@student.han.nl>
19793
19794 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
19795 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
19796 to fail instead. Reported by Vincent Pelletier
19797 <subdino2004@yahoo.fr>.
19798
19799 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
19800 it is not allocated. Reported by Vincent Pelletier
19801 <subdino2004@yahoo.fr>.
19802
19803 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
19804 output so the output looks better.
f19dbdb7 19805
3f1578fe 198062004-12-04 Marco Gerards <metgerards@student.han.nl>
19807
19808 Modulize the partition map support and add support for the amiga
19809 partition map.
f19dbdb7 19810
3f1578fe 19811 * commands/ls.c: Include <grub/partition.h> instead of
19812 <grub/machine/partition.h>.
19813 * kern/disk.c: Likewise.
19814 * kern/rescue.c: Likewise.
19815 * loader/i386/pc/chainloader.c: Likewise.
19816 * normal/cmdline.c: Likewise.
19817 * kern/powerpc/ieee1275/init.c: Likewise.
19818 (grub_machine_init): Call `grub_pc_partition_map_init',
19819 `grub_amiga_partition_map_init' and
19820 `grub_apple_partition_map_init'.
19821 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
19822 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
19823 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
19824 `partition.h' and `pc_partition.h'.
19825 (grub_setup_SOURCES): Remove
19826 `disk/i386/pc/partition.c'. Add `kern/partition.c',
19827 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19828 (grub_emu_SOURCES): Likewise.
19829 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
19830 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
19831 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
19832 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19833 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
19834 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19835 (grubof_SOURCES): Likewise.
19836 * disk/i386/pc/partition.c: File removed.
19837 * disk/powerpc/ieee1275/partition.c: Likewise.
19838 * include/grub/powerpc/ieee1275/partition.h: Likewise.
19839 * include/grub/i386/pc/partition.h: Likewise.
19840 * kern/partition.c: New file.
19841 * partmap/amiga.c: Likewise.
19842 * partmap/apple.c: Likewise.
19843 * partmap/pc.c: Likewise.
19844 * include/grub/partition.h: Likewise..
19845 * include/grub/pc_partition.h: Likewise.
19846 * util/grub-emu.c: Include <grub/partition.h> instead of
19847 <grub/machine/partition.h>.
19848 (main): Call `grub_pc_partition_map_init',
19849 `grub_amiga_partition_map_init' and
19850 `grub_apple_partition_map_init' and deinitialize afterwards.
19851 * util/i386/pc/biosdisk.c: Include `#include
19852 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19853 `<grub/machine/partition.h>'.
19854 * util/i386/pc/grub-setup.c: Likewise.
19855 * util/i386/pc/biosdisk.c: Likewise.
19856 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
19857 partition information in case of a PC partition.
19858 * util/i386/pc/grub-setup.c: Include `#include
19859 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19860 `<grub/machine/partition.h>'.
19861 (setup): Only access the PC specific partition information in case
19862 of a PC partition.
19863
0ef4ced9 198642004-11-17 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 19865
0ef4ced9 19866 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
19867 (grub_longjmp): Likewise.
19868 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
19869 20.
19870 * normal/powerpc/setjmp.S: New file.
19871 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
19872 `normal/powerpc/setjmp.S'.
19873 (grubof_CFLAGS): Add `-DGRUBOF'.
19874 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
19875 [GRUB_UTIL && !GRUBOF].
f19dbdb7 19876
19950e29 198772004-11-16 Marco Gerards <metgerards@student.han.nl>
19878
19879 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
19880 property named `name'. Correctly handle the error returned by
19881 `grub_ieee1275_finddevice' if a device can not be opened.
19882
a2fea427 198832004-11-02 Hollis Blanchard <hollis@penguinppc.org>
19884
19885 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
19886 `actual' for negativity.
19887 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19888 kern/fshelp.c.
19889
41ea0ea3 198902004-11-01 Marco Gerards <metgerards@student.han.nl>
19891
19892 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
19893 (PAGE_OFFSET): New macro.
19894 (CRTC_ADDR_PORT): Likewise.
19895 (CRTC_DATA_PORT): Likewise.
19896 (START_ADDR_HIGH_REGISTER): Likewise.
19897 (START_ADDR_LOW_REGISTER): Likewise.
19898 (GRAPHICS_ADDR_PORT): Likewise.
19899 (GRAPHICS_DATA_PORT): Likewise.
19900 (READ_MAP_REGISTER): Likewise.
19901 (INPUT_STATUS1_REGISTER): Likewise.
19902 (INPUT_STATUS1_VERTR_BIT): Likewise.
19903 (page): New variable.
19904 (wait_vretrace): New function.
19905 (set_read_map): Likewise.
19906 (set_start_address): Likewise.
19907 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
19908 the right page.
19909 (check_vga_mem): Take the page into account.
19910 (write_char): Likewise.
19911 (write_cursor): Likewise.
19912 (scroll_up): Likewise. Copy the page to the page that is not
19913 shown and switch between both pages.
19914 (grub_vga_putchar): Fix off by one error.
19915 (grub_vga_cls): Wait for the vertical retrace. Take the page into
19916 account.
19917
ad0bd20b 199182004-11-01 Marco Gerards <metgerards@student.han.nl>
19919
19920 Add support for iso9660 (including rockridge).
f19dbdb7 19921
ad0bd20b 19922 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19923 (iso9660_mod_SOURCES): New variable.
19924 (iso9660_mod_CFLAGS): Likewise.
19925 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19926 * include/grub/fs.h (grub_iso9660_init): New prototype.
19927 * util/grub-emu.c (main): Call `grub_iso9660_init'.
19928 * fs/iso9660.c: New file.
19929
19930 * include/grub/misc.h (grub_strncat): New prototype.
19931 * kern/misc.c (grub_strncat): New function.
f19dbdb7 19932
ad0bd20b 19933 * fs/hfs.c (grub_hfs_mount): Translate the error
19934 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
19935 * fs/jfs.c (grub_jfs_mount): Likewise.
19936 * fs/ufs.c (grub_ufs_mount): Likewise.
19937
a5477a59 199382004-10-28 Hollis Blanchard <hollis@penguinppc.org>
19939
19940 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
19941 which initialized BAT registers.
19942 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
19943 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19944 Move from here...
19945 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
19946 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19947 ... to here.
19948 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
19949 (grub_mapclaim): Likewise.
19950 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
19951 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
19952 hand.
19953
9304c1f8 199542004-10-19 Hollis Blanchard <hollis@penguinppc.org>
19955
19956 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
19957 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
19958 -ffreestanding and -msoft-float.
19959
86f4ae25 199602004-10-15 Hollis Blanchard <hollis@penguinppc.org>
19961
19962 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
19963 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
19964 set in grub_ieee1275_flags.
19965
38912228 199662004-10-14 Hollis Blanchard <hollis@penguinppc.org>
19967
19968 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
19969 prototype.
19970 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
19971 grub_console_init first.
19972 Change the memory range used for grub_ieee1275_claim and
19973 grub_mm_init_region.
19974 Print an error message if the claim fails.
19975 Include <grub/misc.h>.
19976
d1923dc8 199772004-10-13 Hollis Blanchard <hollis@penguinppc.org>
19978
19979 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
19980 Call grub_children_iterate for device nodes of type `scsi',
19981 `ide', or `ata'.
19982 (grub_ofdisk_open): Remove manual device alias resolution.
19983 Fix memory leak when device cannot be opened.
f19dbdb7 19984 * include/grub/powerpc/ieee1275/ieee1275.h
d1923dc8 19985 (grub_children_iterate): New prototype.
19986 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
19987 New function.
19988 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
19989 Return -1 if args.size was -1.
19990
4512e4f3 199912004-10-11 Hollis Blanchard <hollis@penguinppc.org>
19992
19993 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
19994 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
19995 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
19996 Open Firmware's memory for it; claim memory from _start to _end.
19997 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
19998 (_end): New extern.
19999 (_start): Zero BSS from __bss_start to _end.
20000 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
20001 New extern.
20002 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
20003
4d61feb0 200042004-10-11 Hollis Blanchard <hollis@penguinppc.org>
20005
ad0bd20b 20006 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
20007 -1 if args.base was -1.
4d61feb0 20008
026fa2f9 200092004-10-08 Hollis Blanchard <hollis@penguinppc.org>
20010
20011 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
20012 escape sequence instead of a literal ^L. Also call
20013 grub_ofconsole_gotoxy.
20014
9f2220ef 200152004-10-03 Hollis Blanchard <hollis@penguinppc.org>
20016
20017 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
20018 void * arguments to grub_addr_t. All callers updated. Also make
20019 the `result' argument optional.
20020 (grub_ieee1275_release): change void * arguments to grub_addr_t.
20021 All callers updated.
20022
8a572cd7 200232004-09-22 Hollis Blanchard <hollis@penguinppc.org>
20024
20025 * commands/ls.c (grub_ls_list_files): Use the string following the
20026 initial ')', if present, as the filesystem path.
20027 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
20028
20029 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
20030
18aa81f2 200312004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
20032
20033 Make the source code of the menu interface more readable.
f19dbdb7 20034
18aa81f2 20035 * normal/menu.c: Include grub/mm.h.
20036 (TERM_WIDTH): New macro.
20037 (TERM_HEIGHT): Likewise.
20038 (TERM_INFO_HEIGHT): Likewise.
20039 (TERM_MARGIN): Likewise.
20040 (TERM_SCROLL_WIDTH): Likewise.
20041 (TERM_TOP_BORDER_Y): Likewise.
20042 (TERM_LEFT_BORDER_X): Likewise.
20043 (TERM_BORDER_WIDTH): Likewise.
20044 (TERM_MESSAGE_HEIGHT): Likewise.
20045 (TERM_BORDER_HEIGHT): Likewise.
20046 (TERM_NUM_ENTRIES): Likewise.
20047 (TERM_FIRST_ENTRY_Y): Likewise.
20048 (TERM_ENTRY_WIDTH): Likewise.
20049 (TERM_CURSOR_X): Likewise.
20050 (draw_border): Use macros instead of magic numbers.
20051 (print_entry): Likewise.
20052 (print_entries): Likewise.
20053 (run_menu): Likewise. Also, handle the key 'e'.
20054 (run_menu_entry): Ignore empty command lines.
20055 (print_message): Added a new argument EDIT. If EDIT is true,
20056 print a different message.
20057 (init_page): Likewise.
20058 (edit_menu_entry): New function. Not implemented yet.
20059
b47efe30 200602004-09-17 Marco Gerards <metgerards@student.han.nl>
20061
20062 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
20063 can be loaded from normal mode.
f19dbdb7 20064
b47efe30 20065 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
20066 `multiboot.mod'.
20067 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
20068 (multiboot_mod_CFLAGS): New variables.
20069 * loader/i386/pc/linux_normal.c: New file.
f19dbdb7 20070 * loader/i386/pc/multiboot_normal.c: Likewise.
20071
b47efe30 20072 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
20073 attribute `unused'.
f19dbdb7 20074
b47efe30 20075 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
20076 `fdiro' to read the mode information from instead of `diro'.
20077
20078 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
20079 looking up a symlink.
20080
20081 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
20082 macro.
20083 * normal/command.c (grub_command_execute): Don't parse the
20084 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
20085 flags of the command.
20086
20087 * normal/menu.c (grub_menu_run): Fix typo.
20088
da75ac71 200892004-09-14 Hollis Blanchard <hollis@penguinppc.org>
20090
20091 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
20092
20093 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
20094 `y + 1' instead of `y - 1'.
20095
20096 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
f19dbdb7 20097
062b24c2 200982004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
20099
20100 From Hollis Blanchard <hollis@penguinppc.org>:
20101 * kern/misc.c (memmove): New alias for grub_memmove.
20102 (memcmp): New alias for grub_memcmp.
20103 (memset): New alias for grub_memset.
f19dbdb7 20104 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
062b24c2 20105 Change "int handle" to "grub_ieee1275_phandle_t handle".
f19dbdb7 20106 * include/grub/powerpc/ieee1275/ieee1275.h
062b24c2 20107 (grub_ieee1275_get_property): Likewise.
f19dbdb7 20108
8ddad845 201092004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
20110
20111 Added normal mode command `chainloader' as module chain.mod, which
20112 depends on normal.mod and _chain.mod.
f19dbdb7 20113
8ddad845 20114 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
20115 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
20116 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
20117 Deleted prototype.
20118 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
20119 but arguments parsing moved to ...
20120 (grub_chainloader_cmd): ... here. New function.
20121 * include/grub/i386/pc/chainloader.h: New file.
20122 * loader/i386/pc/chainloader_normal.c: Likewise.
20123
2c1f4ce3 201242004-09-11 Marco Gerards <metgerards@student.han.nl>
20125
20126 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
20127 (grub_mkimage_LDFLAGS): Likewise.
20128 (grub_emu_SOURCES): Likewise.
20129 (kernel_img_HEADERS): Added fshelp.h.
20130 * fs/ext2.c: Include <grub/fshelp.h>.
20131 (FILETYPE_REG): New macro.
20132 (FILETYPE_INO_REG): Likewise.
20133 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
20134 Changed all users.
20135 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
20136 all users.
20137 (grub_fshelp_node): New struct.
20138 (grub_ext2_data): Added member `diropen'. Changed member `inode'
20139 to a pointer.
20140 (grub_ext2_get_file_block): Removed function.
20141 (grub_ext2_read_block): New function.
20142 (grub_ext2_read_file): Replaced parameter `data' by `node'.
20143 This function was written.
20144 (grub_ext2_mount): Read the root inode. Create a diropen struct.
20145 (grub_ext2_find_file): Removed function.
20146 (grub_ext2_read_symlink): New function.
20147 (grub_ext2_iterate_dir): Likewise.
20148 (grub_ext2_open): Rewritten.
20149 (grub_ext2_dir): Rewritten.
20150 * include/grub/fshelp.h: New file.
20151 * fs/fshelp.c: Likewise.
20152
3c52136a 201532004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
20154
20155 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
20156 (print_message): Add a missing newline.
20157 (run_menu): Added timeout support.
20158 (run_menu_entry): New local function.
20159 (grub_menu_run): Added support for booting.
20160
20161 * kern/loader.c (grub_loader_is_loaded): New function.
20162
20163 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
20164 (grub_get_rtc): Exported.
20165
20166 * include/grub/i386/pc/time.h: Include grub/symbol.h.
20167 (grub_get_rtc): Exported.
20168
20169 * include/grub/normal.h (struct grub_command_list): Remove
20170 constant from the member `command'.
20171
20172 * include/grub/loader.h (grub_loader_is_loaded): Declared.
20173
20174 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
20175
20176 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
20177
aa033560 201782004-08-28 Marco Gerards <metgerards@student.han.nl>
20179
20180 Add support for the JFS filesystem.
20181
20182 * fs/jfs.c: New file.
20183 * include/grub/fs.h (grub_jfs_init): New prototype.
20184 (grub_jfs_fini): New prototype.
20185 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
20186 (grub_emu_SOURCES): Likewise.
20187 (pkgdata_MODULES): Add jfs.mod.
20188 (jfs_mod_SOURCES): New variable.
20189 (jfs_mod_CFLAGS): Likewise.
20190 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
20191 (grubof_SOURCES): Likewise.
20192 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
20193
20194 * fs/fat.c (grub_fat_find_dir): Convert the filename little
20195 endian to the host endian.
20196 (grub_fat_utf16_to_utf8): Move function from there...
20197 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
fe987087 20198 the endianness of the source string anymore.
aa033560 20199 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
20200
94bc45af 202012004-08-24 Marco Gerards <metgerards@student.han.nl>
20202
20203 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
20204 (grub_boot_fini) [GRUB_UTIL]: Likewise.
20205 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
20206 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
f19dbdb7 20207
94bc45af 20208 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
20209 (grub_hfs_iterate_dir): Make the function static. Add prototypes
20210 for `node_found' and `it_dir'.
20211 (grub_hfs_dir): Add prototype for `dir_hook'.
20212
20213 * fs/minix.c (grub_minix_get_file_block): Add prototype for
20214 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
20215 and `indir32' to silence a gcc warning.
20216
20217 * include/grub/fs.h (grub_hfs_init): New prototype.
20218 (grub_hfs_fini): Likewise.
f19dbdb7 20219
20220
97543f08 202212004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
20222
20223 Each disk device has its own id now. This is useful to make use
20224 of multiple disk devices.
f19dbdb7 20225
97543f08 20226 * include/grub/disk.h (grub_disk_dev_id): New enum.
20227 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
20228 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
20229
20230 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
20231 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20232
20233 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
20234 GRUB_DISK_DEVICE_OFDISK_ID as an id.
20235
20236 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
20237 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20238
20239 * include/grub/disk.h (struct grub_disk_dev): Added a new member
20240 "id" which is used by the cache manager.
20241
20242 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
20243 of just "GRUB".
20244
64372eb4 202452004-08-18 Marco Gerards <metgerards@student.han.nl>
20246
20247 * fs/hfs.c: New file.
20248 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
20249 (grub_emu_SOURCES): Likewise.
20250 (pkgdata_MODULES): Add hfs.mod.
20251 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
20252 (grubof_SOURCES): Likewise.
20253 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
20254
20255 * include/grub/misc.h (grub_strncasecmp): Add prototype.
20256 * kern/misc.c (grub_strncasecmp): Add function.
20257
cc61b58f 202582004-08-14 Marco Gerards <metgerards@student.han.nl>
20259
20260 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
20261 with parentheses.
20262
20263 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
20264 (grub_ext2_dir): In case the directory entry type is unknown, read
20265 it from the inode.
20266
0ef123f6 202672004-08-02 Peter Bruin <pjbruin@dds.nl>
20268
20269 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
20270 grub_load_linux instead of grub_rescue_cmd_linux as second
20271 argument of grub_rescue_register_command.
20272
20273 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
20274
a447c5df 202752004-07-27 Marco Gerards <metgerards@student.han.nl>
20276
20277 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
20278 function.
20279 * commands/boot.c: Remove the check for `GRUB_UTIL'.
20280 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
20281 `loader/powerpc/ieee1275/linux.c',
20282 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
20283 * include/grub/powerpc/ieee1275/ieee1275.h
20284 (grub_ieee1275_release): New prototype.
20285 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
20286 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
20287 normal, boot, linux and linux_normal.
20288 * loader/powerpc/ieee1275/linux.c: New file.
20289 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
20290
5a9e3546 202912004-07-12 Marco Gerards <metgerards@student.han.nl>
20292
20293 * normal/arg.c (grub_arg_parse): Correct error handling after
20294 reallocating the argumentlist (check if `argl' is not null instead
20295 of checking if `args' is not null).
20296 * kern/mm.c (grub_realloc): Return the same pointer when using the
20297 same region, instead of returning the header address.
20298
e15199cb 202992004-07-11 Marco Gerards <metgerards@student.han.nl>
20300
20301 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
20302 one block instead of two when looking for the initial partition.
20303 (grub_partition_probe): Initialize the local variable `p' with 0.
20304 Use base 10 for the grub_strtoul call.
20305 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
20306 need for one local variable.
20307 (grub_strtoul): Don't add the new value to `num', instead of that
20308 just assign it.
20309
020616c2 203102004-07-11 Marco Gerards <metgerards@student.han.nl>
20311
20312 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
20313 (pxeboot_img_SOURCES): New variable.
20314 (pxeboot_img_ASFLAGS): Likewise.
20315 (pxeboot_img_LDFLAGS): Likewise.
20316 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
20317 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
20318 <lode_leroy@hotmail.com>.
20319
6c51eb64 203202004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20321
20322 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
20323 there was no input.
20324
cfb12aff 203252004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20326
20327 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
20328 the history buffer logic.
20329
6eabba74 203302004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20331
20332 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
20333 (FILETYPE_INO_SYMLINK): New macros.
20334 (grub_ext2_find_file): Check if the node is a directory using the
20335 inode stat information instead of using the filetype in the
20336 dirent. Exclude the first character of an absolute symlink.
20337 (grub_ext2_dir): Mask out the filetype part of the mode member of
20338 the inode.
20339
66e19ef8 203402004-05-24 Marco Gerards <metgerards@student.han.nl>
20341
20342 Add support for UFS version 1 and 2. Add support for the minix
20343 filesystem version 1 and 2, both the variants with 14 and 30 long
20344 filenames.
f19dbdb7 20345
66e19ef8 20346 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
20347 fs/minix.c.
20348 (grub_emu_SOURCES): Likewise.
20349 (pkgdata_MODULES): Add ufs.mod and minix.mod.
20350 (ufs_mod_SOURCES): New variable.
20351 (ufs_mod_CFLAGS): Likewise.
20352 (minix_mod_SOURCES): Likewise.
20353 (minix_mod_CFLAGS): Likewise.
20354 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
20355 fs/minix.c.
20356 (grubof_SOURCES): Likewise.
20357 * fs/ufs.c: New file.
20358 * fs/minix.c: New file.
20359 * include/grub/fs.h (grub_ufs_init): New prototype.
20360 (grub_ufs_fini): Likewise.
20361 (grub_minix_init): Likewise.
20362 (grub_minix_fini): Likewise.
20363 * util/grub-emu.c (main): Initialize and deinitialize UFS and
20364 minix fs.
20365
cc2e748a 203662004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
20367
20368 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
20369 commands/ls.c, commands/terminal.c, commands/boot.c,
20370 commands/cmp.c and commands/cat.c.
20371 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
20372
20373 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
20374 "env.h"
20375
4b13b216 203762004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20377
20378 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
20379 and grub_, respectively. Because the conversion is trivial and
20380 mechanical, I omit the details here. Please refer to the CVS
20381 if you need more information.
20382
6a142551 203832004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20384
20385 * include/pupa: Renamed to ...
20386 * include/grub: ... this.
20387 * util/i386/pc/pupa-mkimage.c: Renamed to ...
20388 * util/i386/pc/grub-mkimage.c: ... this.
20389 * util/i386/pc/pupa-setup.c: Renamed to ...
20390 * util/i386/pc/grub-setup.c: ... this.
20391 * util/pupa-emu.c: Renamed to ...
20392 * util/grub-emu.c: ... this.
20393
e56cdf21 203942004-03-29 Marco Gerards <metgerards@student.han.nl>
20395
20396 Add support for the newworld apple macintosh (PPC). This has been
20397 tested on the powerbook 2000 only. It only adds support for
20398 generic ieee1275 functions, console and disk support. This should
20399 be easy to port to other architectures with support for Open
20400 Firmware.
f19dbdb7 20401
e56cdf21 20402 * configure.ac: Accept the powerpc as host_cpu. In the case of
20403 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
20404 specific tests are only executed while building for the i386.
20405 Inverse test for crosscompile.
20406 * genmk.rb (Utility): Allow assembler files.
20407 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
20408 * conf/powerpc-ieee1275.rmk: New file.
20409 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
20410 * disk/powerpc/ieee1275/partition.c: Likewise.
20411 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
20412 * include/pupa/powerpc/ieee1275/console.h: Likewise.
20413 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
20414 * include/pupa/powerpc/ieee1275/time.h: Likewise.
20415 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
20416 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
20417 * include/pupa/powerpc/ieee1275/loader.h
20418 * include/pupa/powerpc/setjmp.h: Likewise.
20419 * include/pupa/powerpc/types.h: Likewise.
20420 * kern/powerpc/ieee1275/init.c: Likewise.
20421 * kern/powerpc/ieee1275/openfw.c: Likewise.
20422 * term/powerpc/ieee1275/ofconsole.c: Likewise.
20423
20424 These files were written by Johan Rydberg
20425 (jrydberg@night.trouble.net) and I only modified them slightly.
f19dbdb7 20426
e56cdf21 20427 * boot/powerpc/ieee1275/cmain.c: New file.
20428 * boot/powerpc/ieee1275/crt0.S: Likewise.
20429 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
20430 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
20431
8c8cc205 204322004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
20433
20434 * Makefile.in: Update copyright.
20435 * genmodsrc.sh: Likewise.
20436 * gensymlist.sh: Likewise.
20437 * term/i386/pc/vga.c: Indent correctly.
20438
20439 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
20440 bugreporting address.
20441 * util/i386/pc/pupa-setup.c (usage): Likewise,
20442 (main): Call pupa_ext2_init and pupa_ext2_fini.
20443
f19dbdb7 20444 * fs/fat.c (log2): Renamed to ...
8c8cc205 20445 (fat_log2): ... this.
20446 All callers changed.
20447 * kern/misc.c (memcpy): Alias to pupa_memmove.
20448 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
20449 lvalue cast.
20450 * util/console.c (pupa_ncurses_fini): Return 0.
20451
20452 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
20453 Move fail label here.
20454 [__GNU__]: Don't warn when using stat.
20455 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
20456 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
20457 long int. Use strtol instead of strtoul.
f19dbdb7 20458
db1771cf 204592004-03-14 Marco Gerards <metgerards@student.han.nl>
20460
20461 * commands/boot.c: New file.
20462 * commands/cat.c: Likewise.
20463 * commands/cmp.c: Likewise.
20464 * commands/ls.c: Likewise.
20465 * commands/terminal.c: Likewise.
20466 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
20467 (pupa_register_command): Changed interface to match the new
20468 argument parser.
20469 (pupa_command_execute): Changed (almost rewritten) so it uses
20470 pupa_split_command. Added support for setting variables using the
20471 syntax `foo=bar'.
20472 (rescue_command): Changed to work with the new argument parser.
20473 (terminal_command): Moved from here to commands/terminal.c.
20474 (set_command): New function.
20475 (unset_command): New function.
20476 (insmod_command): New function.
20477 (rmmod_command): New function.
20478 (lsmod_command): New function.
20479 (pupa_command_init): Don't initialize the command terminal
20480 anymore. Initialize the commands set, unset, insmod, rmmod and
20481 lsmod.
20482 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
20483 (kernel_img_HEADERS): Add arg.h and env.h.
20484 (pupa_mkimage_LDFLAGS): Add kern/env.c.
20485 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
20486 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
20487 normal/arg.c.
20488 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
20489 terminal.mod.
20490 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
20491 (boot_mod_SOURCES): New variable.
20492 (terminal_mod_SOURCES): Likewise.
20493 (ls_mod_SOURCES): Likewise.
20494 (cmp_mod_SOURCES): Likewise.
20495 (cat_mod_SOURCES): Likewise.
20496
20497 * normal/arg.c: New file.
20498 * kern/env.c: Likewise.
20499 * include/pupa/arg.h: Likewise.
20500 * include/pupa/env.h: Likewise.
20501 * font/manager.c (font_command): Changed to match argument parsing
20502 interface changes.
20503 (PUPA_MOD_INIT): Likewise.
20504 * hello/hello.c (pupa_cmd_hello): Likewise.
20505 (PUPA_MOD_INIT): Likewise.
20506 * include/pupa/disk.h: Include <pupa/device.h>.
20507 (pupa_print_partinfo): New prototype.
20508 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
20509 (pupa_dl_get_prefix): Likewise.
20510 * include/pupa/misc.h: Include <pupa/err.h>.
20511 (pupa_isgraph): New prototype.
20512 (pupa_isdigit): Likewise.
20513 (pupa_split_cmdline): Likewise.
20514 * include/pupa/normal.h: Include <pupa/arg.h>.
20515 (pupa_command): Changed the prototype of the member `func' to
20516 match the argument parsing interface. Added member `options'.
20517 (pupa_register_command): Updated to match function.
20518 (pupa_arg_parse): New prototype.
20519 (pupa_hello_init) [PUPA_UTIL]: New prototype.
20520 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
20521 (pupa_ls_init) [PUPA_UTIL]: Likewise.
20522 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
20523 (pupa_cat_init) [PUPA_UTIL]: Likewise.
20524 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
20525 (pupa_boot_init) [PUPA_UTIL]: Likewise.
20526 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
20527 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
20528 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
20529 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
20530 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
20531 * kern/disk.c: Include <pupa/file.h>.
20532 (pupa_print_partinfo): New function.
20533 * kern/dl.c: Include <pupa/env.h>.
20534 (pupa_dl_dir): Variable removed.
20535 (pupa_dl_load): Use the environment variable `prefix' instead of
20536 the variable pupa_dl_dir.
20537 (pupa_dl_set_prefix): Function removed.
20538 (pupa_dl_get_prefix): Likewise.
20539 * kern/i386/pc/init.c: Include <pupa/env.h>.
20540 (pupa_machine_init): Use the environment variable `prefix' instead of
20541 using pupa_dl_set_prefix to set the prefix.
20542 * kern/main.c: Include <pupa/env.h>.
20543 (pupa_set_root_dev): Use the environment variable `prefix' instead of
20544 using pupa_dl_get_prefix to get the prefix.
20545 * kern/misc.c: Include <pupa/env.h>.
20546 (pupa_isdigit): New function.
20547 (pupa_isgraph): Likewise.
20548 (pupa_ftoa): Likewise.
20549 (pupa_vsprintf): Added support for printing values of the type
20550 `double'. Make it possible to format variable output when using
20551 formatting like `%1.2%f'.
20552 (pupa_split_cmdline): New function.
20553 * kern/rescue.c: Include <pupa/env.h>.
20554 (next_word): Removed function.
20555 (pupa_rescue_cmd_prefix): Likewise.
20556 (pupa_rescue_cmd_set): New function.
20557 (pupa_rescue_cmd_unset): New function.
20558 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
20559 split the command line instead of splitting it here. Added
20560 support for setting variables using the syntax `foo=bar'. Don't
20561 initialize the prefix command anymore. Initialized the set and
20562 unset commands.
20563 * normal/cmdline.c: Include <pupa/env.h>.
20564 (pupa_tab_complete): Added prototypes for print_simple_completion,
20565 print_partition_completion, add_completion, iterate_commands,
20566 iterate_dev, iterate_part and iterate_dir. Moved code to print
20567 partition information from here to kern/disk.c.
fe6b695a 20568 (pupa_cmdline_run): Don't check if the function exists anymore.
db1771cf 20569 * normal/main.c: Include <pupa/env.h>.
20570 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
20571 instead of using pupa_dl_get_prefix to get the prefix.
20572 * term/i386/pc/vga.c: Include <pupa/arg.h>.
20573 (check_vga_mem): Cast pointers to `void *' to silence a gcc
20574 warning.
20575 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
20576 (pupa_vga_setcolor): Declare unused variables with `__attribute__
20577 ((unused))' to silence a gcc warning.
20578 (pupa_vga_setcolor): Likewise.
20579 (debug_command): Changed to match argument parsing
20580 interface changes.
20581 * util/pupa-emu.c: Include <pupa/env.h>.
20582 (options): Added 0's for unused fields to silence a gcc warning.
20583 (argp): Likewise.
20584 (main): Use the environment variable `prefix' instead of using
20585 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
20586 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
20587 and terminal.
20588
20589 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
20590 * util/misc.c: Include <malloc.h>.
20591 (pupa_malloc): Rewritten so errors are correctly reported.
20592 (pupa_realloc): Likewise.
20593 (pupa_memalign): Likewise.
20594 (pupa_mm_init_region): Declare unused variables with
20595 `__attribute__ ((unused))' to silence a gcc warning.
20596 * normal/i386/setjmp.S: Remove tab at the end of the file to
20597 silence a gcc warning.
20598 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
20599 variables with `__attribute__ ((unused))' to silence a gcc
20600 warning.
20601 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
20602 local variable i unsigned to silence a gcc warning.
20603
20604 * kern/term.c: Include <pupa/misc.h>.
20605 (pupa_more_lines): New variable.
20606 (pupa_more): Likewise.
20607 (pupa_putcode): When the pager is active pause at the end of every
20608 screen.
20609 (pupa_set_more): New function.
20610 * include/pupa/term.h (pupa_set_more): New prototype.
20611
20612
3b1139cb 206132004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
20614
20615 Now this project is GRUB 2 rather than PUPA. The location of
20616 the CVS repository was moved to GRUB's.
f19dbdb7 20617
3b1139cb 20618 * configure.ac: Use bug-grub as the reporting address.
20619 Use GRUB instead of PUPA.
20620 Change the version number to 1.90.
20621
8367695c 206222004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
20623
20624 * genkernsyms.sh: Updated copyright information.
20625 * genmk.rb: Likewise.
20626 * genmodsrc.sh: Likewise.
20627 * gensymlist.sh: Likewise.
20628 * boot/i386/pc/boot.S: Likewise.
20629 * boot/i386/pc/diskboot.S: Likewise.
20630 * disk/i386/pc/biosdisk.c: Likewise.
20631 * disk/i386/pc/partition.c: Likewise.
20632 * font/manager.c: Likewise.
20633 * fs/ext2.c: Likewise.
20634 * fs/fat.c: Likewise.
20635 * include/pupa/boot.h: Likewise.
20636 * include/pupa/device.h: Likewise.
20637 * include/pupa/disk.h: Likewise.
20638 * include/pupa/dl.h: Likewise.
20639 * include/pupa/elf.h: Likewise.
20640 * include/pupa/err.h: Likewise.
20641 * include/pupa/file.h: Likewise.
20642 * include/pupa/font.h: Likewise.
20643 * include/pupa/fs.h: Likewise.
20644 * include/pupa/kernel.h: Likewise.
20645 * include/pupa/loader.h: Likewise.
20646 * include/pupa/misc.h: Likewise.
20647 * include/pupa/mm.h: Likewise.
20648 * include/pupa/net.h: Likewise.
20649 * include/pupa/normal.h: Likewise.
20650 * include/pupa/rescue.h: Likewise.
20651 * include/pupa/setjmp.h: Likewise.
20652 * include/pupa/symbol.h: Likewise.
20653 * include/pupa/term.h: Likewise.
20654 * include/pupa/types.h: Likewise.
20655 * include/pupa/i386/setjmp.h: Likewise.
20656 * include/pupa/i386/types.h: Likewise.
20657 * include/pupa/i386/pc/biosdisk.h: Likewise.
20658 * include/pupa/i386/pc/boot.h: Likewise.
20659 * include/pupa/i386/pc/console.h: Likewise.
20660 * include/pupa/i386/pc/init.h: Likewise.
20661 * include/pupa/i386/pc/kernel.h: Likewise.
20662 * include/pupa/i386/pc/linux.h: Likewise.
20663 * include/pupa/i386/pc/loader.h: Likewise.
20664 * include/pupa/i386/pc/memory.h: Likewise.
20665 * include/pupa/i386/pc/multiboot.h: Likewise.
20666 * include/pupa/i386/pc/partition.h: Likewise.
20667 * include/pupa/i386/pc/time.h: Likewise.
20668 * include/pupa/i386/pc/vga.h: Likewise.
20669 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
20670 * include/pupa/util/getroot.h: Likewise.
20671 * include/pupa/util/misc.h: Likewise.
20672 * include/pupa/util/resolve.h: Likewise.
20673 * kern/device.c: Likewise.
20674 * kern/disk.c: Likewise.
20675 * kern/dl.c: Likewise.
20676 * kern/err.c: Likewise.
20677 * kern/file.c: Likewise.
20678 * kern/fs.c: Likewise.
20679 * kern/loader.c: Likewise.
20680 * kern/main.c: Likewise.
20681 * kern/misc.c: Likewise.
20682 * kern/mm.c: Likewise.
20683 * kern/rescue.c: Likewise.
20684 * kern/term.c: Likewise.
20685 * kern/i386/dl.c: Likewise.
20686 * kern/i386/pc/init.c: Likewise.
20687 * kern/i386/pc/lzo1x.S: Likewise.
20688 * kern/i386/pc/startup.S: Likewise.
20689 * loader/i386/pc/chainloader.c: Likewise.
20690 * loader/i386/pc/linux.c: Likewise.
20691 * loader/i386/pc/multiboot.c: Likewise.
20692 * normal/cmdline.c: Likewise.
20693 * normal/command.c: Likewise.
20694 * normal/main.c: Likewise.
20695 * normal/menu.c: Likewise.
20696 * normal/i386/setjmp.S: Likewise.
20697 * term/i386/pc/console.c: Likewise.
20698 * term/i386/pc/vga.c: Likewise.
20699 * util/console.c: Likewise.
20700 * util/genmoddep.c: Likewise.
20701 * util/misc.c: Likewise.
20702 * util/pupa-emu.c: Likewise.
20703 * util/resolve.c: Likewise.
20704 * util/unifont2pff.rb: Likewise.
20705 * util/i386/pc/biosdisk.c: Likewise.
20706 * util/i386/pc/getroot.c: Likewise.
20707 * util/i386/pc/pupa-mkimage.c: Likewise.
20708 * util/i386/pc/pupa-setup.c: Likewise.
20709
e6eced71 207102004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
20711
20712 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
20713 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
20714 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
20715 reading and reset it after reading.
20716 (pupa_ext2_close): Return PUPA_ERR_NONE.
20717
20718 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
20719 Correct value.
20720 (struct linux_kernel_header): Add kernel_version and
20721 initrd_addr_max.
20722 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
20723 pupa_file_read succeeds.
20724 (pupa_rescue_cmd_initrd): Implement.
20725
5aded270 207262003-12-03 Marco Gerards <metgerards@student.han.nl>
20727
20728 * fs/ext2.c (pupa_ext2_label): New function.
20729 (pupa_ext2_fs): Added label.
20730 * fs/fat.c (pupa_fat_label): New function.
20731 (pupa_fat_fs): Added label.
20732 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
20733
20734 * kern/misc.c (pupa_strndup): New function.
20735 * include/pupa/misc.h (pupa_strndup): New prototype.
20736
20737 * include/pupa/normal.h: Include <pupa/err.h>.
20738 (pupa_set_history): New prototype.
20739 (pupa_iterate_commands): New prototype.
20740 * normal/cmdline.c: Include <pupa/machine/partition.h>,
20741 <pupa/disk.h>, <pupa/file.h>.
20742 (hist_size): New variable.
20743 (hist_lines): Likewise.
20744 (hist_end): Likewise.
20745 (hist_used): Likewise.
20746 (pupa_set_history): New function.
20747 (pupa_history_get): Likewise.
20748 (pupa_history_add): Likewise.
20749 (pupa_history_replace): Likewise.
20750 (pupa_tab_complete): Likewise.
20751 (pupa_cmdline_run): Added tab completion and history buffer. Tab
20752 completion shows partitionnames while completing partitions, this
20753 feature was suggested by Jeff Bailey.
20754 * normal/command.c (pupa_iterate_commands): New function.
20755 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
20756 (pupa_normal_init): Initialize history buffer.
20757 (PUPA_MOD_INIT): Likewise.
20758 (pupa_normal_fini): Free the history buffer.
20759 (PUPA_MOD_FINI): Likewise.
20760
20761 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
20762 key.
20763
20764 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
20765 * configure.ac [i386]: Check for regparam bug.
20766 (NESTED_FUNC_ATTR) [! i386]: Defined.
20767
1f7315a3 207682003-11-17 Marco Gerards <metgerards@student.han.nl>
20769
20770 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
20771 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
20772 (pupa_emu_SOURCES): New variable.
20773 (pupa_emu_LDFLAGS): Likewise.
20774 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
20775 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
20776 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
20777 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20778 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
20779 (pupa_jmp_buf): New typedef.
20780 (pupa_setjmp) [PUPA_UTIL]: New macro.
20781 (pupa_longjmp) [PUPA_UTIL]: Likewise.
20782 * include/pupa/term.h (struct pupa_term): New member `refresh'.
20783 (pupa_refresh): New prototype.
20784 * include/pupa/util/getroot.h: New file.
20785 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
20786 it.
20787 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
20788 (pupa_rescue_cmd_cat): Likewise.
20789 (pupa_rescue_cmd_ls): Likewise.
20790 (pupa_rescue_cmd_testload): Likewise.
20791 (pupa_rescue_cmd_lsmod): Likewise.
20792 * normal/cmdline.c (pupa_cmdline_get): Likewise.
20793 * normal/menu.c (run_menu): Likewise.
20794 * kern/term.c (pupa_cls): Likewise.
20795 (pupa_refresh): New function.
20796 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
20797 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20798 * util/console.c: New file.
f19dbdb7 20799
1f7315a3 20800 * util/i386/pc/getroot.c: New file.
20801 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
20802 (pupa_putchar): New function.
20803 (pupa_refresh): Likewise.
20804 (xgetcwd): Function moved to ...
20805 (strip_extra_slashes): Likewise.
20806 (get_prefix): Likewise.
f19dbdb7 20807 * util/i386/pc/getroot.c: ... here.
1f7315a3 20808 (find_root_device): Function moved and renamed to...
20809 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
20810 Changed all callers.
20811 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
20812 and renamed to...
20813 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
20814 Changed all callers.
20815 * util/misc.c (pupa_memalign): New function.
20816 (pupa_mm_init_region): Likewise.
20817 (pupa_register_exported_symbols): Likewise.
20818 (pupa_putchar): Function removed.
20819 * util/pupa-emu.c: New file.
20820
9a5c1ade 208212003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
20822
20823 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
20824 (_multiboot_mod_SOURCES): New variable.
20825 (_multiboot_mod_CFLAGS): Likewise.
20826 * loader/i386/pc/multiboot.c: New file.
20827 * include/pupa/i386/pc/multiboot.h: Likewise.
20828 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
20829 (pupa_multiboot_real_boot): New function.
20830 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
20831 (pupa_multiboot_real_boot): New prototype.
20832 (pupa_rescue_cmd_multiboot): Likewise
20833 (pupa_rescue_cmd_module): Likewise.
20834
20835 * kern/loader.c (pupa_loader_set): Continue when
20836 pupa_loader_unload_func() fails.
20837 (pupa_loader_unset): New function.
20838 * include/pupa/loader.h (pupa_loader_unset): New prototype.
20839
20840 * kern/misc.c (pupa_stpcpy): New function.
20841 * include/pupa/misc.h (pupa_stpcpy): New prototype.
20842
8e72a9c0 208432003-11-12 Marco Gerards <metgerards@student.han.nl>
20844
20845 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
20846 for available extensions.
20847
20848 * include/pupa/i386/pc/time.h: New file.
20849 * kern/disk.c: Include <pupa/machine/time.h>.
20850 (PUPA_CACHE_TIMEOUT): New macro.
20851 (pupa_last_time): New variable.
20852 (pupa_disk_open): Flush the cache when there was a timeout.
20853 (pupa_disk_close): Reset the timer.
20854 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
20855 pupa_currticks.
20856 * util/misc.c: Include <sys/times.h>
20857 (pupa_get_rtc): New function.
20858
c4adbd32 208592003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
20860
20861 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
20862 as blocks.
20863 (pupa_ext2_get_file_block): Use blocks member.
20864
20865 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
20866 first block. Return -1 instead of pupa_errno on error.
20867
bfd30f06 208682003-10-27 Marco Gerards <metgerards@student.han.nl>
20869
20870 * README: In the pupa-mkimage example use _chain instead of chain
20871 and ext2 instead of fat.
20872 * TODO: Replace ext2fs with jfs as an example. Add an item for
20873 adding journal playback for ext2fs.
20874 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
20875 (pkgdata_MODULES): Added ext2.mod.
20876 (ext2_mod_SOURCES): New variable.
20877 (ext2_mod_CFLAGS): Likewise.
20878 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
20879 * include/pupa/misc.h (pupa_strncpy): New prototype.
20880 (pupa_strcat): Likewise.
20881 (pupa_strncmp): Likewise.
20882 * kern/misc.c (pupa_strcat): Enable function.
20883 (pupa_strncpy): New function.
20884 (pupa_strncmp): Likewise.
20885 * fs/ext2.c: New file.
f19dbdb7 20886
bfd30f06 20887 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
20888 when the read failed before retrying.
20889 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
20890 (_FILE_OFFSET_BITS): Likewise.
20891 * configure.ac: Added AC_SYS_LARGEFILE.
20892
98d15063 208932003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20894
20895 * genmk.rb (PModule#rule): Make sure to get only symbol names
20896 from the output of nm.
20897 Reported by Robert Millan <zeratul2@wanadoo.es>.
20898
18d9c7cd 208992003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20900
20901 I forgot to check in these changes for a long time. This adds
20902 incomplete support for VGA console, and this is still very
20903 buggy. Also, a lot of consideration is required for I18N,
20904 UNICODE, and VGA font issues. Therefore, assume that this is
20905 such that "better than nothing".
f19dbdb7 20906
18d9c7cd 20907 * font/manager.c: New file.
20908 * include/pupa/font.h: Likewise.
20909 * include/pupa/i386/pc/vga.h: Likewise.
20910 * term/i386/pc/vga.c: Likewise.
20911 * util/unifont2pff.rb: Likewise.
20912
20913 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
20914 (pkgdata_MODULES): Added vga.mod and font.mod.
20915 (vga_mod_SOURCES): New variables.
20916 (vga_mod_CFLAGS): Likewise.
20917 (font_mod_SOURCES): Likewise.
20918 (font_mod_CFLAGS): Likewise.
20919
20920 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
20921
20922 * include/pupa/term.h: Include pupa/err.h.
f19dbdb7 20923 (struct pupa_term): Added init and fini.
18d9c7cd 20924 Changed the argument of putchar to pupa_uint32_t.
20925
20926 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
20927 (pupa_console_real_putchar): New prototype.
20928 (pupa_console_putchar): Removed.
20929 (pupa_console_checkkey): Exported.
20930 (pupa_console_getkey): Likewise.
20931
20932 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
20933 characters.
20934
20935 * kern/term.c (pupa_term_set_current): Rewritten.
20936 (pupa_putchar): Likewise.
20937 (pupa_putcode): New function.
20938
20939 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
20940 (pupa_console_real_putchar): ... this.
20941 (pupa_vga_set_mode): New function.
20942 (pupa_vga_get_font): Likewise.
20943
20944 * normal/command.c: Include pupa/term.h.
20945 (terminal_command): New function.
20946 (pupa_command_init): Register the command "terminal".
20947
20948 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
20949 (DISP_UP): Likewise.
20950 (DISP_RIGHT): Likewise.
20951 (DISP_DOWN): Likewise.
20952 (DISP_HLINE): Likewise.
20953 (DISP_VLINE): Likewise.
20954 (DISP_UL): Likewise.
20955 (DISP_UR): Likewise.
20956 (DISP_LL): Likewise.
20957 (DISP_LR): Likewise.
20958
20959 * term/i386/pc/console.c (pupa_console_putchar): New function.
f19dbdb7 20960
977329f5 209612003-02-08 NIIBE Yutaka <gniibe@m17n.org>
20962
20963 * util/resolve.c (pupa_util_resolve_dependencies): BUG
20964 FIX. Reverse the path_list.
20965
20966 * include/pupa/normal.h: Export pupa_register_command and
20967 pupa_unregister_command.
20968
20969 * hello/hello.c (pupa_cmd_hello): New module.
20970 * conf/i386-pc.rmk: Added hello.mod.
20971
1f5ab428 209722003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
20973
20974 * kern/i386/pc/lzo1x.S: New file.
f19dbdb7 20975
1f5ab428 20976 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
20977 (compress_kernel): New variable.
20978 (generate_image): Heavily modified to support compressing a
20979 large part of the core image.
20980
20981 * util/misc.c (pupa_util_read_image): Fix a file descriptor
20982 leak.
20983 (pupa_util_load_image): New function.
20984
20985 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
20986 (pupa_compressed_size): New variable.
20987 (codestart): Enable Gate A20 here.
20988 Decompress the compressed part of the core image.
20989 Rearrange the code to put functions and variables which are
20990 required for initialization in the non-compressed part.
20991 Include lzo1x.S.
20992
20993 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
20994 here.
20995
20996 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
20997
f19dbdb7 20998 * include/pupa/i386/pc/kernel.h
1f5ab428 20999 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
21000 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
21001 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
21002 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
21003 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
21004
21005 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
21006
21007 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
21008 (Utility#rule): Likewise.
21009
21010 * configure.ac: Check if LZO is available.
21011
ce5bf700 210122003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
21013
21014 * include/pupa/normal.h: New file.
21015 * include/pupa/setjmp.h: Likewise.
21016 * include/pupa/i386/setjmp.h: Likewise.
21017 * normal/cmdline.c: Likewise.
21018 * normal/command.c: Likewise.
21019 * normal/main.c: Likewise.
21020 * normal/menu.c: Likewise.
21021 * normal/i386/setjmp.S: Likewise.
f19dbdb7 21022
ce5bf700 21023 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
21024 (pupa_rescue_cmd_initrd): Likewise.
21025
21026 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
21027 Likewise.
21028
21029 * kern/i386/pc/startup.S (translation_table): New variable.
21030 (translate_keycode): New function.
21031 (pupa_console_getkey): Call translate_keycode.
21032
21033 * kern/rescue.c (attempt_normal_mode): New function.
21034 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
21035 it failed, print a message.
21036
21037 * kern/mm.c (pupa_real_malloc): Print more information when a
21038 free magic is broken.
21039 (pupa_free): If the first free header is not free actually, set
21040 it to P.
21041
21042 * kern/main.c (pupa_load_normal_mode): Just load the module
21043 "normal".
21044 (pupa_main): Don't print the message
21045 "Entering into rescue mode..." here.
21046
21047 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
21048 Declared.
21049 (pupa_rescue_cmd_initrd): Likewise.
21050 (pupa_rescue_cmd_initrd): Likewise.
21051
21052 * include/pupa/symbol.h (FUNCTION): Specify the type.
21053 (VARIABLE): Likewise.
21054
21055 * include/pupa/err.h (pupa_err_t): Added
21056 PUPA_ERR_UNKNOWN_COMMAND.
21057
21058 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
21059 (pupa_dl_get_prefix): Likewise.
21060
21061 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
21062 Added _chain.mod and _linux.mod instead of chain.mod and
21063 linux.mod.
21064 (chain_mod_SOURCES): Renamed to ...
21065 (_chain_mod_SOURCES): ... this.
21066 (chain_mod_CFLAGS): Renamed to ...
21067 (_chain_mod_CFLAGS): ... this.
21068 (linux_mod_SOURCES): Renamed to ...
21069 (_linux_mod_SOURCES): ... this.
21070 (linux_mod_CFLAGS): Renamed to ...
21071 (_linux_mod_CFLAGS): ... this.
21072 (normal_mod_SOURCES): New variable.
21073 (normal_mod_CFLAGS): Likewise.
21074 (normal_mod_ASFLAGS): Likewise.
21075
210762003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
21077
21078 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
21079 possible.
21080
fe6b695a 21081 * kern/dl.c (pupa_dl_ref): Refer depending modules
ce5bf700 21082 recursively.
21083 (pupa_dl_unref): Unrefer depending modules recursively.
21084 Don't call pupa_dl_unload implicitly, because PUPA can crash if
21085 a module is unloaded before one depending on that module is
21086 unloaded.
21087 (pupa_dl_unload): Unload depending modules explicitly,
21088 if possible.
21089
c04da074 210902003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
21091
21092 * include/pupa/i386/pc/linux.h: New file.
21093 * loader/i386/pc/linux.c: Likewise.
f19dbdb7 21094
c04da074 21095 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
21096 Removed.
21097 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
21098 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
21099 of PUPA_CHAINLOADER_BOOT_SECTOR.
21100
21101 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
21102 (pupa_linux_prot_size): New variable.
21103 (pupa_linux_tmp_addr): Likewise.
21104 (pupa_linux_real_addr): Likewise.
21105 (pupa_linux_boot_zimage): New function.
21106 (pupa_linux_boot_bzimage): Likewise.
21107
21108 * kern/i386/pc/init.c (struct mem_region): New structure.
21109 (MAX_REGIONS): New macro.
21110 (mem_regions): New variable.
21111 (num_regions): Likewise.
21112 (pupa_os_area_addr): Likewise.
21113 (pupa_os_area_size): Likewise.
21114 (pupa_lower_mem): Likewise.
21115 (pupa_upper_mem): Likewise.
21116 (add_mem_region): New function.
21117 (compact_mem_regions): Likewise.
21118 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
21119 the size of the conventional memory and that of so-called upper
21120 memory (before the first memory hole).
21121 Instead of adding each found region to free memory, use
21122 add_mem_region and add them after removing overlaps.
21123 Also, add only 1/4 of the upper memory to free memory. The rest
21124 is used for loading OS images. Maybe this is ad hoc, but this
21125 makes it much easier to relocate OS images when booting.
21126
21127 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
21128 (pupa_enter_rescue_mode): Don't register initrd and module.
21129
21130 * kern/mm.c: Include pupa/dl.h.
21131
21132 * kern/main.c: Include pupa/file.h and pupa/device.h.
21133
21134 * kern/loader.c (pupa_loader_load_module_func): Removed.
21135 (pupa_loader_load_module): Likewise.
21136
21137 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
21138 ``.o''.
21139
21140 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
21141 (pupa_linux_tmp_addr): Likewise.
21142 (pupa_linux_real_addr): Likewise.
21143 (pupa_linux_boot_zimage): Likewise.
21144 (pupa_linux_boot_bzimage): Likewise.
21145
21146 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
21147 (pupa_upper_mem): Likewise.
21148 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
21149 module is too dangerous.
21150
21151 * include/pupa/loader.h (pupa_os_area_addr): Declared.
21152 (pupa_os_area_size): Likewise.
21153 (pupa_loader_set): Remove the first argument. Loader doesn't
21154 manage modules or initrd any longer.
21155 (pupa_loader_load_module): Removed.
21156
21157 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
21158 (linux_mod_SOURCES): New variable.
21159 (linux_mod_CFLAGS): Likewise.
21160
a13f9237 211612003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
21162
21163 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
21164 the length of a blocklist correctly.
21165
21166 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
21167 Use ioctl only if the OS file is a block device.
21168 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
21169 not very useful for normal files.
21170
21171 * kern/main.c (pupa_set_root_dev): New function.
21172 (pupa_load_normal_mode): Likewise.
21173 (pupa_main): Call those above.
21174
21175 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
21176 pupa_uint16_t.
21177
21178 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
21179
a5ffe966 211802003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
21181
21182 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
21183 (setup): Configure the installed partition information and the
21184 dl prefix.
21185
21186 * loader/i386/pc/chainloader.c (my_mod): New variable.
21187 (pupa_chainloader_unload): New function.
21188 (pupa_rescue_cmd_chainloader): Refer itself.
21189 (PUPA_MOD_INIT): Save its own module in MY_MOD.
21190
21191 * kern/i386/pc/startup.S (install_partition): Removed.
21192 (version_string): Likewise.
21193 (config_file): Likewise.
21194 (pupa_install_dos_part): New variable.
21195 (pupa_install_bsd_part): Likewise.
21196 (pupa_prefix): Likewise.
21197 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
21198
21199 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
21200 and pupa/misc.h.
21201 (make_install_device): New function.
21202 (pupa_machine_init): Set the dl prefix.
21203
21204 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
21205 (buf): Renamed to ...
21206 (linebuf): ... this.
21207 (pupa_rescue_cmd_prefix): New function.
21208 (pupa_rescue_cmd_insmod): Likewise.
21209 (pupa_rescue_cmd_rmmod): Likewise.
21210 (pupa_rescue_cmd_lsmod): Likewise.
21211 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
21212 rmmod and lsmod.
21213
21214 * kern/mm.c (pupa_memalign): If failed even after invalidating
21215 disk caches, unload unneeded modules and retry.
21216
21217 * kern/misc.c (pupa_memmove): New function.
21218 (pupa_memcpy): Removed.
21219 (pupa_strcpy): New function.
21220 (pupa_itoa): Made static.
21221
21222 * kern/dl.c (pupa_dl_iterate): New function.
21223 (pupa_dl_ref): Likewise.
21224 (pupa_dl_unref): Likewise.
21225 (pupa_dl_unload): Return if succeeded or not.
21226 (pupa_dl_unload_unneeded): New function.
21227 (pupa_dl_unload_all): Likewise.
21228 (pupa_dl_init): Renamed to ...
21229 (pupa_dl_set_prefix): ... this.
21230 (pupa_dl_get_prefix): New function.
21231
21232 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
21233 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
21234 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
21235 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
21236 (pupa_install_dos_part): Declared.
21237 (pupa_install_bsd_part): Likewise.
21238 (pupa_prefix): Likewise.
21239 (pupa_boot_drive): Likewise.
21240
21241 * include/pupa/types.h: Fix a typo.
21242
21243 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
21244 pupa_memmove.
21245 (pupa_memmove): Declared.
21246 (pupa_strcpy): Likewise.
21247
21248 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
21249 pupa_mod_init takes one argument, its own module.
21250 (pupa_dl_unload_unneeded): Declared.
21251 (pupa_dl_unload_all): Likewise.
21252 (pupa_dl_ref): Likewise.
21253 (pupa_dl_unref): Likewise.
21254 (pupa_dl_iterate): Likewise.
21255 (pupa_dl_init): Renamed to ...
21256 (pupa_dl_set_prefix): ... this.
21257 (pupa_dl_get_prefix): Declared.
21258
21259 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
f19dbdb7 21260 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
a5ffe966 21261 unloaded.
21262 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
21263 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
21264
21265 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
21266 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
21267
012d7999 212682003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21269
21270 * util/i386/pc/pupa-setup.c (setup): Define the internal
21271 function find_first_partition_start at the top level, because GCC
21272 3.0.x cannot compile internal functions in deeper scopes
21273 correctly.
21274 (find_root_device): Use lstat instead of stat.
21275 Don't follow symbolic links.
21276 Fix the path-constructing code.
21277
21278 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
21279 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
21280 by a BLKGETSIZE ioctl first, because block devices don't fill
21281 the member st_mode of the structure stat on Linux.
21282 [__linux__] (linux_find_partition): Use a temporary buffer
21283 REAL_DEV for the working space. Copy it to DEV before returning.
21284 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
21285 buffer cache consistent.
21286 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
21287 strncmp. The previous value was merely wrong.
21288 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
21289
21290 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
21291 FAT size is 12. The previous value was merely wrong.
21292
21293 * kern/main.c (pupa_main): Don't split the starting message from
21294 newlines.
21295
21296 * kern/term.c (pupa_putchar): Put CR after LF instead of before
21297 LF, because BIOS goes crazy about character attributes in this
21298 case.
21299
1cc73a62 213002003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21301
21302 * include/i386/pc/util/biosdisk.h: New file.
21303 * util/i386/pc/biosdisk.c: Likewise.
21304 * util/i386/pc/pupa-setup.c: Likewise.
f19dbdb7 21305
1cc73a62 21306 * Makefile.in (INCLUDE_DISTFILES): Added
21307 include/pupa/i386/pc/util/biosdisk.h.
21308 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
21309 directory util/i386/pc.
21310 (install-local): Added a rule for sbin_UTILITIES.
21311 (uninstall): Likewise.
21312
21313 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
21314
21315 * util/misc.c (xrealloc): New function.
21316 (pupa_malloc): Likewise.
21317 (pupa_free): Likewise.
21318 (pupa_realloc): Likewise.
21319 (pupa_stop): Likewise.
21320 (pupa_putchar): Likewise.
21321
21322 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
21323
21324 * include/pupa/util/misc.h (xrealloc): Declared.
21325
21326 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
21327 macro.
21328 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
21329 (PUPA_BOOT_MACHINE_BPB_END): ... this.
21330
21331 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
21332 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21333
21334 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
21335 way should be implemented.
21336 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21337
21338 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
21339 the size of NAME for safety.
21340 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
21341 0x88.
21342
21343 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
21344 (pupa_setup_SOURCES): Likewise.
21345
21346 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
21347
08b70fe8 213482002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21349
21350 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
21351 bunch of pushl's from pusha, because this destroys the return
21352 value.
21353
62ddcc8f 213542002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21355
21356 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
21357 This means that any missing prototypes could be fatal. Also, you
21358 must take care when writing assembly code. See the comments at
21359 the beginning of startup.S, for more details.
f19dbdb7 21360
62ddcc8f 21361 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
21362 compilation mechanism.
21363 (pupa_chainloader_real_boot): Likewise.
21364 (pupa_biosdisk_rw_int13_extensions): Likewise.
21365 (pupa_biosdisk_rw_standard): Likewise.
21366 (pupa_biosdisk_check_int13_extensions): Likewise.
21367 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
21368 (pupa_biosdisk_get_diskinfo_standard): Likewise.
21369 (pupa_get_memsize): Likewise.
21370 (pupa_get_mmap_entry): Likewise.
21371 (pupa_console_putchar): Likewise.
21372 (pupa_console_setcursor): Likewise.
21373 (pupa_getrtsecs): Use pushl instead of push.
21374
21375 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
21376 memory instead of the stack for a mmap entry, because some
21377 BIOSes may ignore the maximum size and overflow.
21378
21379 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
21380
21381 * genmk.rb (PModule#rule): Compile automatically generated
21382 sources with module-specific CFLAGS as well as other sources.
21383
9962ed99 213842002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21385
21386 * configure.ac: Check ld.
21387 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
21388 respectively, before checking endianness and sizes.
21389
21390 * Makefile.in (LD): New variable.
f19dbdb7 21391
abdfc3c5 213922002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21393
21394 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
21395
6a161fa9 213962002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21397
21398 * Changelog: New file.
21399