Commit graph

38 commits

Author SHA1 Message Date
robertmh
60d6b16e1e Add `lsmmap' command (lists firmware-provided memory map):
* commands/lsmmap.c: New file.
        * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
        (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
        variables.
        * conf/powerpc-ieee1275.rmk: Likewise.
        * conf/i386-coreboot.rmk: Likewise.
        * conf/i386-ieee1275.rmk: Likewise.
2008-11-20 20:34:14 +00:00
robertmh
79d29fd7b8 Harmonize ieee1275's grub_available_iterate() with the generic
grub_machine_mmap_iterate() interface (fixes a recently-introduced
        build problem on i386-ieee1275):
        * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
        * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here.  Add third
        parameter `type'.  Update all users of this function.
        * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
        `kern/ieee1275/mmap.c'.
        * kern/ieee1275/init.c
        * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
        with ...
        (grub_machine_mmap_iterate): ... this.
        * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
        return type to `grub_err_t'.  Update all implementations of this
        function prototype.
        * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
        Likewise.
2008-11-20 20:30:24 +00:00
robertmh
9f3af64471 run autogen.sh ... 2008-11-07 19:12:11 +00:00
robertmh
926b98230e 2008-11-01 Robert Millan <rmh@aybabtu.com>
* Makefile.in (CPPFLAGS): Fix builddir=. assumption.
        (TARGET_CPPFLAGS): Likewise.
        * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
2008-11-01 17:44:47 +00:00
robertmh
0e981d36bb Forgot to remove files / run autogen.sh 2008-09-25 14:17:43 +00:00
robertmh
ddbf5556a7 2008-09-08 Robert Millan <rmh@aybabtu.com>
* include/grub/util/biosdisk.h: Move to ...
        * include/grub/util/hostdisk.h: ... here.  Update all users.
        * util/biosdisk.c: Move to ...
        * util/hostdisk.c: ... here.  Update all users.
2008-09-08 13:52:30 +00:00
robertmh
548e2ea57c 2008-09-07 Robert Millan <rmh@aybabtu.com>
* conf/i386.rmk: New file.  Provides declaration for building
        `cpuid.mod'.
        * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
        (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
        variables.
        Include `conf/i386.mk'.
        * conf/i386-efi.rmk: Likewise.
        * conf/x86_64-efi.rmk: Likewise.
        * conf/i386-coreboot.rmk: Likewise.
        * conf/i386-ieee1275.rmk: Likewise.
2008-09-07 16:09:21 +00:00
bean
5ed20adcb9 2008-08-23 Bean <bean123ch@gmail.com>
* conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
	(grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
	disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
	(pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
	dm_nv.mod.
	(raid5rec_mod_SOURCES): New macro.
	(raid5rec_mod_CFLAGS): Likewise.
	(raid5rec_mod_LDFLAGS): Likewise.
	(raid6rec_mod_SOURCES): Likewise.
	(raid6rec_mod_CFLAGS): Likewise.
	(raid6rec_mod_LDFLAGS): Likewise.
	(mdraid_mod_SOURCES): Likewise.
	(mdraid_mod_CFLAGS): Likewise.
	(mdraid_mod_LDFLAGS): Likewise.
	(dm_nv_mod_SOURCES): Likewise.
	(dm_nv_mod_CFLAGS): Likewise.
	(dm_nv_mod_LDFLAGS): Likewise.

	* conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
	(grub_emu_SOURCES):  Add disk/raid5_recover.c, disk/raid6_recover.c,
	disk/mdraid_linux.c and disk/dmraid_nvidia.c.

	* conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
	disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.

	* conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.

	* conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.

	* conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.

	* conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.

	* disk/raid5_recover.c: New file.

	* disk/raid6_recover.c: Likewise.

	* disk/mdraid_linux.c: Likewise.

	* disk/dmraid_nvidia.c: Likewise.

	* disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
	ULONG_MAX.

	* disk/raid.c (grub_raid_open): Use the size of the smallest disk to
	calculate the size of raid device.
	(grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
	different layout of raid5.
	(grub_raid_scan_device): Remove code specific to mdraid.
	(grub_raid_list): New variable.
	(free_array): New function.
	(grub_raid_register): Likewise.
	(grub_raid_unregister): Likewise.
	(grub_raid_rescan): Likewise.
	(GRUB_MOD_INIT): Don't iterate device here.
	(GRUB_MOD_FINI): Use free_array to release resource.

	* include/grub/raid.h: Remove macro and structure specific to mdraid.
	(grub_raid5_recover_func_t): New function variable type.
	(grub_raid6_recover_func_t): Likewise.
	(grub_raid5_recover_func): New variable.
	(grub_raid6_recover_func): Likewise.
	(grub_raid_register): New function.
	(grub_raid_unregister): Likewise.
	(grub_raid_rescan): Likewise.
	(grub_raid_block_xor): Likewise.

	* util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
	(CMD_CRC): New macro.
	(part): Removed.
	(read_file): Handle device as well as file.
	(cmd_crc): New function.
	(fstest): Handle multiple disks.
	(options): Remove part, raw and long, add root and diskcount.
	(usage): Add crc, remove -p, -r, -l, add -r and -c.
	(main): Find the first non option entry and ignore subsequence options,
	add handling for the new options, support multiple disks.

	* util/grub-probe.c (probe): Add mdraid to abstraction_name.
2008-08-23 14:51:19 +00:00
robertmh
dd6bd6abb9 2008-08-18 Robert Millan <rmh@aybabtu.com>
Unify (identical) linux_normal.c files.
        * loader/i386/efi/linux_normal.c: Move from here ...
        * loader/linux_normal.c: ... to here.  Update all users.
        * loader/i386/pc/linux_normal.c: Delete.  Update all users.
        * loader/i386/ieee1275/linux_normal.c: Likewise.
2008-08-18 13:46:31 +00:00
bean
42ce5170b7 2008-08-15 Bean <bean123ch@gmail.com>
* conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
	and datehook.mod.
	(datetime_mod_SOURCES): New macro.
	(datetime_mod_CFLAGS): Likewise.
	(datetime_mod_LDFLAGS): Likewise.
	(date_mod_SOURCES): Likewise.
	(date_mod_CFLAGS): Likewise.
	(date_mod_LDFLAGS): Likewise.
	(datehook_mod_SOURCES): Likewise.
	(datehook_mod_CFLAGS): Likewise.
	(datehook_mod_LDFLAGS): Likewise.

	* conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
	and datehook.mod.
	(datetime_mod_SOURCES): New macro.
	(datetime_mod_CFLAGS): Likewise.
	(datetime_mod_LDFLAGS): Likewise.
	(date_mod_SOURCES): Likewise.
	(date_mod_CFLAGS): Likewise.
	(date_mod_LDFLAGS): Likewise.
	(datehook_mod_SOURCES): Likewise.
	(datehook_mod_CFLAGS): Likewise.
	(datehook_mod_LDFLAGS): Likewise.

	* conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
	and datehook.mod.
	(datetime_mod_SOURCES): New macro.
	(datetime_mod_CFLAGS): Likewise.
	(datetime_mod_LDFLAGS): Likewise.
	(date_mod_SOURCES): Likewise.
	(date_mod_CFLAGS): Likewise.
	(date_mod_LDFLAGS): Likewise.
	(datehook_mod_SOURCES): Likewise.
	(datehook_mod_CFLAGS): Likewise.
	(datehook_mod_LDFLAGS): Likewise.

	* conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
	and datehook.mod.
	(datetime_mod_SOURCES): New macro.
	(datetime_mod_CFLAGS): Likewise.
	(datetime_mod_LDFLAGS): Likewise.
	(date_mod_SOURCES): Likewise.
	(date_mod_CFLAGS): Likewise.
	(date_mod_LDFLAGS): Likewise.
	(datehook_mod_SOURCES): Likewise.
	(datehook_mod_CFLAGS): Likewise.
	(datehook_mod_LDFLAGS): Likewise.

	* conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
	and datehook.mod.
	(datetime_mod_SOURCES): New macro.
	(datetime_mod_CFLAGS): Likewise.
	(datetime_mod_LDFLAGS): Likewise.
	(date_mod_SOURCES): Likewise.
	(date_mod_CFLAGS): Likewise.
	(date_mod_LDFLAGS): Likewise.
	(datehook_mod_SOURCES): Likewise.
	(datehook_mod_CFLAGS): Likewise.
	(datehook_mod_LDFLAGS): Likewise.

	* kern/env.c (grub_env_insert): Fix a bug in prevp pointer.

	* commands/date.c: New file.

	* hook/datehook.c: Likewise.

	* include/grub/lib/datetime.h: Likewise.

	* include/grub/i386/cmos.h: Likewise.

	* lib/datetime.c: Likewise.

	* lib/i386/datetime.c: Likewise.

	* lib/efi/datetime.c: Likewise.
2008-08-15 15:39:02 +00:00
bean
e383b3d0c8 2008-08-07 Bean <bean123ch@gmail.com>
* conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.

	* conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,

	* include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
	multiple inclusion. Add #include <grub/types.h>.
2008-08-07 11:58:55 +00:00
marco_g
a829251bdb Urgh, and now actually add the files :-) 2008-08-05 12:26:29 +00:00
robertmh
dd19c7d795 2008-08-03 Robert Millan <rmh@aybabtu.com>
Make PCI available on all i386 architectures.

        * include/grub/i386/pc/pci.h: Move from here ...
        * include/grub/i386/pci.h: ... to here.

        * include/grub/i386/pc/pci.h: Remove.
        * include/grub/i386/efi/pci.h: Remove.
        * include/grub/x86_64/efi/pci.h: Remove.

        * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
        `<grub/cpu/pci.h>'.

        * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
        (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
        (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.

        * conf/i386-ieee1275.rmk: Likewise.
2008-08-03 18:14:07 +00:00
robertmh
3bd0a12aca 2008-08-02 Robert Millan <rmh@aybabtu.com>
* disk/memdisk.c (memdisk_size): Don't initialize.
        (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().

        * include/grub/i386/pc/kernel.h
        (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
        (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
        (grub_memdisk_image_size, grub_arch_memdisk_addr)
        (grub_arch_memdisk_size): Remove.

        * include/grub/kernel.h (struct grub_module_header): Remove `offset'
        field (was only used to transfer a constant).  Add `type' field to
        support multiple module types.
        (grub_module_iterate): New function.

        * kern/device.c (grub_device_open): Do not hide error messages
        when grub_disk_open() fails.  Use grub_print_error() instead.

        * kern/i386/pc/init.c (grub_arch_modules_addr)
        (grub_arch_memdisk_size): Remove functions.
        (grub_arch_modules_addr): Return the module address in high memory
        (now that it isn't copied anymore).

        * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
        (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
        decompression routine (grub_total_module_size already includes that
        now).  Don't copy modules back to low memory.

        * kern/main.c: Include `<grub/mm.h>'.
        (grub_load_modules): Split out (and use) ...
        (grub_module_iterate): ... this function, which iterates through
        module objects and runs a hook.
        Comment out grub_mm_init_region() call, as it would cause non-ELF
        modules to be overwritten.

        * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
        the memdisk image in its own region, make it part of the module list.
        * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
        (main): Parse --memdisk|-m option, and pass user-provided path as
        parameter to generate_image().
        (add_segments): Pass `memdisk_path' down to load_modules().
        (load_modules): Embed memdisk image in module section when requested.
        * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
        `header.type' instead of `header.offset'.

        * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
        (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
        (memdisk_mod_LDFLAGS): New variables.
        * conf/i386-coreboot.rmk: Likewise.
        * conf/i386-ieee1275.rmk: Likewise.
2008-08-02 12:17:44 +00:00
proski
cfd0b4e6fa 2008-07-28 Pavel Roskin <proski@gnu.org>
* genmk.rb: Add a warning to the beginning of the output that
	it's a generated file and should not be edited.
2008-07-28 22:35:40 +00:00
bean
a85cd5a0b5 2008-07-27 Bean <bean123ch@gmail.com>
* commands/crc.c: New file.

	* lib/crc.c: Likewise.

	* include/grub/lib/crc.h: Likewise.

	* util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.

	* commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
	(hexdump): Move this function to ...

	* lib/hexdump.c: ... here.

	* include/grub/hexdump.h: Renamed to ...

	* include/grub/lib/hexdump.h: ... this.

	* commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h

	* util/grub-editenv.c: Likewise.

	* include/envblk.h: Renamed to ...

	* include/lib/envblk.h: ... this.

	* util/envblk.c: Renamed to ...

	* lib/envblk.c: ... this.

	* conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
	lib/hexdump.c.
	(grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
	(pkglib_MODULES): Add crc.mod.
	(hexdump_mod_SOURCES): Add lib/hexdump.c.
	(loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
	(crc_mod_SOURCES): New macro.
	(crc_mod_CFLAGS): Likewise.
	(crc_mod_LDFLAGS): Likewise.

	* conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.

	* conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.

	* conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.

	* conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.

	* conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
2008-07-27 13:51:30 +00:00
bean
2a8a80e4f4 2008-07-24 Bean <bean123ch@gmail.com>
* common.rmk (bin_UTILITIES): Add grub-pe2elf.
	(grub_pe2elf_SOURCES): New macro.
	(CLEANFILES): Add grub-pe2elf.

	* include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
	(GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
	(GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
	(GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
	(GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
	(GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
	(GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
	(GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
	(GRUB_PE32_SCN_ALIGN_MASK): Likewise.
	(GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
	(GRUB_PE32_SYM_CLASS_STATIC): Likewise.
	(GRUB_PE32_SYM_CLASS_FILE): Likewise.
	(GRUB_PE32_DT_FUNCTION): Likewise.
	(GRUB_PE32_REL_I386_DIR32): Likewise.
	(GRUB_PE32_REL_I386_REL32): Likewise.
	(grub_pe32_symbol): New structure.
	(grub_pe32_reloc): Likewise.

	* util/grub-pe2elf.c: New file.

	* configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
	start symbol in non pc platform.

	* genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.

	The following patches are from Christian Franke.

	* include/grub/dl.h: Remove .previous, gas supports this only
	for ELF format.

	* include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
	Remove .type, gas supports this only for ELF format.

	* kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
	nullbytes in symbol table. This fixes an infinite loop if table is
	zero filled.

	* Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
	TARGET_IMG_LDFLAGS and EXEEXT.

	* aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
	TARGET_IMG_LDFLAGS_AC.
	(grub_CHECK_STACK_ARG_PROBE): New function.

	* conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.

	* conf/i386-pc-cygwin-ld-img.sc: New linker script.

	* configure.ac: Add check for linker script "conf/${target}-img-ld.c"
	to set TARGET_IMG_LD* accordingly.
	Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
	Add call to grub_CHECK_STACK_ARG_PROBE.
	Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.

	* genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.

	* genmk.rb: Add EXEEXT to CLEANFILES.
2008-07-24 14:56:30 +00:00
proski
cb71ba20e9 2008-07-02 Pavel Roskin <proski@gnu.org>
* Makefile.in (MODULE_LDFLAGS): New variable.
	* aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro.  Check if
	the linker accepts --build-id=none.
	* configure.ac: Call grub_PROG_LD_BUILD_ID_NONE.  Substitute
	MODULE_LDFLAGS.
	* genmk.rb: Use MODULE_LDFLAGS when linking modules.
2008-07-02 19:03:23 +00:00
proski
47395a42d7 2008-06-19 Pavel Roskin <proski@gnu.org>
* conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
	changed.  This is needed in case GRUB_LIBDIR changes.
	* conf/i386-ieee1275.rmk: Likewise.
	* conf/i386-linuxbios.rmk: Likewise.
	* conf/i386-pc.rmk: Likewise.
	* conf/powerpc-ieee1275.rmk: Likewise.
2008-06-19 05:14:16 +00:00
proski
22f16596ae 2008-05-30 Pavel Roskin <proski@gnu.org>
* conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
	compiling execute.c doesn't need grub_script.tab.h anymore.
	(normal/command.c_DEPENDENCIES): Likewise.
	(normal/function.c_DEPENDENCIES): Likewise.
	* conf/i386-ieee1275.rmk: Likewise.
	* conf/i386-linuxbios.rmk: Likewise.
	* conf/i386-pc.rmk: Likewise.
	* conf/powerpc-ieee1275.rmk: Likewise.
	* conf/sparc64-ieee1275.rmk: Likewise.
2008-05-30 04:20:48 +00:00
robertmh
eee96e0837 2008-05-29 Robert Millan <rmh@aybabtu.com>
* util/powerpc/ieee1275/grub-install.in: Move from here ...
        * util/ieee1275/grub-install.in: ... to here.
        * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
        * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
        (grub_install_SOURCES): Likewise.
2008-05-29 16:27:24 +00:00
bean
25f16ec1f6 2008-04-25 Bean <bean123ch@gmail.com>
* Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
	i386-linuxbios.

	* commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
	change the buffer size to 4096 for cdrom device.

	* conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
	and nand.mod.
	(_linux_mod_SOURCES): New variable.
	(_linux_mod_CFLAGS): Likewise.
	(_linux_mod_LDFLAGS): Likewise.
	(linux_mod_SOURCES): Likewise.
	(linux_mod_CFLAGS): Likewise.
	(linux_mod_LDFLAGS): Likewise.
	(nand_mod_SOURCES): Likewise.
	(nand_mod_CFLAGS): Likewise.
	(nand_mod_LDFLAGS): Likewise.

	* disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
	GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
	type property. (nand device in olpc don't have this property)

	* include/grub/disk.h (grub_disk_dev_id): New macro
	GRUB_DISK_DEVICE_NAND_ID.

	* include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
	function prototype.
	(grub_rescue_cmd_initrd): Likewise.

	* include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
	(linux_kernel_params): Add new member ofw_signature, ofw_num_items,
	ofw_cif_handler and ofw_idt, adjust padding number.

	* include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
	GRUB_MACHINE_IEEE1275 is defined.

	* include/grub/ieee1275/ieee1275.h (grub_available_iterate):
	Use NESTED_FUNC_ATTR attribute on the hook parameter.

	* kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
	on nested function heap_init.
	(grub_upper_mem): New variable for i386-ieee1275.
	(grub_get_extended_memory): New function for i386-ieee1275.
	(grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.

	* kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
	NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
	property.

	* loader/i386/ieee1275/linux.c: New file.

	* loader/i386/ieee1275/linux_normal.c: New file.

	* disk/ieee1275/nand.c: New file.
2008-04-25 19:41:51 +00:00
proski
228ffeab3e Regenerate 2008-04-14 00:58:23 +00:00
robertmh
a91627b40a 2008-04-12 Robert Millan <rmh@aybabtu.com>
* kern/powerpc/ieee1275/init.c: Move from here ...
        * kern/ieee1275/init.c: ... to here.  Update all users.

        * kern/powerpc/ieee1275/cmain.c: Move from here ...
        * kern/ieee1275/cmain.c: ... to here.  Update all users.

        * kern/powerpc/ieee1275/openfw.c: Move from here ...
        * kern/ieee1275/openfw.c: ... to here.  Update all users.

        * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
        * loader/ieee1275/multiboot2.c: ... to here.  Update all users.
2008-04-12 21:09:36 +00:00
bean
86cb4f54b4 2008-03-31 Bean <bean123ch@gmail.com>
* conf/common.rmk (pkgdata_MODULES): Add afs.mod.
	(grub_probe_SOURCES): Add fs/afs.c.
	(grub_fstest_SOURCES): Likewise.
	(afs_mod_SOURCES): New variable.
	(afs_mod_CFLAGS): Likewise.
	(afs_mod_LDFLAGS): Likewise.

	* conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
	(grub_emu_SOURCES): Likewise.

	* conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.

	* conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.

	* conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.

	* conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.

	* fs/afs.c: New file.
2008-03-31 11:18:00 +00:00
proski
a303c7835f Regenerate 2008-03-25 02:52:15 +00:00
bean
0d16e571f1 2008-02-24 Bean <bean123ch@gmail.com>
* fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
	(GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
	(GRUB_ISO9660_VOLDESC_SUPP): Likewise.
	(GRUB_ISO9660_VOLDESC_PART): Likewise.
	(GRUB_ISO9660_VOLDESC_END): Likewise.
	(grub_iso9660_primary_voldesc): New member escape.
	(grub_iso9660_data): New member joliet.
	(grub_iso9660_convert_string): New function.
	(grub_iso9660_mount): Detect joliet extension.
	(grub_iso9660_iterate_dir): Convert filename when joliet is detected.
	(grub_iso9660_iso9660_label): Likewise.

	* conf/common.rmk (pkgdata_MODULES): Add udf.mod.
	(grub_setup_SOURCES): Add fs/udf.c.
	(grub_fstest_SOURCES): Likewise.
	(udf_mod_SOURCES): New variable.
	(udf_mod_CFLAGS): Likewise.
	(udf_mod_LDFLAGS): Likewise.

	* conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
	(grub_emu_SOURCES): Likewise.

	* conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.

	* conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.

	* conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.

	* conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.

	* fs/udf.c: New file.
2008-02-24 15:34:15 +00:00
robertmh
8a594a17c7 2008-02-24 Robert Millan <rmh@aybabtu.com>
* conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
        (normal/lexer.c_DEPENDENCIES): New variables.
        * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
        (normal/lexer.c_DEPENDENCIES): Likewise.
        * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
        (normal/lexer.c_DEPENDENCIES): Likewise.
        * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
        (normal/lexer.c_DEPENDENCIES): Likewise.
        * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
        (normal/lexer.c_DEPENDENCIES): Likewise.
        * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
        (normal/lexer.c_DEPENDENCIES): Likewise.
2008-02-24 15:06:30 +00:00
okuji
c3db83643a 2008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
* configure.ac: Only a cosmetic change on the handling of
      -fno-stack-protector.
2008-02-13 03:35:48 +00:00
robertmh
bf7486424d 2008-02-10 Robert Millan <rmh@aybabtu.com>
* conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
        `disk/lvm.c'.
        * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
        * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.

        * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
        `disk/lvm.c' to the end of the list.
        * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
        * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2008-02-10 20:00:37 +00:00
robertmh
7d31f41fc6 2008-02-01 Robert Millan <rmh@aybabtu.com>
* conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
        top.
        (normal/command.c_DEPENDENCIES): New variable.
        (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
        * conf/i386-ieee1275.rmk: Likewise.
        * conf/i386-linuxbios.rmk: Likewise.
        * conf/i386-pc.rmk: Likewise.
        * conf/sparc64-ieee1275.rmk: Likewise.
        * conf/powerpc-ieee1275.rmk: Likewise.
        (grub_emu_SOURCES): Add `fs/fshelp.c'.

        * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
2008-02-01 15:45:17 +00:00
robertmh
ccaa8a5f50 2008-01-30 Robert Millan <rmh@aybabtu.com>
* conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
        (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
        * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
        (grub_probe_SOURCES): ... to here.

        * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
        (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
        * conf/i386-ieee1275.rmk: Likewise.
        * conf/i386-linuxbios.rmk: Likewise.
        * conf/powerpc-ieee1275.rmk: Likewise.
2008-01-30 15:32:56 +00:00
robertmh
e1907778a1 2008-01-27 Robert Millan <rmh@aybabtu.com>
Get grub-emu to build again (including parallel builds).

        * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
        Split into ...
        (util/grub-emu.c_DEPENDENCIES): ... this, ...
        (normal/execute.c_DEPENDENCIES): ... this, ...
        (grub-emu_DEPENDENCIES): ... and this.

        * conf/i386-efi.rmk: Likewise.
        * conf/i386-linuxbios.rmk: Likewise.
        * conf/i386-ieee1275.rmk: Likewise.
        * conf/powerpc-ieee1275.rmk: Likewise.
        (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
2008-01-27 22:44:02 +00:00
robertmh
f75172d9e7 2008-01-27 Robert Millan <rmh@aybabtu.com>
Fix parallel builds with grub-emu.  Based on earlier commit for
        grub-probe and grub-setup.

        * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
        (util/grub-emu.c_DEPENDENCIES): ... this.
        * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
        (util/grub-emu.c_DEPENDENCIES): ... this.
        * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
        (util/grub-emu.c_DEPENDENCIES): ... this.
        * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
        (util/grub-emu.c_DEPENDENCIES): ... this.
        * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
        (util/grub-emu.c_DEPENDENCIES): ... this.
2008-01-27 21:35:44 +00:00
robertmh
2a9525e6c3 2008-01-25 Robert Millan <rmh@aybabtu.com>
* conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
        make all filesystem sources appear together (possibly fixing omissions
        while at it).
        * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
        * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
        * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
        * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.

        * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.  Additionally,
        add `kern/file.c'.
        * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
        * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
        * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
        * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.

        * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
        (probe): Add a sanity check to make sure of our ability to read
        requested files when probing for filesystem type.

        * genmk.rb: Update copyright year (2007).

        * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
        (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
        (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
        (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
        (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
        : Remove function prototypes.
2008-01-25 22:33:57 +00:00
robertmh
5882ae4b0e 2008-01-23 Robert Millan <rmh@aybabtu.com>
* conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
        `term/i386/pc/at_keyboard.c'.
        (pkglib_MODULES): Add `serial.mod'.
        (serial_mod_SOURCES): New variable.
        (serial_mod_CFLAGS): Likewise.
        (serial_mod_LDFLAGS): Likewise.

        * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'.  Remove
        `<grub/powerpc/ieee1275/console.h>'.
        (grub_keyboard_controller_init): New function prototype.
        (grub_console_checkkey): Likewise.
        (grub_console_getkey): Likewise.

        * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
        keyboard on i386.

        * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
        grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
2008-01-23 11:57:22 +00:00
robertmh
dbb475a441 2008-01-23 Robert Millan <rmh@aybabtu.com>
* conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
        and `machine/memory.h'.
        (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
        (_multiboot_mod_SOURCES): New variable.
        (_multiboot_mod_CFLAGS): Likewise.
        (_multiboot_mod_LDFLAGS): Likewise.
        (multiboot_mod_SOURCES): Likewise.
        (multiboot_mod_CFLAGS): Likewise.
        (multiboot_mod_LDFLAGS): Likewise.

        * include/grub/i386/ieee1275/loader.h: New file.

        * include/grub/i386/ieee1275/machine.h: Likewise.

        * include/grub/i386/ieee1275/memory.h: Likewise.

        * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
        variable declaration.
        (grub_os_area_size): Likewise.

        * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
        (grub_lower_mem, grub_upper_mem): New variables.
        (grub_stop_floppy): New function (just to make
        grub_multiboot2_real_boot() happy).

        * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
        `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
        (grub_stop): New function.
        Include `"../realmode.S"' and `"../loader.S"'.

        * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
        Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.

        * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
        rely on grub_multiboot2_real_boot() for final boot.
2008-01-23 09:57:26 +00:00
robertmh
3d04eab83e 2008-01-15 Robert Millan <rmh@aybabtu.com>
* configure.ac: Add `i386-ieee1275' to the list of supported targets.
        * conf/i386-ieee1275.rmk: New file.
        * include/grub/i386/ieee1275/console.h: Likewise.
        * include/grub/i386/ieee1275/ieee1275.h: Likewise.
        * include/grub/i386/ieee1275/kernel.h: Likewise.
        * include/grub/i386/ieee1275/time.h: Likewise.
        * kern/i386/ieee1275/init.c: Likewise.
        * kern/i386/ieee1275/startup.S: Likewise.
2008-01-15 20:05:44 +00:00