mirror of https://github.com/aredn/aredn.git
hardware: Update get_model to use the ar71xx board detect routines
Returns the same data for devices as CPUInfo would of returned for previous devices and for new devices like the CPE510 causes the system to list the exact model instead of of the family.
This commit is contained in:
parent
31bd519266
commit
08600fd4e8
|
@ -1,7 +1,11 @@
|
|||
#!/bin/sh
|
||||
#CMLARA: Temporary shell script for ar71xx platform models
|
||||
# Just resport what is on the /proc/cpuinfo field --- this will work for most ar71xx devices
|
||||
# This doesn't work for linksys however since they have multiple devices
|
||||
#Eventually we will want to to clean this up to a diffrent method
|
||||
# Return the model of the device
|
||||
|
||||
echo `awk 'BEGIN{FS="[ \t]+:[ \t]"} /machine/ {print $2}' /proc/cpuinfo`;
|
||||
if [ ! -f /tmp/sysinfo/model ]; then
|
||||
. /lib/functions.sh
|
||||
. /lib/ar71xx.sh
|
||||
ar71xx_board_detect
|
||||
fi
|
||||
|
||||
cat /tmp/sysinfo/model
|
||||
|
|
Loading…
Reference in New Issue