mtd: mtd_nandecctest: rewrite the test routine
authorAkinobu Mita <akinobu.mita@gmail.com>
Fri, 7 Sep 2012 16:48:07 +0000 (01:48 +0900)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Sat, 29 Sep 2012 14:47:37 +0000 (15:47 +0100)
commit6060fb42a0bf93015d05c1a857b94894936f40ee
tree4b28d8730eba19b6f61692b520c7529039fd3605
parentc092b43906098a6879d0fa9f74e5141516b9b856
mtd: mtd_nandecctest: rewrite the test routine

This rewrites the entire test routine in order to make it easy to add more
tests by later changes and minimize duplication of each tests as much as
possible.

Now that each test is described by the members of struct nand_ecc_test:
- name: descriptive testname
- prepare: function to prepare data block and ecc with artifical corruption
- verify: function to verify the result of correcting data block

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/tests/mtd_nandecctest.c