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: <20250603223020.3344d362@pumpkin>
Date: Tue, 3 Jun 2025 22:30:20 +0100
From: David Laight <david.laight.linux@...il.com>
To: Christoph Hellwig <hch@....de>
Cc: Kuniyuki Iwashima <kuni1840@...il.com>, axboe@...nel.dk,
 chuck.lever@...cle.com, davem@...emloft.net, edumazet@...gle.com,
 horms@...nel.org, jaka@...ux.ibm.com, jlayton@...nel.org,
 kbusch@...nel.org, kuba@...nel.org, kuniyu@...zon.com,
 linux-nfs@...r.kernel.org, linux-nvme@...ts.infradead.org,
 linux-rdma@...r.kernel.org, matttbe@...nel.org, mptcp@...ts.linux.dev,
 netdev@...r.kernel.org, pabeni@...hat.com, sfrench@...ba.org,
 wenjia@...ux.ibm.com, willemb@...gle.com
Subject: Re: [PATCH v2 net-next 3/7] socket: Restore sock_create_kern().

On Mon, 2 Jun 2025 07:08:17 +0200
Christoph Hellwig <hch@....de> wrote:

> On Thu, May 29, 2025 at 07:53:41PM -0700, Kuniyuki Iwashima wrote:
> > In the old days, sock_create_kern() did take a ref to netns,
> > but an implicit change that avoids taking the ref has caused
> > a lot of problems for people who used to the old semantics.

That must have been a long time ago.
Was it even long after the namespace code was added?
(I don't have a system with the git tree up at the moment)

> > 
> > This series rather rolls back the change, so I think using
> > the same name here is better than leaving the catchy
> > sock_create_kern() error-prone.  
> 
> Ok.

Except that you are changing the semantics again.
So you end up with the same problem the other way around.
I can imagine code ending up with an extra reference to the ns.

The obvious name a a function for general driver use would be
kernel_socket() - matching the other functions that were added
when set_fs(KERNEL_DS) was removed.

I definitely aim to end up where the existing code fails to
compile - just to ensure all the code is found.

	David

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ