diff options
author | Paul Mackerras | 2007-05-08 05:37:51 +0200 |
---|---|---|
committer | Paul Mackerras | 2007-05-08 05:37:51 +0200 |
commit | 02bbc0f09c90cefdb2837605c96a66c5ce4ba2e1 (patch) | |
tree | 04ef573cd4de095c500c9fc3477f4278c0b36300 /include/linux/kernel.h | |
parent | [POWERPC] Holly bootwrapper (diff) | |
parent | Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 (diff) | |
download | kernel-qcow2-linux-02bbc0f09c90cefdb2837605c96a66c5ce4ba2e1.tar.gz kernel-qcow2-linux-02bbc0f09c90cefdb2837605c96a66c5ce4ba2e1.tar.xz kernel-qcow2-linux-02bbc0f09c90cefdb2837605c96a66c5ce4ba2e1.zip |
Merge branch 'linux-2.6'
Diffstat (limited to 'include/linux/kernel.h')
-rw-r--r-- | include/linux/kernel.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h index e2f41b051b12..144b615f3a89 100644 --- a/include/linux/kernel.h +++ b/include/linux/kernel.h @@ -35,7 +35,8 @@ extern const char linux_proc_banner[]; #define ALIGN(x,a) __ALIGN_MASK(x,(typeof(x))(a)-1) #define __ALIGN_MASK(x,mask) (((x)+(mask))&~(mask)) -#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0])) +#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) + __must_be_array(arr)) + #define FIELD_SIZEOF(t, f) (sizeof(((t*)0)->f)) #define DIV_ROUND_UP(n,d) (((n) + (d) - 1) / (d)) #define roundup(x, y) ((((x) + ((y) - 1)) / (y)) * (y)) |