Commit 91f382a4 authored by Masahiro Yamada's avatar Masahiro Yamada Committed by Greg Kroah-Hartman

firmware_loader: move CONFIG_FW_LOADER_USER_HELPER switch to Makefile

The whole code of fallback_table.c is surrounded by #ifdef of
CONFIG_FW_LOADER_USER_HELPER.

Move the CONFIG_FW_LOADER_USER_HELPER switch to Makefile so that
it is not compiled at all when this CONFIG option is disabled.

I also removed the confusing comment, "Module or buit-in [sic]".
CONFIG_FW_LOADER_USER_HELPER is a boolean option.
(If it were a module, CONFIG_FW_LOADER_USER_HELPER_MODULE would
be defined instead.)
Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 925f8d4a
# SPDX-License-Identifier: GPL-2.0 # SPDX-License-Identifier: GPL-2.0
# Makefile for the Linux firmware loader # Makefile for the Linux firmware loader
obj-y := fallback_table.o obj-$(CONFIG_FW_LOADER_USER_HELPER) += fallback_table.o
obj-$(CONFIG_FW_LOADER) += firmware_class.o obj-$(CONFIG_FW_LOADER) += firmware_class.o
firmware_class-objs := main.o firmware_class-objs := main.o
firmware_class-$(CONFIG_FW_LOADER_USER_HELPER) += fallback.o firmware_class-$(CONFIG_FW_LOADER_USER_HELPER) += fallback.o
...@@ -16,9 +16,6 @@ ...@@ -16,9 +16,6 @@
* firmware fallback configuration table * firmware fallback configuration table
*/ */
/* Module or buit-in */
#ifdef CONFIG_FW_LOADER_USER_HELPER
static unsigned int zero; static unsigned int zero;
static unsigned int one = 1; static unsigned int one = 1;
...@@ -51,5 +48,3 @@ struct ctl_table firmware_config_table[] = { ...@@ -51,5 +48,3 @@ struct ctl_table firmware_config_table[] = {
{ } { }
}; };
EXPORT_SYMBOL_GPL(firmware_config_table); EXPORT_SYMBOL_GPL(firmware_config_table);
#endif
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