]> git.baikalelectronics.ru Git - kernel.git/commit
skmsg: Schedule psock work if the cached skb exists on the psock
authorLiu Jian <liujian56@huawei.com>
Wed, 7 Sep 2022 07:13:11 +0000 (15:13 +0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Mon, 26 Sep 2022 15:48:05 +0000 (17:48 +0200)
commit6e47d8239384695f959680a6ae520aa403aa6fd9
treee63d07ff0f00d7820945717090e7d6169a6313ee
parent1e495b52a68079e0638e82b32712287defacfe6a
skmsg: Schedule psock work if the cached skb exists on the psock

In sk_psock_backlog function, for ingress direction skb, if no new data
packet arrives after the skb is cached, the cached skb does not have a
chance to be added to the receive queue of psock. As a result, the cached
skb cannot be received by the upper-layer application. Fix this by reschedule
the psock work to dispose the cached skb in sk_msg_recvmsg function.

Fixes: eaf66302e456 ("bpf, sockmap: convert to generic sk_msg interface")
Signed-off-by: Liu Jian <liujian56@huawei.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20220907071311.60534-1-liujian56@huawei.com
net/core/skmsg.c