linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ryan Harper <ryanh@us.ibm.com>
To: linux-hotplug@vger.kernel.org
Subject: Re: [PATCH 1/3] Add virtioblk_id tool to extract drive serial numbers
Date: Tue, 29 Jun 2010 14:48:34 +0000	[thread overview]
Message-ID: <20100629144834.GD1647@us.ibm.com> (raw)
In-Reply-To: <1275592024-2625-2-git-send-email-ryanh@us.ibm.com>

* Kay Sievers <kay.sievers@vrfy.org> [2010-06-14 08:30]:
> On Mon, Jun 14, 2010 at 15:15, Ryan Harper <ryanh@us.ibm.com> wrote:
> > * Kay Sievers <kay.sievers@vrfy.org> [2010-06-14 03:55]:
> >> On Thu, Jun 10, 2010 at 21:16, Ryan Harper <ryanh@us.ibm.com> wrote:
> >> > Use the 'VBID' virtio-blk ioctl to extract drive serial numbers
> >> > to be used for building disk/by-id symlinks.  After extracting
> >> > the serial number of the device it prints out the minimum info
> >> > needed in a similar format to `scsi_id --export` so that the
> >> > persistent-storage rules can process the serial information.
> >> >
> >> > This program depends on the virtio-blk serial device patches posted
> >> > here[1] being applied to qemu and linux-kernel.
> >> >
> >> > Here is what the output looks like:
> >> >
> >> > % ./virtioblk_id /dev/vdb
> >> > ID_VIRTIO=1
> >> > ID_TYPE=disk
> >> > ID_SERIAL=QM00001
> >> > ID_SERIAL_SHORT=QM00001
> >>
> >> As requested in the ealier mail. Please provide a good reason why the
> >> kernel code can not create a "serial" file (or whatever fits your
> >> needs) in sysfs at the block device.
> >
> > I didn't see you respond John's email:
> >
> > http://www.spinics.net/lists/hotplug/msg03869.html
> >
> > which included quite  bit of the gory history on this topic.
> 
> Yeah, and I don't find any reason there, why a sysfs attribute will not work.

You were quite right; the sysfs attribute route was rather simple.
Thanks for pointing me in the right direction.  We've got the
kernel-side fix picked up.  I've posted v3 of this series that uses the
sysfs attribute.

Thanks!

-- 
Ryan Harper
Software Engineer; Linux Technology Center
IBM Corp., Austin, Tx
ryanh@us.ibm.com

      parent reply	other threads:[~2010-06-29 14:48 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-03 19:07 [PATCH 0/3] Add virtio-blk support to persistent-storage rules Ryan Harper
2010-06-03 19:07 ` [PATCH 1/3] Add virtioblk_id tool to extract drive serial numbers Ryan Harper
2010-06-03 19:52   ` Kay Sievers
2010-06-03 20:01   ` Ryan Harper
2010-06-03 20:04   ` Kay Sievers
2010-06-03 20:13   ` David Zeuthen
2010-06-03 21:03   ` Ryan Harper
2010-06-04 15:06     ` john cooper
2010-06-10 19:16   ` Ryan Harper
2010-06-14  8:54   ` Kay Sievers
2010-06-14 13:15   ` Ryan Harper
2010-06-14 13:29   ` Kay Sievers
2010-06-29 14:48   ` Ryan Harper [this message]

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=20100629144834.GD1647@us.ibm.com \
    --to=ryanh@us.ibm.com \
    --cc=linux-hotplug@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;
as well as URLs for NNTP newsgroup(s).