diff options
author | Stephen Rothwell <sfr@canb.auug.org.au> | 2015-06-30 03:59:04 +0300 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2015-07-07 14:27:03 +0300 |
commit | 908a5544cd29ed60114ed60bded6dbe8cdd56326 (patch) | |
tree | f5e2af14e04fb053e296b64ec79855bd08f69952 /drivers | |
parent | bcfeacab45e6d419c6bafc0e57ea4b1125e23231 (diff) | |
download | linux-908a5544cd29ed60114ed60bded6dbe8cdd56326.tar.xz |
virtio scsi: fix unused variable warning
drivers/scsi/virtio_scsi.c: In function 'virtscsi_probe':
drivers/scsi/virtio_scsi.c:952:11: warning: unused variable 'host_prot' [-Wunused-variable]
int err, host_prot;
^
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/virtio_scsi.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/scsi/virtio_scsi.c b/drivers/scsi/virtio_scsi.c index f164f24a4a55..55441c7f3e83 100644 --- a/drivers/scsi/virtio_scsi.c +++ b/drivers/scsi/virtio_scsi.c @@ -944,7 +944,7 @@ static int virtscsi_probe(struct virtio_device *vdev) { struct Scsi_Host *shost; struct virtio_scsi *vscsi; - int err, host_prot; + int err; u32 sg_elems, num_targets; u32 cmd_per_lun; u32 num_queues; @@ -1003,6 +1003,8 @@ static int virtscsi_probe(struct virtio_device *vdev) shost->nr_hw_queues = num_queues; if (virtio_has_feature(vdev, VIRTIO_SCSI_F_T10_PI)) { + int host_prot; + host_prot = SHOST_DIF_TYPE1_PROTECTION | SHOST_DIF_TYPE2_PROTECTION | SHOST_DIF_TYPE3_PROTECTION | SHOST_DIX_TYPE1_PROTECTION | SHOST_DIX_TYPE2_PROTECTION | SHOST_DIX_TYPE3_PROTECTION; |