提交 3b5bcede 编写于 作者: M Matheos Worku 提交者: David S. Miller

[NIU]: Fix BMAC alternate MAC address indexing.

BMAC port alternate MAC address index needs to start at 1. Index 0 is
used for the main MAC address.
Signed-off-by: NMatheos Worku <matheos.worku@sun.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 31729363
......@@ -5147,7 +5147,12 @@ static void niu_set_rx_mode(struct net_device *dev)
index++;
}
} else {
for (i = 0; i < niu_num_alt_addr(np); i++) {
int alt_start;
if (np->flags & NIU_FLAGS_XMAC)
alt_start = 0;
else
alt_start = 1;
for (i = alt_start; i < niu_num_alt_addr(np); i++) {
err = niu_enable_alt_mac(np, i, 0);
if (err)
printk(KERN_WARNING PFX "%s: Error %d "
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册