mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Soren Hansen <soren@linux2go.dk>
To: linux-kernel@vger.kernel.org
Subject: [PATCH 2/2] Make the Xen block device prefix configurable
Date: Fri, 14 May 2010 18:10:48 +0200	[thread overview]
Message-ID: <f0020ee67542b6b535372d6a7b217d71a2c7293b.1273825543.git.soren@linux2go.dk> (raw)
In-Reply-To: <cover.1273825543.git.soren@linux2go.dk>

Add a config option to tweak the Xen block device prefix.

Signed-off-by: Soren Hansen <soren@linux2go.dk>
Tested-By: Major Hayden <major.hayden@rackspace.com>
---
 drivers/block/Kconfig        |   10 ++++++++++
 drivers/block/xen-blkfront.c |    2 +-
 2 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/drivers/block/Kconfig b/drivers/block/Kconfig
index 1d886e0..89c1887 100644
--- a/drivers/block/Kconfig
+++ b/drivers/block/Kconfig
@@ -467,6 +467,16 @@ config XEN_BLKDEV_FRONTEND
 	  block device driver.  It communicates with a back-end driver
 	  in another domain which drives the actual block device.
 
+config XEN_BLKDEV_NAME
+	string "Base name for Xen block devices"
+	depends on XEN_BLKDEV_FRONTEND
+	default "xvd"
+	help
+	  Use this as the base name for Xen block devices. This is
+	  traditionally "xvd", but if you're trying to boot a system
+	  that expects to find its root device on /dev/sda, you can
+	  use this setting to accomodate that.
+
 config VIRTIO_BLK
 	tristate "Virtio block driver (EXPERIMENTAL)"
 	depends on EXPERIMENTAL && VIRTIO
diff --git a/drivers/block/xen-blkfront.c b/drivers/block/xen-blkfront.c
index b8578bb..a8fd8fd 100644
--- a/drivers/block/xen-blkfront.c
+++ b/drivers/block/xen-blkfront.c
@@ -117,7 +117,7 @@ static DEFINE_SPINLOCK(blkif_io_lock);
 #define VDEV_IS_EXTENDED(dev) ((dev)&(EXTENDED))
 #define BLKIF_MINOR_EXT(dev) ((dev)&(~EXTENDED))
 
-#define DEV_NAME	"xvd"	/* name in /dev */
+#define DEV_NAME CONFIG_XEN_BLKDEV_NAME /* name in /dev */
 
 static int get_id_from_freelist(struct blkfront_info *info)
 {
-- 
1.7.0.4


  parent reply	other threads:[~2010-05-14 16:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-14 16:11 [PATCH 0/2] A couple of workarounds for Xen based VPS services Soren Hansen
2010-05-14 16:10 ` [PATCH 1/2] Allow hvc tty's to pose as vt's Soren Hansen
2010-05-14 16:43   ` Alan Cox
2010-05-14 16:50     ` Soren Hansen
2010-05-18 21:26   ` Valdis.Kletnieks
2010-05-14 16:10 ` Soren Hansen [this message]
2010-05-14 16:29   ` [PATCH 2/2] Make the Xen block device prefix configurable Randy Dunlap

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=f0020ee67542b6b535372d6a7b217d71a2c7293b.1273825543.git.soren@linux2go.dk \
    --to=soren@linux2go.dk \
    --cc=linux-kernel@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®