mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-20 22:23:27 +00:00
8b4df1efd5
Add support for the Netgear Nighthawk X4 R7500 and build appropariate sysupgrade and factory images. Known issues: * 5 GHz wifi not working - there is no quantenna driver * One of the USB ports is not working Signed-off-by: Jonas Gorski <jogo@openwrt.org> SVN-Revision: 46796
47 lines
823 B
Bash
47 lines
823 B
Bash
#!/bin/sh
|
|
#
|
|
# Copyright (c) 2014 The Linux Foundation. All rights reserved.
|
|
# Copyright (C) 2011 OpenWrt.org
|
|
#
|
|
|
|
IPQ806X_BOARD_NAME=
|
|
IPQ806X_MODEL=
|
|
|
|
ipq806x_board_detect() {
|
|
local machine
|
|
local name
|
|
|
|
machine=$(cat /proc/device-tree/model)
|
|
|
|
case "$machine" in
|
|
*"AP148")
|
|
name="ap148"
|
|
;;
|
|
*"DB149")
|
|
name="db149"
|
|
;;
|
|
*"R7500")
|
|
name="r7500"
|
|
;;
|
|
esac
|
|
|
|
[ -z "$name" ] && name="unknown"
|
|
|
|
[ -z "$IPQ806X_BOARD_NAME" ] && IPQ806X_BOARD_NAME="$name"
|
|
[ -z "$IPQ806X_MODEL" ] && IPQ806X_MODEL="$machine"
|
|
|
|
[ -e "/tmp/sysinfo/" ] || mkdir -p "/tmp/sysinfo/"
|
|
|
|
echo "$IPQ806X_BOARD_NAME" > /tmp/sysinfo/board_name
|
|
echo "$IPQ806X_MODEL" > /tmp/sysinfo/model
|
|
}
|
|
|
|
ipq806x_board_name() {
|
|
local name
|
|
|
|
[ -f /tmp/sysinfo/board_name ] && name=$(cat /tmp/sysinfo/board_name)
|
|
[ -z "$name" ] && name="unknown"
|
|
|
|
echo "$name"
|
|
}
|