Home
last modified time | relevance | path

Searched refs:block_size (Results 1 – 11 of 11) sorted by relevance

/bootable/recovery/fuse_sideload/
Dfuse_sideload.cpp83 uint32_t block_size; // block size that the adb host is using to send the file to us member
234 memset(fd->block_data, 0, fd->block_size); in fetch_block()
239 uint32_t fetch_size = fd->block_size; in fetch_block()
240 if (block * fd->block_size + fetch_size > fd->file_size) { in fetch_block()
243 fetch_size = fd->file_size - (block * fd->block_size); in fetch_block()
244 memset(fd->block_data + fetch_size, 0, fd->block_size - fetch_size); in fetch_block()
261 SHA256(fd->block_data, fd->block_size, hash.data()); in fetch_block()
303 uint32_t block = offset / fd->block_size; in handle_read()
315 uint32_t block_offset = offset - (block * fd->block_size); in handle_read()
318 if (size + block_offset <= fd->block_size) { in handle_read()
[all …]
Dfuse_provider.cpp36 FuseFileDataProvider::FuseFileDataProvider(const std::string& path, uint32_t block_size) { in FuseFileDataProvider() argument
49 fuse_block_size_ = block_size; in FuseFileDataProvider()
53 uint32_t block_size) { in CreateFromFile() argument
54 return std::make_unique<FuseFileDataProvider>(path, block_size); in CreateFromFile()
150 block_map.block_size(), block_map.block_ranges())); in CreateFromBlockMap()
/bootable/recovery/updater/
Dcommands.cpp318 const std::vector<uint8_t>& source, size_t block_size) { in MoveRange() argument
326 memmove(to + (it->first * block_size), from + (start * block_size), blocks * block_size); in MoveRange()
331 std::vector<uint8_t>* buffer, size_t block_size, in ReadAll() argument
334 if (buffer->size() < blocks() * block_size) { in ReadAll()
344 MoveRange(buffer, location_, *buffer, block_size); in ReadAll()
350 std::vector<uint8_t> stash_buffer(stash.blocks() * block_size); in ReadAll()
354 MoveRange(buffer, stash.ranges(), stash_buffer, block_size); in ReadAll()
359 void SourceInfo::DumpBuffer(const std::vector<uint8_t>& buffer, size_t block_size) const { in DumpBuffer()
366 CHECK_LE((buffer_index + 1) * block_size, buffer.size()); in DumpBuffer()
369 SHA1(buffer.data() + buffer_index * block_size, block_size, digest); in DumpBuffer()
/bootable/recovery/fuse_sideload/include/
Dfuse_provider.h31 FuseDataProvider(uint64_t file_size, uint32_t block_size) in FuseDataProvider() argument
32 : file_size_(file_size), fuse_block_size_(block_size) {} in FuseDataProvider()
63 FuseFileDataProvider(const std::string& path, uint32_t block_size);
66 uint32_t block_size);
/bootable/recovery/otautil/include/otautil/
Dsysutil.h53 uint32_t block_size() const { in block_size() function
63 BlockMapData(const std::string& path, uint64_t file_size, uint32_t block_size, in BlockMapData() argument
67 block_size_(block_size), in BlockMapData()
/bootable/recovery/minadbd/
Dfuse_adb_provider.h26 FuseAdbDataProvider(int fd, uint64_t file_size, uint32_t block_size) in FuseAdbDataProvider() argument
27 : FuseDataProvider(file_size, block_size), fd_(fd) {} in FuseAdbDataProvider()
Dminadbd_services.cpp104 int block_size; in RunAdbFuseSideload() local
106 !android::base::ParseInt(pieces[1], &block_size) || block_size <= 0) { in RunAdbFuseSideload()
111 LOG(INFO) << "sideload-host file size " << file_size << ", block size " << block_size; in RunAdbFuseSideload()
117 auto adb_data_reader = std::make_unique<FuseAdbDataProvider>(sfd, file_size, block_size); in RunAdbFuseSideload()
/bootable/recovery/tests/unit/
Dfuse_sideload_test.cpp36 FuseTestDataProvider(uint64_t file_size, uint32_t block_size) in FuseTestDataProvider() argument
37 : FuseDataProvider(file_size, block_size) {} in FuseTestDataProvider()
Dsysutil_test.cpp44 ASSERT_EQ(4096, block_map_data.block_size()); in TEST()
79 ASSERT_EQ(4294967295, block_map_data.block_size()); in TEST()
/bootable/recovery/updater/include/private/
Dcommands.h123 std::vector<uint8_t>* buffer, size_t block_size,
132 void DumpBuffer(const std::vector<uint8_t>& buffer, size_t block_size) const;
357 size_t block_size() const { in block_size() function
/bootable/recovery/otautil/
Dsysutil.cpp138 uint32_t blksize = block_map_data.block_size(); in MapBlockFile()