aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/bcm63xx/patches-5.4/021-v5.8-mtd-rawnand-brcmnand-improve-hamming-oob-layout.patch
diff options
context:
space:
mode:
authorDaniel Golle <daniel@makrotopia.org>2022-03-21 01:16:48 +0000
committerDaniel Golle <daniel@makrotopia.org>2022-03-21 13:11:56 +0000
commit786bf7fdaca4c75e7eba6e9aa3a8b5775fd21186 (patch)
tree926fecb2b1f6ce1e42ba7ef4c7aab8e68dfd214c /target/linux/bcm63xx/patches-5.4/021-v5.8-mtd-rawnand-brcmnand-improve-hamming-oob-layout.patch
parent9470160c350d15f765c33d6c1db15d6c4709a64c (diff)
downloadupstream-786bf7fdaca4c75e7eba6e9aa3a8b5775fd21186.tar.gz
upstream-786bf7fdaca4c75e7eba6e9aa3a8b5775fd21186.tar.bz2
upstream-786bf7fdaca4c75e7eba6e9aa3a8b5775fd21186.zip
kernel: delete Linux 5.4 config and patches
As the upcoming release will be based on Linux 5.10 only, remove all kernel configuration as well as patches for Linux 5.4. There were no targets still actively using Linux 5.4. Signed-off-by: Daniel Golle <daniel@makrotopia.org> (cherry picked from commit 3a14580411adfb75f9a44eded9f41245b9e44606)
Diffstat (limited to 'target/linux/bcm63xx/patches-5.4/021-v5.8-mtd-rawnand-brcmnand-improve-hamming-oob-layout.patch')
-rw-r--r--target/linux/bcm63xx/patches-5.4/021-v5.8-mtd-rawnand-brcmnand-improve-hamming-oob-layout.patch92
1 files changed, 0 insertions, 92 deletions
diff --git a/target/linux/bcm63xx/patches-5.4/021-v5.8-mtd-rawnand-brcmnand-improve-hamming-oob-layout.patch b/target/linux/bcm63xx/patches-5.4/021-v5.8-mtd-rawnand-brcmnand-improve-hamming-oob-layout.patch
deleted file mode 100644
index 78fa1b39e3..0000000000
--- a/target/linux/bcm63xx/patches-5.4/021-v5.8-mtd-rawnand-brcmnand-improve-hamming-oob-layout.patch
+++ /dev/null
@@ -1,92 +0,0 @@
-From d00358d7a1c50718232799e1ee10955bcd73795a Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= <noltari@gmail.com>
-Date: Tue, 12 May 2020 09:57:33 +0200
-Subject: [PATCH] mtd: rawnand: brcmnand: improve hamming oob layout
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-The current code generates 8 oob sections:
-S1 1-5
-ECC 6-8
-S2 9-15
-S3 16-21
-ECC 22-24
-S4 25-31
-S5 32-37
-ECC 38-40
-S6 41-47
-S7 48-53
-ECC 54-56
-S8 57-63
-
-Change it by merging continuous sections:
-S1 1-5
-ECC 6-8
-S2 9-21
-ECC 22-24
-S3 25-37
-ECC 38-40
-S4 41-53
-ECC 54-56
-S5 57-63
-
-Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
-Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
-Link: https://lore.kernel.org/linux-mtd/20200512075733.745374-3-noltari@gmail.com
----
- drivers/mtd/nand/raw/brcmnand/brcmnand.c | 35 +++++++++++-------------
- 1 file changed, 16 insertions(+), 19 deletions(-)
-
---- a/drivers/mtd/nand/raw/brcmnand/brcmnand.c
-+++ b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
-@@ -1004,33 +1004,30 @@ static int brcmnand_hamming_ooblayout_fr
- struct brcmnand_cfg *cfg = &host->hwcfg;
- int sas = cfg->spare_area_size << cfg->sector_size_1k;
- int sectors = cfg->page_size / (512 << cfg->sector_size_1k);
-+ u32 next;
-
-- if (section >= sectors * 2)
-+ if (section > sectors)
- return -ERANGE;
-
-- oobregion->offset = (section / 2) * sas;
-+ next = (section * sas);
-+ if (section < sectors)
-+ next += 6;
-
-- if (section & 1) {
-- oobregion->offset += 9;
-- oobregion->length = 7;
-+ if (section) {
-+ oobregion->offset = ((section - 1) * sas) + 9;
- } else {
-- oobregion->length = 6;
--
-- /* First sector of each page may have BBI */
-- if (!section) {
-- /*
-- * Small-page NAND use byte 6 for BBI while large-page
-- * NAND use bytes 0 and 1.
-- */
-- if (cfg->page_size > 512) {
-- oobregion->offset += 2;
-- oobregion->length -= 2;
-- } else {
-- oobregion->length--;
-- }
-+ if (cfg->page_size > 512) {
-+ /* Large page NAND uses first 2 bytes for BBI */
-+ oobregion->offset = 2;
-+ } else {
-+ /* Small page NAND uses last byte before ECC for BBI */
-+ oobregion->offset = 0;
-+ next--;
- }
- }
-
-+ oobregion->length = next - oobregion->offset;
-+
- return 0;
- }
-