summaryrefslogtreecommitdiffstats
path: root/net/can/proc.c
diff options
context:
space:
mode:
authorAlexander Aring <aar@pengutronix.de>2016-05-23 15:13:00 +0200
committerMarc Kleine-Budde <mkl@pengutronix.de>2016-06-17 15:39:41 +0200
commita20fadf85312f7e999c7279af3e038e4f3539fbf (patch)
treec5cfc361049f3cdd460e6c99353bcc206593c726 /net/can/proc.c
parent3636876a5680f2816a99807cd997b142ed24fcdb (diff)
downloadop-kernel-dev-a20fadf85312f7e999c7279af3e038e4f3539fbf.zip
op-kernel-dev-a20fadf85312f7e999c7279af3e038e4f3539fbf.tar.gz
can: build proc support only if CONFIG_PROC_FS is activated
When building can subsystem with CONFIG_PROC_FS=n I detected some unused variables warning by using proc functions. In CAN the proc handling is nicely placed in one object file. This patch adds simple add a dependency on CONFIG_PROC_FS for CAN's proc.o file and corresponding static inline no-op functions. Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Oliver Hartkopp <socketcan@hartkopp.net> [mkl: provide static inline noops instead of using #ifdefs] Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'net/can/proc.c')
-rw-r--r--net/can/proc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/can/proc.c b/net/can/proc.c
index 1a19b98..85ef7bb 100644
--- a/net/can/proc.c
+++ b/net/can/proc.c
@@ -517,8 +517,7 @@ void can_init_proc(void)
can_dir = proc_mkdir("can", init_net.proc_net);
if (!can_dir) {
- printk(KERN_INFO "can: failed to create /proc/net/can . "
- "CONFIG_PROC_FS missing?\n");
+ pr_info("can: failed to create /proc/net/can.\n");
return;
}
OpenPOWER on IntegriCloud