]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
afs: Fix non-setting of mtime when writing into mmap
authorDavid Howells <dhowells@redhat.com>
Thu, 11 Jun 2020 23:15:13 +0000 (00:15 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 24 Jun 2020 15:49:13 +0000 (17:49 +0200)
commit467f654f800ca470593ced33e69c5d22925b8bd3
tree5c9132a87f1df6dccc77f70204e62799dd4aaabb
parent1357148122938a09e3562512081c252446990eb2
afs: Fix non-setting of mtime when writing into mmap

[ Upstream commit bb413489288e4e457353bac513fddb6330d245ca ]

The mtime on an inode needs to be updated when a write is made into an
mmap'ed section.  There are three ways in which this could be done: update
it when page_mkwrite is called, update it when a page is changed from dirty
to writeback or leave it to the server and fix the mtime up from the reply
to the StoreData RPC.

Found with the generic/215 xfstest.

Fixes: 1cf7a1518aef ("afs: Implement shared-writeable mmap")
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/afs/write.c