]> git.baikalelectronics.ru Git - kernel.git/commit
ppp: Fix false xmit recursion detect with two ppp devices
authorGao Feng <gfree.wind@vip.163.com>
Mon, 17 Jul 2017 10:34:42 +0000 (18:34 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 18 Jul 2017 18:20:33 +0000 (11:20 -0700)
commit2469076f4d33edee7c4db08613a3038ed8503e3c
tree3bda78ff436360497a70f52a51668355b0693138
parent961fd44f431453c19553e270a8d0f422dd533b31
ppp: Fix false xmit recursion detect with two ppp devices

The global percpu variable ppp_xmit_recursion is used to detect the ppp
xmit recursion to avoid the deadlock, which is caused by one CPU tries to
lock the xmit lock twice. But it would report false recursion when one CPU
wants to send the skb from two different PPP devices, like one L2TP on the
PPPoE. It is a normal case actually.

Now use one percpu member of struct ppp instead of the gloable variable to
detect the xmit recursion of one ppp device.

Fixes: e7ca382c7e2e ("ppp: avoid dealock on recursive xmit")
Signed-off-by: Gao Feng <gfree.wind@vip.163.com>
Signed-off-by: Liu Jianying <jianying.liu@ikuai8.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ppp/ppp_generic.c