Go to the documentation of this file.
37 #ifndef __DEV_ARM_FLASH_DEVICE_HH__
38 #define __DEV_ARM_FLASH_DEVICE_HH__
43 #include "debug/FlashDevice.hh"
45 #include "enums/DataDistribution.hh"
46 #include "params/FlashDevice.hh"
96 std::function<void()>
function;
125 const std::function<
void()> &
event)
override
132 const std::function<
void()> &
event)
override
207 #endif //__DEV_ARM_FLASH_DEVICE_HH__
DrainState drain() override
Checkpoint functions.
This is a simple scalar statistic, like a counter.
statistics::Scalar totalGCActivations
Amount of GC activations.
void initializeMemory(uint64_t disk_size, uint32_t sector_size) override
Device access functions Inherrited from AbstractNVM.
statistics::Histogram readAccess
statistics::Histogram writeLatency
Histogram of access latencies.
@ ActionCopy
A copy involves taking all the used pages from a block and store it in another.
std::vector< uint32_t > blockEmptyEntries
number of empty entries
void unserialize(CheckpointIn &cp) override
Unserialize; needed to restore from checkpoints.
std::vector< uint32_t > unknownPages
when the disk is first started we are unsure of the number of used pages, this variable will help det...
EventFunctionWrapper planeEvent
Completion event.
Actions
Defines the possible actions to the flash.
void clearUnknownPages(uint32_t index)
Function to indicate that a page is known.
void accessDevice(uint64_t address, uint32_t amount, const std::function< void()> &event, Actions action)
Flash action function.
DrainState
Object drain/handover states.
void initializeFlash(uint64_t disk_size, uint32_t sector_size)
Initialization function; called when all disk specifics are known.
const uint32_t GCActivePercentage
Garbage collection algorithm emulator.
struct FlashDeviceStats stats
RequestHandler stats.
uint64_t Tick
Tick count type.
std::vector< uint32_t > blockValidEntries
number of valid entries per block
statistics::Histogram readLatency
Tick accessTimes(uint64_t address, Actions accesstype)
Access time calculator.
std::vector< struct PageMapEntry > locationTable
address to logic place has a block and a page field
statistics::Histogram fileSystemAccess
void serialize(CheckpointOut &cp) const override
Serialize; needed to create checkpoints.
const enums::DataDistribution dataDistribution
Flash organization.
Flash Device model The Flash Device model is a timing model for a NAND flash device.
void readMemory(uint64_t address, uint32_t amount, const std::function< void()> &event) override
Access functions Access function to simulate a read/write access to the memory.
const Tick readLatency
Access latencies.
statistics::Histogram writeAccess
Histogram of address accesses.
void checkDrain()
Checkdrain; needed to enable checkpoints.
std::ostream CheckpointOut
uint32_t pagesPerBlock
Disk dimensions in pages and blocks.
bool getUnknownPages(uint32_t index)
Function to test if a page is known.
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
FlashDevice(const FlashDeviceParams &)
Initialize functions.
This is an interface between the disk interface (which will handle the disk data transactions) and th...
void actionComplete()
Event rescheduler.
std::vector< std::deque< struct CallBackEntry > > planeEventQueue
This vector of queues keeps track of all the callbacks per plane.
uint64_t diskSize
Disk sizes in bytes.
Tick remap(uint64_t logic_page_addr)
FTL functionality.
void writeMemory(uint64_t address, uint32_t amount, const std::function< void()> &event) override
FlashDeviceStats(statistics::Group *parent)
Every logical address maps to a physical block and a physical page.
Generated on Tue Dec 21 2021 11:34:28 for gem5 by doxygen 1.8.17