From: Martin KaFai Lau <martin.lau@linux.dev>
To: Alexei Starovoitov <alexei.starovoitov@gmail.com>,
Xu Kuohai <xukuohai@huaweicloud.com>
Cc: Martin KaFai Lau <martin.lau@kernel.org>,
bpf <bpf@vger.kernel.org>,
Network Development <netdev@vger.kernel.org>,
Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
Andrii Nakryiko <andrii@kernel.org>,
Eduard Zingerman <eddyz87@gmail.com>,
Yonghong Song <yonghong.song@linux.dev>,
Kui-Feng Lee <thinker.li@gmail.com>
Subject: Re: [PATCH bpf-next v2] bpf: Add kernel symbol for struct_ops trampoline
Date: Mon, 4 Nov 2024 14:13:30 -0800 [thread overview]
Message-ID: <85160853-cc20-40df-b090-62b4359bec37@linux.dev> (raw)
In-Reply-To: <CAADnVQLvpwLp=t1oz3ic-EKnaio2DhOCanmuBQ+8nSf-jzBePw@mail.gmail.com>
On 11/4/24 9:53 AM, Alexei Starovoitov wrote:
> As a separate clean up I would switch the freeing to call_rcu_tasks.
> Synchronous waiting is expensive.
>
> Martin,
>
> any suggestions?
There is a map->rcu now. May be add a "bool free_after_rcu_tasks_gp" to "struct
bpf_map" and do the call_rcu_tasks() in bpf_map_put(). The
bpf_struct_ops_map_alloc() can set the map->free_after_rcu_tasks_gp.
Take this chance to remove the "st_map->rcu" from "struct bpf_struct_ops_map"
also. It is a left over after cleaning up the kvalue->refcnt in the
commit b671c2067a04 ("bpf: Retire the struct_ops map kvalue->refcnt.").
Xu, it will be great if you can follow up with this cleanup. Otherwise, I will
put it under the top of my todo list. Let me know what you prefer.
next prev parent reply other threads:[~2024-11-04 22:13 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-01 11:19 [PATCH bpf-next v2] bpf: Add kernel symbol for struct_ops trampoline Xu Kuohai
2024-11-01 18:19 ` Alexei Starovoitov
2024-11-04 11:55 ` Xu Kuohai
2024-11-04 17:53 ` Alexei Starovoitov
2024-11-04 22:13 ` Martin KaFai Lau [this message]
2024-11-04 22:32 ` Alexei Starovoitov
2024-11-05 9:30 ` Xu Kuohai
2024-11-05 9:29 ` Xu Kuohai
2024-11-05 0:10 ` Martin KaFai Lau
2024-11-05 9:30 ` Xu Kuohai
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=85160853-cc20-40df-b090-62b4359bec37@linux.dev \
--to=martin.lau@linux.dev \
--cc=alexei.starovoitov@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=eddyz87@gmail.com \
--cc=martin.lau@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=thinker.li@gmail.com \
--cc=xukuohai@huaweicloud.com \
--cc=yonghong.song@linux.dev \
/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;
as well as URLs for NNTP newsgroup(s).