[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Zl3utZZF/Sa7OnAj@pop-os.localdomain>
Date: Mon, 3 Jun 2024 09:26:29 -0700
From: Cong Wang <xiyou.wangcong@...il.com>
To: Kuniyuki Iwashima <kuniyu@...zon.com>
Cc: "David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org,
Cong Wang <cong.wang@...edance.com>
Subject: Re: [PATCH v1 net 01/15] af_unix: Set sk->sk_state under
unix_state_lock() for truly disconencted peer.
On Mon, Jun 03, 2024 at 07:32:17AM -0700, Kuniyuki Iwashima wrote:
> - if (other != old_peer)
> + if (other != old_peer) {
> unix_dgram_disconnected(sk, old_peer);
> +
> + unix_state_lock(old_peer);
> + if (!unix_peer(old_peer))
> + WRITE_ONCE(old_peer->sk_state, TCP_CLOSE);
> + unix_state_lock(old_peer);
lock() old_peer twice? Has it been tested? ;-)
Regards.
Powered by blists - more mailing lists