2010/8/18, Colin Watson <cjwat...@ubuntu.com>:
> On Wed, Aug 18, 2010 at 03:07:57PM +0200, Aurelien Jarno wrote:
>> Since GNU/kFreeBSD switch to grub as the default bootloader, it is
>> almost possible to use an ext2 or xfs root filesystem. While there
>> is not a lot of interest in doing that, the patch to do it is quite
>> small. Could you please apply it in the next upload?
>
> Sending upstream first.  Does this require copyright assignment?

I'd rather make it generic, something like this.  Does it work for you?

This has interesting side-effects, like for example it would be possible to
build UFS as a module.

-- 
Robert Millan
2010-08-20  Robert Millan  <r...@gnu.org>

	* util/grub.d/10_kfreebsd.in (kfreebsd_entry): Add generic module
	load routine.
	Map GRUB `ext2' to kFreeBSD `ext2fs'.

=== modified file 'util/grub.d/10_kfreebsd.in'
--- util/grub.d/10_kfreebsd.in	2010-08-08 14:27:58 +0000
+++ util/grub.d/10_kfreebsd.in	2010-08-19 21:54:59 +0000
@@ -92,6 +92,14 @@ EOF
 	kfreebsd_module		${rel_dirname}/zfs/zpool.cache type=/boot/zfs/zpool.cache
 EOF
     ;;
+    *)
+      ls "${module_dir}/${kfreebsd_fs}.ko" > /dev/null
+
+      printf '%s\n' "${prepare_module_dir_cache}"
+      cat << EOF
+	kfreebsd_module_elf	${module_dir_rel}/${kfreebsd_fs}.ko
+EOF
+    ;;
   esac
 
   cat << EOF
@@ -121,8 +129,9 @@ while [ "x$list" != "x" ] ; do
   fi
 
   case ${GRUB_FS} in
-    ufs1 | ufs2)        kfreebsd_fs=ufs ;;
-    *)                  kfreebsd_fs=${GRUB_FS} ;;
+    ufs1 | ufs2)	kfreebsd_fs=ufs ;;
+    ext2)		kfreebsd_fs=ext2fs ;;
+    *)			kfreebsd_fs=${GRUB_FS} ;;
   esac
 
   case ${GRUB_FS} in

_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to