Commit 1256f739 authored by Hannes Eder's avatar Hannes Eder Committed by David S. Miller

drivers/net/at1700.c: fix sparse warning: symbol shadows an earlier one

Impact: Move variable declaration to a more inner scope.

Fix this sparse warning:
  drivers/net/at1700.c:846:21: warning: symbol 'i' shadows an earlier one
  drivers/net/at1700.c:831:13: originally declared here
Signed-off-by: default avatarHannes Eder <hannes@hanneseder.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1c10c49d
...@@ -828,7 +828,6 @@ set_rx_mode(struct net_device *dev) ...@@ -828,7 +828,6 @@ set_rx_mode(struct net_device *dev)
struct net_local *lp = netdev_priv(dev); struct net_local *lp = netdev_priv(dev);
unsigned char mc_filter[8]; /* Multicast hash filter */ unsigned char mc_filter[8]; /* Multicast hash filter */
unsigned long flags; unsigned long flags;
int i;
if (dev->flags & IFF_PROMISC) { if (dev->flags & IFF_PROMISC) {
memset(mc_filter, 0xff, sizeof(mc_filter)); memset(mc_filter, 0xff, sizeof(mc_filter));
...@@ -857,6 +856,7 @@ set_rx_mode(struct net_device *dev) ...@@ -857,6 +856,7 @@ set_rx_mode(struct net_device *dev)
spin_lock_irqsave (&lp->lock, flags); spin_lock_irqsave (&lp->lock, flags);
if (memcmp(mc_filter, lp->mc_filter, sizeof(mc_filter))) { if (memcmp(mc_filter, lp->mc_filter, sizeof(mc_filter))) {
int i;
int saved_bank = inw(ioaddr + CONFIG_0); int saved_bank = inw(ioaddr + CONFIG_0);
/* Switch to bank 1 and set the multicast table. */ /* Switch to bank 1 and set the multicast table. */
outw((saved_bank & ~0x0C00) | 0x0480, ioaddr + CONFIG_0); outw((saved_bank & ~0x0C00) | 0x0480, ioaddr + CONFIG_0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment