random: use IS_ENABLED(CONFIG_NUMA) instead of ifdefs
authorJason A. Donenfeld <Jason@zx2c4.com>
Thu, 30 Dec 2021 14:59:26 +0000 (15:59 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 30 May 2022 07:29:01 +0000 (09:29 +0200)
commit5822fad8d3dc88fb8fc3774ae911afc962290882
treeb9ef0b5c5d59b8868d47a825374d30a12c940764
parent69bb5f0917f973dbaad21d02e4763530627c1dc2
random: use IS_ENABLED(CONFIG_NUMA) instead of ifdefs

commit 7b87324112df2e1f9b395217361626362dcfb9fb upstream.

Rather than an awkward combination of ifdefs and __maybe_unused, we can
ensure more source gets parsed, regardless of the configuration, by
using IS_ENABLED for the CONFIG_NUMA conditional code. This makes things
cleaner and easier to follow.

I've confirmed that on !CONFIG_NUMA, we don't wind up with excess code
by accident; the generated object file is the same.

Reviewed-by: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/char/random.c