aboutsummaryrefslogtreecommitdiff
path: root/target/linux/ipq40xx/base-files/etc/init.d/bootcount
blob: 367ccfcd0cabbaf08700576ca36d1c93cb5be508 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/sh /etc/rc.common

START=99

boot() {
	case $(board_name) in
	alfa-network,ap120c-ac)
		[ -n "$(fw_printenv bootcount changed 2>/dev/null)" ] &&\
			echo -e "bootcount\nchanged\n" | /usr/sbin/fw_setenv -s -
		;;
	linksys,ea6350v3|\
	linksys,ea8300|\
	linksys,mr8300|\
	linksys,whw01-v1)
		mtd resetbc s_env || true
		;;
	netgear,wac510)
		fw_setenv boot_cnt=0
		;;
	esac
}