Home
last modified time | relevance | path

Searched refs:new_block (Results 1 – 14 of 14) sorted by relevance

/system/core/fs_mgr/libsnapshot/
Dsnapuserd_readahead.cpp175 if (dest_blocks_.count(cow_op->new_block) || source_blocks_.count(cow_op->source)) { in CheckOverlap()
180 source_blocks_.insert(cow_op->new_block); in CheckOverlap()
195 blocks.push_back(cow_op->new_block); in PrepareReadAhead()
211 blocks.push_back(op->new_block); in PrepareReadAhead()
234 if (bm->new_block == 0 && bm->file_offset == 0) { in ReconstructDataFromCow()
240 read_ahead_buffer_map[bm->new_block] = bufptr; in ReconstructDataFromCow()
252 if (read_ahead_buffer_map.find(op->new_block) != read_ahead_buffer_map.end()) { in ReconstructDataFromCow()
254 snapuserd_->SetFinalBlockMerged(op->new_block); in ReconstructDataFromCow()
301 bm->new_block = 0; in ReadAheadIOStart()
340 uint64_t new_block = blocks.back(); in ReadAheadIOStart() local
[all …]
Dsnapshot_reader_test.cpp65 std::string new_block = MakeNewBlockString(); in WriteCow() local
68 ASSERT_TRUE(writer->AddRawBlocks(5, new_block.data(), new_block.size())); in WriteCow()
138 std::string new_block = "This is a new block"; in MakeNewBlockString() local
139 new_block.resize(kBlockSize / 2, '*'); in MakeNewBlockString()
140 new_block.resize(kBlockSize, '!'); in MakeNewBlockString()
141 return new_block; in MakeNewBlockString()
Dcow_writer.cpp39 bool ICowWriter::AddCopy(uint64_t new_block, uint64_t old_block) { in AddCopy() argument
40 if (!ValidateNewBlock(new_block)) { in AddCopy()
43 return EmitCopy(new_block, old_block); in AddCopy()
73 bool ICowWriter::ValidateNewBlock(uint64_t new_block) { in ValidateNewBlock() argument
74 if (options_.max_blocks && new_block >= options_.max_blocks.value()) { in ValidateNewBlock()
75 LOG(ERROR) << "New block " << new_block << " exceeds maximum block count " in ValidateNewBlock()
261 bool CowWriter::EmitCopy(uint64_t new_block, uint64_t old_block) { in EmitCopy() argument
265 op.new_block = new_block; in EmitCopy()
276 op.new_block = new_block_start + i; in EmitRawBlocks()
314 op.new_block = new_block_start + i; in EmitZeroBlocks()
Dsnapshot_writer.cpp100 bool CompressedSnapshotWriter::EmitCopy(uint64_t new_block, uint64_t old_block) { in EmitCopy() argument
101 return cow_->AddCopy(new_block, old_block); in EmitCopy()
166 bool OnlineKernelSnapshotWriter::EmitCopy(uint64_t new_block, uint64_t old_block) { in EmitCopy() argument
178 return EmitRawBlocks(new_block, buffer.data(), buffer.size()); in EmitCopy()
Dcow_api_test.cpp102 ASSERT_EQ(op->new_block, 10); in TEST_F()
114 ASSERT_EQ(op->new_block, 50); in TEST_F()
126 ASSERT_EQ(op->new_block, 51); in TEST_F()
136 ASSERT_EQ(op->new_block, 52); in TEST_F()
172 ASSERT_EQ(op->new_block, 50); in TEST_F()
213 ASSERT_EQ(op->new_block, 50); in TEST_F()
230 ASSERT_EQ(op->new_block, 51); in TEST_F()
274 ASSERT_EQ(op->new_block, 51); in TEST_F()
788 AssertionResult WriteDataBlock(CowWriter* writer, uint64_t new_block, std::string data) { in WriteDataBlock() argument
790 if (!writer->AddRawBlocks(new_block, data.data(), data.size())) { in WriteDataBlock()
[all …]
Dsnapshot_reader.cpp97 if (op->new_block >= ops_.size()) { in SetCow()
98 ops_.resize(op->new_block + 1, nullptr); in SetCow()
100 ops_[op->new_block] = op; in SetCow()
Dsnapuserd_worker.cpp138 SNAP_LOG(ERROR) << "ProcessReplaceOp failed for block " << cow_op->new_block; in ProcessReplaceOp()
151 SNAP_LOG(DEBUG) << " ReadFromBaseDevice...: new-block: " << cow_op->new_block in ReadFromBaseDevice()
170 if (!snapuserd_->GetReadAheadPopulatedBuffer(cow_op->new_block, buffer)) { in GetReadAheadPopulatedBuffer()
182 << " new_block: " << cow_op->new_block; in ProcessCopyOp()
518 if (read_ahead_buffer_map.find(cow_op->new_block) == read_ahead_buffer_map.end()) { in GetNumberOfMergedOps()
520 << " Block: " << cow_op->new_block << " not found in read-ahead cache" in GetNumberOfMergedOps()
527 if (cow_op->new_block == snapuserd_->GetFinalBlockMerged()) { in GetNumberOfMergedOps()
Dsnapuserd.cpp410 de->old_chunk = cow_op->new_block; in ReadMetadata()
510 if (dest_blocks.count(cow_op->new_block) || source_blocks.count(cow_op->source)) { in ReadMetadata()
518 source_blocks.insert(cow_op->new_block); in ReadMetadata()
519 prev_id = cow_op->new_block; in ReadMetadata()
533 de->old_chunk = cow_op->new_block; in ReadMetadata()
Dcow_format.cpp54 os << "new_block:" << op.new_block << ",\t"; in operator <<()
Dcow_reader.cpp376 return op1.new_block > op2.new_block; in InitializeMerge()
/system/core/fs_mgr/libsnapshot/include/libsnapshot/
Dcow_writer.h53 bool AddCopy(uint64_t new_block, uint64_t old_block);
77 virtual bool EmitCopy(uint64_t new_block, uint64_t old_block) = 0;
82 bool ValidateNewBlock(uint64_t new_block);
112 virtual bool EmitCopy(uint64_t new_block, uint64_t old_block) override;
Dcow_format.h125 uint64_t new_block; member
170 uint64_t new_block; member
Dsnapshot_writer.h75 bool EmitCopy(uint64_t new_block, uint64_t old_block) override;
104 bool EmitCopy(uint64_t new_block, uint64_t old_block) override;
/system/update_engine/payload_consumer/
Dsnapshot_extent_writer_unittest.cc46 bool EmitCopy(uint64_t new_block, uint64_t old_block) override { in EmitCopy() argument
47 operations_[new_block] = {.type = CowOp::COW_COPY, in EmitCopy()