[Report] requests are submitted to hardware in reverse order from nvme/virtio-blk queue_rqs()

Christoph Hellwig hch at infradead.org
Fri Jan 26 06:10:23 PST 2024


On Wed, Jan 24, 2024 at 07:59:54PM +0800, Ming Lei wrote:
> Hello,
> 
> Requests are added to plug list in reverse order, and both virtio-blk
> and nvme retrieves request from plug list in order, so finally requests
> are submitted to hardware in reverse order via nvme_queue_rqs() or
> virtio_queue_rqs, see:

> May this reorder be one problem for virtio-blk and nvme-pci?

It it isn't really a problem for the drivers, but de-serializing
I/O patterns tends to be not good.  I know at least a couple cases
where this would hurt:

 - SSDs with sequential write detection
 - zoned SSDs with zoned append, as this now turns a sequential
   user write pattern into one that is fairly random
 - HDDs much prefer real sequential I/O, although until nvme HDDs
   go beyong the prototype stage that's probably not hitting this
   case yet

So yes, we should fix this.

> 
> 
> Thanks,
> Ming
> 
> 
---end quoted text---



More information about the Linux-nvme mailing list