MCPcopy Create free account
hub / github.com/PiSCSI/piscsi / GetTrack

Method GetTrack

cpp/devices/disk_cache.cpp:37–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35}
36
37shared_ptr<DiskTrack> DiskCache::GetTrack(uint64_t block)
38{
39 // Update first
40 UpdateSerialNumber();
41
42 // Calculate track (fixed to 256 sectors/track)
43 int64_t track = block >> 8;
44
45 // Get track data
46 return Assign(track);
47}
48
49bool DiskCache::ReadSector(span<uint8_t> buf, uint64_t block)
50{

Callers 1

AssignMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected