diff --git a/liteeth/core/arp.py b/liteeth/core/arp.py index a9028c0..5497e2e 100644 --- a/liteeth/core/arp.py +++ b/liteeth/core/arp.py @@ -1,4 +1,4 @@ -# This file is Copyright (c) 2015-2018 Florent Kermarrec +# This file is Copyright (c) 2015-2020 Florent Kermarrec # License: BSD from liteeth.common import * @@ -7,6 +7,7 @@ from migen.genlib.misc import WaitTimer from litex.soc.interconnect.packet import Depacketizer, Packetizer +# ARP Layouts -------------------------------------------------------------------------------------- _arp_table_layout = [ ("reply", 1), @@ -15,7 +16,7 @@ _arp_table_layout = [ ("mac_address", 48) ] -# arp tx +# ARP TX ------------------------------------------------------------------------------------------- class LiteEthARPPacketizer(Packetizer): def __init__(self, dw=8): @@ -86,7 +87,7 @@ class LiteEthARPTX(Module): ) ) -# arp rx +# ARP RX ------------------------------------------------------------------------------------------- class LiteEthARPDepacketizer(Depacketizer): def __init__(self, dw=8): @@ -149,7 +150,7 @@ class LiteEthARPRX(Module): ) ) -# arp table +# ARP Table ---------------------------------------------------------------------------------------- class LiteEthARPTable(Module): def __init__(self, clk_freq, max_requests=8): @@ -288,7 +289,7 @@ class LiteEthARPTable(Module): ) ) -# arp +# ARP ---------------------------------------------------------------------------------------------- class LiteEthARP(Module): def __init__(self, mac, mac_address, ip_address, clk_freq, dw=8): diff --git a/liteeth/core/icmp.py b/liteeth/core/icmp.py index 34dc5c1..d85150a 100644 --- a/liteeth/core/icmp.py +++ b/liteeth/core/icmp.py @@ -1,12 +1,11 @@ -# This file is Copyright (c) 2015-2019 Florent Kermarrec +# This file is Copyright (c) 2015-2020 Florent Kermarrec # License: BSD from liteeth.common import * from litex.soc.interconnect.packet import Depacketizer, Packetizer - -# icmp tx +# ICMP TX ------------------------------------------------------------------------------------------ class LiteEthICMPPacketizer(Packetizer): def __init__(self, dw=8): @@ -53,7 +52,7 @@ class LiteEthICMPTX(Module): ) ) -# icmp rx +# ICMP RX ------------------------------------------------------------------------------------------ class LiteEthICMPDepacketizer(Depacketizer): def __init__(self, dw=8): @@ -120,7 +119,7 @@ class LiteEthICMPRX(Module): ) ) -# icmp echo +# ICMP Echo ---------------------------------------------------------------------------------------- class LiteEthICMPEcho(Module): def __init__(self, dw=8): @@ -138,7 +137,7 @@ class LiteEthICMPEcho(Module): self.source.checksum.eq(self.buffer.source.checksum + 0x800 + (self.buffer.source.checksum >= 0xf800)) ] -# icmp +# ICMP --------------------------------------------------------------------------------------------- class LiteEthICMP(Module): def __init__(self, ip, ip_address, dw=8): diff --git a/liteeth/core/ip.py b/liteeth/core/ip.py index 5f70e34..8bb4c64 100644 --- a/liteeth/core/ip.py +++ b/liteeth/core/ip.py @@ -1,4 +1,4 @@ -# This file is Copyright (c) 2015-2017 Florent Kermarrec +# This file is Copyright (c) 2015-2020 Florent Kermarrec # License: BSD from liteeth.common import * @@ -6,8 +6,7 @@ from liteeth.crossbar import LiteEthCrossbar from litex.soc.interconnect.packet import Depacketizer, Packetizer - -# ip crossbar +# IP Crossbar -------------------------------------------------------------------------------------- class LiteEthIPV4MasterPort: def __init__(self, dw): @@ -39,7 +38,7 @@ class LiteEthIPV4Crossbar(LiteEthCrossbar): self.users[protocol] = port return port -# ip checksum +# IP Checksum -------------------------------------------------------------------------------------- @ResetInserter() @CEInserter() @@ -81,7 +80,7 @@ class LiteEthIPV4Checksum(Module): self.done.eq(counter == n_cycles) ] -# ip tx +# IP TX -------------------------------------------------------------------------------------------- class LiteEthIPV4Packetizer(Packetizer): def __init__(self, dw=8): @@ -175,7 +174,7 @@ class LiteEthIPTX(Module): ) ) -# ip rx +# IP RX -------------------------------------------------------------------------------------------- class LiteEthIPV4Depacketizer(Depacketizer): def __init__(self, dw=8): @@ -252,7 +251,7 @@ class LiteEthIPRX(Module): ) ) -# ip +# IP ----------------------------------------------------------------------------------------------- class LiteEthIP(Module): def __init__(self, mac, mac_address, ip_address, arp_table, dw=8): diff --git a/liteeth/core/udp.py b/liteeth/core/udp.py index a33eee8..869a63a 100644 --- a/liteeth/core/udp.py +++ b/liteeth/core/udp.py @@ -1,4 +1,4 @@ -# This file is Copyright (c) 2015-2017 Florent Kermarrec +# This file is Copyright (c) 2015-2020 Florent Kermarrec # License: BSD from liteeth.common import * @@ -7,8 +7,7 @@ from liteeth.crossbar import LiteEthCrossbar from litex.soc.interconnect import stream from litex.soc.interconnect.packet import Depacketizer, Packetizer - -# udp crossbar +# UDP Crossbar ------------------------------------------------------------------------------------- class LiteEthUDPMasterPort: def __init__(self, dw): @@ -77,7 +76,7 @@ class LiteEthUDPCrossbar(LiteEthCrossbar): return user_port -# udp tx +# UDP TX ------------------------------------------------------------------------------------------- class LiteEthUDPPacketizer(Packetizer): def __init__(self, dw=8): @@ -124,7 +123,7 @@ class LiteEthUDPTX(Module): ) ) -# udp rx +# UDP RX ------------------------------------------------------------------------------------------- class LiteEthUDPDepacketizer(Depacketizer): def __init__(self, dw=8): @@ -190,7 +189,7 @@ class LiteEthUDPRX(Module): ) ) -# udp +# UDP ---------------------------------------------------------------------------------------------- class LiteEthUDP(Module): def __init__(self, ip, ip_address, dw=8):