* [PATCH] nvme-pci: fix PRP pool size
@ 2020-08-18 17:51 Christoph Hellwig
2020-08-18 18:58 ` Keith Busch
2020-08-18 19:09 ` Sagi Grimberg
0 siblings, 2 replies; 3+ messages in thread
From: Christoph Hellwig @ 2020-08-18 17:51 UTC (permalink / raw)
To: kbusch, sagi; +Cc: linux-nvme
All operations are based on the controller, not the host page size.
Switch the dma pool to use the controller page size as well to avoid
massive overallocations on large page size systems.
Signed-off-by: Christoph Hellwig <hch@lst.de>
---
drivers/nvme/host/pci.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c
index ba725ae47305ef..a33adab62acbaf 100644
--- a/drivers/nvme/host/pci.c
+++ b/drivers/nvme/host/pci.c
@@ -2460,7 +2460,8 @@ static int nvme_disable_prepare_reset(struct nvme_dev *dev, bool shutdown)
static int nvme_setup_prp_pools(struct nvme_dev *dev)
{
dev->prp_page_pool = dma_pool_create("prp list page", dev->dev,
- PAGE_SIZE, PAGE_SIZE, 0);
+ NVME_CTRL_PAGE_SIZE,
+ NVME_CTRL_PAGE_SIZE, 0);
if (!dev->prp_page_pool)
return -ENOMEM;
--
2.28.0
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] nvme-pci: fix PRP pool size
2020-08-18 17:51 [PATCH] nvme-pci: fix PRP pool size Christoph Hellwig
@ 2020-08-18 18:58 ` Keith Busch
2020-08-18 19:09 ` Sagi Grimberg
1 sibling, 0 replies; 3+ messages in thread
From: Keith Busch @ 2020-08-18 18:58 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: sagi, linux-nvme
On Tue, Aug 18, 2020 at 07:51:59PM +0200, Christoph Hellwig wrote:
> All operations are based on the controller, not the host page size.
> Switch the dma pool to use the controller page size as well to avoid
> massive overallocations on large page size systems.
Oof, we've been over-allocating for a while.
Reviewed-by: Keith Busch <kbusch@kernel.org>
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] nvme-pci: fix PRP pool size
2020-08-18 17:51 [PATCH] nvme-pci: fix PRP pool size Christoph Hellwig
2020-08-18 18:58 ` Keith Busch
@ 2020-08-18 19:09 ` Sagi Grimberg
1 sibling, 0 replies; 3+ messages in thread
From: Sagi Grimberg @ 2020-08-18 19:09 UTC (permalink / raw)
To: Christoph Hellwig, kbusch; +Cc: linux-nvme
Queued for 5.9-rc
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-08-18 19:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-18 17:51 [PATCH] nvme-pci: fix PRP pool size Christoph Hellwig
2020-08-18 18:58 ` Keith Busch
2020-08-18 19:09 ` Sagi Grimberg
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.