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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 15 Apr 2021 15:40:56 +0100
From:   Christoph Hellwig <hch@...radead.org>
To:     Zhang Yi <yi.zhang@...wei.com>
Cc:     linux-ext4@...r.kernel.org, linux-fsdevel@...r.kernel.org,
        tytso@....edu, adilger.kernel@...ger.ca, jack@...e.cz,
        yukuai3@...wei.com
Subject: Re: [RFC PATCH v2 6/7] fs: introduce a usage count into the
 superblock

On Wed, Apr 14, 2021 at 09:47:36PM +0800, Zhang Yi wrote:
> Commit <87d8fe1ee6b8> ("add releasepage hooks to block devices which can
> be used by file systems") introduce a hook that used by ext4 filesystem
> to release journal buffers, but it doesn't add corresponding concurrency
> protection that ->bdev_try_to_free_page() could be raced by umount
> filesystem concurrently. This patch add a usage count on superblock that
> filesystem can use it to prevent above race and make invoke
> ->bdev_try_to_free_page() safe.

We already have two refcounts in the superblock: s_active which counts
the active refernce, and s_count which prevents the data structures
from beeing freed.  I don't think we need yet another one.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ