Vladimir 'phcoder' Serbinenko
de9c615e5c
Removed unused GRUB_BOOT_VERSION. Check for kernel version is better
...
done with a dedicated section.
* grub-core/boot/sparc64/ieee1275/boot.S: Remove GRUB_BOOT_VERSION.
Ensure the correct position of boot_path.
* grub-core/kern/i386/efi/startup.S: Remove GRUB_BOOT_VERSION.
* grub-core/kern/i386/pc/startup.S: Likewise. Ensure correct position of
other fields.
* grub-core/kern/x86_64/efi/startup.S: Remove GRUB_BOOT_VERSION.
* include/grub/boot.h: Removed. All references removed.
* include/grub/sparc64/ieee1275/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
Removed.
(GRUB_BOOT_MACHINE_BOOT_DEVPATH): Make it lower.
2011-10-19 23:01:44 +02:00
Vladimir 'phcoder' Serbinenko
e55599dcbf
* util/grub-install.in: Declare IEEE1275 as able to find out the disk
...
name.
2011-10-19 20:35:41 +02:00
Vladimir 'phcoder' Serbinenko
36dd20ad0b
* grub-core/kern/main.c (grub_set_prefix_and_root): Init prefix.
2011-10-19 20:30:06 +02:00
Vladimir 'phcoder' Serbinenko
f8f72eb890
* grub-core/kern/ieee1275/openfw.c (grub_ieee1275_encode_devname):
...
Don't add the bogus brackets.
2011-10-19 20:28:09 +02:00
Vladimir 'phcoder' Serbinenko
a374751b16
ExFAT support.
...
* Makefile.util.def (libgrubmods.a): Add grub-core/fs/exfat.c.
* grub-core/Makefile.core.def (exfat): New module.
* grub-core/fs/exfat.c: New file.
* grub-core/fs/fat.c (GRUB_FAT_DIR_ENTRY_SIZE): Removed.
(GRUB_FAT_ATTR_*): Make into an enum.
(GRUB_FAT_ATTR_LONG_NAME) [MODE_EXFAT]: Removed.
(GRUB_FAT_ATTR_VALID) [MODE_EXFAT]: Remove GRUB_FAT_ATTR_VOLUME_ID.
(GRUB_FAT_ATTR_VOLUME_ID) [MODE_EXFAT]: Removed.
(GRUB_FAT_MAXFILE): Removed.
(grub_exfat_bpb) [MODE_EXFAT]: New struct.
(grub_current_fat_bpb_t): New type.
(grub_fat_dir_entry) [MODE_EXFAT]: New struct.
(grub_fat_dir_node) [MODE_EXFAT]: New struct.
(grub_fat_dir_node_t): New type.
(grub_fat_data) [MODE_EXFAT]: Remove root_sector and num_root_sectors.
(fat_log2) [MODE_EXFAT]: Removed.
(grub_fat_mount): Use grub_current_fat_bpb_t. Add some sanity checks.
(grub_fat_mount) [MODE_EXFAT]: Handle ExFAT.
(grub_fat_iterate_dir) [MODE_EXFAT]: New function.
(grub_fat_find_dir) [MODE_EXFAT]: Handle ExFAT.
(grub_fat_label) [MODE_EXFAT]: New function.
(grub_fat_fs) [MODE_EXFAT]: Set name to "exfat" and
reserved_first_sector to 0.
2011-10-19 20:19:25 +02:00
Vladimir 'phcoder' Serbinenko
544c24876e
Move grub_reboot out of the kernel.
...
* grub-core/Makefile.core.def (reboot): Add platform-specific files.
* grub-core/kern/efi/efi.c (grub_reboot): Moved to ...
* grub-core/lib/efi/reboot.c: ... here.
* grub-core/kern/i386/efi/startup.S: Remove including of realmode.S.
* grub-core/kern/i386/ieee1275/startup.S: Likewise.
* grub-core/kern/i386/pc/startup.S (grub_exit): Inline cold_reboot.
* grub-core/kern/i386/realmode.S (grub_reboot): Moved to...
* grub-core/lib/i386/reboot_trampoline.S: ... here.
* grub-core/kern/ieee1275/openfw.c (grub_reboot): Moved to...
* grub-core/lib/ieee1275/reboot.c: ... here.
* grub-core/kern/mips/arc/init.c (grub_reboot): Moved to...
* grub-core/lib/mips/arc/reboot.c: ... here.
* grub-core/kern/mips/loongson/init.c (grub_reboot): Moved to...
* grub-core/lib/mips/loongson/reboot.c: ...here.
* grub-core/kern/mips/qemu_mips/init.c (grub_reboot): Moved to...
* grub-core/lib/mips/qemu_mips/reboot.c: ... here.
* include/grub/emu/misc.h (grub_reboot): New function declaration.
* include/grub/i386/reboot.h: New file.
* include/grub/mips/loongson/ec.h: Fix includes.
* include/grub/mips/qemu_mips/kernel.h (grub_reboot): Removed.
* include/grub/misc.h (grub_reboot): Don't mark as kernel function.
* grub-core/lib/i386/reboot.c: New file.
2011-10-19 16:53:18 +02:00
Vladimir 'phcoder' Serbinenko
a97501d238
Make grub_prefix into module to fix the arbitrary limit and save
...
some space.
* grub-core/kern/emu/main.c (grub_prefix): Removed.
* grub-core/kern/i386/coreboot/startup.S (grub_prefix): Likewise.
* grub-core/kern/i386/efi/startup.S (grub_prefix): Likewise.
* grub-core/kern/i386/ieee1275/startup.S (grub_prefix): Likewise.
* grub-core/kern/i386/pc/startup.S (grub_prefix): Likewise.
* grub-core/kern/i386/qemu/startup.S (grub_prefix): Likewise.
* grub-core/kern/ia64/efi/startup.S (grub_prefix): Likewise.
* grub-core/kern/mips/startup.S (grub_prefix): Likewise.
* grub-core/kern/powerpc/ieee1275/startup.S (grub_prefix): Likewise.
* grub-core/kern/sparc64/ieee1275/crt0.S (grub_prefix): Likewise.
* grub-core/kern/x86_64/efi/startup.S (grub_prefix): Likewise.
* include/grub/ia64/efi/kernel.h: Removed.
* include/grub/kernel.h: New module type OBJ_TYPE_PREFIX.
(grub_prefix): Removed.
* include/grub/offsets.h (GRUB_KERNEL_I386_PC_PREFIX): Removed.
(GRUB_KERNEL_I386_PC_PREFIX_END): Likewise.
(GRUB_KERNEL_I386_QEMU_PREFIX): Likewise.
(GRUB_KERNEL_I386_QEMU_PREFIX_END): Likewise.
(GRUB_KERNEL_SPARC64_IEEE1275_PREFIX): Likewise.
(GRUB_KERNEL_SPARC64_IEEE1275_PREFIX_END): Likewise.
(GRUB_KERNEL_POWERPC_IEEE1275_PREFIX): Likewise.
(GRUB_KERNEL_POWERPC_IEEE1275_PREFIX_END): Likewise.
(GRUB_KERNEL_MIPS_LOONGSON_PREFIX): Likewise.
(GRUB_KERNEL_MIPS_LOONGSON_PREFIX_END): Likewise.
(GRUB_KERNEL_MIPS_QEMU_MIPS_PREFIX): Likewise.
(GRUB_KERNEL_MIPS_QEMU_MIPS_PREFIX_END): Likewise.
(GRUB_KERNEL_MIPS_ARC_PREFIX): Likewise.
(GRUB_KERNEL_MIPS_ARC_PREFIX_END): Likewise.
(GRUB_KERNEL_I386_EFI_PREFIX): Likewise.
(GRUB_KERNEL_I386_EFI_PREFIX_END): Likewise.
(GRUB_KERNEL_IA64_EFI_PREFIX): Likewise.
(GRUB_KERNEL_IA64_EFI_PREFIX_END): Likewise.
(GRUB_KERNEL_X86_64_EFI_PREFIX): Likewise.
(GRUB_KERNEL_X86_64_EFI_PREFIX_END): Likewise.
(GRUB_KERNEL_I386_COREBOOT_PREFIX): Likewise.
(GRUB_KERNEL_I386_COREBOOT_PREFIX_END): Likewise.
(GRUB_KERNEL_I386_MULTIBOOT_PREFIX): Likewise.
(GRUB_KERNEL_I386_MULTIBOOT_PREFIX_END): Likewise.
(GRUB_KERNEL_I386_IEEE1275_PREFIX): Likewise.
(GRUB_KERNEL_I386_IEEE1275_PREFIX_END): Likewise.
(GRUB_KERNEL_MACHINE_PREFIX): Likewise.
(GRUB_KERNEL_MACHINE_PREFIX_END): Likewise.
* grub-core/kern/main.c (grub_set_prefix_and_root): Retrieve grub_prefix
from module.
* util/grub-mkimage.c (image_target_desc): Removed prefix and
prefix_end.
(image_targets): Likewise.
(generate_image): Put prefix as a module.
2011-10-18 15:21:51 +02:00
Vladimir 'phcoder' Serbinenko
39705fadd7
Replace grub_module_iterate with FOR_MODULES.
...
* grub-core/disk/memdisk.c (GRUB_MOD_INIT): Switched to new interface.
* grub-core/kern/efi/efi.c (grub_arch_modules_addr): Renamed to...
(grub_efi_modules_addr): ...this.
* grub-core/kern/efi/init.c (grub_modbase): New variable.
(grub_efi_init): Set grub_modbase.
* grub-core/kern/emu/main.c (grub_arch_modules_addr): Removed.
(grub_modbase): New variable.
* grub-core/kern/i386/coreboot/init.c (grub_arch_modules_addr): Removed.
(grub_modbase): New variable.
(grub_machine_init): Set grub_modbase.
* grub-core/kern/i386/pc/init.c (grub_arch_modules_addr): Removed.
(grub_modbase): New variable.
(grub_machine_init): Set grub_modbase.
* grub-core/kern/ieee1275/init.c (grub_arch_modules_addr): Removed.
(grub_modbase): New variable.
(grub_machine_init): Set grub_modbase.
* grub-core/kern/main.c (grub_module_iterate): Remove.
(grub_modules_get_end): Use grub_modbase.
(grub_load_modules): Use FOR_MODULES.
(grub_load_config): Likewise.
* grub-core/kern/mips/arc/init.c (grub_arch_modules_addr): Removed.
(grub_modbase): New variable.
(grub_machine_init): Set grub_modbase.
* grub-core/kern/mips/loongson/init.c (grub_arch_modules_addr): Removed.
(grub_modbase): New variable.
(grub_machine_init): Set grub_modbase.
* grub-core/kern/mips/qemu_mips/init.c (grub_arch_modules_addr):
Removed.
(grub_modbase): New variable.
(grub_machine_init): Set grub_modbase.
* include/grub/efi/efi.h (grub_efi_modules_addr): New declaration.
* include/grub/kernel.h (grub_arch_modules_addr): Removed.
(grub_module_iterate): Likewise.
(grub_modbase): New variable declaration.
(FOR_MODULES): New macro.
2011-10-16 15:23:29 +02:00
Vladimir 'phcoder' Serbinenko
2afb7f6cbf
* configure.ac: Check for __ctzdi2 and __ctzsi2.
...
* include/grub/libgcc.h: Include __ctzdi2 and __ctzsi2 if present.
2011-10-16 15:15:35 +02:00
Vladimir 'phcoder' Serbinenko
366e34fa5a
Fix few obvious type discrepancies.
...
* grub-core/fs/affs.c (grub_affs_read_file): Use grub_off_t for offset.
* grub-core/fs/afs.c (grub_afs_read_file): Likewise.
* grub-core/fs/fshelp.c (grub_fshelp_find_file): Remove leftover
variable.
* grub-core/fs/hfs.c (grub_hfs_read_file): Use grub_off_t for offset
and connected types.
* grub-core/fs/nilfs2.c (grub_nilfs2_read_file): Use grub_off_t for
offset.
(grub_nilfs2_iterate_dir): Use grub_off_t for fpos.
* grub-core/fs/sfs.c (grub_sfs_read_file): Use grub_off_t for offset.
* grub-core/fs/ufs.c (grub_ufs_read_file): Use grub_off_t for offset
and connected types.
2011-10-16 11:57:48 +02:00
Vladimir 'phcoder' Serbinenko
177b960ea4
Fix python 3.x incompatibilities.
...
* gentpl.py: Put brackets around print strings.
* util/import_gcry.py: Open explicitly as utf-8.
Use in instead of has_key.
2011-10-16 11:53:27 +02:00
Vladimir 'phcoder' Serbinenko
3b619ae116
* grub-core/fs/xfs.c (grub_xfs_inode): New field fork_offset.
...
(GRUB_XFS_INO_AGBITS): Make into inline function.
(GRUB_XFS_INO_INOINAG): Likewise.
(GRUB_XFS_INO_AG): Likewise.
(GRUB_XFS_FSB_TO_BLOCK): Likewise.
(GRUB_XFS_EXTENT_OFFSET): Likewise.
(GRUB_XFS_EXTENT_BLOCK): Likewise.
(GRUB_XFS_EXTENT_SIZE): Likewise.
(GRUB_XFS_ROUND_TO_DIRENT): Likewise.
(GRUB_XFS_NEXT_DIRENT): Likewise.
(grub_xfs_read_block): Rewrite the btree parsing. Fixes invalid BMAP.
(grub_xfs_read_file): Fix offset type.
2011-10-16 11:48:54 +02:00
Robert Millan
8bcebcb8e4
2011-10-15 Robert Millan <rmh@gnu.org>
...
* util/getroot.c (grub_util_get_grub_dev): Fix OS selection #ifdefs.
2011-10-15 18:37:55 +02:00
Robert Millan
0017e5ef84
2011-10-15 Robert Millan <rmh@gnu.org>
...
Fix build problem on FreeBSD and GNU/kFreeBSD.
* util/getroot.c [__FreeBSD_kernel__]: Include `<sys/mount.h>'.
2011-10-15 13:33:41 +02:00
Vladimir 'phcoder' Serbinenko
d891955241
Fix overflow with >2GiB file on HFS+. >4GiB wasn't tested.
...
* grub-core/fs/hfsplus.c (grub_hfsplus_btree): Use more appropriate
types.
(grub_hfsplus_btree_recoffset): Likewise.
(grub_hfsplus_btree_recptr): Likewise.
(grub_hfsplus_find_block): Likewise.
(grub_hfsplus_btree_search): Likewise.
(grub_hfsplus_read_block): Likewise.
(grub_hfsplus_read_file): Likewise.
(grub_hfsplus_mount): Likewise.
(grub_hfsplus_btree_iterate_node): Likewise.
(grub_hfsplus_btree_search): Likewise.
(grub_hfsplus_iterate_dir): Likewise.
(grub_hfsplus_read): A small code simplification.
2011-10-14 22:41:21 +02:00
Vladimir 'phcoder' Serbinenko
038ec56a31
nslookup implementation
2011-10-14 19:21:59 +02:00
Vladimir 'phcoder' Serbinenko
c81296b65f
* grub-core/kern/emu/hostdisk.c
...
(convert_system_partition_to_system_disk): Don't assume that children
of mapper nodes are mapper nodes.
2011-10-14 19:20:44 +02:00
Vladimir 'phcoder' Serbinenko
0eb8ffb1f5
* grub-core/lib/posix_wrap/ctype.h (isxdigit): Use grub_isxdigit.
...
* include/grub/misc.h (grub_isxdigit): New function.
* grub-core/video/colors.c (my_isxdigit): Removed. All users
switched to grub_isxdigit.
* grub-core/term/serial.c (grub_serial_find): Fix in case of port
number starting with a letter.
2011-10-14 19:16:37 +02:00
Vladimir 'phcoder' Serbinenko
0cb9503b70
support routed pings
2011-10-13 20:53:22 +02:00
Vladimir 'phcoder' Serbinenko
bd40efbf0b
several net bugfixes and improvements and fix some memory leaks
2011-10-13 18:31:53 +02:00
Vladimir 'phcoder' Serbinenko
da1b289afc
IPv6. Apparently working. At least I could retrieve a file with http6
2011-10-13 01:22:56 +02:00
Vladimir 'phcoder' Serbinenko
7c006811f8
more ipv6 code. Now ipv6 ping succeeds
2011-10-12 23:15:02 +02:00
Vladimir 'phcoder' Serbinenko
a53cf6534d
some more ipv6 code
2011-10-12 10:20:55 +02:00
Robert Millan
a98f4a0808
2011-10-09 Robert Millan <rmh@gnu.org>
...
LVM support for FreeBSD and GNU/kFreeBSD.
* util/lvm.c (grub_util_lvm_isvolume): Enable on FreeBSD and
GNU/kFreeBSD.
(LVM_DEV_MAPPER_STRING): Move from here ...
* include/grub/util/lvm.h (LVM_DEV_MAPPER_STRING): ... to here.
* util/getroot.c: Include `<grub/util/lvm.h>'.
(grub_util_get_dev_abstraction): Enable
grub_util_biosdisk_is_present() on FreeBSD and GNU/kFreeBSD.
Check for LVM abstraction on FreeBSD and GNU/kFreeBSD.
(grub_util_get_grub_dev): Replace "/dev/mapper/" with
`LVM_DEV_MAPPER_STRING'. Enable LVM and mdRAID only on platforms that
support it.
* util/grub-setup.c (main): Check for LVM also on FreeBSD and
GNU/kFreeBSD.
* util/grub.d/10_kfreebsd.in: Load `geom_linux_lvm' kernel module
when LVM abstraction is required for ${GRUB_DEVICE}.
2011-10-09 21:13:00 +02:00
Szymon Janc
050e8e9080
Add support for LZO compression in GRUB:
...
- import of minilzo library,
- LZO decompression for btrfs,
- lzop files decompression.
* grub-core/io/lzopio.c: New file.
* grub-core/lib/adler32.c: Likewise.
* grub-core/lib/minilzo/lzoconf.h: Likewise.
* grub-core/lib/minilzo/lzodefs.h: Likewise.
* grub-core/lib/minilzo/minilzo.c: Likewise.
* grub-core/lib/minilzo/minilzo.h: Likewise.
* Makefile.util.def (libgrubmods.a): Add grub-core/io/lzopio.c,
grub-core/lib/adler32.c, grub-core/io/lzopio.c,
grub-core/lib/minilzo/minilzo.c to common.
* Makefile.util.def (libgrubmods.a): Add flags required by minilzo to
cflags in cppflags.
* grub-core/Makefile.core.def (btrfs): Likewise.
* grub-core/Makefile.core.def (lzopio): New module.
(adler32): Likewise.
* grub-core/fs/btrfs.c: Include minilzo.h.
(GRUB_BTRFS_COMPRESSION_LZO): New define.
(GRUB_BTRFS_LZO_BLOCK_SIZE): Likewise.
(GRUB_BTRFS_LZO_BLOCK_MAX_CSIZE): Likewise.
(grub_btrfs_lzo_decompress): New function.
(grub_btrfs_extent_read): Add support for LZO compression type.
* include/grub/types.h (GRUB_UCHAR_MAX): New define.
(GRUB_USHRT_MAX): Likewise.
(GRUB_UINT_MAX): Likewise.
* grub-core/lib/posix_wrap/limits.h (USHRT_MAX): Likewise.
(UINT_MAX): Likewise.
(CHAR_BIT): Likewise.
* grub-core/lib/posix_wrap/sys/types.h (ULONG_MAX): Moved to
grub-core/lib/posix_wrap/limits.h
(UCHAR_MAX): Likewise.
* include/grub/file.h (grub_file_filter_id): New compression filter
GRUB_FILE_FILTER_LZOPIO.
* include/grub/file.h (grub_file_filter_id): Set
GRUB_FILE_FILTER_LZOPIO as GRUB_FILE_FILTER_COMPRESSION_LAST.
* include/grub/types.h (grub_get_unaligned16): New function.
(grub_get_unaligned32): Likewise.
(grub_get_unaligned64): Likewise.
* util/import_gcry.py (cryptolist): Add adler32.
2011-10-06 20:45:14 +02:00
Szymon Janc
a664449575
merge trunk
2011-10-06 19:00:10 +02:00
Vladimir 'phcoder' Serbinenko
d5e60b1ba0
Add license statement to the emunet
2011-10-05 23:50:43 +02:00
Vladimir 'phcoder' Serbinenko
eb6a7b9788
Hopefully fix EFI problem. Not tested
2011-10-05 23:33:36 +02:00
Vladimir 'phcoder' Serbinenko
8530b00aa9
Fix compilation on 64-bit targets
2011-10-05 23:19:11 +02:00
Vladimir 'phcoder' Serbinenko
140674be60
Remove leftover variabel
2011-10-05 23:18:44 +02:00
Vladimir 'phcoder' Serbinenko
faba379c96
put license on priority_queue
2011-10-05 23:18:22 +02:00
Vladimir 'phcoder' Serbinenko
9aad3cd91d
IPv6 support. Several fixes and unifications
2011-10-05 22:15:30 +02:00
Vladimir 'phcoder' Serbinenko
96bd62413f
Don't set RST in response to empty packets
2011-10-05 17:50:52 +02:00
Vladimir 'phcoder' Serbinenko
4f71e077b9
HTTP seek support. Various bugfixes.
2011-10-05 17:39:13 +02:00
Vladimir 'phcoder' Serbinenko
aa6b91afe9
merge mainline into net
2011-10-05 13:32:40 +02:00
Vladimir 'phcoder' Serbinenko
fe942b7dbb
* grub-core/Makefile.core.def: Eliminate rarely used emu_condition. This
...
in perspective decreases the complexity of build system and fixes
compilation right now.
2011-10-05 11:53:36 +02:00
Vladimir 'phcoder' Serbinenko
5c62099a8f
Fix warning on i386-pc
2011-10-05 10:22:23 +02:00
Vladimir 'phcoder' Serbinenko
805448e987
Add network functions for grub-menulst2cfg
2011-10-05 10:21:32 +02:00
Szymon Janc
bc4d3f4809
* grub-core/io/lzopio.c (calculate_uncompressed_size): Fix return code.
2011-10-04 21:10:21 +02:00
Szymon Janc
709e61a55f
merge trunk
2011-10-04 20:21:12 +02:00
Szymon Janc
b871e8ebcc
* grub-core/Makefile.core.def (btrfs): Remove minilzo.c from common.
2011-10-03 23:01:14 +02:00
Szymon Janc
0e2b7e39f2
* grub-core/fs/btrfs.c: Include <minilzo.h> instead of "minilzo.h".
...
* grub-core/io/lzopio.c: Likewise.
2011-10-03 22:25:06 +02:00
Szymon Janc
c5ed9266fc
* grub-core/io/lzopio.c: Improve crypt context alignment.
2011-10-03 22:06:10 +02:00
Szymon Janc
139d67a82f
* grub-core/fs/btrfs.c: Fix code style regressions.
2011-10-03 21:50:32 +02:00
Vladimir 'phcoder' Serbinenko
9305dd1a82
Some CS5536 code
2011-10-01 22:51:12 +02:00
Vladimir 'phcoder' Serbinenko
1333929060
Disable SMI on OS ownership failure
2011-10-01 22:01:31 +02:00
Vladimir 'phcoder' Serbinenko
81dbdc1d0a
Several small fixes
2011-10-01 21:53:43 +02:00
Vladimir 'phcoder' Serbinenko
2d523c70e5
Use map range
2011-10-01 21:42:44 +02:00
Vladimir 'phcoder' Serbinenko
0a213f4cdb
Move p2v and v2p to pci.h
2011-10-01 21:37:02 +02:00
Vladimir 'phcoder' Serbinenko
e5c0534f0b
Fix p2v and v2p
2011-10-01 21:31:53 +02:00