kernel-module-pcie: Use devicetree to configure gpios

id:452476
This commit is contained in:
Alexandre Bard 2023-09-27 16:51:46 +02:00 committed by Alexandre Bard
parent d9c27fbd9a
commit 3c81ac50ca
3 changed files with 2 additions and 41 deletions

View File

@ -1,38 +0,0 @@
diff --git a/netbox_pcie.c b/netbox_pcie.c
index 934368e..d982b78 100644
--- a/netbox_pcie.c
+++ b/netbox_pcie.c
@@ -36,7 +36,6 @@
#include <linux/kern_levels.h>
#include <linux/version.h>
-#include <nbsw.h>
#include <misc/nrsw-global.h>
#include <linux/board_descriptor.h>
@@ -806,7 +805,6 @@ static int nm_pcie_probe(struct platform_device *pdev)
pcie_slot_count = 0;
hwver = hwrel = -1;
-#ifdef NBSW_TARGET_netbolt_arm
if (NBHW == 14) {
for (i = 0; i < 6; i++) {
ps = pcie_add_slot(i, PCIE_MAIN);
@@ -850,8 +848,7 @@ static int nm_pcie_probe(struct platform_device *pdev)
if (ret)
goto error;
}
-#elif defined(NBSW_TARGET_netbird_arm)
- if (NBHW == 16) {
+ } else if (NBHW == 16) {
ps = pcie_add_slot(0, PCIE_MAIN);
if (IS_ERR(ps)) {
ret = PTR_ERR(ps);
@@ -1116,7 +1113,6 @@ static int nm_pcie_probe(struct platform_device *pdev)
ret = pcie_init_slot(ps);
if (ret)
goto error;
-#endif
} else {
printk("Unknwon NBHW: %d\n", NBHW);
ret = -EINVAL;

View File

@ -3,11 +3,10 @@ LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=b234ee4d69f5fce4486a80fdaf4a4263"
SRC_URI = "git://git.netmodule.intranet/NRSW/netbox_pcie.git;protocol=ssh;user=gitea;branch=master \
file://temporary-src-tree-fix-pcie.patch \
"
PV = "1.0+git${SRCPV}"
SRCREV="6467938980a2829539419a94edfe1324025bbdfb"
SRCREV = "b479888720835ae1a03c78531e08ff5f70e26b50"
S = "${WORKDIR}/git"

View File

@ -20,7 +20,7 @@ KERNEL_VERSION_SANITY_SKIP="1"
LINUX_VERSION = "5.15"
LINUX_VERSION_EXTENSION = "-netmodule"
SRCREV="15e5ac9e46205b7cf80efd72f957c83a76c84d67"
SRCREV = "62363256fdc9c2cb684200d7d5c9df70e4df5a8d"
PV = "${LINUX_VERSION}+git${SRCPV}"