drivers: ethernet: eth_liteeth: Update driver
Correct width when accessing LITEETH_RX_LENGTH register. Also update register data in device tree to the 32-bit CSR variant. Signed-off-by: Michal Sieron <msieron@internships.antmicro.com>
This commit is contained in:
parent
e088d05159
commit
17a2c6d647
2 changed files with 16 additions and 7 deletions
|
@ -129,7 +129,7 @@ static void eth_rx(const struct device *port)
|
|||
key = irq_lock();
|
||||
|
||||
/* get frame's length */
|
||||
len = litex_read32(LITEETH_RX_LENGTH_ADDR);
|
||||
len = litex_read16(LITEETH_RX_LENGTH_ADDR);
|
||||
|
||||
/* which slot is the frame in */
|
||||
context->rxslot = litex_read8(LITEETH_RX_SLOT_ADDR);
|
||||
|
|
|
@ -117,26 +117,35 @@
|
|||
interrupt-parent = <&intc0>;
|
||||
interrupts = <3 0>;
|
||||
reg = <0xe0009800 0x4
|
||||
0xe0009804 0x8
|
||||
0xe0009804 0x4
|
||||
0xe0009808 0x4
|
||||
0xe000980c 0x4
|
||||
0xe0009810 0x4
|
||||
0xe0009814 0x4
|
||||
0xe0009818 0x4
|
||||
0xe000981c 0x4
|
||||
0xe0009820 0x4
|
||||
0xe0009824 0x4
|
||||
0xe0009828 0x4
|
||||
0xe000982c 0x4
|
||||
0xe0009830 0x4
|
||||
0xe0009834 0x4
|
||||
0xe000983c 0x4
|
||||
0xe0009840 0x8
|
||||
0xe000984c 0x4
|
||||
0xb0000000 0x2000>;
|
||||
local-mac-address = [10 e2 d5 00 00 02];
|
||||
reg-names =
|
||||
"rx_slot",
|
||||
reg-names = "rx_slot",
|
||||
"rx_length",
|
||||
"rx_errors",
|
||||
"rx_ev_status",
|
||||
"rx_ev_pending",
|
||||
"rx_ev_enable",
|
||||
"tx_start",
|
||||
"tx_ready",
|
||||
"tx_level",
|
||||
"tx_slot",
|
||||
"tx_length",
|
||||
"tx_ev_status",
|
||||
"tx_ev_pending",
|
||||
"tx_ev_enable",
|
||||
"buffers";
|
||||
label = "eth0";
|
||||
status = "disabled";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue