From: Josef Bacik <josef@toxicpanda.com>
To: hch@lst.de, linux-btrfs@vger.kernel.org, kernel-team@fb.com
Subject: [PATCH v2 0/2] Update device mod time fixes
Date: Thu, 14 Oct 2021 13:10:59 -0400 [thread overview]
Message-ID: <cover.1634231213.git.josef@toxicpanda.com> (raw)
Hello,
Christoph noticed that my original fix to stop calling filp_open() when we
remove devices was wrong because ->bd_inode isn't the inode we need to be
update, it needs to be the inode that is associated with the path to the device
node.
In order to do this I need to do a kern_path() to lookup the path to that inode,
and then I need to update the time for that inode. generic_update_time() isn't
appropriate here as it should be used by ->update_time() if at all. Instead
export a inode_update_time() helper to do the correct thing, and use that.
This allows us to update the time properly for libblkid, and makes sure we still
have the lockdep fix that was the motivation of the original fix. Thanks,
Josef Bacik (2):
fs: export an inode_update_time helper
btrfs: update device path inode time instead of bd_inode
fs/btrfs/volumes.c | 21 +++++++++++++--------
fs/inode.c | 7 ++++---
include/linux/fs.h | 2 ++
3 files changed, 19 insertions(+), 11 deletions(-)
--
2.26.3
next reply other threads:[~2021-10-14 17:11 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-14 17:10 Josef Bacik [this message]
2021-10-14 17:11 ` [PATCH v2 1/2] fs: export an inode_update_time helper Josef Bacik
2021-10-21 16:38 ` David Sterba
2021-10-25 7:45 ` Christoph Hellwig
2021-10-25 17:36 ` David Sterba
2021-10-14 17:11 ` [PATCH v2 2/2] btrfs: update device path inode time instead of bd_inode Josef Bacik
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=cover.1634231213.git.josef@toxicpanda.com \
--to=josef@toxicpanda.com \
--cc=hch@lst.de \
--cc=kernel-team@fb.com \
--cc=linux-btrfs@vger.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;
as well as URLs for NNTP newsgroup(s).