From 62d5c5531334c25918dad7f2b303eefe33da4f5a Mon Sep 17 00:00:00 2001 From: Don Brady Date: Thu, 15 Feb 2018 10:53:04 -0700 Subject: Address objtool check failures in lua module The use of void __attribute__((noreturn)) in kernel builds was causing lots of warnings if CONFIG_STACK_VALIDATION is active. For now we just remove this attribute to achieve clean builds for the Lua module. There was no significant increase in the time to run the full channel_program ZTS tests. Reviewed-by: Brian Behlendorf Reviewed-by: George Melikov Signed-off-by: Don Brady Closes #7173 --- module/lua/llimits.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'module/lua') diff --git a/module/lua/llimits.h b/module/lua/llimits.h index 7d9e13797..eee8f0c2d 100644 --- a/module/lua/llimits.h +++ b/module/lua/llimits.h @@ -97,8 +97,10 @@ typedef LUAI_UACNUMBER l_uacNumber; /* ** non-return type +** +** Supress noreturn attribute in kernel builds to avoid objtool check warnings */ -#if defined(__GNUC__) +#if defined(__GNUC__) && !defined(_KERNEL) #define l_noret void __attribute__((noreturn)) #elif defined(_MSC_VER) #define l_noret void __declspec(noreturn) -- cgit v1.2.3