public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH] mtd: nandbiterrs: Support for NAND biterrors test on platforms without raw write
@ 2016-05-06  0:00 Iwo Mergler
  2016-05-08 16:44 ` Boris Brezillon
  0 siblings, 1 reply; 8+ messages in thread
From: Iwo Mergler @ 2016-05-06  0:00 UTC (permalink / raw)
  To: linux-mtd; +Cc: Richard Weinberger, Brian Norris, Huang Shijie

Hi all,


I'm vaguely aware that there is an ongoing effort to move this
stuff to mtd-utils, but I was unable to find a source tree
with the work so far.

Below is a single-line patch for the kernel tests, feel free
to apply to the userspace source as well.


Best regards,

Iwo


Support for NAND biterrors test on platforms without raw write

While the default test mode relies on raw write (mtd_write_oob) to introduce
bit errors into a page, the rewrite test mode doesn't need it.

Some drivers use eldritch data/ECC arrangements in a NAND page and reshuffle
things on-the-fly, to present a normal page view to the kernel. Typically,
raw write / read is unsupported on such platforms. Examples are Freescale
MXS and Qualcomm MDM9 and probably many others.

Changed the overwrite test to use normal writes.

Signed-off-by: Iwo Mergler <Iwo.Mergler@netcommwireless.com>
---
  drivers/mtd/tests/nandbiterrs.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/tests/nandbiterrs.c 
b/drivers/mtd/tests/nandbiterrs.c
index 09a4cca..f26dec8 100644
--- a/drivers/mtd/tests/nandbiterrs.c
+++ b/drivers/mtd/tests/nandbiterrs.c
@@ -290,7 +290,7 @@ static int overwrite_test(void)

      while (opno < max_overwrite) {

-        err = rewrite_page(0);
+        err = write_page(0);
          if (err)
              break;

-- 
2.7.3

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2016-06-20 11:49 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-05-06  0:00 [PATCH] mtd: nandbiterrs: Support for NAND biterrors test on platforms without raw write Iwo Mergler
2016-05-08 16:44 ` Boris Brezillon
2016-05-08 16:47   ` Boris Brezillon
2016-05-09  4:09   ` Iwo Mergler
2016-05-10  8:48     ` Boris Brezillon
2016-05-11  6:54       ` Iwo Mergler
2016-05-11  6:54       ` Iwo Mergler
2016-06-20 11:48         ` Boris Brezillon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox