diff options
author | Gabor Juhos <juhosg@openwrt.org> | 2007-09-29 14:27:54 +0000 |
---|---|---|
committer | Gabor Juhos <juhosg@openwrt.org> | 2007-09-29 14:27:54 +0000 |
commit | 438dfe5c6fbfa63f5841fda9b4ec44b2f7712674 (patch) | |
tree | 35defc07076a1deea87ff74b8ee97cd891494183 /target/linux/brcm-2.4/base-files/lib | |
parent | 2068b8d48de6b07bf656613fb1e25850483d5c67 (diff) | |
download | mtk-20170518-438dfe5c6fbfa63f5841fda9b4ec44b2f7712674.zip mtk-20170518-438dfe5c6fbfa63f5841fda9b4ec44b2f7712674.tar.gz mtk-20170518-438dfe5c6fbfa63f5841fda9b4ec44b2f7712674.tar.bz2 |
get rid of per-profile base-files
SVN-Revision: 9069
Diffstat (limited to 'target/linux/brcm-2.4/base-files/lib')
-rw-r--r-- | target/linux/brcm-2.4/base-files/lib/upgrade/platform.sh | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/target/linux/brcm-2.4/base-files/lib/upgrade/platform.sh b/target/linux/brcm-2.4/base-files/lib/upgrade/platform.sh new file mode 100644 index 0000000..ac53b9d --- /dev/null +++ b/target/linux/brcm-2.4/base-files/lib/upgrade/platform.sh @@ -0,0 +1,24 @@ +platform_check_image() { + [ "$ARGC" -gt 1 ] && return 1 + + case "$(get_magic_word "$1")" in + # .trx files + 4844) return 0;; + # .bin files + 5735) return 0;; + *) + echo "Invalid image type" + return 1 + ;; + esac +} + +platform_do_upgrade() { + get_image "$1" > $(find_mtd_part "linux") + sync +} + +brcm_prepare_mtd() { + [ "$SAVE_CONFIG" -eq 1 ] && return 0 +} +append sysupgrade_pre_upgrade brcm_prepare_mtd |