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: <CANn89iJ+n12nw-PDJNk-i1tcSbiJ33nqYS0V9+TeqY9iHsVUJQ@mail.gmail.com>
Date: Mon, 27 Oct 2025 08:37:32 -0700
From: Eric Dumazet <edumazet@...gle.com>
To: Matthieu Baerts <matttbe@...nel.org>
Cc: "David S . Miller" <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>, 
	Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>, 
	Neal Cardwell <ncardwell@...gle.com>, Willem de Bruijn <willemb@...gle.com>, 
	Kuniyuki Iwashima <kuniyu@...gle.com>, Mat Martineau <martineau@...nel.org>, 
	Geliang Tang <geliang@...nel.org>, netdev@...r.kernel.org, eric.dumazet@...il.com
Subject: Re: [PATCH v2 net 2/3] tcp: add newval parameter to tcp_rcvbuf_grow()

On Mon, Oct 27, 2025 at 7:50 AM Matthieu Baerts <matttbe@...nel.org> wrote:
>
> Hi Eric,
>
> On 27/10/2025 08:38, Eric Dumazet wrote:
> > This patch has no functional change, and prepares the following one.
> >
> > tcp_rcvbuf_grow() will need to have access to tp->rcvq_space.space
> > old and new values.
> >
> > Change mptcp_rcvbuf_grow() in a similar way.
>
> Thank you for the v2, and for having adapted MPTCP as well.
>
> > Signed-off-by: Eric Dumazet <edumazet@...gle.com>
> > ---
> >  include/net/tcp.h    |  2 +-
> >  net/ipv4/tcp_input.c | 15 ++++++++-------
> >  net/mptcp/protocol.c | 16 ++++++++--------
> >  3 files changed, 17 insertions(+), 16 deletions(-)
> >
> > diff --git a/include/net/tcp.h b/include/net/tcp.h
> > index 5ca230ed526ae02711e8d2a409b91664b73390f2..ab20f549b8f9143671b75ed0a3f87d64b9e73583 100644
> > --- a/include/net/tcp.h
> > +++ b/include/net/tcp.h
> > @@ -370,7 +370,7 @@ void tcp_delack_timer_handler(struct sock *sk);
> >  int tcp_ioctl(struct sock *sk, int cmd, int *karg);
> >  enum skb_drop_reason tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb);
> >  void tcp_rcv_established(struct sock *sk, struct sk_buff *skb);
> > -void tcp_rcvbuf_grow(struct sock *sk);
> > +void tcp_rcvbuf_grow(struct sock *sk, u32 newval);
> >  void tcp_rcv_space_adjust(struct sock *sk);
> >  int tcp_twsk_unique(struct sock *sk, struct sock *sktw, void *twp);
> >  void tcp_twsk_destructor(struct sock *sk);
> > diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
> > index 31ea5af49f2dc8a6f95f3f8c24065369765b8987..600b733e7fb554c36178e432996ecc7d4439268a 100644
> > --- a/net/ipv4/tcp_input.c
> > +++ b/net/ipv4/tcp_input.c
> > @@ -891,18 +891,21 @@ static inline void tcp_rcv_rtt_measure_ts(struct sock *sk,
> >       }
> >  }
> >
> > -void tcp_rcvbuf_grow(struct sock *sk)
> > +void tcp_rcvbuf_grow(struct sock *sk, u32 newval)
> >  {
> >       const struct net *net = sock_net(sk);
> >       struct tcp_sock *tp = tcp_sk(sk);
> > -     int rcvwin, rcvbuf, cap;
> > +     u32 rcvwin, rcvbuf, cap, oldval;
> > +
> > +     oldval = tp->rcvq_space.space;
>
> Even if the series as a whole is OK, NIPA (and the MPTCP CI) are
> complaining about this line, because in this patch, 'oldval' is set but
> not used. It is used in the next patch.
>
> I guess we want to fix this to prevent issues with 'git bisect'. If yes,
> do you mind moving the declaration to the next patch please?

This is quite annoying.

Whole point was to have separate patches to help review, not to add more work.

I will not have time to send a V3 soon, I am OOO.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ