[PATCH] nvme-pci: fix host memory buffer allocation size
Christoph Hellwig
hch at lst.de
Thu Apr 28 08:06:44 PDT 2022
On Thu, Apr 28, 2022 at 04:44:47PM +0200, Thomas Weißschuh wrote:
> Is the current code supposed to reach HMPRE? It does not for me.
>
> The code tries to allocate memory for HMPRE in chunks.
> The best allocation would be to allocate one chunk for all of HMPRE.
> If this fails we half the chunk size on each iteration and try again.
>
> On my hardware we start with a chunk_size of 4MiB and just allocate
> 8 (hmmaxd) * 4 = 32 MiB which is worse than 1 * 200MiB.
And that is because the hardware only has a limited set of descriptors.
Is there any real problem you are fixing with this? Do you actually
see a performance difference on a relevant workload?
More information about the Linux-nvme
mailing list