summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2012-05-24 05:12:50 +0200
committerDavid S. Miller <davem@davemloft.net>2012-05-24 22:10:05 +0200
commit446969084d33a4064a39d280806da642c54ba4ac (patch)
tree0887795d96007b228733c9499bda1731d64e48fe /include
parentsparc: Increase portability of strncpy_from_user() implementation. (diff)
downloadlinux-446969084d33a4064a39d280806da642c54ba4ac.tar.xz
linux-446969084d33a4064a39d280806da642c54ba4ac.zip
kernel: Move REPEAT_BYTE definition into linux/kernel.h
And make sure that everything using it explicitly includes that header file. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/linux/kernel.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index 645231c373c8..fbe9bfacb8db 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -38,6 +38,8 @@
#define STACK_MAGIC 0xdeadbeef
+#define REPEAT_BYTE(x) ((~0ul / 0xff) * (x))
+
#define ALIGN(x, a) __ALIGN_KERNEL((x), (a))
#define __ALIGN_MASK(x, mask) __ALIGN_KERNEL_MASK((x), (mask))
#define PTR_ALIGN(p, a) ((typeof(p))ALIGN((unsigned long)(p), (a)))