Re: [PATCH bpf-next] bpf: Use separate RCU callbacks for freeing selem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 3 Mar 2023 at 16:40, Martin KaFai Lau <martin.lau@xxxxxxxxx> wrote:
>
> On 3/3/23 6:15 AM, Kumar Kartikeya Dwivedi wrote:
> > Martin suggested that instead of using a byte in the hole (which he has
> > a use for in his future patch) in bpf_local_storage_elem, we can
> > dispatch a different call_rcu callback based on whether we need to free
> > special fields in bpf_local_storage_elem data. The free path, described
> > in commit 9db44fdd8105 ("bpf: Support kptrs in local storage maps"),
> > only waits for call_rcu callbacks when there are special (kptrs, etc.)
> > fields in the map value, hence it is necessary that we only access
> > smap in this case.
> >
> > Therefore, dispatch different RCU callbacks based on the BPF map has a
> > valid btf_record, which dereference and use smap's btf_record only when
> > it is valid.
> >
> > Signed-off-by: Kumar Kartikeya Dwivedi <memxor@xxxxxxxxx>
>
> Thanks for your patch. I have already made a similar change in my local branch
> which has some differences like refactored it a little for my work. The set is
> almost ready. Do you mind if I include your patch in my set and keep your SOB?
>

No problem, please do.



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux