Lines Matching refs:offset

195 static bool discard_blocks(int fd, off64_t offset, uint64_t size, bool force = false) {  in discard_blocks()  argument
201 uint64_t args[2] = { static_cast<uint64_t>(offset), size }; in discard_blocks()
213 static bool check_lseek(int fd, off64_t offset, int whence) { in check_lseek() argument
214 off64_t rc = TEMP_FAILURE_RETRY(lseek64(fd, offset, whence)); in check_lseek()
306 off64_t offset = static_cast<off64_t>(range.first) * BLOCKSIZE; in SeekToOutputRange() local
310 if (!discard_blocks(fd_, offset, current_range_left_)) { in SeekToOutputRange()
313 if (!check_lseek(fd_, offset, SEEK_SET)) { in SeekToOutputRange()
505 off64_t offset = static_cast<off64_t>(begin) * BLOCKSIZE; in WriteBlocks() local
507 if (!discard_blocks(fd, offset, size)) { in WriteBlocks()
511 if (!check_lseek(fd, offset, SEEK_SET)) { in WriteBlocks()
1291 off64_t offset = static_cast<off64_t>(begin) * BLOCKSIZE; in PerformCommandZero() local
1293 if (!discard_blocks(params.fd, offset, size)) { in PerformCommandZero()
1297 if (!check_lseek(params.fd, offset, SEEK_SET)) { in PerformCommandZero()
1361 size_t offset; in PerformCommandDiff() local
1362 if (!android::base::ParseUint(params.tokens[params.cpos++], &offset)) { in PerformCommandDiff()
1396 std::string(reinterpret_cast<const char*>(params.patch_start + offset), len)); in PerformCommandDiff()
1469 off64_t offset = static_cast<off64_t>(begin) * BLOCKSIZE; in PerformCommandErase() local
1471 if (!discard_blocks(params.fd, offset, size, true /* force */)) { in PerformCommandErase()
1695 params.patch_start = updater->GetMappedPackageAddress() + patch_entry.offset; in PerformBlockImageUpdate()