summaryrefslogtreecommitdiffstats
path: root/kernel/rcutorture.c
diff options
context:
space:
mode:
authorAhmed S. Darwish <darwish.07@gmail.com>2007-05-08 09:33:14 +0200
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-08 20:15:17 +0200
commit788e770eb2d17212eafaeedde0be56e3444c6b9a (patch)
tree0833022390feec63302918b454a8ac97c9786e45 /kernel/rcutorture.c
parentsched: align rq to cacheline boundary (diff)
downloadlinux-788e770eb2d17212eafaeedde0be56e3444c6b9a.tar.xz
linux-788e770eb2d17212eafaeedde0be56e3444c6b9a.zip
rcutorture: Use ARRAY_SIZE macro when appropriate
Use ARRAY_SIZE macro already defined in kernel.h Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com> Cc: "Paul E. McKenney" <paulmck@us.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to '')
-rw-r--r--kernel/rcutorture.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/rcutorture.c b/kernel/rcutorture.c
index 75ca2a740471..7d20d764b847 100644
--- a/kernel/rcutorture.c
+++ b/kernel/rcutorture.c
@@ -899,7 +899,7 @@ rcu_torture_init(void)
/* Set up the freelist. */
INIT_LIST_HEAD(&rcu_torture_freelist);
- for (i = 0; i < sizeof(rcu_tortures) / sizeof(rcu_tortures[0]); i++) {
+ for (i = 0; i < ARRAY_SIZE(rcu_tortures); i++) {
rcu_tortures[i].rtort_mbtest = 0;
list_add_tail(&rcu_tortures[i].rtort_free,
&rcu_torture_freelist);