|
DESERT 4.0.0
|
#include <uwmll-module.h>


Public Member Functions | |
| UWMllModule () | |
| ~UWMllModule () | |
| virtual int | crLayCommand (ClMessage *m) |
| virtual int | recvAsyncClMsg (ClMessage *m) |
| virtual int | recvSyncClMsg (ClMessage *m) |
| virtual int | command (int argc, const char *const *argv) |
| virtual void | recv (Packet *p) |
| virtual void | recv (Packet *p, int idSrc) |
Protected Member Functions | |
| virtual void | sendDown (Packet *p) |
| virtual void | sendUp (Packet *p) |
| virtual int | getDownAddr (int downId=-1) |
| virtual int | arpResolve (nsaddr_t dst, Packet *p) |
| void | incrArpPktDrop () |
| int | getArpPktDropped () |
Protected Attributes | |
| UWARPTable * | arptable_ |
| vector< nsaddr_t > | netAddr |
| int | seqno_ |
| int | n_arp_pkt_drop |
| int | enable_addr_copy |
Module for ARP-resolve. Should live between one or more IPModule and one MMacModule NOTE: You should only use one MMacModule below this module, else behavior is undef
| UWMllModule::UWMllModule | ( | ) |
Constructor
References arptable_, and enable_addr_copy.
| UWMllModule::~UWMllModule | ( | ) |
Desctructor
|
protectedvirtual |
Resolve MAC address for given dst address
| dst | IP destination address |
| p | packet which requested the resolv, will be cached |
References arptable_, UWARPTable::lookup(), UWARPEntry::macaddr_, and UWARPEntry::up_.
Referenced by sendDown().

|
virtual |
TCL Command handler
References UWARPTable::addEntry(), arptable_, UWARPTable::clear(), getArpPktDropped(), UWARPEntry::macaddr_, and UWARPEntry::up_.

|
virtual |
Receive asyncronous commands In Practive only IPModule telling us its IP-address
| m | Pointer to message object |
|
inlineprotected |
References n_arp_pkt_drop.
Referenced by command().
|
protectedvirtual |
Retrieve MAC address for lower layer
| downId | id of downward module if> -1, only the module with id downId will be asked, else request is broadcasted |
Referenced by sendDown().
|
inlineprotected |
References n_arp_pkt_drop.
|
virtual |
|
virtual |
Retrieve packets from other modules This method is used to know which mac-module to send ARP-replies to
References sendDown(), and sendUp().

|
virtual |
|
virtual |
|
protectedvirtual |
Handle packet going down
References arpResolve(), hdr_uwip::daddr(), enable_addr_copy, getDownAddr(), and seqno_.
Referenced by recv().

|
protectedvirtual |
Handle packet going up
Referenced by recv().
|
protected |
Pointer to an arptable
Referenced by arpResolve(), command(), and UWMllModule().
|
protected |
Referenced by sendDown(), and UWMllModule().
|
protected |
Referenced by getArpPktDropped(), and incrArpPktDrop().
|
protected |
List of IP address to our upper layers
|
protected |
Link layer sequence number
Referenced by sendDown().