From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Qingfang Deng <dqfext@gmail.com>
Cc: stable@vger.kernel.org, Tejun Heo <tj@kernel.org>,
linux-kernel@vger.kernel.org, Ian Kent <raven@themaw.net>,
Miklos Szeredi <mszeredi@redhat.com>
Subject: Re: [PATCH 5.10 1/5] kernfs: add a revision to identify directory node changes
Date: Wed, 21 May 2025 06:16:01 +0200 [thread overview]
Message-ID: <2025052147-sushi-panther-ab51@gregkh> (raw)
In-Reply-To: <20250521015336.3450911-2-dqfext@gmail.com>
On Wed, May 21, 2025 at 09:53:31AM +0800, Qingfang Deng wrote:
> From: Ian Kent <raven@themaw.net>
>
> Commit 895adbec302e92086359e6fd92611ac3be6d92c3 upstream.
>
> Add a revision counter to kernfs directory nodes so it can be used
> to detect if a directory node has changed during negative dentry
> revalidation.
>
> There's an assumption that sizeof(unsigned long) <= sizeof(pointer)
> on all architectures and as far as I know that assumption holds.
>
> So adding a revision counter to the struct kernfs_elem_dir variant of
> the kernfs_node type union won't increase the size of the kernfs_node
> struct. This is because struct kernfs_elem_dir is at least
> sizeof(pointer) smaller than the largest union variant. It's tempting
> to make the revision counter a u64 but that would increase the size of
> kernfs_node on archs where sizeof(pointer) is smaller than the revision
> counter.
>
> Reviewed-by: Miklos Szeredi <mszeredi@redhat.com>
> Signed-off-by: Ian Kent <raven@themaw.net>
> Link: https://lore.kernel.org/r/162642769895.63632.8356662784964509867.stgit@web.messagingengine.com
> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
When forwarding on patches, you HAVE to sign off on them as well.
thanks,
greg k-h
next prev parent reply other threads:[~2025-05-21 4:16 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-21 1:53 [PATCH 5.10 0/5] kernfs: backport locking and concurrency improvement Qingfang Deng
2025-05-21 1:53 ` [PATCH 5.10 1/5] kernfs: add a revision to identify directory node changes Qingfang Deng
2025-05-21 4:16 ` Greg Kroah-Hartman [this message]
2025-05-21 1:53 ` [PATCH 5.10 2/5] kernfs: use VFS negative dentry caching Qingfang Deng
2025-05-21 1:53 ` [PATCH 5.10 3/5] kernfs: switch kernfs to use an rwsem Qingfang Deng
2025-05-21 1:53 ` [PATCH 5.10 4/5] kernfs: use i_lock to protect concurrent inode updates Qingfang Deng
2025-05-21 1:53 ` [PATCH 5.10 5/5] kernfs: dont call d_splice_alias() under kernfs node lock Qingfang Deng
2025-05-21 4:15 ` [PATCH 5.10 0/5] kernfs: backport locking and concurrency improvement Greg Kroah-Hartman
2025-05-21 5:35 ` Ian Kent
2025-05-21 6:09 ` Ian Kent
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2025052147-sushi-panther-ab51@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=dqfext@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mszeredi@redhat.com \
--cc=raven@themaw.net \
--cc=stable@vger.kernel.org \
--cc=tj@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®