Prevent mANT 15s and 19s from bricking while upgrading (#1152)

A change to how the flash is managed on these devices causes
the upgrade process from 3.23.12.0 to brick the device. Fix.
This commit is contained in:
Tim Wilkinson 2024-04-03 15:01:53 -07:00 committed by GitHub
parent 3fee4eadae
commit d1342289c2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 14 additions and 0 deletions

View File

@ -26,3 +26,17 @@
+ { "s25fl116k", INFO(0x014015, 0, 64 * 1024, 32,
+ SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ) },
+ { "s25fl132k", INFO(0x014016, 0, 64 * 1024, 64, SECT_4K) },
--- /dev/null
+++ b/target/linux/ath79/patches-5.15/941-mikrotik-nand-flash.patch
@@ -0,0 +1,11 @@
+--- a/drivers/mtd/nand/raw/nand_amd.c
++++ b/drivers/mtd/nand/raw/nand_amd.c
+@@ -44,6 +44,8 @@
+ chip->options |= NAND_BBM_FIRSTPAGE | NAND_BBM_SECONDPAGE |
+ NAND_BBM_LASTPAGE;
+
++ chip->options |= NAND_NO_SUBPAGE_WRITE;
++
+ return 0;
+ }
+