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]
Date:   Wed, 11 May 2022 19:58:10 +1000
From:   Imran Khan <imran.f.khan@...cle.com>
To:     Tejun Heo <tj@...nel.org>
Cc:     viro@...iv.linux.org.uk, gregkh@...uxfoundation.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 5/5] kernfs: Replace global kernfs_open_file_mutex with
 hashed mutexes.

Hello Tejun,

On 6/5/22 6:05 am, Tejun Heo wrote:
> On Thu, Apr 28, 2022 at 03:54:31PM +1000, Imran Khan wrote:
>> +static void __init kernfs_mutex_init(void)
>> +{
>> +	int count;
>> +
>> +	for (count = 0; count < NR_KERNFS_LOCKS; count++)
>> +		mutex_init(&kernfs_locks->open_file_mutex[count]);
>> +}
> 
> Does this need to be a separate function?
> 

Above, I have moved mutex initialization from kernfs_lock_init to a
separate function kernfs_mutex_init. Could you please let me know if I
am missing something here ?
>> +static void __init kernfs_lock_init(void)
>> +{
>> +	kernfs_locks = kmalloc(sizeof(struct kernfs_global_locks), GFP_KERNEL);
>> +	WARN_ON(!kernfs_locks);
>> +
>> +	kernfs_mutex_init();
>> +}
>> +
>>  void __init kernfs_init(void)
>>  {
>>  	kernfs_node_cache = kmem_cache_create("kernfs_node_cache",
> 
> Other than that minor nitpick,
> 
> Acked-by: Tejun Heo <tj@...nel.org>
> 
> Thanks.
> 

Thanks,
 -- Imran

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ