Skip to content

Commit 2096721

Browse files
aeglardbiesheuvel
authored andcommitted
efivarfs: Update inode modification time for successful writes
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 <[email protected]> Signed-off-by: Tony Luck <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Ard Biesheuvel <[email protected]>
1 parent 4ddf473 commit 2096721

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

fs/efivarfs/file.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ static ssize_t efivarfs_file_write(struct file *file,
5151
} else {
5252
inode_lock(inode);
5353
i_size_write(inode, datasize + sizeof(attributes));
54+
inode->i_mtime = current_time(inode);
5455
inode_unlock(inode);
5556
}
5657

0 commit comments

Comments
 (0)