]> git.baikalelectronics.ru Git - kernel.git/commit
dm crypt: replaced #if defined with IS_ENABLED
authorAhmad Fatoum <a.fatoum@pengutronix.de>
Fri, 22 Jan 2021 08:43:20 +0000 (09:43 +0100)
committerMike Snitzer <snitzer@redhat.com>
Wed, 3 Feb 2021 15:12:31 +0000 (10:12 -0500)
commit2022e88d448372d456d39f8f37b7be156f1c08de
treea92a2e59de2de8e0f6c51d3a107b6f63de96549c
parent1d1f0c34f48788bad6e549d818dfa70b3c9c49ec
dm crypt: replaced #if defined with IS_ENABLED

IS_ENABLED(CONFIG_ENCRYPTED_KEYS) is true whether the option is built-in
or a module, so use it instead of #if defined checking for each
separately.

The other #if was to avoid a static function defined, but unused
warning. As we now always build the callsite when the function
is defined, we can remove that first #if guard.

Suggested-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Acked-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
drivers/md/dm-crypt.c