[PATCH] nvmet: use the local P2P device on metadata allocation failure
Keith Busch
kbusch at kernel.org
Sat Oct 3 01:57:47 PDT 2026
On Wed, Sep 30, 2026 at 04:08:58PM +0900, Sang-Hoon Choi wrote:
> nvmet_req_alloc_p2pmem_sgls() assigns req->p2p_dev only after the data
> and metadata SGL allocations succeed. If the data allocation succeeds
> but the metadata allocation fails, out_free_sg passes req->p2p_dev to
> pci_p2pmem_free_sgl() before that assignment has taken place.
>
> Pass the local p2p_dev argument instead, so cleanup uses the same PCI
> device as the successful data allocation.
Thanks, applied to nvme-7.3.
More information about the Linux-nvme
mailing list