ar71xx: mikrotik: erase firmware partition on SPI NOR devices in pre_upgrade()
authorThibaut VARENE <hacks@slashdirt.org>
Thu, 23 Feb 2017 11:24:05 +0000 (12:24 +0100)
committerFelix Fietkau <nbd@nbd.name>
Sun, 26 Feb 2017 12:30:39 +0000 (13:30 +0100)
On Mikrotik SPI NOR devices, the firmware partition must be erased when flashing
from stock firmware, otherwise leftover bits (in particular a kernel signature)
can trigger a boot loop.

When booted from initramfs (the only way to flash LEDE on these devices),
this patch unconditionally erases the firmware partition in the pre_upgrade()
stage for all supported SPI NOR devices.

Signed-off-by: Thibaut VARENE <hacks@slashdirt.org>

No differences found