diff options
Diffstat (limited to 'drivers/mtd/tests/pagetest.c')
-rw-r--r-- | drivers/mtd/tests/pagetest.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/mtd/tests/pagetest.c b/drivers/mtd/tests/pagetest.c index 88296e888e9d..ba1890d5632c 100644 --- a/drivers/mtd/tests/pagetest.c +++ b/drivers/mtd/tests/pagetest.c @@ -407,7 +407,10 @@ static int __init mtd_pagetest_init(void) goto out; if (i % 256 == 0) pr_info("written up to eraseblock %u\n", i); - cond_resched(); + + err = mtdtest_relax(); + if (err) + goto out; } pr_info("written %u eraseblocks\n", i); @@ -422,7 +425,10 @@ static int __init mtd_pagetest_init(void) goto out; if (i % 256 == 0) pr_info("verified up to eraseblock %u\n", i); - cond_resched(); + + err = mtdtest_relax(); + if (err) + goto out; } pr_info("verified %u eraseblocks\n", i); |