lantiq: add tplink header id to sysupgrade and fix a comment
[openwrt/openwrt.git] / target / linux / lantiq / base-files / lib / upgrade / platform.sh
1 PART_NAME=linux
2
3 platform_check_image() {
4 [ "$ARGC" -gt 1 ] && return 1
5
6 case "$(get_magic_word "$1")" in
7 # uImage
8 2705) return 0;;
9 # tplink
10 0200) return 0;;
11 *)
12 echo "Invalid image type"
13 return 1
14 ;;
15 esac
16 }
17
18 # use default for platform_do_upgrade()
19
20 disable_watchdog() {
21 killall watchdog
22 ( ps | grep -v 'grep' | grep '/dev/watchdog' ) && {
23 echo 'Could not disable watchdog'
24 return 1
25 }
26 }
27 append sysupgrade_pre_upgrade disable_watchdog