[MTD] [OneNAND] Exit the loop when transferring/filling of the oob is finished
When transferring/filling of the oob is finished in OOB_AUTO, we exit the loop Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
This commit is contained in:
committed by
David Woodhouse
parent
81280d5879
commit
5bc399e9ef
@@ -854,7 +854,8 @@ static int onenand_transfer_auto_oob(struct mtd_info *mtd, uint8_t *buf, int col
|
|||||||
int n = ed - st;
|
int n = ed - st;
|
||||||
memcpy(buf, oob_buf + st, n);
|
memcpy(buf, oob_buf + st, n);
|
||||||
buf += n;
|
buf += n;
|
||||||
}
|
} else
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -1295,7 +1296,8 @@ static int onenand_fill_auto_oob(struct mtd_info *mtd, u_char *oob_buf,
|
|||||||
int n = ed - st;
|
int n = ed - st;
|
||||||
memcpy(oob_buf + st, buf, n);
|
memcpy(oob_buf + st, buf, n);
|
||||||
buf += n;
|
buf += n;
|
||||||
}
|
} else
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user