[PATCH 1/2] nvme-pci: allocate nvme_command within driver pdu

Keith Busch kbusch at kernel.org
Tue Mar 16 18:13:54 GMT 2021


On Tue, Mar 16, 2021 at 07:02:55PM +0100, Christoph Hellwig wrote:
> On Tue, Mar 16, 2021 at 10:06:31AM -0700, Keith Busch wrote:
> > All the nvme transport drivers had allocated the nvme command within the
> > driver's pdu except for pci. Align pci with everyone else and replace
> > the stack variable with the pdu command.
> 
> At some point in this series nvme_request.cmd should become the
> actual structure instead of a pointer so that we can remove this
> indiretion.  I'd be tempted to just do this in the initial patch,
> but I'm fine with any kind of patch ordering.

I tried to start off in that direction, but had some trouble. All the
fabrics drivers embed their preallocated command within a larger
protocol specific payload, so we either need the indirection or have a
copy of the command.



More information about the Linux-nvme mailing list