[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <a7220de9-0a51-0548-03c0-236e37aa2ef4@redhat.com>
Date: Fri, 11 Aug 2017 20:36:59 +0200
From: Paolo Bonzini <pbonzini@...hat.com>
To: "Michael S. Tsirkin" <mst@...hat.com>
Cc: "Richard W.M. Jones" <rjones@...hat.com>, jejb@...ux.vnet.ibm.com,
martin.petersen@...cle.com, jasowang@...hat.com,
linux-scsi@...r.kernel.org, linux-kernel@...r.kernel.org,
virtualization@...ts.linux-foundation.org, hch@....de
Subject: Re: [PATCH 1/2] virtio: Reduce BUG if total_sg > virtqueue size to
WARN.
On 11/08/2017 19:23, Michael S. Tsirkin wrote:
> On Fri, Aug 11, 2017 at 04:09:26PM +0200, Paolo Bonzini wrote:
>> On 10/08/2017 23:41, Michael S. Tsirkin wrote:
>>>>> Then we probably should fail probe if vq size is too small.
>>>> What does this mean?
>>>
>>> We must prevent driver from submitting s/g lists > vq size to device.
>>
>> What is the rationale for the limit?
>
> So the host knows what it needs to support.
>
>> both virtio-blk and virtio-scsi transmit their own value for the
>> maximum sg list size (max_seg in virtio-scsi, seg_max in virtio-blk).
>
> No other device has it, and it seemed like a good idea to
> limit it generally at the time.
>
> we can fix the spec to relax the requirement for blk and scsi -
> want to submit a proposal? Alternatively, add a generic field
> for that.
Yes, I can submit a proposal. blk and scsi are the ones that are most
likely to have very long sg lists.
When I was designing scsi I just copied that field from blk. :)
Paolo
Powered by blists - more mailing lists