gem5  v21.1.0.2
Public Member Functions | Public Attributes | Protected Types | Protected Member Functions | Protected Attributes | List of all members
gem5::IGbE::DescCache< T > Class Template Referenceabstract
Inheritance diagram for gem5::IGbE::DescCache< T >:
gem5::Serializable

Public Member Functions

 DescCache (IGbE *i, const std::string n, int s)
 
virtual ~DescCache ()
 
std::string name ()
 
void areaChanged ()
 If the address/len/head change when we've got descriptors that are dirty that is very bad. More...
 
void writeback (Addr aMask)
 
void writeback1 ()
 
void fetchDescriptors ()
 Fetch a chunk of descriptors into the descriptor cache. More...
 
void fetchDescriptors1 ()
 
void fetchComplete ()
 Called by event when dma to read descriptors is completed. More...
 
void wbComplete ()
 Called by event when dma to writeback descriptors is completed. More...
 
unsigned descLeft () const
 
unsigned descUsed () const
 
unsigned descUnused () const
 
void reset ()
 
void serialize (CheckpointOut &cp) const override
 Serialize an object. More...
 
void unserialize (CheckpointIn &cp) override
 Unserialize an object. More...
 
virtual bool hasOutstandingEvents ()
 
- Public Member Functions inherited from gem5::Serializable
 Serializable ()
 
virtual ~Serializable ()
 
void serializeSection (CheckpointOut &cp, const char *name) const
 Serialize an object into a new section. More...
 
void serializeSection (CheckpointOut &cp, const std::string &name) const
 
void unserializeSection (CheckpointIn &cp, const char *name)
 Unserialize an a child object. More...
 
void unserializeSection (CheckpointIn &cp, const std::string &name)
 

Public Attributes

std::string annSmFetch
 Annotate sm. More...
 
std::string annSmWb
 
std::string annUnusedDescQ
 
std::string annUsedCacheQ
 
std::string annUsedDescQ
 
std::string annUnusedCacheQ
 
std::string annDescQ
 
EventFunctionWrapper wbDelayEvent
 
EventFunctionWrapper fetchDelayEvent
 
EventFunctionWrapper fetchEvent
 
EventFunctionWrapper wbEvent
 

Protected Types

typedef std::deque< T * > CacheType
 

Protected Member Functions

virtual Addr descBase () const =0
 
virtual long descHead () const =0
 
virtual long descTail () const =0
 
virtual long descLen () const =0
 
virtual void updateHead (long h)=0
 
virtual void enableSm ()=0
 
virtual void actionAfterWb ()
 
virtual void fetchAfterWb ()=0
 
Addr pciToDma (Addr a)
 Shortcut for DMA address translation. More...
 

Protected Attributes

CacheType usedCache
 
CacheType unusedCache
 
T * fetchBuf
 
T * wbBuf
 
IGbEigbe
 
std::string _name
 
int cachePnt
 
int size
 
int curFetching
 
int wbOut
 
bool moreToWb
 
Addr wbAlignment
 
EthPacketPtr pktPtr
 The packet that is currently being dmad to memory if any. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from gem5::Serializable
static const std::string & currentSection ()
 Gets the fully-qualified name of the active section. More...
 
static void generateCheckpointOut (const std::string &cpt_dir, std::ofstream &outstream)
 Generate a checkpoint file so that the serialization can be routed to it. More...
 

Detailed Description

template<class T>
class gem5::IGbE::DescCache< T >

Definition at line 181 of file i8254xGBe.hh.

Member Typedef Documentation

◆ CacheType

template<class T >
typedef std::deque<T *> gem5::IGbE::DescCache< T >::CacheType
protected

Definition at line 193 of file i8254xGBe.hh.

Constructor & Destructor Documentation

◆ DescCache()

template<class T >
gem5::IGbE::DescCache< T >::DescCache ( IGbE i,
const std::string  n,
int  s 
)

Definition at line 826 of file i8254xGBe.cc.

◆ ~DescCache()

template<class T >
gem5::IGbE::DescCache< T >::~DescCache ( )
virtual

Definition at line 839 of file i8254xGBe.cc.

Member Function Documentation

◆ actionAfterWb()

template<class T >
virtual void gem5::IGbE::DescCache< T >::actionAfterWb ( )
inlineprotectedvirtual

Reimplemented in gem5::IGbE::TxDescCache.

Definition at line 190 of file i8254xGBe.hh.

◆ areaChanged()

template<class T >
void gem5::IGbE::DescCache< T >::areaChanged ( )

If the address/len/head change when we've got descriptors that are dirty that is very bad.

This function checks that we don't and if we do panics.

Definition at line 848 of file i8254xGBe.cc.

Referenced by gem5::IGbE::write().

◆ descBase()

template<class T >
virtual Addr gem5::IGbE::DescCache< T >::descBase ( ) const
protectedpure virtual

◆ descHead()

template<class T >
virtual long gem5::IGbE::DescCache< T >::descHead ( ) const
protectedpure virtual

◆ descLeft()

template<class T >
unsigned gem5::IGbE::DescCache< T >::descLeft ( ) const
inline

◆ descLen()

template<class T >
virtual long gem5::IGbE::DescCache< T >::descLen ( ) const
protectedpure virtual

◆ descTail()

template<class T >
virtual long gem5::IGbE::DescCache< T >::descTail ( ) const
protectedpure virtual

◆ descUnused()

template<class T >
unsigned gem5::IGbE::DescCache< T >::descUnused ( ) const
inline

Definition at line 288 of file i8254xGBe.hh.

Referenced by gem5::IGbE::rxStateMachine(), and gem5::IGbE::txStateMachine().

◆ descUsed()

template<class T >
unsigned gem5::IGbE::DescCache< T >::descUsed ( ) const
inline

Definition at line 285 of file i8254xGBe.hh.

Referenced by gem5::IGbE::rxStateMachine().

◆ enableSm()

template<class T >
virtual void gem5::IGbE::DescCache< T >::enableSm ( )
protectedpure virtual

◆ fetchAfterWb()

template<class T >
virtual void gem5::IGbE::DescCache< T >::fetchAfterWb ( )
protectedpure virtual

◆ fetchComplete()

template<class T >
void gem5::IGbE::DescCache< T >::fetchComplete ( )

Called by event when dma to read descriptors is completed.

Definition at line 989 of file i8254xGBe.cc.

◆ fetchDescriptors()

template<class T >
void gem5::IGbE::DescCache< T >::fetchDescriptors ( )

Fetch a chunk of descriptors into the descriptor cache.

Calls fetchComplete when the memory system returns the data

Definition at line 930 of file i8254xGBe.cc.

Referenced by gem5::IGbE::rxStateMachine(), gem5::IGbE::txStateMachine(), and gem5::IGbE::write().

◆ fetchDescriptors1()

template<class T >
void gem5::IGbE::DescCache< T >::fetchDescriptors1 ( )

Definition at line 969 of file i8254xGBe.cc.

◆ hasOutstandingEvents()

template<class T >
virtual bool gem5::IGbE::DescCache< T >::hasOutstandingEvents ( )
inlinevirtual

Reimplemented in gem5::IGbE::TxDescCache, and gem5::IGbE::RxDescCache.

Definition at line 298 of file i8254xGBe.hh.

◆ name()

template<class T >
std::string gem5::IGbE::DescCache< T >::name ( )
inline

Definition at line 239 of file i8254xGBe.hh.

◆ pciToDma()

template<class T >
Addr gem5::IGbE::DescCache< T >::pciToDma ( Addr  a)
inlineprotected

Shortcut for DMA address translation.

Definition at line 229 of file i8254xGBe.hh.

◆ reset()

template<class T >
void gem5::IGbE::DescCache< T >::reset ( )

Definition at line 1056 of file i8254xGBe.cc.

Referenced by gem5::IGbE::write().

◆ serialize()

template<class T >
void gem5::IGbE::DescCache< T >::serialize ( CheckpointOut cp) const
overridevirtual

Serialize an object.

Output an object's state into the current checkpoint section.

Parameters
cpCheckpoint state

Implements gem5::Serializable.

Definition at line 1073 of file i8254xGBe.cc.

Referenced by gem5::IGbE::RxDescCache::serialize(), and gem5::IGbE::TxDescCache::serialize().

◆ unserialize()

template<class T >
void gem5::IGbE::DescCache< T >::unserialize ( CheckpointIn cp)
overridevirtual

Unserialize an object.

Read an object's state from the current checkpoint section.

Parameters
cpCheckpoint state

Implements gem5::Serializable.

Definition at line 1108 of file i8254xGBe.cc.

Referenced by gem5::IGbE::RxDescCache::unserialize(), and gem5::IGbE::TxDescCache::unserialize().

◆ updateHead()

template<class T >
virtual void gem5::IGbE::DescCache< T >::updateHead ( long  h)
protectedpure virtual

◆ wbComplete()

template<class T >
void gem5::IGbE::DescCache< T >::wbComplete ( )

Called by event when dma to writeback descriptors is completed.

Definition at line 1017 of file i8254xGBe.cc.

◆ writeback()

template<class T >
void gem5::IGbE::DescCache< T >::writeback ( Addr  aMask)

◆ writeback1()

template<class T >
void gem5::IGbE::DescCache< T >::writeback1 ( )

Definition at line 906 of file i8254xGBe.cc.

Member Data Documentation

◆ _name

template<class T >
std::string gem5::IGbE::DescCache< T >::_name
protected

Definition at line 204 of file i8254xGBe.hh.

Referenced by gem5::IGbE::DescCache< igbreg::RxDesc >::name().

◆ annDescQ

template<class T >
std::string gem5::IGbE::DescCache< T >::annDescQ

Definition at line 234 of file i8254xGBe.hh.

◆ annSmFetch

template<class T >
std::string gem5::IGbE::DescCache< T >::annSmFetch

Annotate sm.

Definition at line 233 of file i8254xGBe.hh.

◆ annSmWb

template<class T >
std::string gem5::IGbE::DescCache< T >::annSmWb

Definition at line 233 of file i8254xGBe.hh.

◆ annUnusedCacheQ

template<class T >
std::string gem5::IGbE::DescCache< T >::annUnusedCacheQ

Definition at line 234 of file i8254xGBe.hh.

◆ annUnusedDescQ

template<class T >
std::string gem5::IGbE::DescCache< T >::annUnusedDescQ

Definition at line 233 of file i8254xGBe.hh.

◆ annUsedCacheQ

template<class T >
std::string gem5::IGbE::DescCache< T >::annUsedCacheQ

Definition at line 233 of file i8254xGBe.hh.

◆ annUsedDescQ

template<class T >
std::string gem5::IGbE::DescCache< T >::annUsedDescQ

Definition at line 234 of file i8254xGBe.hh.

◆ cachePnt

template<class T >
int gem5::IGbE::DescCache< T >::cachePnt
protected

Definition at line 207 of file i8254xGBe.hh.

Referenced by gem5::IGbE::DescCache< igbreg::RxDesc >::descLeft().

◆ curFetching

template<class T >
int gem5::IGbE::DescCache< T >::curFetching
protected

Definition at line 213 of file i8254xGBe.hh.

◆ fetchBuf

template<class T >
T* gem5::IGbE::DescCache< T >::fetchBuf
protected

Definition at line 197 of file i8254xGBe.hh.

◆ fetchDelayEvent

template<class T >
EventFunctionWrapper gem5::IGbE::DescCache< T >::fetchDelayEvent

Definition at line 256 of file i8254xGBe.hh.

◆ fetchEvent

template<class T >
EventFunctionWrapper gem5::IGbE::DescCache< T >::fetchEvent

◆ igbe

template<class T >
IGbE* gem5::IGbE::DescCache< T >::igbe
protected

Definition at line 201 of file i8254xGBe.hh.

Referenced by gem5::IGbE::DescCache< igbreg::RxDesc >::pciToDma().

◆ moreToWb

template<class T >
bool gem5::IGbE::DescCache< T >::moreToWb
protected

Definition at line 220 of file i8254xGBe.hh.

◆ pktPtr

template<class T >
EthPacketPtr gem5::IGbE::DescCache< T >::pktPtr
protected

The packet that is currently being dmad to memory if any.

Definition at line 226 of file i8254xGBe.hh.

◆ size

template<class T >
int gem5::IGbE::DescCache< T >::size
protected

Definition at line 210 of file i8254xGBe.hh.

◆ unusedCache

template<class T >
CacheType gem5::IGbE::DescCache< T >::unusedCache
protected

◆ usedCache

template<class T >
CacheType gem5::IGbE::DescCache< T >::usedCache
protected

Definition at line 194 of file i8254xGBe.hh.

Referenced by gem5::IGbE::DescCache< igbreg::RxDesc >::descUsed().

◆ wbAlignment

template<class T >
Addr gem5::IGbE::DescCache< T >::wbAlignment
protected

Definition at line 223 of file i8254xGBe.hh.

◆ wbBuf

template<class T >
T* gem5::IGbE::DescCache< T >::wbBuf
protected

Definition at line 198 of file i8254xGBe.hh.

◆ wbDelayEvent

template<class T >
EventFunctionWrapper gem5::IGbE::DescCache< T >::wbDelayEvent

Definition at line 249 of file i8254xGBe.hh.

◆ wbEvent

template<class T >
EventFunctionWrapper gem5::IGbE::DescCache< T >::wbEvent

◆ wbOut

template<class T >
int gem5::IGbE::DescCache< T >::wbOut
protected

Definition at line 216 of file i8254xGBe.hh.


The documentation for this class was generated from the following files:

Generated on Tue Sep 21 2021 12:27:43 for gem5 by doxygen 1.8.17