Lines Matching defs:offset
363 * @offset: offset within the logical eraseblock to read from
370 int offset, int len)
377 lnum >= vol->used_ebs || offset < 0 || len < 0 ||
378 offset + len > vol->usable_leb_size)
386 offset + len > vol->last_eb_bytes)
401 * @offset: offset within the logical eraseblock to read from
405 * This function reads data from offset @offset of logical eraseblock @lnum and
423 int ubi_leb_read(struct ubi_volume_desc *desc, int lnum, char *buf, int offset,
430 dbg_gen("read %d bytes from LEB %d:%d:%d", len, vol_id, lnum, offset);
432 err = leb_read_sanity_check(desc, lnum, offset, len);
439 err = ubi_eba_read_leb(ubi, vol, lnum, buf, offset, len, check);
455 * @offset: offset within the logical eraseblock to read from
464 int offset, int len, int check)
470 dbg_gen("read %d bytes from LEB %d:%d:%d", len, vol_id, lnum, offset);
472 err = leb_read_sanity_check(desc, lnum, offset, len);
479 err = ubi_eba_read_leb_sg(ubi, vol, sgl, lnum, offset, len, check);
494 * @offset: offset within the logical eraseblock where to write
497 * This function writes @len bytes of data from @buf to offset @offset of
515 int offset, int len)
521 dbg_gen("write %d bytes to LEB %d:%d:%d", len, vol_id, lnum, offset);
529 if (!ubi_leb_valid(vol, lnum) || offset < 0 || len < 0 ||
530 offset + len > vol->usable_leb_size ||
531 offset & (ubi->min_io_size - 1) || len & (ubi->min_io_size - 1))
540 return ubi_eba_write_leb(ubi, vol, lnum, buf, offset, len);