summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@linux-foundation.org>2007-03-09 07:43:49 +0300
committerDavid S. Miller <davem@sunset.davemloft.net>2007-04-26 09:24:10 +0400
commit1ac58ee37f439044eb09381f33c97ce0e7f2643b (patch)
tree2482c575c6cb1afffe0bb13480e74a1bcd6f0deb
parente71a4783aae059931f63b2d4e7013e36529badef (diff)
downloadlinux-1ac58ee37f439044eb09381f33c97ce0e7f2643b.tar.xz
[WIRELESS]: use ARRAY_SIZE()
Use ARRAY_SIZE() macro now. Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/core/wireless.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/net/core/wireless.c b/net/core/wireless.c
index 8f7f3abdb224..21c091dd39ee 100644
--- a/net/core/wireless.c
+++ b/net/core/wireless.c
@@ -349,8 +349,7 @@ static const struct iw_ioctl_description standard_ioctl[] = {
.max_tokens = sizeof(struct iw_pmksa),
},
};
-static const unsigned standard_ioctl_num = (sizeof(standard_ioctl) /
- sizeof(struct iw_ioctl_description));
+static const unsigned standard_ioctl_num = ARRAY_SIZE(standard_ioctl);
/*
* Meta-data about all the additional standard Wireless Extension events
@@ -400,8 +399,7 @@ static const struct iw_ioctl_description standard_event[] = {
.max_tokens = sizeof(struct iw_pmkid_cand),
},
};
-static const unsigned standard_event_num = (sizeof(standard_event) /
- sizeof(struct iw_ioctl_description));
+static const unsigned standard_event_num = ARRAY_SIZE(standard_event);
/* Size (in bytes) of the various private data types */
static const char iw_priv_type_size[] = {