bcm57xx: correct the MAC status bit positions and name the underrun bit
CFG_CHANGED and SYNC_CHANGED were defined one bit low (0x4 and 0x8 instead of 0x8 and 0x10), so MACSTAT_STICKY never cleared SYNC_CHANGED and the driver's picture of which attention bits are pending was never quite the chip's. The rest of the table is filled in while here. TXSTAT_OFLOW was one of those additions and carried the wrong name: 0x08000000 is the send engine underrunning, the receive overrun is 0x04000000, which the table already calls RXSTAT_OFLOW. Nothing observed changes from this - the driver only ever tests LINK_CHANGED, which both versions mask - but a register table that disagrees with the reference is a trap for the next reader. Assisted-by: ZCode:deepseek-flash
This commit is contained in:
1 parent
a574e8f1a6
commit
fcdaf45caf
1 file changed
+8
-2
@@ -107,10 +107,16 @@ MAC_MODE_TXDMA_EN = 0x00200000
|
||||
MAC_MODE_RXDMA_EN = 0x00400000
|
||||
MAC_MODE_FRMHDR_DMA_EN = 0x00800000
|
||||
|
||||
MACSTAT_CFG_CHANGED = 0x00000004
|
||||
MACSTAT_SYNC_CHANGED = 0x00000008
|
||||
MACSTAT_RX_CFG = 0x00000004
|
||||
MACSTAT_CFG_CHANGED = 0x00000008
|
||||
MACSTAT_SYNC_CHANGED = 0x00000010
|
||||
MACSTAT_LINK_CHANGED = 0x00001000
|
||||
MACSTAT_MI_COMPLETE = 0x00400000
|
||||
MACSTAT_MI_INTERRUPT = 0x00800000
|
||||
MACSTAT_AUTOPOLL_ERROR = 0x01000000
|
||||
MACSTAT_ODI_ERROR = 0x02000000
|
||||
MACSTAT_RXSTAT_OFLOW = 0x04000000 ; receive overrun
|
||||
MACSTAT_TXSTAT_UNDERRUN = 0x08000000 ; send underrun; 0x04000000 is the RX one
|
||||
MACSTAT_STICKY = MACSTAT_LINK_CHANGED or MACSTAT_SYNC_CHANGED \
|
||||
or MACSTAT_CFG_CHANGED or MACSTAT_MI_COMPLETE
|
||||
EVTENB_LINK_CHANGED = 0x00001000
|
||||
|
||||
Reference in new issue
Block a user