summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorJim Cromie <jim.cromie@gmail.com>2012-04-10 14:56:22 +0000
committerDavid S. Miller <davem@davemloft.net>2012-04-13 13:15:14 -0400
commit302846e3a692131a99b462078fe232ca2927b9d3 (patch)
treecfee204d344edeab2f038f17392a46dd1f0f82ed /drivers
parent4133099b3e1ffd63476ede836a5a10aa26fa93d0 (diff)
ethernet: replace open-coded ARRAY_SIZE with macro
Signed-off-by: Jim Cromie <jim.cromie@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ethernet/s6gmac.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/s6gmac.c b/drivers/net/ethernet/s6gmac.c
index 1895605abb35..8e9fda0c7aeb 100644
--- a/drivers/net/ethernet/s6gmac.c
+++ b/drivers/net/ethernet/s6gmac.c
@@ -937,7 +937,7 @@ static struct net_device_stats *s6gmac_stats(struct net_device *dev)
do {
unsigned long flags;
spin_lock_irqsave(&pd->lock, flags);
- for (i = 0; i < sizeof(pd->stats) / sizeof(unsigned long); i++)
+ for (i = 0; i < ARRAY_SIZE(pd->stats); i++)
pd->stats[i] =
pd->carry[i] << (S6_GMAC_STAT_SIZE_MIN - 1);
s6gmac_stats_collect(pd, &statinf[0][0]);