static int __init
init_crypto_ccmp_test(void)
{
-#define N(a) (sizeof(a)/sizeof(a[0]))
struct ieee80211com ic;
struct ieee80211vap vap;
int i, pass, total;
pass = 0;
total = 0;
- for (i = 0; i < N(ccmptests); i++)
+ for (i = 0; i < ARRAY_SIZE(ccmptests); i++)
if (tests & (1 << i)) {
total++;
pass += runtest(&vap, &ccmptests[i]);
ieee80211_crypto_vdetach(&vap);
ieee80211_crypto_detach(&ic);
return (pass == total ? 0 : -ENXIO);
-#undef N
}
module_init(init_crypto_ccmp_test);