mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-23 15:32:33 +00:00
d97143fadc
Following 5264296
, Mirotik NAND devices now use yafut to flash the
kernel on devices. This method is incompatible with the old-style
"kernel2minor" flash mechanism.
Even though NAND images were disabled in default build since 21.02, a
user flashing a new-style image onto an old-style image would result in
in a soft-brick[1]. In order to prevent such accidental mishap,
especially as these device images will be reenabled in the upcoming
release, bump the compat version.
After the new image is flashed, the compat version can be updated:
uci set system.@system[0].compat_version='1.1'
uci commit
[1] https://github.com/openwrt/openwrt/pull/12225#issuecomment-1517529262
Cc: Michał Kępień <openwrt@kempniu.pl>
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
Reviewed-by: Robert Marko <robimarko@gmail.com>
26 lines
770 B
Makefile
26 lines
770 B
Makefile
define Device/mikrotik
|
|
DEVICE_VENDOR := MikroTik
|
|
LOADER_TYPE := elf
|
|
KERNEL_NAME := vmlinuz
|
|
KERNEL := kernel-bin | append-dtb-elf
|
|
KERNEL_INITRAMFS_NAME := vmlinux-initramfs
|
|
KERNEL_INITRAMFS := kernel-bin | append-dtb | lzma | loader-kernel
|
|
endef
|
|
|
|
define Device/mikrotik_nor
|
|
$(Device/mikrotik)
|
|
DEVICE_PACKAGES := -yafut
|
|
IMAGE/sysupgrade.bin := append-kernel | kernel2minor -s 1024 -e | \
|
|
pad-to $$$$(BLOCKSIZE) | append-rootfs | pad-rootfs | \
|
|
check-size | append-metadata
|
|
endef
|
|
|
|
define Device/mikrotik_nand
|
|
$(Device/mikrotik)
|
|
IMAGE/sysupgrade.bin = append-kernel | sysupgrade-tar | append-metadata
|
|
DEVICE_COMPAT_MESSAGE := \
|
|
NAND images switched to yafut. If running older image, reinstall from initramfs.
|
|
DEVICE_COMPAT_VERSION := 1.1
|
|
|
|
endef
|