0036-bcm53xx-upgrade-fix-RAMFS_COPY_.patch 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. From: Matthias Schiffer <mschiffer@universe-factory.net>
  2. Date: Sat, 10 Jun 2017 16:14:54 +0200
  3. Subject: bcm53xx: upgrade: fix RAMFS_COPY_*
  4. Fixes: 30f61a34b4cf "base-files: always use staged sysupgrade"
  5. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
  6. diff --git a/package/base-files/files/lib/upgrade/stage2 b/package/base-files/files/lib/upgrade/stage2
  7. index 097ad63adfecdd70019acaa5b652d2056e774c3f..8cc8c8b34e9f349f1d1283ac00f9782b52ab01c1 100755
  8. --- a/package/base-files/files/lib/upgrade/stage2
  9. +++ b/package/base-files/files/lib/upgrade/stage2
  10. @@ -48,7 +48,7 @@ switch_to_ramfs() {
  11. /bin/sleep /bin/zcat /usr/bin/bzcat /usr/bin/printf /usr/bin/wc \
  12. /bin/cut /usr/bin/printf /bin/sync /bin/mkdir /bin/rmdir \
  13. /bin/rm /usr/bin/basename /bin/kill /bin/chmod /usr/bin/find \
  14. - /bin/mknod /bin/touch
  15. + /bin/mknod /bin/touch /bin/sed
  16. install_bin /sbin/mtd
  17. install_bin /sbin/mount_root
  18. diff --git a/target/linux/bcm53xx/base-files/lib/upgrade/platform.sh b/target/linux/bcm53xx/base-files/lib/upgrade/platform.sh
  19. index eb6dc823e3890497389716c32ec7e4caf8d30c45..a90a58299dc293afbe15a0b491ef6898402deca4 100644
  20. --- a/target/linux/bcm53xx/base-files/lib/upgrade/platform.sh
  21. +++ b/target/linux/bcm53xx/base-files/lib/upgrade/platform.sh
  22. @@ -1,3 +1,5 @@
  23. +RAMFS_COPY_BIN='/usr/bin/osafeloader /usr/bin/oseama'
  24. +
  25. PART_NAME=firmware
  26. # $(1): file to read magic from
  27. @@ -260,8 +262,6 @@ platform_pre_upgrade_seama() {
  28. }
  29. platform_pre_upgrade() {
  30. - export RAMFS_COPY_BIN="${RAMFS_COPY_BIN} /usr/bin/osafeloader /usr/bin/oseama /bin/sed"
  31. -
  32. local file_type=$(platform_identify "$1")
  33. [ "$(platform_flash_type)" != "nand" ] && return