summaryrefslogtreecommitdiffstats
path: root/meta-agl-bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi/0003-Fix-PCIe-in-dom0-for-RPi4.patch
diff options
context:
space:
mode:
authorPaul Barker <pbarker@konsulko.com>2021-01-12 11:38:20 +0000
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2021-01-12 16:57:45 +0000
commit8395c5513a6fd133d47a92f88f92ebeacf8183e5 (patch)
treec07d6d5d5a6539caece1be3fff135b3414cd869f /meta-agl-bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi/0003-Fix-PCIe-in-dom0-for-RPi4.patch
parent67248e369aac29a94797f2f6bb52ee162f6ca378 (diff)
linux-raspberrypi: Tidy patches & config fragments
Move all patches and config fragments into the linux-raspberrypi subdirectory to remove confusion and warnings seen for non-4.19 kernel versions: WARNING: .../bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.14.bb: Unable to get checksum for linux-raspberrypi SRC_URI entry 0001-mconf-menuconfig.patch: file could not be found WARNING: .../bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.bb: Unable to get checksum for linux-raspberrypi SRC_URI entry 0001-mconf-menuconfig.patch: file could not be found Bug-AGL: SPEC-3760 Cc: Jan-Simon Moeller <jsmoeller@linuxfoundation.org> Signed-off-by: Paul Barker <pbarker@konsulko.com> Change-Id: Iccb9efcd8240f28437e3494bd008dc9aca649c4e Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl/+/25887 Tested-by: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org> ci-image-build: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org> ci-image-boot-test: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org> Reviewed-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
Diffstat (limited to 'meta-agl-bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi/0003-Fix-PCIe-in-dom0-for-RPi4.patch')
-rw-r--r--meta-agl-bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi/0003-Fix-PCIe-in-dom0-for-RPi4.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/meta-agl-bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi/0003-Fix-PCIe-in-dom0-for-RPi4.patch b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi/0003-Fix-PCIe-in-dom0-for-RPi4.patch
new file mode 100644
index 000000000..835f36da3
--- /dev/null
+++ b/meta-agl-bsp/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi/0003-Fix-PCIe-in-dom0-for-RPi4.patch
@@ -0,0 +1,31 @@
+From 77765c2a47ce43911b8fe7b09f037c9bc13008ca Mon Sep 17 00:00:00 2001
+From: Jeff Kubascik <jeff.kubascik@dornerworks.com>
+Date: Tue, 30 Jul 2019 08:49:56 -0400
+Subject: [PATCH 3/4] Fix PCIe in dom0 for RPi4
+
+There is an issue where the Broadcom PCIe driver and Xen swiotlb layer
+invoke each other's dma alloc function recursively until the stack blows
+up. The cause appears to be due to arch_setup_dma_ops being called
+more than once for the device, possibly through of_dma_configure, and
+screwing up the dma_ops pointers. This patch adds a check to make sure
+that the xen_dma_ops are applied only once for a device.
+---
+ arch/arm64/mm/dma-mapping.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/arch/arm64/mm/dma-mapping.c b/arch/arm64/mm/dma-mapping.c
+index d3a5bb16f..243a3b9be 100644
+--- a/arch/arm64/mm/dma-mapping.c
++++ b/arch/arm64/mm/dma-mapping.c
+@@ -895,7 +895,7 @@ void arch_setup_dma_ops(struct device *dev, u64 dma_base, u64 size,
+ __iommu_setup_dma_ops(dev, dma_base, size, iommu);
+
+ #ifdef CONFIG_XEN
+- if (xen_initial_domain()) {
++ if (!dev->archdata.dev_dma_ops && xen_initial_domain()) {
+ dev->archdata.dev_dma_ops = dev->dma_ops;
+ dev->dma_ops = xen_dma_ops;
+ }
+--
+2.17.1
+