aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wavelan_cs.c
diff options
context:
space:
mode:
authorAlejandro Martinez Ruiz <alex@flawedcode.org>2007-10-18 04:16:33 -0400
committerDavid S. Miller <davem@davemloft.net>2008-01-28 18:03:37 -0500
commitc00acf46deb18926931ba264510353cf22b98a79 (patch)
tree7b7105d3505cb13aa0474e0bd89b23d7b9f2b958 /drivers/net/wireless/wavelan_cs.c
parent4c3616cdda0632a3d0e39069765f9ea0e6bd093e (diff)
netdev: ARRAY_SIZE() cleanups
Convert array size calculations to use ARRAY_SIZE(). Signed-off-by: Alejandro Martinez Ruiz <alex@flawedcode.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/wireless/wavelan_cs.c')
-rw-r--r--drivers/net/wireless/wavelan_cs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/wavelan_cs.c b/drivers/net/wireless/wavelan_cs.c
index 577c647824fe..f5b38de4f0df 100644
--- a/drivers/net/wireless/wavelan_cs.c
+++ b/drivers/net/wireless/wavelan_cs.c
@@ -3223,14 +3223,14 @@ wv_mmc_init(struct net_device * dev)
3223 * non-NCR/AT&T/Lucent PCMCIA cards, see wavelan_cs.h for detail on 3223 * non-NCR/AT&T/Lucent PCMCIA cards, see wavelan_cs.h for detail on
3224 * how to configure your card... 3224 * how to configure your card...
3225 */ 3225 */
3226 for(i = 0; i < (sizeof(MAC_ADDRESSES) / sizeof(char) / 3); i++) 3226 for(i = 0; i < ARRAY_SIZE(MAC_ADDRESSES); i++)
3227 if((psa.psa_univ_mac_addr[0] == MAC_ADDRESSES[i][0]) && 3227 if((psa.psa_univ_mac_addr[0] == MAC_ADDRESSES[i][0]) &&
3228 (psa.psa_univ_mac_addr[1] == MAC_ADDRESSES[i][1]) && 3228 (psa.psa_univ_mac_addr[1] == MAC_ADDRESSES[i][1]) &&
3229 (psa.psa_univ_mac_addr[2] == MAC_ADDRESSES[i][2])) 3229 (psa.psa_univ_mac_addr[2] == MAC_ADDRESSES[i][2]))
3230 break; 3230 break;
3231 3231
3232 /* If we have not found it... */ 3232 /* If we have not found it... */
3233 if(i == (sizeof(MAC_ADDRESSES) / sizeof(char) / 3)) 3233 if(i == ARRAY_SIZE(MAC_ADDRESSES))
3234 { 3234 {
3235#ifdef DEBUG_CONFIG_ERRORS 3235#ifdef DEBUG_CONFIG_ERRORS
3236 printk(KERN_WARNING "%s: wv_mmc_init(): Invalid MAC address: %02X:%02X:%02X:...\n", 3236 printk(KERN_WARNING "%s: wv_mmc_init(): Invalid MAC address: %02X:%02X:%02X:...\n",