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]
Message-ID: <87plc6kzvl.fsf@wotan.olymp>
Date: Thu, 04 Sep 2025 16:21:02 +0100
From: Luis Henriques <luis@...lia.com>
To: Miklos Szeredi <miklos@...redi.hu>
Cc: Bernd Schubert <bernd@...ernd.com>,  Laura Promberger
 <laura.promberger@...n.ch>,  Dave Chinner <david@...morbit.com>,  Matt
 Harvey <mharvey@...ptrading.com>,  linux-fsdevel@...r.kernel.org,
  kernel-dev@...lia.com,  linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH v5 2/2] fuse: new work queue to invalidate dentries
 from old epochs

On Thu, Sep 04 2025, Miklos Szeredi wrote:

> On Thu, 4 Sept 2025 at 16:11, Luis Henriques <luis@...lia.com> wrote:
>>
>> On Thu, Sep 04 2025, Miklos Szeredi wrote:
>>
>> > On Thu, 28 Aug 2025 at 18:30, Luis Henriques <luis@...lia.com> wrote:
>> >>
>> >> With the infrastructure introduced to periodically invalidate expired
>> >> dentries, it is now possible to add an extra work queue to invalidate
>> >> dentries when an epoch is incremented.  This work queue will only be
>> >> triggered when the 'inval_wq' parameter is set.
>> >>
>> >> Signed-off-by: Luis Henriques <luis@...lia.com>
>> >> ---
>> >>  fs/fuse/dev.c    |  7 ++++---
>> >>  fs/fuse/dir.c    | 34 ++++++++++++++++++++++++++++++++++
>> >>  fs/fuse/fuse_i.h |  4 ++++
>> >>  fs/fuse/inode.c  | 41 ++++++++++++++++++++++-------------------
>> >>  4 files changed, 64 insertions(+), 22 deletions(-)
>> >>
>> >> diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c
>> >> index e80cd8f2c049..48c5c01c3e5b 100644
>> >> --- a/fs/fuse/dev.c
>> >> +++ b/fs/fuse/dev.c
>> >> @@ -2033,13 +2033,14 @@ static int fuse_notify_resend(struct fuse_conn *fc)
>> >>
>> >>  /*
>> >>   * Increments the fuse connection epoch.  This will result of dentries from
>> >> - * previous epochs to be invalidated.
>> >> - *
>> >> - * XXX optimization: add call to shrink_dcache_sb()?
>> >
>> > I guess it wouldn't hurt.   Definitely simpler, so I'd opt for this.
>>
>> So, your suggesting to have the work queue simply calling this instead of
>> walking through the dentries?  (Or even *not* having a work queue at all?)
>
> I think doing in in a work queue is useful, since walking the tree
> might take a significant amount of time.
>
> Not having to do the walk manually is definitely a simplification.
> It might throw out dentries that got looked up since the last epoch,
> but it's probably not a big loss in terms of performance.

OK, so that definitely makes things simpler for v6.  Thanks!

Cheers,
-- 
Luís

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ