mtd: introduce mtd_read interface
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
This commit is contained in:

committad av
David Woodhouse

förälder
04c601bfa4
incheckning
329ad399a9
@@ -736,7 +736,7 @@ static int mtdswap_move_block(struct mtdswap_dev *d, unsigned int oldblock,
|
||||
retries = 0;
|
||||
|
||||
retry:
|
||||
ret = mtd->read(mtd, readpos, PAGE_SIZE, &retlen, d->page_buf);
|
||||
ret = mtd_read(mtd, readpos, PAGE_SIZE, &retlen, d->page_buf);
|
||||
|
||||
if (ret < 0 && !mtd_is_bitflip(ret)) {
|
||||
oldeb = d->eb_data + oldblock / d->pages_per_eblk;
|
||||
@@ -1161,7 +1161,7 @@ static int mtdswap_readsect(struct mtd_blktrans_dev *dev,
|
||||
retries = 0;
|
||||
|
||||
retry:
|
||||
ret = mtd->read(mtd, readpos, PAGE_SIZE, &retlen, buf);
|
||||
ret = mtd_read(mtd, readpos, PAGE_SIZE, &retlen, buf);
|
||||
|
||||
d->mtd_read_count++;
|
||||
if (mtd_is_bitflip(ret)) {
|
||||
|
Referens i nytt ärende
Block a user