core/arp: Fix missing set of response.mac_address in UPDATE_TABLE and reset update_count at the end of CLEAR state.
Fixes #147.
This commit is contained in:
parent
e784bf8fd3
commit
9d13f612c1
|
@ -217,6 +217,7 @@ class LiteEthARPCache(LiteXModule):
|
||||||
mem_wr_port_valid.eq(0),
|
mem_wr_port_valid.eq(0),
|
||||||
NextValue(update_count, update_count + 1),
|
NextValue(update_count, update_count + 1),
|
||||||
If(update_count == (entries - 1),
|
If(update_count == (entries - 1),
|
||||||
|
NextValue(update_count, 0),
|
||||||
NextState("IDLE")
|
NextState("IDLE")
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -320,6 +321,7 @@ class LiteEthARPTable(LiteXModule):
|
||||||
cache.update.mac_address.eq(sink.mac_address),
|
cache.update.mac_address.eq(sink.mac_address),
|
||||||
If(cache.update.ready,
|
If(cache.update.ready,
|
||||||
NextValue(request_pending, 0),
|
NextValue(request_pending, 0),
|
||||||
|
NextValue(response.mac_address, sink.mac_address),
|
||||||
NextState("PRESENT_RESPONSE")
|
NextState("PRESENT_RESPONSE")
|
||||||
)
|
)
|
||||||
).Else(
|
).Else(
|
||||||
|
|
Loading…
Reference in New Issue