[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-49e4ba54592435cbd150aea8f5ae6b776fc687f9@git.kernel.org>
Date: Fri, 25 Jan 2013 03:19:02 -0800
From: tip-bot for Sasha Levin <sasha.levin@...cle.com>
To: linux-tip-commits@...r.kernel.org
Cc: acme@...hat.com, linux-kernel@...r.kernel.org, paulus@...ba.org,
mingo@...hat.com, sasha.levin@...cle.com, hpa@...or.com,
mingo@...nel.org, a.p.zijlstra@...llo.nl, tglx@...utronix.de
Subject: [tip:perf/core] perf kmem:
use ARRAY_SIZE instead of reinventing it
Commit-ID: 49e4ba54592435cbd150aea8f5ae6b776fc687f9
Gitweb: http://git.kernel.org/tip/49e4ba54592435cbd150aea8f5ae6b776fc687f9
Author: Sasha Levin <sasha.levin@...cle.com>
AuthorDate: Thu, 20 Dec 2012 14:11:16 -0500
Committer: Arnaldo Carvalho de Melo <acme@...hat.com>
CommitDate: Thu, 24 Jan 2013 16:40:15 -0300
perf kmem: use ARRAY_SIZE instead of reinventing it
Signed-off-by: Sasha Levin <sasha.levin@...cle.com>
Cc: Ingo Molnar <mingo@...hat.com>
Cc: Paul Mackerras <paulus@...ba.org>
Cc: Peter Zijlstra <a.p.zijlstra@...llo.nl>
Link: http://lkml.kernel.org/r/1356030701-16284-8-git-send-email-sasha.levin@oracle.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
---
tools/perf/builtin-kmem.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/tools/perf/builtin-kmem.c b/tools/perf/builtin-kmem.c
index 9fddca7..c746108 100644
--- a/tools/perf/builtin-kmem.c
+++ b/tools/perf/builtin-kmem.c
@@ -609,8 +609,7 @@ static struct sort_dimension *avail_sorts[] = {
&pingpong_sort_dimension,
};
-#define NUM_AVAIL_SORTS \
- (int)(sizeof(avail_sorts) / sizeof(struct sort_dimension *))
+#define NUM_AVAIL_SORTS ((int)ARRAY_SIZE(avail_sorts))
static int sort_dimension__add(const char *tok, struct list_head *list)
{
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists