[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20141201135552.01915825.cornelia.huck@de.ibm.com>
Date: Mon, 1 Dec 2014 13:55:52 +0100
From: Cornelia Huck <cornelia.huck@...ibm.com>
To: "Michael S. Tsirkin" <mst@...hat.com>
Cc: linux-kernel@...r.kernel.org, David Miller <davem@...emloft.net>,
rusty@....ibm.com, nab@...ux-iscsi.org, pbonzini@...hat.com,
thuth@...ux.vnet.ibm.com, dahi@...ux.vnet.ibm.com,
"James E.J. Bottomley" <JBottomley@...allels.com>,
Rusty Russell <rusty@...tcorp.com.au>,
linux-scsi@...r.kernel.org,
virtualization@...ts.linux-foundation.org
Subject: Re: [PATCH v7 42/46] virtio_scsi: v1.0 support
On Mon, 1 Dec 2014 14:53:05 +0200
"Michael S. Tsirkin" <mst@...hat.com> wrote:
> On Mon, Dec 01, 2014 at 01:50:01PM +0100, Cornelia Huck wrote:
> > On Sun, 30 Nov 2014 17:12:47 +0200
> > "Michael S. Tsirkin" <mst@...hat.com> wrote:
> >
> > > Note: for consistency, and to avoid sparse errors,
> > > convert all fields, even those no longer in use
> > > for virtio v1.0.
> > >
> > > Signed-off-by: Michael S. Tsirkin <mst@...hat.com>
> > > Acked-by: Paolo Bonzini <pbonzini@...hat.com>
> > > ---
> > > include/linux/virtio_scsi.h | 32 +++++++++++++++-------------
> > > drivers/scsi/virtio_scsi.c | 51 ++++++++++++++++++++++++++++-----------------
> > > 2 files changed, 49 insertions(+), 34 deletions(-)
> > >
> >
> > > @@ -196,10 +196,13 @@ static void virtscsi_complete_cmd(struct virtio_scsi *vscsi, void *buf)
> > > break;
> > > }
> > >
> > > - WARN_ON(resp->sense_len > VIRTIO_SCSI_SENSE_SIZE);
> > > + WARN_ON(virtio32_to_cpu(vscsi->vdev, resp->sense_len) >
> > > + VIRTIO_SCSI_SENSE_SIZE);
> >
> > Introduce a local variable for this? Might make this statement and the
> > min_t statement below easier to read.
>
> I prefer 1:1 code conversions. We can do refactorings on top.
> Since you mention this line as hard to read, I'll just make it > 80
> chars for now, and trivial line splits can come later.
> OK?
I guess I don't care strongly enough about this, so go ahead.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists