Brian Norris
28fa65e643
mtd: nand: fix off-by-one read retry mode counting
A flash may support N read retry voltage threshold modes, numbered 0
through N-1 (where mode 0 represents the initial state). However,
nand_do_read_ops() tries to use mode 0 through N.
This off-by-one error shows up, for instance, when using nanddump, and
we have cycled through available modes:
nand: setting READ RETRY mode 0
nand: setting READ RETRY mode 1
nand: setting READ RETRY mode 2
nand: setting READ RETRY mode 3
nand: setting READ RETRY mode 4
nand: setting READ RETRY mode 5
nand: setting READ RETRY mode 6
nand: setting READ RETRY mode 7
nand: setting READ RETRY mode 8
libmtd: error!: cannot read 8192 bytes from mtd0 (eraseblock 20, offset 0)
error 22 (Invalid argument)
nanddump: error!: mtd_read
Tested on Micron MT29F64G08CBCBBH1, with 8 retry modes.
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Acked-by: Huang Shijie <b32955@freescale.com>
2014-02-14 12:08:20 -08:00
..
2014-02-06 23:08:54 +01:00
2014-01-24 15:51:02 -08:00
2014-01-25 13:18:00 -08:00
2014-01-30 17:20:32 -08:00
2014-02-05 16:01:11 -08:00
2014-01-31 15:15:13 -08:00
2014-01-30 11:40:10 -08:00
2014-02-09 15:21:16 -05:00
2014-01-28 18:44:53 -08:00
2014-01-31 21:04:01 -08:00
2014-02-04 21:41:15 +01:00
2014-01-29 17:02:24 +11:00
2014-01-23 18:49:36 -08:00
2014-01-29 11:48:23 +01:00
2014-01-29 20:27:23 -08:00
2014-01-27 21:02:40 -08:00
2014-01-23 18:49:36 -08:00
2014-02-06 12:13:52 +10:00
2014-01-31 09:31:14 -08:00
2014-01-27 16:40:45 -08:00
2014-02-06 17:22:33 -08:00
2014-01-29 19:56:20 -08:00
2014-01-28 23:35:09 -08:00
2014-01-24 15:51:02 -08:00
2014-01-22 21:21:55 -08:00
2014-01-31 15:31:23 -08:00
2014-01-24 17:17:30 -08:00
2014-01-29 20:00:13 -08:00
2014-02-05 16:02:53 -08:00
2014-01-25 11:17:34 -08:00
2014-01-28 18:53:01 -08:00
2014-01-27 21:11:26 -08:00
2014-01-23 16:36:53 -08:00
2014-01-30 11:40:10 -08:00
2014-02-04 06:46:10 -02:00
2014-01-23 16:37:04 -08:00
2014-01-30 11:19:05 -08:00
2014-01-25 13:19:10 -08:00
2014-01-29 18:56:27 -08:00
2014-01-26 11:00:41 -08:00
2014-02-14 12:08:20 -08:00
2014-01-30 18:44:44 -08:00
2014-01-25 11:17:34 -08:00
2014-02-03 22:30:15 +01:00
2014-01-22 16:39:28 -08:00
2014-01-25 11:17:34 -08:00
2014-02-06 14:21:19 +01:00
2014-01-29 20:06:01 -08:00
2014-01-25 11:17:34 -08:00
2014-01-27 08:15:51 -08:00
2014-02-04 12:58:19 +00:00
2014-01-23 19:11:50 -08:00
2014-01-31 08:37:32 -08:00
2014-01-28 23:38:23 -08:00
2014-01-31 15:31:23 -08:00
2014-01-29 16:53:55 +11:00
2014-01-30 17:20:32 -08:00
2014-02-04 06:28:00 -02:00
2014-01-31 15:31:23 -08:00
2014-01-24 17:13:49 -08:00
2014-01-30 17:20:32 -08:00
2014-01-29 16:53:55 +11:00
2014-01-27 21:11:26 -08:00
2014-01-31 15:31:23 -08:00
2014-02-02 20:56:47 +01:00
2014-01-22 22:24:35 -08:00
2014-01-23 16:36:55 -08:00
2014-01-23 16:37:04 -08:00
2014-02-08 09:47:11 +01:00
2014-02-05 16:01:11 -08:00