35 #ifndef __DEV_NET_ETHERTAP_HH__
36 #define __DEV_NET_ETHERTAP_HH__
42 #include "config/use_tuntap.hh"
48 #include "params/EtherTap.hh"
52 #include "params/EtherTapStub.hh"
92 virtual void recvReal(
int revent) = 0;
122 {
return "EtherTapBase retransmit"; }
190 typedef EtherTapParams
Params;
191 EtherTap(
const Params *
p);
197 return dynamic_cast<const Params *
>(
_params);
210 #endif // __DEV_NET_ETHERTAP_HH__
EtherTapStub(const Params *p)
void unserialize(CheckpointIn &cp) override
Unserialize an object.
void serialize(CheckpointOut &cp) const override
Serialize an object.
const Params * params() const
void sendSimulated(void *data, size_t len)
bool recvPacket(EthPacketPtr pkt) override
TxEvent(EtherTapBase *_tap)
bool recvSimulated(EthPacketPtr packet)
void serialize(CheckpointOut &cp) const override
Serialize an object.
void unserialize(CheckpointIn &cp) override
Unserialize an object.
virtual bool sendReal(const void *data, size_t len)=0
std::shared_ptr< EthPacketData > EthPacketPtr
bool sendReal(const void *data, size_t len) override
EtherTapBase(const Params *p)
The base EtherObject class, allows for an accesor function to a simobj that returns the Port...
const Params * params() const
virtual void recvReal(int revent)=0
std::ostream CheckpointOut
EtherTapBaseParams Params
const SimObjectParams * _params
Cached copy of the object parameters.
const std::string & name() const
Return port name (for DPRINTF).
EtherInt * getEthPort(const std::string &if_name, int idx) override
Additional function to return the Port of a memory object.
std::queue< EthPacketPtr > packetBuffer
EtherTapStubParams Params
void recvReal(int revent) override
virtual const char * description() const
Return a C string describing the event.
EtherTapInt(const std::string &name, EtherTapBase *t)
Base Ethernet Object declaration.