mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tony Luck <tony.luck@intel.com>
To: Ard Biesheuvel <ardb@kernel.org>
Cc: Tony Luck <tony.luck@intel.com>,
	Lennart Poettering <mzxreary@0pointer.de>,
	Matthew Garrett <matthew.garrett@nebula.com>,
	Jeremy Kerr <jk@ozlabs.org>,
	linux-efi@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 1/2] efivarfs: Update inode modification time for successful writes
Date: Thu, 28 May 2020 12:49:04 -0700	[thread overview]
Message-ID: <20200528194905.690-2-tony.luck@intel.com> (raw)
In-Reply-To: <20200528194905.690-1-tony.luck@intel.com>

Some applications want to be able to see when EFI variables
have been updated.

Update the modification time for successful writes.

Reported-by: Lennart Poettering <mzxreary@0pointer.de>
Signed-off-by: Tony Luck <tony.luck@intel.com>
---
 fs/efivarfs/file.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/fs/efivarfs/file.c b/fs/efivarfs/file.c
index e9e27a271af0..4b8bc4560d70 100644
--- a/fs/efivarfs/file.c
+++ b/fs/efivarfs/file.c
@@ -51,6 +51,7 @@ static ssize_t efivarfs_file_write(struct file *file,
 	} else {
 		inode_lock(inode);
 		i_size_write(inode, datasize + sizeof(attributes));
+		inode->i_mtime = current_time(inode);
 		inode_unlock(inode);
 	}
 
-- 
2.21.1


  reply	other threads:[~2020-05-28 19:49 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-28 19:49 [PATCH 0/2] Couple of efivarfs fixes Tony Luck
2020-05-28 19:49 ` Tony Luck [this message]
2020-06-19 16:46   ` [tip: efi/urgent] efivarfs: Update inode modification time for successful writes tip-bot2 for Tony Luck
2020-05-28 19:49 ` [PATCH 2/2] efivarfs: Don't return -EINTR when rate-limiting reads Tony Luck
2020-06-19 16:46   ` [tip: efi/urgent] " tip-bot2 for Tony Luck
2020-06-15  9:50 ` [PATCH 0/2] Couple of efivarfs fixes Ard Biesheuvel

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=20200528194905.690-2-tony.luck@intel.com \
    --to=tony.luck@intel.com \
    --cc=ardb@kernel.org \
    --cc=jk@ozlabs.org \
    --cc=linux-efi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matthew.garrett@nebula.com \
    --cc=mzxreary@0pointer.de \
    /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

Powered by JetHome