瀏覽代碼

tools include: Drop ARRAY_SIZE() definition from linux/hashtable.h

As tools/include/linux/kernel.h has it now, with the goodies present in
the kernel.h counterpart, i.e. checking that the parameter is an array
at build time.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/n/tip-v0b41ivu6z6dyugbq9ffa9ez@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Arnaldo Carvalho de Melo 8 年之前
父節點
當前提交
68289cbd83
共有 1 個文件被更改,包括 0 次插入4 次删除
  1. 0 4
      tools/include/linux/hashtable.h

+ 0 - 4
tools/include/linux/hashtable.h

@@ -13,10 +13,6 @@
 #include <linux/hash.h>
 #include <linux/hash.h>
 #include <linux/log2.h>
 #include <linux/log2.h>
 
 
-#ifndef ARRAY_SIZE
-#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
-#endif
-
 #define DEFINE_HASHTABLE(name, bits)						\
 #define DEFINE_HASHTABLE(name, bits)						\
 	struct hlist_head name[1 << (bits)] =					\
 	struct hlist_head name[1 << (bits)] =					\
 			{ [0 ... ((1 << (bits)) - 1)] = HLIST_HEAD_INIT }
 			{ [0 ... ((1 << (bits)) - 1)] = HLIST_HEAD_INIT }