x86/soekris: Add script to detect soekris model
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Wed, 26 Jan 2011 11:33:42 +0000 (11:33 +0000)
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Wed, 26 Jan 2011 11:33:42 +0000 (11:33 +0000)
Add script to detect soekris board of net4801 and net4826.

Patch from: kentarou matsuyama <matsuyama@thinktube.com>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@25102 3c298f89-4303-0410-b956-a3cf2f4a3e73

target/linux/x86/base-files/lib/soekris.sh [new file with mode: 0755]

diff --git a/target/linux/x86/base-files/lib/soekris.sh b/target/linux/x86/base-files/lib/soekris.sh
new file mode 100755 (executable)
index 0000000..e416ad3
--- /dev/null
@@ -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
+}
This page took 0.025961 seconds and 4 git commands to generate.