From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1M9tX2-0008D3-JP for qemu-devel@nongnu.org; Fri, 29 May 2009 00:17:24 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1M9tWx-0008Bk-5S for qemu-devel@nongnu.org; Fri, 29 May 2009 00:17:23 -0400 Received: from [199.232.76.173] (port=45969 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1M9tWx-0008Bh-0L for qemu-devel@nongnu.org; Fri, 29 May 2009 00:17:19 -0400 Received: from mx2.redhat.com ([66.187.237.31]:53785) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1M9tWw-0001e0-GF for qemu-devel@nongnu.org; Fri, 29 May 2009 00:17:18 -0400 Message-ID: <4A1F6130.9070705@redhat.com> Date: Fri, 29 May 2009 00:14:40 -0400 From: john cooper MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] [PATCH 0/2] Add serial number support for virtio_blk, V4 List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: KVM list , qemu-devel@nongnu.org Cc: john.cooper@redhat.com, Rusty Russell , Christoph Hellwig [Rework of earlier patch to provide additional information in the response to an ATA identify request -- virtio_blk treats the data as opaque, content created by qemu's virtio-blk. Comments from Christoph also incorporated.] This patch allows passing of a virtio_blk drive serial number from qemu into a guest's virtio_blk driver, and provides a means to access the serial number from a guest's userspace. Equivalent functionality currently exists for IDE and SCSI, however it is not yet implemented for virtio. Scenarios exist where guest code relies on a unique drive serial number to correctly identify the machine environment in which it exists. The following two patches implement the above: qemu-vblk-serial-4.patch which provides the qemu missing bits to interpret a '-drive .. serial=XYZ ..' flag, and: virtio_blk-serial-4.patch which extracts this information and makes it available to guest userspace via an HDIO_GET_IDENTITY ioctl, eg: 'hdparm -i /dev/vda'. The above patches are relative to qemu-kvm.git and 2.6.29.3 respectively. -john -- john.cooper@redhat.com