All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Laager <rlaager@wiktel.com>
To: "Vladimir 'φ-coder/phcoder' Serbinenko" <phcoder@gmail.com>
Cc: grub-devel@gnu.org
Subject: Re: [PATCH] Don't create grubenv on ZFS
Date: Fri, 03 Feb 2012 05:59:19 -0600	[thread overview]
Message-ID: <1328270359.5007.3.camel@watermelon.coderich.net> (raw)
In-Reply-To: <4F2BB548.5010106@gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 265 bytes --]

I've attached an updated patch.

I also noticed a whitespace inconsistency when looking at another case
statement. I've attached a patch.

Both patches are -p0 and have a ChangeLog entry (in a separate file,
which I think is the convention).

-- 
Richard

[-- Attachment #1.2: zfs-no-grubenv.patch --]
[-- Type: text/x-patch, Size: 929 bytes --]

--- util/grub-install.in	2012-02-03 04:16:36.032265000 -0600
+++ util/grub-install.in	2012-02-03 05:35:50.362628000 -0600
@@ -469,7 +469,12 @@
 grub_device="`"$grub_probe" --device-map="${device_map}" --target=device "${grubdir}"`" || exit 1
 
 if ! test -f "${grubdir}"/grubenv; then
-    "$grub_editenv" "${grubdir}"/grubenv create
+    case "`"$grub_probe" --target=fs "${grubdir}"`" in
+        btrfs | cpiofs | newc | odc | romfs | squash4 | tarfs | zfs)
+	    ;;
+        *)
+            "$grub_editenv" "${grubdir}"/grubenv create
+    esac
 fi
 
 # Create the core image. First, auto-detect the filesystem module.
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ ChangeLog.zfs-no-grubenv	2012-02-03 05:49:27.977376000 -0600
@@ -0,0 +1,5 @@
+2012-02-03  Richard Laager <rlaager@wiktel.com>
+
+	* util/grub-install.in: Don't create a grubenv file on filesystems
+	to which GRUB cannot write.
+

[-- Attachment #1.3: grub-install-whitespace.patch --]
[-- Type: text/x-patch, Size: 1037 bytes --]

--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ ChangeLog.grub-install-whitespace	2012-02-03 05:52:51.439942000 -0600
@@ -0,0 +1,4 @@
+2012-02-03  Richard Laager <rlaager@wiktel.com>
+
+	* util/grub-install.in: Fix some inconsistent whitespace.
+
--- util/grub-install.in	2012-02-03 05:53:36.039465769 -0600
+++ util/grub-install.in	2012-02-03 05:54:04.771697000 -0600
@@ -486,13 +486,13 @@
 # filesystem will be accessible).
 partmap_module=
 for x in `echo "${grub_device}" | xargs "$grub_probe" --device-map="${device_map}" --target=partmap --device 2> /dev/null`; do
-   case "$x" in
-       netbsd | openbsd) 
-	   partmap_module="$partmap_module part_bsd";;
-       "") ;;
-       *)
-	   partmap_module="$partmap_module part_$x";;
-   esac
+    case "$x" in
+        netbsd | openbsd)
+            partmap_module="$partmap_module part_bsd";;
+        "") ;;
+        *)
+            partmap_module="$partmap_module part_$x";;
+    esac
 done
 
 # Device abstraction module, if any (lvm, raid).

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  reply	other threads:[~2012-02-03 11:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-02 11:16 [PATCH] Don't create grubenv on ZFS Richard Laager
2012-02-03 10:05 ` Vladimir 'φ-coder/phcoder' Serbinenko
2012-02-03 10:07   ` Richard Laager
2012-02-03 10:22     ` Vladimir 'φ-coder/phcoder' Serbinenko
2012-02-03 11:59       ` Richard Laager [this message]
2012-02-04 22:34 ` Jordan Uggla
2012-02-05  1:26   ` Richard Laager

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1328270359.5007.3.camel@watermelon.coderich.net \
    --to=rlaager@wiktel.com \
    --cc=grub-devel@gnu.org \
    --cc=phcoder@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.