[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: RE: [virtio-comment] Re: [PATCH 0/3] Rename queue index to queue number
> From: Michael S. Tsirkin <mst@redhat.com> > Sent: Wednesday, March 1, 2023 12:38 PM > > On Wed, Mar 01, 2023 at 06:22:07PM +0100, Halil Pasic wrote: > > On Mon, 27 Feb 2023 09:45:31 +0100 > > Cornelia Huck <cohuck@redhat.com> wrote: > > > > > For the vq index/number, I'm not that sure that "virtqueue number" > > > is better that "virtqueue index" -- actually, I'd prefer the latter. > > > We'd need some renaming either way. > > > > I prefer index as well. Especially that we start indexing with 0. Also > > seems to be the more common term for such stuff in both Mathematics > > and CS. > > > > Regards, > > Halil > > > Basically I am saying that this: > > /* Queue size for the currently selected queue - Write Only */ > #define VIRTIO_MMIO_QUEUE_NUM 0x038 > > is a bad name because queue number seems to be ambiguous. > > Maybe start with just getting rid of uses of QUEUE_NUM meaning size? > > > If we want to use queue index we need to fix RSS spec in networking > since that seems to want to use queue index in a very weird way: > networking has this idea of calling queues like this: > receiveq1 receiveq2 .... > why 1-based? I guess we wanted this to be clear even to a 5 year olds ;) > > And then for extra fun, in the RSS section we say "0 based index" where we > seem to mean "this number in the queue name, but subtract 1 in your head". > Why subtract 1? I guess we wanted these 5 year olds to practice math ... :) I think vqn is just fine that helps to keep things simple. I will insert the patch to fix the net device's index text and other text suggestions that Michael had for MMIO side.
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]