diff options
author | bad <bad@pkgsrc.org> | 2006-10-17 21:55:33 +0000 |
---|---|---|
committer | bad <bad@pkgsrc.org> | 2006-10-17 21:55:33 +0000 |
commit | 9fd8390500195de4867d42218fb34d8c84253817 (patch) | |
tree | 7cae2f154a9e0dbdf0df0638d470091827810983 /sysutils/grub | |
parent | 47a8fedecebef9af836881921cc0ba78f3609d45 (diff) | |
download | pkgsrc-9fd8390500195de4867d42218fb34d8c84253817.tar.gz |
stage2/pc_slice.h: add the missing disklabel FS_TYPE #defines and RF_PROTECTED_SECTORS.
stage2/disk_io.c: adjust the partition start and size by RF_PROTECTED sectors for partitions of type FS_RAID.
stage2/fsys_ffs.c: accept partitions of type FS_RAID as candidates for FFS, too.
stage2/fsys_ufs2.c: accept partitions of type FS_RAID as candidates for FFSv2, too.
This allows grub to directly boot from NetBSD RAID1 partitions the same way
as with the native bootloader.
Bump PKGREVISION.
Diffstat (limited to 'sysutils/grub')
-rw-r--r-- | sysutils/grub/Makefile | 4 | ||||
-rw-r--r-- | sysutils/grub/distinfo | 6 | ||||
-rw-r--r-- | sysutils/grub/patches/patch-aa | 18 | ||||
-rw-r--r-- | sysutils/grub/patches/patch-ab | 20 | ||||
-rw-r--r-- | sysutils/grub/patches/patch-af | 14 | ||||
-rw-r--r-- | sysutils/grub/patches/patch-ag | 14 |
6 files changed, 73 insertions, 3 deletions
diff --git a/sysutils/grub/Makefile b/sysutils/grub/Makefile index 526b6bf1a46..533e7ab5bf8 100644 --- a/sysutils/grub/Makefile +++ b/sysutils/grub/Makefile @@ -1,8 +1,8 @@ -# $NetBSD: Makefile,v 1.44 2006/05/13 14:41:51 jmmv Exp $ +# $NetBSD: Makefile,v 1.45 2006/10/17 21:55:33 bad Exp $ # DISTNAME= grub-0.97 -PKGREVISION= 5 +PKGREVISION= 6 CATEGORIES= sysutils MASTER_SITES= ftp://alpha.gnu.org/gnu/grub/ diff --git a/sysutils/grub/distinfo b/sysutils/grub/distinfo index 2495e6e1d28..35368d61a6c 100644 --- a/sysutils/grub/distinfo +++ b/sysutils/grub/distinfo @@ -1,10 +1,14 @@ -$NetBSD: distinfo,v 1.19 2006/02/03 09:59:32 jmmv Exp $ +$NetBSD: distinfo,v 1.20 2006/10/17 21:55:33 bad Exp $ SHA1 (grub-0.97.tar.gz) = 2580626c4579bd99336d3af4482c346c95dac4fb RMD160 (grub-0.97.tar.gz) = 7fb5674edf0c950bd38e94f85ff1e2909aa741f0 Size (grub-0.97.tar.gz) = 971783 bytes +SHA1 (patch-aa) = 2fd8872e6e3d3912d41d3eb8dff9371320a53bf3 +SHA1 (patch-ab) = 945ee0385d82f4ea98e86acfa449bcbf2a214285 SHA1 (patch-ac) = dc7774a09ca88f6696e0680a7be39df56244eedc SHA1 (patch-ad) = 613e915a015ad22c9bd5712d416e12b1b81fdb93 SHA1 (patch-ae) = 96d8283e90ceb3e887ba0ada05619858c52bc144 +SHA1 (patch-af) = 9447ead52940203c998afb67e38ae3d3d26097f8 +SHA1 (patch-ag) = 1dd709652d457ba03dda47b64d22cd9320f81e26 SHA1 (patch-ai) = 60088cf6786a364da37e19fbb5df4c6fd7641016 SHA1 (patch-aj) = bfbac23a7c250ed615dcfb4a988708c970b617d8 diff --git a/sysutils/grub/patches/patch-aa b/sysutils/grub/patches/patch-aa new file mode 100644 index 00000000000..8c423465f09 --- /dev/null +++ b/sysutils/grub/patches/patch-aa @@ -0,0 +1,18 @@ +$NetBSD: patch-aa,v 1.3 2006/10/17 21:55:33 bad Exp $ + +--- stage2/pc_slice.h.orig 2003-07-09 13:45:53.000000000 +0200 ++++ stage2/pc_slice.h 2006-09-18 00:36:35.000000000 +0200 +@@ -246,6 +246,13 @@ + #define FS_HFS 15 /* Macintosh HFS */ + #define FS_FILECORE 16 /* Acorn Filecore Filing System */ + #define FS_EXT2FS 17 /* Linux Extended 2 file system */ ++#define FS_NTFS 18 /* Windows/NT file system */ ++#define FS_RAID 19 /* RAIDframe component */ ++#define FS_CCD 20 /* concatenated disk component */ ++#define FS_JFS2 21 /* IBM JFS2 */ ++#define FS_APPLEUFS 22 /* Apple UFS */ ++ ++#define RF_PROTECTED_SECTORS 64 /* sectors reserved by RAIDframe */ + + + #endif /* _PC_SLICE_H */ diff --git a/sysutils/grub/patches/patch-ab b/sysutils/grub/patches/patch-ab new file mode 100644 index 00000000000..8e7c7caf8b3 --- /dev/null +++ b/sysutils/grub/patches/patch-ab @@ -0,0 +1,20 @@ +$NetBSD: patch-ab,v 1.3 2006/10/17 21:55:33 bad Exp $ + +--- stage2/disk_io.c.orig 2004-05-23 18:35:24.000000000 +0200 ++++ stage2/disk_io.c 2006-09-18 01:12:19.000000000 +0200 +@@ -632,6 +632,15 @@ + bsd_evil_hack = 4; + #endif /* ! STAGE1_5 */ + ++ if (BSD_PART_TYPE(buf, i) == FS_RAID) ++ { ++ /* found a RAID partition, restart inside that */ ++ /* *offset += RF_PROTECTED_SECTORS; */ ++ *start += RF_PROTECTED_SECTORS; ++ *len -= RF_PROTECTED_SECTORS; ++ /* *partition = (*partition & 0xFF00FF) | (0xFF << 8); */ ++ /* return next_bsd_partition(); */ ++ } + return 1; + } + } diff --git a/sysutils/grub/patches/patch-af b/sysutils/grub/patches/patch-af new file mode 100644 index 00000000000..f180d1965cc --- /dev/null +++ b/sysutils/grub/patches/patch-af @@ -0,0 +1,14 @@ +$NetBSD: patch-af,v 1.3 2006/10/17 21:55:33 bad Exp $ + +--- stage2/fsys_ffs.c.orig 2003-07-09 13:45:52.000000000 +0200 ++++ stage2/fsys_ffs.c 2006-09-20 00:38:40.000000000 +0200 +@@ -83,7 +83,8 @@ + int retval = 1; + + if ((((current_drive & 0x80) || (current_slice != 0)) +- && ! IS_PC_SLICE_TYPE_BSD_WITH_FS (current_slice, FS_BSDFFS)) ++ && ! (IS_PC_SLICE_TYPE_BSD_WITH_FS (current_slice, FS_BSDFFS) ++ || IS_PC_SLICE_TYPE_BSD_WITH_FS(current_slice, FS_RAID))) + || part_length < (SBLOCK + (SBSIZE / DEV_BSIZE)) + || !devread (SBLOCK, 0, SBSIZE, (char *) SUPERBLOCK) + || SUPERBLOCK->fs_magic != FS_MAGIC) diff --git a/sysutils/grub/patches/patch-ag b/sysutils/grub/patches/patch-ag new file mode 100644 index 00000000000..4c3b4be181d --- /dev/null +++ b/sysutils/grub/patches/patch-ag @@ -0,0 +1,14 @@ +$NetBSD: patch-ag,v 1.3 2006/10/17 21:55:33 bad Exp $ + +--- stage2/fsys_ufs2.c.orig 2004-06-19 14:17:52.000000000 +0200 ++++ stage2/fsys_ufs2.c +@@ -88,7 +88,8 @@ ufs2_mount (void) + type = 0; + + if (! (((current_drive & 0x80) || (current_slice != 0)) +- && ! IS_PC_SLICE_TYPE_BSD_WITH_FS (current_slice, FS_BSDFFS))) ++ && ! (IS_PC_SLICE_TYPE_BSD_WITH_FS (current_slice, FS_BSDFFS) ++ || IS_PC_SLICE_TYPE_BSD_WITH_FS (current_slice, FS_RAID)))) + { + for (i = 0; sblock_try[i] != -1; ++i) + { |