net: niu: fix missing register write in niu_txc_set_imask
Subsystems (2)
PATCH 1/1 net: niu: fix missing register write in niu_txc_set_imask
While reviewing W=1 build warnings in this driver, I noticed niu_txc_set_imask() reads TXC_INT_MASK, computes the new mask value, but never writes it back to the register, making the function a no-op regardless of the imask parameter passed in.
Add the missing nw64(TXC_INT_MASK, val) call so the function actually programs the mask as its name and signature imply.
I don't have access to this hardware (Sun Neptune NIU), so this was found through code review, not tested on real hardware.
Signed-off-by Ronan Marchal <[email protected]>
--- drivers/net/ethernet/sun/niu.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/ethernet/sun/niu.c +1 -0
@@ -4650,6 +4650,7 @@ static void niu_txc_set_imask(struct niu *np, u64 imask) val =nr64 (TXC_INT_MASK ); val &= ~TXC_INT_MASK_VAL (np->port); val |= (imask <<TXC_INT_MASK_VAL_SHIFT (np->port)); +nw64 (TXC_INT_MASK , val);niu_unlock_parent (np, flags); }
Signature · 1 line
2.55.0