Loading drivers/net/apne.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -246,7 +246,7 @@ static int __init apne_probe1(struct net_device *dev, int ioaddr) {0x00, NE_EN0_RSARHI}, {0x00, NE_EN0_RSARHI}, {E8390_RREAD+E8390_START, NE_CMD}, {E8390_RREAD+E8390_START, NE_CMD}, }; }; for (i = 0; i < sizeof(program_seq)/sizeof(program_seq[0]); i++) { for (i = 0; i < ARRAY_SIZE(program_seq); i++) { outb(program_seq[i].value, ioaddr + program_seq[i].offset); outb(program_seq[i].value, ioaddr + program_seq[i].offset); } } Loading drivers/net/arm/am79c961a.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -414,7 +414,7 @@ static void am79c961_setmulticastlist (struct net_device *dev) /* /* * Update the multicast hash table * Update the multicast hash table */ */ for (i = 0; i < sizeof(multi_hash) / sizeof(multi_hash[0]); i++) for (i = 0; i < ARRAY_SIZE(multi_hash); i++) write_rreg(dev->base_addr, i + LADRL, multi_hash[i]); write_rreg(dev->base_addr, i + LADRL, multi_hash[i]); /* /* Loading drivers/net/atarilance.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -263,7 +263,7 @@ struct lance_addr { (highest byte stripped) */ (highest byte stripped) */ }; }; #define N_LANCE_ADDR (sizeof(lance_addr_list)/sizeof(*lance_addr_list)) #define N_LANCE_ADDR ARRAY_SIZE(lance_addr_list) /* Definitions for the Lance */ /* Definitions for the Lance */ Loading drivers/net/atl1/atl1_hw.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -603,7 +603,7 @@ static struct atl1_spi_flash_dev flash_table[] = { static void atl1_init_flash_opcode(struct atl1_hw *hw) static void atl1_init_flash_opcode(struct atl1_hw *hw) { { if (hw->flash_vendor >= sizeof(flash_table) / sizeof(flash_table[0])) if (hw->flash_vendor >= ARRAY_SIZE(flash_table)) hw->flash_vendor = 0; /* ATMEL */ hw->flash_vendor = 0; /* ATMEL */ /* Init OP table */ /* Init OP table */ Loading drivers/net/bnx2.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -3492,7 +3492,7 @@ bnx2_init_nvram(struct bnx2 *bp) /* Determine the selected interface. */ /* Determine the selected interface. */ val = REG_RD(bp, BNX2_NVM_CFG1); val = REG_RD(bp, BNX2_NVM_CFG1); entry_count = sizeof(flash_table) / sizeof(struct flash_spec); entry_count = ARRAY_SIZE(flash_table); if (val & 0x40000000) { if (val & 0x40000000) { Loading Loading
drivers/net/apne.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -246,7 +246,7 @@ static int __init apne_probe1(struct net_device *dev, int ioaddr) {0x00, NE_EN0_RSARHI}, {0x00, NE_EN0_RSARHI}, {E8390_RREAD+E8390_START, NE_CMD}, {E8390_RREAD+E8390_START, NE_CMD}, }; }; for (i = 0; i < sizeof(program_seq)/sizeof(program_seq[0]); i++) { for (i = 0; i < ARRAY_SIZE(program_seq); i++) { outb(program_seq[i].value, ioaddr + program_seq[i].offset); outb(program_seq[i].value, ioaddr + program_seq[i].offset); } } Loading
drivers/net/arm/am79c961a.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -414,7 +414,7 @@ static void am79c961_setmulticastlist (struct net_device *dev) /* /* * Update the multicast hash table * Update the multicast hash table */ */ for (i = 0; i < sizeof(multi_hash) / sizeof(multi_hash[0]); i++) for (i = 0; i < ARRAY_SIZE(multi_hash); i++) write_rreg(dev->base_addr, i + LADRL, multi_hash[i]); write_rreg(dev->base_addr, i + LADRL, multi_hash[i]); /* /* Loading
drivers/net/atarilance.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -263,7 +263,7 @@ struct lance_addr { (highest byte stripped) */ (highest byte stripped) */ }; }; #define N_LANCE_ADDR (sizeof(lance_addr_list)/sizeof(*lance_addr_list)) #define N_LANCE_ADDR ARRAY_SIZE(lance_addr_list) /* Definitions for the Lance */ /* Definitions for the Lance */ Loading
drivers/net/atl1/atl1_hw.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -603,7 +603,7 @@ static struct atl1_spi_flash_dev flash_table[] = { static void atl1_init_flash_opcode(struct atl1_hw *hw) static void atl1_init_flash_opcode(struct atl1_hw *hw) { { if (hw->flash_vendor >= sizeof(flash_table) / sizeof(flash_table[0])) if (hw->flash_vendor >= ARRAY_SIZE(flash_table)) hw->flash_vendor = 0; /* ATMEL */ hw->flash_vendor = 0; /* ATMEL */ /* Init OP table */ /* Init OP table */ Loading
drivers/net/bnx2.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -3492,7 +3492,7 @@ bnx2_init_nvram(struct bnx2 *bp) /* Determine the selected interface. */ /* Determine the selected interface. */ val = REG_RD(bp, BNX2_NVM_CFG1); val = REG_RD(bp, BNX2_NVM_CFG1); entry_count = sizeof(flash_table) / sizeof(struct flash_spec); entry_count = ARRAY_SIZE(flash_table); if (val & 0x40000000) { if (val & 0x40000000) { Loading