[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1f8289f84cd4dd9f440705d3ebab2c8a3e2e6a2c.camel@sipsolutions.net>
Date: Mon, 17 May 2021 11:11:59 +0200
From: Johannes Berg <johannes@...solutions.net>
To: Xie Yongji <xieyongji@...edance.com>, mst@...hat.com,
jasowang@...hat.com, stefanha@...hat.com
Cc: amit@...nel.org, arei.gonglei@...wei.com, airlied@...ux.ie,
kraxel@...hat.com, dan.j.williams@...el.com, ohad@...ery.com,
bjorn.andersson@...aro.org, david@...hat.com, vgoyal@...hat.com,
miklos@...redi.hu, sgarzare@...hat.com,
virtualization@...ts.linux-foundation.org,
linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH 01/17] virtio_ring: Avoid reading unneeded used
length
On Mon, 2021-05-17 at 17:08 +0800, Xie Yongji wrote:
> If device driver doesn't need used length, it can pass a NULL
> len in virtqueue_get_buf()/virtqueue_get_buf_ctx().
>
Well, actually, it can't right now?
You should probably rephrase this, saying something like
Allow passing NULL to len in ... if the device driver doesn't need
the length, and don't read it in that case.
or so?
> Then
> we can avoid reading and validating the len value in used
> ring entries.
Not sure what that "validating" is about, I only see reading?
johannes
Powered by blists - more mailing lists