[openwrt/openwrt] vrx518_ep: fix compilation error with kernel 6.1
LEDE Commits
lede-commits at lists.infradead.org
Sun Aug 27 10:27:38 PDT 2023
hauke pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/e8e5dbc3c91e92ccaa6ea11da208b89f65f79f3d
commit e8e5dbc3c91e92ccaa6ea11da208b89f65f79f3d
Author: Andre Heider <a.heider at gmail.com>
AuthorDate: Tue Aug 22 13:07:02 2023 +0200
vrx518_ep: fix compilation error with kernel 6.1
Unconditionally use the newer APIs, since our oldest supported kernel
contains them too.
Signed-off-by: Andre Heider <a.heider at gmail.com>
---
.../kernel/lantiq/vrx518_ep/patches/100-compat.patch | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/package/kernel/lantiq/vrx518_ep/patches/100-compat.patch b/package/kernel/lantiq/vrx518_ep/patches/100-compat.patch
index f5b917e707..a139c7a862 100644
--- a/package/kernel/lantiq/vrx518_ep/patches/100-compat.patch
+++ b/package/kernel/lantiq/vrx518_ep/patches/100-compat.patch
@@ -42,6 +42,25 @@
dev_err(&pdev->dev,
"%s: Failed to enable MSI interrupts error code: %d\n",
__func__, err);
+@@ -589,15 +589,15 @@ static int dc_ep_probe(struct pci_dev *p
+ /* Target structures have a limit of 32 bit DMA pointers.
+ * DMA pointers can be wider than 32 bits by default on some systems.
+ */
+- ret = pci_set_dma_mask(pdev, DMA_BIT_MASK(32));
++ ret = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));
+ if (ret) {
+ dev_err(&pdev->dev, "32-bit DMA not available: %d\n", ret);
+ goto err_region;
+ }
+
+- ret = pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(32));
++ ret = dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(32));
+ if (ret) {
+- dev_err(&pdev->dev, "cannot enable 32-bit consistent DMA\n");
++ dev_err(&pdev->dev, "cannot enable 32-bit coherent DMA\n");
+ goto err_region;
+ }
+
@@ -654,7 +654,7 @@ static int dc_ep_probe(struct pci_dev *p
goto err_iomap;
More information about the lede-commits
mailing list