Subject: Re: [PATCH net-next 10/10] tcp: preserve const qualifier in tcp_sk()

From: Simon Horman <[email-masked]>
Date: Fri, 17 Mar 2023 18:12:24 +0100

On Fri, Mar 17, 2023 at 03:55:39PM +0000, Eric Dumazet wrote:
> We can change tcp_sk() to propagate its argument const qualifier,
> thanks to container_of_const().
> 
> We have two places where a const sock pointer has to be upgraded
> to a write one. We have been using const qualifier for lockless
> listeners to clearly identify points where writes could happen.
> 
> Add tcp_sk_rw() helper to better document these.
> 
> tcp_inbound_md5_hash(), __tcp_grow_window(), tcp_reset_check()
> and tcp_rack_reo_wnd() get an additional const qualififer
> for their @tp local variables.
> 
> smc_check_reset_syn_req() also needs a similar change.
> 
> Signed-off-by: Eric Dumazet <[email-masked]>

Upgrading gives me the heebie-jeebies, but ok.

Reviewed-by: Simon Horman <[email-masked]>