Disk: Allow mismatched access for Read and Write drivers

This will cause the driver to fall back to the least common
denominator.
This commit is contained in:
Paul Hollinsky
2022-03-03 20:29:13 -05:00
parent 1118428250
commit 0a15adbe91
9 changed files with 56 additions and 7 deletions
+1
View File
@@ -16,6 +16,7 @@ optional<uint64_t> ReadDriver::readLogicalDisk(Communication& com, device_eventh
// beginning or end of the block.
std::vector<uint8_t> alignedReadBuffer;
pos += vsaOffset;
const uint32_t idealBlockSize = getBlockSizeBounds().second;
const uint64_t startBlock = pos / idealBlockSize;
const uint32_t posWithinFirstBlock = static_cast<uint32_t>(pos % idealBlockSize);