Add script to detect soekris board of net4801 and net4826.
---
 target/linux/x86/base-files/lib/soekris.sh |   19 +++++++++++++++++++
 1 files changed, 19 insertions(+), 0 deletions(-)
 create mode 100755 target/linux/x86/base-files/lib/soekris.sh

diff --git a/target/linux/x86/base-files/lib/soekris.sh 
b/target/linux/x86/base-files/lib/soekris.sh
new file mode 100755
index 0000000..e416ad3
--- /dev/null
+++ b/target/linux/x86/base-files/lib/soekris.sh
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+net48xx_board_name () {
+    local name
+    local pci=`wc -l /proc/bus/pci/devices`
+
+    case "$pci" in
+       *"8"*)
+           name="net4826"
+           ;;
+       *1[0-4]*)
+           name="net4801"
+           ;;
+       *)
+           name="net4826"
+           ;;
+    esac
+    echo $name
+}

_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to