lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <8a268c26-ea57-89ec-9fea-72ec5b8e12e2@gmail.com>
Date:   Fri, 17 Mar 2023 14:46:34 -0700
From:   Kui-Feng Lee <sinquersw@...il.com>
To:     Daniel Borkmann <daniel@...earbox.net>,
        Martin KaFai Lau <martin.lau@...ux.dev>
Cc:     netdev@...r.kernel.org, Eric Dumazet <edumazet@...gle.com>,
        Kui-Feng Lee <kuifeng@...a.com>, bpf@...r.kernel.org,
        ast@...nel.org, song@...nel.org, kernel-team@...a.com,
        andrii@...nel.org, sdf@...gle.com
Subject: Re: [PATCH bpf-next v7 2/8] net: Update an existing TCP congestion
 control algorithm.



On 3/17/23 10:23, Daniel Borkmann wrote:
> On 3/17/23 6:18 PM, Martin KaFai Lau wrote:
>> On 3/17/23 8:23 AM, Daniel Borkmann wrote:
>>>  From the function itself what is not clear whether
>>> callers that replace an existing one should do the synchronize_rcu() 
>>> themselves or if this should
>>> be part of tcp_update_congestion_control?
>>
>> bpf_struct_ops_map_free (in patch 1) also does synchronize_rcu() for 
>> another reason (bpf_setsockopt), so the caller (bpf_struct_ops) is 
>> doing it. From looking at tcp_unregister_congestion_control(), make 
>> sense that it is more correct to have another synchronize_rcu() also 
>> in tcp_update_congestion_control in case there will be other non 
>> bpf_struct_ops caller doing update in the future.
> 
> Agree, I was looking at 'bpf: Update the struct_ops of a bpf_link', and 
> essentially as-is
> it was implicit via map free. +1, tcp_update_congestion_control() would 
> be more obvious and
> better for other/non-BPF users.

It makes sense to me.
I will refactor functions as well.

> 
> Thanks,
> Daniel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ