From: Qingfang Deng <qingfang.deng@linux.dev>
To: James Chapman <jchapman@katalix.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@kernel.org>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: Qingfang Deng <qingfang.deng@linux.dev>
Subject: [PATCH net-next] l2tp: ppp: remove unused backlog callback
Date: Fri, 30 Oct 2026 15:00:03 +0800 [thread overview]
Message-ID: <20261030070003.2590-1-qingfang.deng@linux.dev> (raw)
PPPoL2TP sessions receive packets through pppol2tp_recv(), which passes
packets directly to PPP or queues them on sk_receive_queue. No receive
path queues packets on the session socket backlog or calls
sk_receive_skb() with that socket, so pppol2tp_backlog_recv() is unused.
Remove the unused callback. L2TP/IP control sockets retain their
separate backlog callbacks. Selftests passed.
Signed-off-by: Qingfang Deng <qingfang.deng@linux.dev>
---
net/l2tp/l2tp_ppp.c | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/net/l2tp/l2tp_ppp.c b/net/l2tp/l2tp_ppp.c
index 4f311d473a64..15e02864bfd5 100644
--- a/net/l2tp/l2tp_ppp.c
+++ b/net/l2tp/l2tp_ppp.c
@@ -454,17 +454,6 @@ static struct proto pppol2tp_sk_proto = {
.obj_size = sizeof(struct pppox_sock),
};
-static int pppol2tp_backlog_recv(struct sock *sk, struct sk_buff *skb)
-{
- int rc;
-
- rc = l2tp_udp_encap_recv(sk, skb);
- if (rc)
- kfree_skb(skb);
-
- return NET_RX_SUCCESS;
-}
-
/* socket() handler. Initialize a new struct sock.
*/
static int pppol2tp_create(struct net *net, struct socket *sock, int kern)
@@ -482,7 +471,6 @@ static int pppol2tp_create(struct net *net, struct socket *sock, int kern)
sock->state = SS_UNCONNECTED;
sock->ops = &pppol2tp_ops;
- sk->sk_backlog_rcv = pppol2tp_backlog_recv;
sk->sk_protocol = PX_PROTO_OL2TP;
sk->sk_family = PF_PPPOX;
sk->sk_state = PPPOX_NONE;
--
2.43.0
next reply other threads:[~2026-10-30 7:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-30 7:00 Qingfang Deng [this message]
2026-10-30 22:36 ` Jakub Kicinski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261030070003.2590-1-qingfang.deng@linux.dev \
--to=qingfang.deng@linux.dev \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=horms@kernel.org \
--cc=jchapman@katalix.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®