summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriyEshenko <dmitriy.eshenko@vyos.io>2021-01-25 18:25:22 +0000
committerDmitriyEshenko <dmitriy.eshenko@vyos.io>2021-01-25 18:25:49 +0000
commitf85dcdcb1a2b8a88278251fdacd853ec4b0a4924 (patch)
tree75ea9c0b2672fd15dd570ba335218648f5992d7e
parentbd84d229722c9a770b42ad9ca7696d55b85ac9e0 (diff)
downloadvyos-build-f85dcdcb1a2b8a88278251fdacd853ec4b0a4924.tar.gz
vyos-build-f85dcdcb1a2b8a88278251fdacd853ec4b0a4924.zip
Lanner: Add build procedure for Lanner NCA-25XX devices
-rw-r--r--Makefile12
-rw-r--r--tools/vendors_udev/64-vyos-lanner-NCA-25XX-net.rules9
2 files changed, 21 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 21e5662e..abcef85b 100644
--- a/Makefile
+++ b/Makefile
@@ -254,6 +254,18 @@ dell: check_build_config clean prepare
cd ..
@scripts/copy-image
+.PHONY: lanner_nca25xx
+.ONESHELL:
+lanner_nca25xx: check_build_config clean prepare
+ @set -e
+ @echo "It's not like I'm building this specially for you or anything!"
+ mkdir -p build/config/includes.chroot/lib/udev/rules.d/
+ cp tools/vendors_udev/64-vyos-lanner-NCA-25XX-net.rules build/config/includes.chroot/lib/udev/rules.d/
+ cd $(build_dir)
+ lb build 2>&1 | tee build.log
+ cd ..
+ @scripts/copy-image
+
.PHONY: test
.ONESHELL:
test:
diff --git a/tools/vendors_udev/64-vyos-lanner-NCA-25XX-net.rules b/tools/vendors_udev/64-vyos-lanner-NCA-25XX-net.rules
new file mode 100644
index 00000000..095a3ea6
--- /dev/null
+++ b/tools/vendors_udev/64-vyos-lanner-NCA-25XX-net.rules
@@ -0,0 +1,9 @@
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:04:00.0", ENV{VYOS_IFNAME}="eth0"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:03:00.0", ENV{VYOS_IFNAME}="eth1"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:03:00.1", ENV{VYOS_IFNAME}="eth2"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:03:00.2", ENV{VYOS_IFNAME}="eth3"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:03:00.3", ENV{VYOS_IFNAME}="eth4"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:07:00.0", ENV{VYOS_IFNAME}="eth5", ATTR{ifalias}="SFP+"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:07:00.1", ENV{VYOS_IFNAME}="eth6", ATTR{ifalias}="SFP+"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:08:00.0", ENV{VYOS_IFNAME}="eth7", ATTR{ifalias}="SFP+"
+ACTION=="add", SUBSYSTEM=="net", KERNELS=="0000:08:00.1", ENV{VYOS_IFNAME}="eth8", ATTR{ifalias}="SFP+"