diff options
author | Matheos Worku <matheos.worku@sun.com> | 2008-02-19 00:30:03 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-02-19 00:30:03 -0500 |
commit | 3b5bcedeeb755b6e813537fcf4c32f010b490aef (patch) | |
tree | f1be8719296e52d2cdfce8732d913b31ef51e4f0 /drivers/net | |
parent | 31729363418ea25b01aa9410838c38e36792e44c (diff) |
[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: Matheos Worku <matheos.worku@sun.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/niu.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/niu.c b/drivers/net/niu.c index 2fe14b0c5c67..1f1b815e0813 100644 --- a/drivers/net/niu.c +++ b/drivers/net/niu.c | |||
@@ -5147,7 +5147,12 @@ static void niu_set_rx_mode(struct net_device *dev) | |||
5147 | index++; | 5147 | index++; |
5148 | } | 5148 | } |
5149 | } else { | 5149 | } else { |
5150 | for (i = 0; i < niu_num_alt_addr(np); i++) { | 5150 | int alt_start; |
5151 | if (np->flags & NIU_FLAGS_XMAC) | ||
5152 | alt_start = 0; | ||
5153 | else | ||
5154 | alt_start = 1; | ||
5155 | for (i = alt_start; i < niu_num_alt_addr(np); i++) { | ||
5151 | err = niu_enable_alt_mac(np, i, 0); | 5156 | err = niu_enable_alt_mac(np, i, 0); |
5152 | if (err) | 5157 | if (err) |
5153 | printk(KERN_WARNING PFX "%s: Error %d " | 5158 | printk(KERN_WARNING PFX "%s: Error %d " |