Re: [PATCH] nvme-pci: fix prp list allocation

From: Keith Busch
Date: Sat Feb 12 2022 - 15:48:59 EST


On Sat, Feb 12, 2022 at 01:06:49PM -0700, Matthew Waltz wrote:
> Fixes kernel block errors originating from the hard-coded 256-byte
> alignment of dma_pool_create(). The NVMe specification requires a PRP
> List PBAO offset field of 0h, i.e. a PRP List must be aligned to the
> configured 4096-byte memory page size.

That is not correct. The spec (2.0a section 4.1.1) says:

The first PRP List entry [...] shall be qword aligned and may also
have a non-zero offset within the memory page.