Re: [PATCH 4.19 012/120] tcp: annotate tp->write_seq lockless reads

2021-03-16 Thread Eric Dumazet
On Tue, Mar 16, 2021 at 10:50 AM Pavel Machek wrote: > > > --- a/net/ipv4/tcp_minisocks.c > > +++ b/net/ipv4/tcp_minisocks.c > > @@ -510,7 +510,7 @@ struct sock *tcp_create_openreq_child(co > > newtp->app_limited = ~0U; > > > > tcp_init_xmit_timers(newsk); > > - newtp->write_seq =

Re: [PATCH 4.19 012/120] tcp: annotate tp->write_seq lockless reads

2021-03-16 Thread Pavel Machek
Hi! > > From: Greg Kroah-Hartman > > > > From: Eric Dumazet > > Dup. Aha, sorry, crossed mails. Still I wonder if hiding assignment into macro is good: > > --- a/net/ipv4/tcp_minisocks.c > > +++ b/net/ipv4/tcp_minisocks.c > > @@ -510,7 +510,7 @@ struct sock *tcp_create_openreq_child(co > >

Re: [PATCH 4.19 012/120] tcp: annotate tp->write_seq lockless reads

2021-03-16 Thread Eric Dumazet
On Tue, Mar 16, 2021 at 10:50 AM Pavel Machek wrote: > > Hi! > > > From: Greg Kroah-Hartman > > > > From: Eric Dumazet > > Dup. > > > > We need to add READ_ONCE() annotations, and also make > > sure write sides use corresponding WRITE_ONCE() to avoid > > store-tearing. > > > @@ -1037,7 +1037,7 @

Re: [PATCH 4.19 012/120] tcp: annotate tp->write_seq lockless reads

2021-03-16 Thread Pavel Machek
Hi! > From: Greg Kroah-Hartman > > From: Eric Dumazet Dup. > We need to add READ_ONCE() annotations, and also make > sure write sides use corresponding WRITE_ONCE() to avoid > store-tearing. > @@ -1037,7 +1037,7 @@ new_segment: > sk->sk_wmem_queued += copy; > sk_