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: <385f7646-7f87-43ca-9585-5ecdd59a4379@linux.ibm.com>
Date: Mon, 9 Dec 2024 12:05:03 +0100
From: Wenjia Zhang <wenjia@...ux.ibm.com>
To: Kuniyuki Iwashima <kuniyu@...zon.com>,
        "David S. Miller" <davem@...emloft.net>,
        Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
        Paolo Abeni <pabeni@...hat.com>
Cc: Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org
Subject: Re: [PATCH v1 net-next 03/15] smc: Pass kern to smc_sock_alloc().



On 06.12.24 08:54, Kuniyuki Iwashima wrote:
> Since commit d7cd421da9da ("net/smc: Introduce TCP ULP support"),
> smc_ulp_init() calls __smc_create() with kern=1.
> 
> However, __smc_create() does not pass it to smc_sock_alloc(),
> which finally calls sk_alloc() with kern=0.
> 
> Let's pass kern down to smc_sock_alloc() and sk_alloc().
> 
> Note that we change kern from 1 to 0 in smc_ulp_init() not to
> introduce any functional change.
> 
> Signed-off-by: Kuniyuki Iwashima <kuniyu@...zon.com>
> ---
>   net/smc/af_smc.c | 10 +++++-----
>   1 file changed, 5 insertions(+), 5 deletions(-)
> 
Sorry, I didn't see the need to add the **kern** parameter in 
smc_sock_alloc(). Because the **kern** parameter in sk_alloc is not used 
others than to decide the value of sk->sk_net_refcnt, which in SMC code 
is already set in smc_create_clcsk(). Thus, IMO removing the **kern** 
parameter from __smc_create() makes more sense, since this parameter is 
not used in the function.

Thanks,
Wenjia

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ