diff options
author | James Chapman <jchapman@katalix.com> | 2024-07-29 16:38:03 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2024-07-31 09:25:12 +0100 |
commit | eeb11209e000797d555aefd642e24ed6f4e70140 (patch) | |
tree | 802bed51e77f675dbd606c17bc98149224da9040 | |
parent | ed8ebee6def7b7b760bd4fd90c03b9e86622701c (diff) | |
download | lwn-eeb11209e000797d555aefd642e24ed6f4e70140.tar.gz lwn-eeb11209e000797d555aefd642e24ed6f4e70140.zip |
l2tp: don't use tunnel socket sk_user_data in ppp procfs output
l2tp's ppp procfs output can be used to show internal state of
pppol2tp. It includes a 'user-data-ok' field, which is derived from
the tunnel socket's sk_user_data being non-NULL. Use tunnel->sock
being non-NULL to indicate this instead.
Signed-off-by: James Chapman <jchapman@katalix.com>
Signed-off-by: Tom Parkin <tparkin@katalix.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | net/l2tp/l2tp_ppp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/l2tp/l2tp_ppp.c b/net/l2tp/l2tp_ppp.c index 3596290047b2..0844b86cd0a6 100644 --- a/net/l2tp/l2tp_ppp.c +++ b/net/l2tp/l2tp_ppp.c @@ -1513,7 +1513,7 @@ static void pppol2tp_seq_tunnel_show(struct seq_file *m, void *v) seq_printf(m, "\nTUNNEL '%s', %c %d\n", tunnel->name, - (tunnel == tunnel->sock->sk_user_data) ? 'Y' : 'N', + tunnel->sock ? 'Y' : 'N', refcount_read(&tunnel->ref_count) - 1); seq_printf(m, " %08x %ld/%ld/%ld %ld/%ld/%ld\n", 0, |