openwrtv4/target/linux/ipq806x/base-files/etc/init.d/linksys_recovery
Luis Araneda 33f09cf151 ipq806x: convert to dt-based board-detection
Use the generic board detection method:
- Board name: First compatible string from the device tree
- Board model: Model property from the device tree

Change occurrences of board name in userspace by the compatible
string, and removed target specific board detection script

Replace the definition of SUPPORTED_DEVICES in Device/Default
to extract the dt compatible string from each device definition.
Additionally, for devices supported by lede-17.01, append
the value of BOARD_NAME to SUPPORTED_DEVICES in the device
definition.

Signed-off-by: Luis Araneda <luaraneda@gmail.com>
2018-01-13 07:33:03 +01:00

19 lines
381 B
Bash
Executable file

#!/bin/sh /etc/rc.common
# Copyright (C) 2015 OpenWrt.org
START=97
boot() {
. /lib/functions.sh
case $(board_name) in
linksys,ea8500)
# make sure auto_recovery in uboot is always on
AUTO_RECOVERY_ENA="`fw_printenv -n auto_recovery`"
if [ "$AUTO_RECOVERY_ENA" != "yes" ] ; then
fw_setenv auto_recovery yes
fi
# reset the boot counter
mtd resetbc s_env
;;
esac
}