[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251014112640.261770-1-dongml2@chinatelecom.cn>
Date: Tue, 14 Oct 2025 19:26:36 +0800
From: Menglong Dong <menglong8.dong@...il.com>
To: ast@...nel.org,
paulmck@...nel.org
Cc: daniel@...earbox.net,
andrii@...nel.org,
martin.lau@...ux.dev,
eddyz87@...il.com,
song@...nel.org,
yonghong.song@...ux.dev,
john.fastabend@...il.com,
kpsingh@...nel.org,
sdf@...ichev.me,
haoluo@...gle.com,
jolsa@...nel.org,
jakub@...udflare.com,
davem@...emloft.net,
edumazet@...gle.com,
kuba@...nel.org,
pabeni@...hat.com,
horms@...nel.org,
jiang.biao@...ux.dev,
bpf@...r.kernel.org,
linux-kernel@...r.kernel.org,
netdev@...r.kernel.org
Subject: [PATCH bpf-next 0/4] bpf: add and use migrate_enable_rcu
For now, we can use rcu_read_lock_dont_migrate() for the case that call
both rcu_read_lock() and migrate_disable(). However, sometimes they can be
called separately.
Therefore, we factor out migrate_enable_rcu and migrate_disable_rcu from
rcu_read_lock_dont_migrate and rcu_read_unlock_migrate.
And we introduce the function bpf_prog_run_pin_on_cpu_rcu(), which is
similar to bpf_prog_run_pin_on_cpu() but use
migrate_disable_rcu/migrate_enable_rcu instead.
The function bpf_prog_run_pin_on_cpu_rcu() is used in following functions:
sk_psock_msg_verdict
sk_psock_tls_strp_read
sk_psock_strp_read
sk_psock_strp_parse
sk_psock_verdict_recv
bpf_prog_run_clear_cb
Menglong Dong (4):
rcu: factor out migrate_enable_rcu and migrate_disable_rcu
bpf: introduce bpf_prog_run_pin_on_cpu_rcu()
bpf: use bpf_prog_run_pin_on_cpu_rcu() in skmsg.c
bpf: use bpf_prog_run_pin_on_cpu_rcu() in bpf_prog_run_clear_cb
include/linux/filter.h | 16 +++++++++++++++-
include/linux/rcupdate.h | 18 +++++++++++++++---
net/core/skmsg.c | 10 +++++-----
3 files changed, 35 insertions(+), 9 deletions(-)
--
2.51.0
Powered by blists - more mailing lists