public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] PCI: apple: Add depends on PAGE_SIZE_16KB
@ 2025-02-11 18:03 Alyssa Rosenzweig
  2025-02-11 18:38 ` Bjorn Helgaas
  0 siblings, 1 reply; 6+ messages in thread
From: Alyssa Rosenzweig @ 2025-02-11 18:03 UTC (permalink / raw)
  To: Lorenzo Pieralisi, Krzysztof Wilczyński,
	Manivannan Sadhasivam, Rob Herring, Bjorn Helgaas
  Cc: linux-pci, linux-kernel, Janne Grunau, Alyssa Rosenzweig

From: Janne Grunau <j@jannau.net>

The iommu on Apple's M1 and M2 supports only a page size of 16kB and is
mandatory for PCIe devices. Mismatched page sizes will render devices
useless due to non-working DMA. While the iommu prints a warning in this
scenario, it seems a common and hard to debug problem, so prevent it at
build-time.

Signed-off-by: Janne Grunau <j@jannau.net>
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
---
 drivers/pci/controller/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/pci/controller/Kconfig b/drivers/pci/controller/Kconfig
index 9800b768105402d6dd1ba4b134c2ec23da6e4201..507e6ac5d65257578e4eec74b459f6605c9c2907 100644
--- a/drivers/pci/controller/Kconfig
+++ b/drivers/pci/controller/Kconfig
@@ -39,6 +39,7 @@ config PCIE_APPLE
 	depends on ARCH_APPLE || COMPILE_TEST
 	depends on OF
 	depends on PCI_MSI
+	depends on PAGE_SIZE_16KB || COMPILE_TEST
 	select PCI_HOST_COMMON
 	help
 	  Say Y here if you want to enable PCIe controller support on Apple

---
base-commit: 2014c95afecee3e76ca4a56956a936e23283f05b
change-id: 20250211-pci-16k-4c391a5dcd18

Best regards,
-- 
Alyssa Rosenzweig <alyssa@rosenzweig.io>


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2025-02-16 19:51 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-11 18:03 [PATCH] PCI: apple: Add depends on PAGE_SIZE_16KB Alyssa Rosenzweig
2025-02-11 18:38 ` Bjorn Helgaas
2025-02-11 19:56   ` Janne Grunau
2025-02-11 22:00     ` Janne Grunau
2025-02-14 15:44       ` Manivannan Sadhasivam
2025-02-16 19:51       ` Alyssa Rosenzweig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox