Lines Matching refs:erase_size
34 unsigned int erase_size;
146 p->erase_size = mtderasesize;
239 size_t *total_size, size_t *erase_size, size_t *write_size)
252 if (erase_size != NULL) *erase_size = mtd_info.erasesize;
262 ctx->buffer = malloc(partition->erase_size);
278 ctx->consumed = partition->erase_size;
298 ssize_t size = partition->erase_size;
322 pos += partition->erase_size;
333 if (ctx->consumed < ctx->partition->erase_size) {
334 size_t avail = ctx->partition->erase_size - ctx->consumed;
342 while (ctx->consumed == ctx->partition->erase_size &&
343 len - read >= ctx->partition->erase_size) {
345 read += ctx->partition->erase_size;
353 if (ctx->consumed == ctx->partition->erase_size && read < len) {
378 ctx->buffer = malloc(partition->erase_size);
415 ssize_t size = partition->erase_size;
424 pos += partition->erase_size;
468 pos += partition->erase_size;
481 if (ctx->stored > 0 || len - wrote < ctx->partition->erase_size) {
482 size_t avail = ctx->partition->erase_size - ctx->stored;
490 if (ctx->stored == ctx->partition->erase_size) {
496 while (ctx->stored == 0 && len - wrote >= ctx->partition->erase_size) {
498 wrote += ctx->partition->erase_size;
509 size_t zero = ctx->partition->erase_size - ctx->stored;
518 const int total = (ctx->partition->size - pos) / ctx->partition->erase_size;
530 pos += ctx->partition->erase_size;
536 erase_info.length = ctx->partition->erase_size;
540 erase_size;
565 pos += ctx->partition->erase_size;