]> git.baikalelectronics.ru Git - kernel.git/commit
l2tp: remove ->recv_payload_hook
authorGuillaume Nault <g.nault@alphalink.fr>
Wed, 25 Jul 2018 12:53:33 +0000 (14:53 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 Jul 2018 21:06:34 +0000 (14:06 -0700)
commited2c10877336cae84096d051a965fedf3556b6c2
tree8118769260d6bd3c5d27472c4cd4ff4ae3e579b9
parent108e487d1a631c8253af65ec10b72c5f7a30b833
l2tp: remove ->recv_payload_hook

The tunnel reception hook is only used by l2tp_ppp for skipping PPP
framing bytes. This is a session specific operation, but once a PPP
session sets ->recv_payload_hook on its tunnel, all frames received by
the tunnel will enter pppol2tp_recv_payload_hook(), including those
targeted at Ethernet sessions (an L2TPv3 tunnel can multiplex PPP and
Ethernet sessions).

So this mechanism is wrong, and uselessly complex. Let's just move this
functionality to the pppol2tp rx handler and drop ->recv_payload_hook.

Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/l2tp/l2tp_core.c
net/l2tp/l2tp_core.h
net/l2tp/l2tp_ip.c
net/l2tp/l2tp_ip6.c
net/l2tp/l2tp_ppp.c