aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kernel.h
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2009-12-14 21:00:19 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-12-15 11:53:26 -0500
commit0b2749aa6ca40ff3fe12ebb3fdf010ebad2e9085 (patch)
treec4c848da19ee1e3f1bd4f8733af7676b5b52984c /include/linux/kernel.h
parent196a15b4ee99f627fbc2c07e58e14aab2065fa80 (diff)
kernel.h: remove initialization of bool in printk_once
Don't initialize __print_once. Invert the test to reduce initialized data. defconfig before: $size vmlinux text data bss dec hex filename 6976022 679572 1359668 9015262 898fde vmlinux defconfig after: $size vmlinux text data bss dec hex filename 6976006 679508 1359700 9015214 898fae vmlinux Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/kernel.h')
-rw-r--r--include/linux/kernel.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index a93cdd031aee..910db75b1a72 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -251,10 +251,10 @@ extern int printk_delay_msec;
251 * Print a one-time message (analogous to WARN_ONCE() et al): 251 * Print a one-time message (analogous to WARN_ONCE() et al):
252 */ 252 */
253#define printk_once(x...) ({ \ 253#define printk_once(x...) ({ \
254 static bool __print_once = true; \ 254 static bool __print_once; \
255 \ 255 \
256 if (__print_once) { \ 256 if (!__print_once) { \
257 __print_once = false; \ 257 __print_once = true; \
258 printk(x); \ 258 printk(x); \
259 } \ 259 } \
260}) 260})