summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRandy Dunlap <rdunlap@infradead.org>2018-07-06 23:49:19 -0400
committerJens Axboe <axboe@kernel.dk>2018-07-09 11:07:55 -0400
commit3993e501bf853cce85c5114a704b86b8f486790c (patch)
treed3914fd1a125af7782b508c922e035904e882231
parentca4b2a011948fae4e4d31490107db4926385a983 (diff)
block/DAC960.c: fix defined but not used build warnings
Fix build warnings in DAC960.c when CONFIG_PROC_FS is not enabled by marking the unused functions as __maybe_unused. ../drivers/block/DAC960.c:6429:12: warning: 'dac960_proc_show' defined but not used [-Wunused-function] ../drivers/block/DAC960.c:6449:12: warning: 'dac960_initial_status_proc_show' defined but not used [-Wunused-function] ../drivers/block/DAC960.c:6456:12: warning: 'dac960_current_status_proc_show' defined but not used [-Wunused-function] Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Cc: Jens Axboe <axboe@kernel.dk> Cc: linux-block@vger.kernel.org Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r--drivers/block/DAC960.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c
index f6518067aa7d..f99e5c883368 100644
--- a/drivers/block/DAC960.c
+++ b/drivers/block/DAC960.c
@@ -21,6 +21,7 @@
21#define DAC960_DriverDate "21 Aug 2007" 21#define DAC960_DriverDate "21 Aug 2007"
22 22
23 23
24#include <linux/compiler.h>
24#include <linux/module.h> 25#include <linux/module.h>
25#include <linux/types.h> 26#include <linux/types.h>
26#include <linux/miscdevice.h> 27#include <linux/miscdevice.h>
@@ -6426,7 +6427,7 @@ static bool DAC960_V2_ExecuteUserCommand(DAC960_Controller_T *Controller,
6426 return true; 6427 return true;
6427} 6428}
6428 6429
6429static int dac960_proc_show(struct seq_file *m, void *v) 6430static int __maybe_unused dac960_proc_show(struct seq_file *m, void *v)
6430{ 6431{
6431 unsigned char *StatusMessage = "OK\n"; 6432 unsigned char *StatusMessage = "OK\n";
6432 int ControllerNumber; 6433 int ControllerNumber;
@@ -6446,14 +6447,16 @@ static int dac960_proc_show(struct seq_file *m, void *v)
6446 return 0; 6447 return 0;
6447} 6448}
6448 6449
6449static int dac960_initial_status_proc_show(struct seq_file *m, void *v) 6450static int __maybe_unused dac960_initial_status_proc_show(struct seq_file *m,
6451 void *v)
6450{ 6452{
6451 DAC960_Controller_T *Controller = (DAC960_Controller_T *)m->private; 6453 DAC960_Controller_T *Controller = (DAC960_Controller_T *)m->private;
6452 seq_printf(m, "%.*s", Controller->InitialStatusLength, Controller->CombinedStatusBuffer); 6454 seq_printf(m, "%.*s", Controller->InitialStatusLength, Controller->CombinedStatusBuffer);
6453 return 0; 6455 return 0;
6454} 6456}
6455 6457
6456static int dac960_current_status_proc_show(struct seq_file *m, void *v) 6458static int __maybe_unused dac960_current_status_proc_show(struct seq_file *m,
6459 void *v)
6457{ 6460{
6458 DAC960_Controller_T *Controller = (DAC960_Controller_T *) m->private; 6461 DAC960_Controller_T *Controller = (DAC960_Controller_T *) m->private;
6459 unsigned char *StatusMessage = 6462 unsigned char *StatusMessage =