aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRandy Dunlap <rdunlap@infradead.org>2018-07-06 23:53:09 -0400
committerDarren Hart (VMware) <dvhart@infradead.org>2018-07-21 12:26:45 -0400
commitc2e2a618eb7104e18fdcf739d4d911563812a81c (patch)
tree7799d24a450c9ab7182c7f19d4559f674e9cf496
parent1a32ebb26ba9adc9a3fe59079b79a82f6bbec34e (diff)
platform/x86: toshiba_acpi: Fix defined but not used build warnings
Fix a build warning in toshiba_acpi.c when CONFIG_PROC_FS is not enabled by marking the unused function as __maybe_unused. ../drivers/platform/x86/toshiba_acpi.c:1685:12: warning: 'version_proc_show' defined but not used [-Wunused-function] Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Cc: Azael Avalos <coproscefalo@gmail.com> Cc: platform-driver-x86@vger.kernel.org Cc: Andy Shevchenko <andy@infradead.org> Signed-off-by: Darren Hart (VMware) <dvhart@infradead.org>
-rw-r--r--drivers/platform/x86/toshiba_acpi.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/platform/x86/toshiba_acpi.c b/drivers/platform/x86/toshiba_acpi.c
index e7186b1f3229..e366977bda41 100644
--- a/drivers/platform/x86/toshiba_acpi.c
+++ b/drivers/platform/x86/toshiba_acpi.c
@@ -34,6 +34,7 @@
34#define TOSHIBA_ACPI_VERSION "0.24" 34#define TOSHIBA_ACPI_VERSION "0.24"
35#define PROC_INTERFACE_VERSION 1 35#define PROC_INTERFACE_VERSION 1
36 36
37#include <linux/compiler.h>
37#include <linux/kernel.h> 38#include <linux/kernel.h>
38#include <linux/module.h> 39#include <linux/module.h>
39#include <linux/moduleparam.h> 40#include <linux/moduleparam.h>
@@ -1682,7 +1683,7 @@ static const struct file_operations keys_proc_fops = {
1682 .write = keys_proc_write, 1683 .write = keys_proc_write,
1683}; 1684};
1684 1685
1685static int version_proc_show(struct seq_file *m, void *v) 1686static int __maybe_unused version_proc_show(struct seq_file *m, void *v)
1686{ 1687{
1687 seq_printf(m, "driver: %s\n", TOSHIBA_ACPI_VERSION); 1688 seq_printf(m, "driver: %s\n", TOSHIBA_ACPI_VERSION);
1688 seq_printf(m, "proc_interface: %d\n", PROC_INTERFACE_VERSION); 1689 seq_printf(m, "proc_interface: %d\n", PROC_INTERFACE_VERSION);