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: <CAGXJAmwcsyngTjX3XihgVZ88a+-nW6QQb-UO1hYHBjfD8jNEDA@mail.gmail.com>
Date: Mon, 27 Jan 2025 20:26:21 -0800
From: John Ousterhout <ouster@...stanford.edu>
To: Paolo Abeni <pabeni@...hat.com>
Cc: netdev@...r.kernel.org, edumazet@...gle.com, horms@...nel.org, 
	kuba@...nel.org
Subject: Re: [PATCH net-next v6 07/12] net: homa: create homa_sock.h and homa_sock.c

On Mon, Jan 27, 2025 at 4:40 PM John Ousterhout <ouster@...stanford.edu> wrote:

> > This homa_socktab thing looks quite complex. A simpler implementation
> > could use a simple RCU list _and_ acquire a reference to the hsk before
> > releasing the RCU lock.
>
> I agree that this is complicated. But I can't see a simpler solution.
> The problem is that we need to iterate through all of the sockets and
> release the RCU lock at some points during the iteration. The problem
> isn't preserving the current hsk; it's preserving the validity of the
> pointer to the next one also. I don't fully understand what you're
> proposing above; if you can make it a bit more precise I'll see if it
> solves all the problems I'm aware of and does it in a simpler way.

Responding to my own email: about 15 minutes after sending this email
I realized what you were getting at with your suggestion.  I agree
that's a much better approach than the one currently implemented, so
I'm going to switch to that. Among other things, I think it may allow
all of the RCU stuff  to be encapsulated entirely within the socket
iteration mechanism  (no need for callers to invoke rcu_read_lock).

-John-

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ