aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/tests
diff options
context:
space:
mode:
authorChristian Herzig <christian.herzig@keymile.com>2012-11-23 09:31:26 -0500
committerArtem Bityutskiy <artem.bityutskiy@linux.intel.com>2012-12-04 09:00:34 -0500
commitd8b1e34e248d89f43bab18704894d537dc0b497e (patch)
treedfedf841987b44e475442ec9f8d03a11d7ede36d /drivers/mtd/tests
parentc0c70d9ee6569150ff6a10f9d3c50c63c917e3a1 (diff)
mtd: tests/read: initialize buffer for whole next page
fix: do block-buffer initialize for the whole next page to zero. Signed-off-by: Christian Herzig <christian.herzig@keymile.com> Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Diffstat (limited to 'drivers/mtd/tests')
-rw-r--r--drivers/mtd/tests/mtd_readtest.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/tests/mtd_readtest.c b/drivers/mtd/tests/mtd_readtest.c
index 31f505cc942a..266de04b6d29 100644
--- a/drivers/mtd/tests/mtd_readtest.c
+++ b/drivers/mtd/tests/mtd_readtest.c
@@ -51,7 +51,7 @@ static int read_eraseblock_by_page(int ebnum)
51 void *oobbuf = iobuf1; 51 void *oobbuf = iobuf1;
52 52
53 for (i = 0; i < pgcnt; i++) { 53 for (i = 0; i < pgcnt; i++) {
54 memset(buf, 0 , pgcnt); 54 memset(buf, 0 , pgsize);
55 ret = mtd_read(mtd, addr, pgsize, &read, buf); 55 ret = mtd_read(mtd, addr, pgsize, &read, buf);
56 if (ret == -EUCLEAN) 56 if (ret == -EUCLEAN)
57 ret = 0; 57 ret = 0;