From: Felix Fietkau Date: Wed, 26 Jan 2011 11:33:42 +0000 (+0000) Subject: x86/soekris: Add script to detect soekris model X-Git-Url: http://git.openwrt.org/?p=openwrt%2Fsvn-archive%2Farchive.git;a=commitdiff_plain;h=cbc68fc74b8fc8d152a7dd4112d704c9edf15692;hp=5ac8900bfd7d2a36aef3e5544471918b3e98e8cb;ds=sidebyside x86/soekris: Add script to detect soekris model Add script to detect soekris board of net4801 and net4826. Patch from: kentarou matsuyama SVN-Revision: 25102 --- 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 0000000000..e416ad3962 --- /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 +}