cns21xx: add initial support for the Cavium CNS21xx SoC
[openwrt.git] / target / linux / cns21xx / base-files / lib / cns21xx.sh
diff --git a/target/linux/cns21xx/base-files/lib/cns21xx.sh b/target/linux/cns21xx/base-files/lib/cns21xx.sh
new file mode 100755 (executable)
index 0000000..c10f6d3
--- /dev/null
@@ -0,0 +1,25 @@
+#!/bin/sh
+#
+# Copyright (C) 2010 OpenWrt.org
+#
+
+get_board_name() {
+       local hardware
+       local name
+
+       hardware=$(awk 'BEGIN{FS="[ \t]+:[ \t]"} /Hardware/ {print $2}' /proc/cpuinfo)
+
+       case "$hardware" in
+       *NSB3AST)
+               name="nsb3ast"
+               ;;
+       "NS-K330 NAS")
+               name="ns-k330"
+               ;;
+       *)
+               name="generic"
+               ;;
+       esac
+
+       echo $name
+}
This page took 0.029535 seconds and 4 git commands to generate.