kernel: Fix oob layout of XTX XT26G0xA
authorFelix Matouschek <felix@matouschek.org>
Fri, 8 Apr 2022 16:27:05 +0000 (18:27 +0200)
committerChuanhong Guo <gch981213@gmail.com>
Sat, 9 Apr 2022 13:08:26 +0000 (21:08 +0800)
The correct oob layout is:

ECC:
region->offset = 48;
region->length = 16;

Free:
/* Reserve 1 byte for the BBM. */
region->offset = 1;
region->length = 47;

Signed-off-by: Felix Matouschek <felix@matouschek.org>
target/linux/generic/pending-5.10/483-mtd-spinand-add-support-for-xtx-xt26g0xa.patch
target/linux/generic/pending-5.15/483-mtd-spinand-add-support-for-xtx-xt26g0xa.patch

index c55ce872251761e28ab92ae1f70a54a62db43eef..3a8ba498bd1aa87e90a8a24631129d3e238db4a1 100644 (file)
@@ -83,8 +83,8 @@ Signed-off-by: Felix Matouschek <felix@matouschek.org>
 +      if (section)
 +              return -ERANGE;
 +
-+      region->offset = 8;
-+      region->length = 40;
++      region->offset = 48;
++      region->length = 16;
 +
 +      return 0;
 +}
@@ -96,7 +96,7 @@ Signed-off-by: Felix Matouschek <felix@matouschek.org>
 +              return -ERANGE;
 +
 +      region->offset = 1;
-+      region->length = 7;
++      region->length = 47;
 +
 +      return 0;
 +}
index 3d89e58d1939596a9c72782a1ce663240d944879..a73c9fa97dfd4ae10d2a39851890b4fbc4afbd03 100644 (file)
@@ -83,8 +83,8 @@ Signed-off-by: Felix Matouschek <felix@matouschek.org>
 +      if (section)
 +              return -ERANGE;
 +
-+      region->offset = 8;
-+      region->length = 40;
++      region->offset = 48;
++      region->length = 16;
 +
 +      return 0;
 +}
@@ -96,7 +96,7 @@ Signed-off-by: Felix Matouschek <felix@matouschek.org>
 +              return -ERANGE;
 +
 +      region->offset = 1;
-+      region->length = 7;
++      region->length = 47;
 +
 +      return 0;
 +}