Ethernet.py revision 1644
11689SN/Afrom Device import DmaDevice
22329SN/Afrom Pci import PciDevice
31689SN/A
41689SN/Asimobj EtherInt(SimObject):
51689SN/A    type = 'EtherInt'
61689SN/A    abstract = True
71689SN/A    peer = Param.EtherInt(NULL, "peer interface")
81689SN/A
91689SN/Asimobj EtherLink(SimObject):
101689SN/A    type = 'EtherLink'
111689SN/A    int1 = Param.EtherInt("interface 1")
121689SN/A    int2 = Param.EtherInt("interface 2")
131689SN/A    delay = Param.Latency('0us', "packet transmit delay")
141689SN/A    speed = Param.NetworkBandwidth('100Mbps', "link speed")
151689SN/A    dump = Param.EtherDump(NULL, "dump object")
161689SN/A
171689SN/Asimobj EtherBus(SimObject):
181689SN/A    type = 'EtherBus'
191689SN/A    loopback = Param.Bool(True, "send packet back to the sending interface")
201689SN/A    dump = Param.EtherDump(NULL, "dump object")
211689SN/A    speed = Param.NetworkBandwidth('100Mbps', "bus speed in bits per second")
221689SN/A
231689SN/Asimobj EtherTap(EtherInt):
241689SN/A    type = 'EtherTap'
251689SN/A    bufsz = Param.Int(10000, "tap buffer size")
261689SN/A    dump = Param.EtherDump(NULL, "dump object")
272665Ssaidi@eecs.umich.edu    port = Param.UInt16(3500, "tap port")
282665Ssaidi@eecs.umich.edu
291689SN/Asimobj EtherDump(SimObject):
301689SN/A    type = 'EtherDump'
3111793Sbrandon.potter@amd.com    file = Param.String("dump file")
3211793Sbrandon.potter@amd.com
332348SN/Asimobj EtherDev(DmaDevice):
3412334Sgabeblack@google.com    type = 'EtherDev'
351689SN/A    hardware_address = Param.EthernetAddr(NextEthernetAddr,
368232Snate@binkert.org        "Ethernet Hardware Address")
371061SN/A
388519SAli.Saidi@ARM.com    dma_data_free = Param.Bool(False, "DMA of Data is free")
398519SAli.Saidi@ARM.com    dma_desc_free = Param.Bool(False, "DMA of Descriptors is free")
401061SN/A    dma_read_delay = Param.Latency('0us', "fixed delay for dma reads")
411061SN/A    dma_read_factor = Param.Latency('0us', "multiplier for dma reads")
421062SN/A    dma_write_delay = Param.Latency('0us', "fixed delay for dma writes")
432292SN/A    dma_write_factor = Param.Latency('0us', "multiplier for dma writes")
441061SN/A
452348SN/A    rx_filter = Param.Bool(True, "Enable Receive Filter")
462348SN/A    rx_delay = Param.Latency('1us', "Receive Delay")
472348SN/A    tx_delay = Param.Latency('1us', "Transmit Delay")
482348SN/A
492292SN/A    intr_delay = Param.Latency('0us', "Interrupt Delay")
501061SN/A    payload_bus = Param.Bus(NULL, "The IO Bus to attach to for payload")
512292SN/A    physmem = Param.PhysicalMemory(parent.any, "Physical Memory")
521061SN/A    tlaser = Param.Turbolaser(parent.any, "Turbolaser")
532292SN/A
541061SN/Asimobj NSGigE(PciDevice):
551061SN/A    type = 'NSGigE'
562348SN/A    hardware_address = Param.EthernetAddr(NextEthernetAddr,
572348SN/A        "Ethernet Hardware Address")
582348SN/A
592348SN/A    cycle_time = Param.Frequency('100MHz', "State machine processor frequency")
602292SN/A
611061SN/A    dma_data_free = Param.Bool(False, "DMA of Data is free")
622292SN/A    dma_desc_free = Param.Bool(False, "DMA of Descriptors is free")
631061SN/A    dma_read_delay = Param.Latency('0us', "fixed delay for dma reads")
642292SN/A    dma_read_factor = Param.Latency('0us', "multiplier for dma reads")
651061SN/A    dma_write_delay = Param.Latency('0us', "fixed delay for dma writes")
662292SN/A    dma_write_factor = Param.Latency('0us', "multiplier for dma writes")
671061SN/A
681061SN/A    rx_filter = Param.Bool(True, "Enable Receive Filter")
692292SN/A    rx_delay = Param.Latency('1us', "Receive Delay")
701061SN/A    tx_delay = Param.Latency('1us', "Transmit Delay")
712292SN/A
728519SAli.Saidi@ARM.com    rx_fifo_size = Param.MemorySize('128kB', "max size in bytes of rxFifo")
738519SAli.Saidi@ARM.com    tx_fifo_size = Param.MemorySize('128kB', "max size in bytes of txFifo")
741061SN/A
751061SN/A    m5reg = Param.UInt32(0, "Register for m5 usage")
762292SN/A
772292SN/A    intr_delay = Param.Latency('0us', "Interrupt Delay in microseconds")
782292SN/A    payload_bus = Param.Bus(NULL, "The IO Bus to attach to for payload")
792292SN/A    physmem = Param.PhysicalMemory(parent.any, "Physical Memory")
802292SN/A
818519SAli.Saidi@ARM.comsimobj EtherDevInt(EtherInt):
822292SN/A    type = 'EtherDevInt'
832292SN/A    device = Param.EtherDev("Ethernet device of this interface")
842292SN/A
858519SAli.Saidi@ARM.comsimobj NSGigEInt(EtherInt):
862292SN/A    type = 'NSGigEInt'
872292SN/A    device = Param.NSGigE("Ethernet device of this interface")
882292SN/A
892292SN/A
902292SN/A