qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [PATCH 2/2] Add serial number support for virtio_blk, V


From: Rusty Russell
Subject: [Qemu-devel] Re: [PATCH 2/2] Add serial number support for virtio_blk, V4
Date: Mon, 1 Jun 2009 16:40:01 +0930
User-agent: KMail/1.11.2 (Linux/2.6.28-11-generic; KDE/4.2.2; i686; ; )

On Fri, 29 May 2009 01:45:27 pm john cooper wrote:
> virtio_blk-serial-4.patch

Hate to ask dumb questions, but is there a scsi equivalent of this?  It'd be 
nice if we could avoid being ATA-specific in the long run...

Also, why u16?

Thanks,
Rusty.

> +/* return ATA identify data
> + */
> +static int virtblk_identify(struct gendisk *disk, void *argp)
> +{
> +     struct virtio_blk *vblk = disk->private_data;
> +     u16 *id;
> +     int err = -ENOMEM;
> +
> +     id = kmalloc(VIRTIO_BLK_ID_BYTES, GFP_KERNEL);
> +     if (!id)
> +             goto out;
> +
> +     err = virtio_config_buf(vblk->vdev, VIRTIO_BLK_F_IDENTIFY,
> +             offsetof(struct virtio_blk_config, identify), id,
> +             VIRTIO_BLK_ID_BYTES);





reply via email to

[Prev in Thread] Current Thread [Next in Thread]