Commit cebc04ba authored by Andrew Morton's avatar Andrew Morton Committed by Greg Kroah-Hartman

add CONFIG_ENABLE_MUST_CHECK

Those 1500 warnings can be a bit of a pain.  Add a config option to shut them
up.
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 4a7fb636
...@@ -99,6 +99,11 @@ extern void __chk_io_ptr(void __iomem *); ...@@ -99,6 +99,11 @@ extern void __chk_io_ptr(void __iomem *);
#define __must_check #define __must_check
#endif #endif
#ifndef CONFIG_ENABLE_MUST_CHECK
#undef __must_check
#define __must_check
#endif
/* /*
* Allow us to avoid 'defined but not used' warnings on functions and data, * Allow us to avoid 'defined but not used' warnings on functions and data,
* as well as force them to be emitted to the assembly file. * as well as force them to be emitted to the assembly file.
......
...@@ -8,6 +8,13 @@ config PRINTK_TIME ...@@ -8,6 +8,13 @@ config PRINTK_TIME
operations. This is useful for identifying long delays operations. This is useful for identifying long delays
in kernel startup. in kernel startup.
config ENABLE_MUST_CHECK
bool "Enable __must_check logic"
default y
help
Enable the __must_check logic in the kernel build. Disable this to
suppress the "warning: ignoring return value of 'foo', declared with
attribute warn_unused_result" messages.
config MAGIC_SYSRQ config MAGIC_SYSRQ
bool "Magic SysRq key" bool "Magic SysRq key"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment