Lines Matching refs:nextpage
51 int nextpage; member
103 cxt->nextpage++; in mtdoops_inc_counter()
104 if (cxt->nextpage >= cxt->oops_pages) in mtdoops_inc_counter()
105 cxt->nextpage = 0; in mtdoops_inc_counter()
110 if (page_is_used(cxt, cxt->nextpage)) { in mtdoops_inc_counter()
116 cxt->nextpage, cxt->nextcount); in mtdoops_inc_counter()
131 mod = (cxt->nextpage * record_size) % mtd->erasesize; in mtdoops_workfunc_erase()
133 cxt->nextpage = cxt->nextpage + ((mtd->erasesize - mod) / record_size); in mtdoops_workfunc_erase()
134 if (cxt->nextpage >= cxt->oops_pages) in mtdoops_workfunc_erase()
135 cxt->nextpage = 0; in mtdoops_workfunc_erase()
138 while ((ret = mtd_block_isbad(mtd, cxt->nextpage * record_size)) > 0) { in mtdoops_workfunc_erase()
141 cxt->nextpage * record_size); in mtdoops_workfunc_erase()
143 cxt->nextpage = cxt->nextpage + (mtd->erasesize / record_size); in mtdoops_workfunc_erase()
144 if (cxt->nextpage >= cxt->oops_pages) in mtdoops_workfunc_erase()
145 cxt->nextpage = 0; in mtdoops_workfunc_erase()
158 ret = mtdoops_erase_block(cxt, cxt->nextpage * record_size); in mtdoops_workfunc_erase()
162 cxt->nextpage, cxt->nextcount); in mtdoops_workfunc_erase()
167 ret = mtd_block_markbad(mtd, cxt->nextpage * record_size); in mtdoops_workfunc_erase()
189 ret = mtd_panic_write(mtd, cxt->nextpage * record_size, in mtdoops_write()
196 ret = mtd_write(mtd, cxt->nextpage * record_size, in mtdoops_write()
201 cxt->nextpage * record_size, retlen, record_size, ret); in mtdoops_write()
202 mark_page_used(cxt, cxt->nextpage); in mtdoops_write()
258 cxt->nextpage = cxt->oops_pages - 1; in find_next_position()
262 cxt->nextpage = maxpos; in find_next_position()