summaryrefslogtreecommitdiffstats
path: root/net/l2tp/l2tp_core.h
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2018-08-13 23:43:05 +0200
committerDavid S. Miller <davem@davemloft.net>2018-08-13 20:45:49 -0700
commitc2ebc25674e5123d134e81758828084f1cc58cc3 (patch)
treebf2724e414a7035fb883e9e8f4b165fc2dbe9894 /net/l2tp/l2tp_core.h
parent3d46eee5a5f2f22ca04e2139e8c9a16b81d16073 (diff)
downloadlinux-c2ebc25674e5123d134e81758828084f1cc58cc3.tar.bz2
l2tp: fix unused function warning
Removing one of the callers of pppol2tp_session_get_sock caused a harmless warning in some configurations: net/l2tp/l2tp_ppp.c:142:21: 'pppol2tp_session_get_sock' defined but not used [-Wunused-function] Rather than adding another #ifdef here, using a proper IS_ENABLED() check makes the code more readable and avoids those warnings while letting the compiler figure out for itself which code is needed. This adds one pointer for the unused show() callback in struct l2tp_session, but that seems harmless. Fixes: b0e29063dcb3 ("l2tp: remove pppol2tp_session_ioctl()") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/l2tp/l2tp_core.h')
-rw-r--r--net/l2tp/l2tp_core.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/net/l2tp/l2tp_core.h b/net/l2tp/l2tp_core.h
index 8480a0af973e..9c9afe94d389 100644
--- a/net/l2tp/l2tp_core.h
+++ b/net/l2tp/l2tp_core.h
@@ -118,9 +118,7 @@ struct l2tp_session {
int (*build_header)(struct l2tp_session *session, void *buf);
void (*recv_skb)(struct l2tp_session *session, struct sk_buff *skb, int data_len);
void (*session_close)(struct l2tp_session *session);
-#if IS_ENABLED(CONFIG_L2TP_DEBUGFS)
void (*show)(struct seq_file *m, void *priv);
-#endif
uint8_t priv[0]; /* private data */
};