[PATCH v1 1/1] arm64: remove unnecessary ifdefs around is_compat_task()
Arnd Bergmann
arnd at arndb.de
Fri Jan 5 02:43:42 PST 2024
On Fri, Jan 5, 2024, at 05:15, Leonardo Bras wrote:
> Currently some parts of the codebase will test for CONFIG_COMPAT before
> testing is_compat_task().
>
> is_compat_task() is a inlined function only present on CONFIG_COMPAT.
> On the other hand, for !CONFIG_COMPAT, we have in linux/compat.h:
>
> #define is_compat_task() (0)
>
> Since we have this define available in every usage of is_compat_task() for
> !CONFIG_COMPAT, it's unnecessary to keep the ifdefs, since the compiler is
> smart enough to optimize-out those snippets on CONFIG_COMPAT=n
>
> Signed-off-by: Leonardo Bras <leobras at redhat.com>
Reviewed-by: Arnd Bergmann <arnd at arndb.de>
More information about the linux-arm-kernel
mailing list