On Sun, Oct 29, 2017 at 02:34:56PM +0000, Ilya Lesokhin wrote:> > -----Original Message----- > > From: Michael S. Tsirkin [mailto:mst at redhat.com] > > Sent: Sunday, October 29, 2017 4:22 PM > > To: Ilya Lesokhin <ilyal at mellanox.com> > > Cc: virtio-dev at lists.oasis-open.org; virtualization at lists.linux-foundation.org > > Subject: Re: packed ring layout proposal v3 > > > > If you do this whats the point of the id? Just use descriptor offset like virtio 0 did. > > > > I agree that ID is pointless when requests are completed in order. > > But I'm not sure what you mean by descriptor offset?Where the descriptor is within the ring. -- MST
> -----Original Message----- > From: Michael S. Tsirkin [mailto:mst at redhat.com] > Sent: Monday, October 30, 2017 4:09 AM > To: Ilya Lesokhin <ilyal at mellanox.com> > Cc: virtio-dev at lists.oasis-open.org; virtualization at lists.linux-foundation.org > Subject: Re: packed ring layout proposal v3 > > On Sun, Oct 29, 2017 at 02:34:56PM +0000, Ilya Lesokhin wrote: > > > -----Original Message----- > > > From: Michael S. Tsirkin [mailto:mst at redhat.com] > > > Sent: Sunday, October 29, 2017 4:22 PM > > > To: Ilya Lesokhin <ilyal at mellanox.com> > > > Cc: virtio-dev at lists.oasis-open.org; virtualization at lists.linux-foundation.org > > > Subject: Re: packed ring layout proposal v3 > > > > > > If you do this whats the point of the id? Just use descriptor offset like virtio 0 > did. > > > > > > > I agree that ID is pointless when requests are completed in order. > > > > But I'm not sure what you mean by descriptor offset? > > Where the descriptor is within the ring. >Using descriptor offset like virtio 0, won't work. In virtio 0, there was no reordering in the descriptor ring, so the offset was always unique. In the new spec, if descriptor in offset 2 completes before the descriptor in offset 1, It can be put in offset 1, but reusing offset 1 is not yet safe. Also, please ignore my earlier comment about in-order completion, It invalidates the entire discussion.
On Mon, Oct 30, 2017 at 06:30:56AM +0000, Ilya Lesokhin wrote:> > -----Original Message----- > > From: Michael S. Tsirkin [mailto:mst at redhat.com] > > Sent: Monday, October 30, 2017 4:09 AM > > To: Ilya Lesokhin <ilyal at mellanox.com> > > Cc: virtio-dev at lists.oasis-open.org; virtualization at lists.linux-foundation.org > > Subject: Re: packed ring layout proposal v3 > > > > On Sun, Oct 29, 2017 at 02:34:56PM +0000, Ilya Lesokhin wrote: > > > > -----Original Message----- > > > > From: Michael S. Tsirkin [mailto:mst at redhat.com] > > > > Sent: Sunday, October 29, 2017 4:22 PM > > > > To: Ilya Lesokhin <ilyal at mellanox.com> > > > > Cc: virtio-dev at lists.oasis-open.org; virtualization at lists.linux-foundation.org > > > > Subject: Re: packed ring layout proposal v3 > > > > > > > > If you do this whats the point of the id? Just use descriptor offset like virtio 0 > > did. > > > > > > > > > > I agree that ID is pointless when requests are completed in order. > > > > > > But I'm not sure what you mean by descriptor offset? > > > > Where the descriptor is within the ring. > > > > Using descriptor offset like virtio 0, won't work. > In virtio 0, there was no reordering in the descriptor ring, so the offset was always unique. > In the new spec, if descriptor in offset 2 completes before the descriptor in offset 1, > It can be put in offset 1, but reusing offset 1 is not yet safe. > > Also, please ignore my earlier comment about in-order completion, > It invalidates the entire discussion. > >Yes, using offsets only works if all descriptors are used and written back in order. If they are, descriptor ID isn't necessary. If they aren't, it's necessary. -- MST