39 #ifndef __DEV_ARM_FLASH_DEVICE_HH__
40 #define __DEV_ARM_FLASH_DEVICE_HH__
45 #include "debug/FlashDevice.hh"
47 #include "enums/DataDistribution.hh"
48 #include "params/FlashDevice.hh"
197 #endif //__DEV_ARM_FLASH_DEVICE_HH__
uint32_t pagesPerBlock
Disk dimensions in pages and blocks.
void serialize(CheckpointOut &cp) const override
Serialize; needed to create checkpoints.
void actionComplete()
Event rescheduler.
void regStats() override
Stats register function.
std::vector< uint32_t > blockEmptyEntries
number of empty entries
Stats::Scalar totalGCActivations
Amount of GC activations.
DrainState
Object drain/handover states.
Stats::Histogram writeAccess
Histogram of address accesses.
std::vector< struct PageMapEntry > locationTable
address to logic place has a block and a page field
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...
Stats::Histogram fileSystemAccess
Stats::Histogram writeLatency
Histogram of access latencies.
void unserialize(CheckpointIn &cp) override
Unserialize; needed to restore from checkpoints.
Tick accessTimes(uint64_t address, Actions accesstype)
Access time calculator.
void initializeMemory(uint64_t disk_size, uint32_t sector_size) override
Device access functions Inherrited from AbstractNVM.
const Enums::DataDistribution dataDistribution
Flash organization.
void clearUnknownPages(uint32_t index)
Function to indicate that a page is known.
Declaration of Statistics objects.
Stats::Histogram readAccess
This is a simple scalar statistic, like a counter.
DrainState drain() override
Checkpoint functions.
EventWrapper< FlashDevice,&FlashDevice::actionComplete > planeEvent
Completion event.
void checkDrain()
Checkdrain; needed to enable checkpoints.
void accessDevice(uint64_t address, uint32_t amount, Callback *event, Actions action)
Flash action function.
FlashDevice(const FlashDeviceParams *)
Initialize functions.
struct FlashDeviceStats stats
RequestHandler stats.
uint64_t Tick
Tick count type.
A copy involves taking all the used pages from a block and store it in another.
const Tick readLatency
Access latencies.
void writeMemory(uint64_t address, uint32_t amount, Callback *event) override
Stats::Histogram readLatency
std::vector< uint32_t > blockValidEntries
number of valid entries per block
Flash Device model The Flash Device model is a timing model for a NAND flash device.
std::vector< std::deque< struct CallBackEntry > > planeEventQueue
This vector of queues keeps track of all the callbacks per plane.
std::ostream CheckpointOut
Actions
Defines the possible actions to the flash.
Tick remap(uint64_t logic_page_addr)
FTL functionality.
void readMemory(uint64_t address, uint32_t amount, Callback *event) override
Access functions Access function to simulate a read/write access to the memory.
This is an interface between the disk interface (which will handle the disk data transactions) and th...
bool getUnknownPages(uint32_t index)
Function to test if a page is known.
uint64_t diskSize
Disk sizes in bytes.
const uint32_t GCActivePercentage
Garbage collection algorithm emulator.
Every logical address maps to a physical block and a physical page.
void initializeFlash(uint64_t disk_size, uint32_t sector_size)
Initialization function; called when all disk specifics are known.