ath79: improve factory.bin for some Senao devices
authorMichael Pratt <mcpratt@pm.me>
Wed, 17 Mar 2021 23:07:46 +0000 (19:07 -0400)
committerHauke Mehrtens <hauke@hauke-m.de>
Sun, 13 Mar 2022 18:54:57 +0000 (19:54 +0100)
commit07723492e9acf5aea51eb8de3bcc4e36305c9e6b
tree278137aae14e36433db2fe8c2b3c441ee702f6a9
parente83ab243bef6e32c1fbb8ceda5301aa21f0c51cf
ath79: improve factory.bin for some Senao devices

Some boards with firmware made with Senao SDK based on Linux 3.3
have the following lines in the OEM upgrade script at
/etc/fwupgrade.sh

local append=""
local CONF_TAR="/tmp/sysupgrade.tgz"
[ -f "$CONF_TAR" ] && append="-j $CONF_TAR"

and

\# check FWINFO filename
[ -z $(ls FWINFO* | grep -i ${modelname}) ] && errcode="1"

This addition also prevents needing to factory reset after flashing
for some boards that also have these lines in the script

\# Support downgrade but do default (Smart v2.x.x.x -> senaowrt v1.x.x.x)
[ $(ls FWINFO* | grep -i ${modelname} | cut -d "-" -f4 | cut -c 2) -lt 2 ] && append=""

Signed-off-by: Michael Pratt <mcpratt@pm.me>
target/linux/ath79/image/common-senao.mk