linux-erofs.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] iomap: Add missing flush_dcache_page
@ 2021-07-16 15:00 Matthew Wilcox (Oracle)
  2021-07-16 15:04 ` Christoph Hellwig
  2021-07-16 15:04 ` Gao Xiang
  0 siblings, 2 replies; 6+ messages in thread
From: Matthew Wilcox (Oracle) @ 2021-07-16 15:00 UTC (permalink / raw)
  To: Andreas Gruenbacher, Christoph Hellwig, Darrick J . Wong
  Cc: stable, linux-xfs, Matthew Wilcox (Oracle),
	linux-fsdevel, Gao Xiang, linux-erofs

Inline data needs to be flushed from the kernel's view of a page before
it's mapped by userspace.

Cc: stable@vger.kernel.org
Fixes: 19e0c58f6552 ("iomap: generic inline data handling")
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
---
 fs/iomap/buffered-io.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c
index 41da4f14c00b..fe60c603f4ca 100644
--- a/fs/iomap/buffered-io.c
+++ b/fs/iomap/buffered-io.c
@@ -222,6 +222,7 @@ iomap_read_inline_data(struct inode *inode, struct page *page,
 	memcpy(addr, iomap->inline_data, size);
 	memset(addr + size, 0, PAGE_SIZE - size);
 	kunmap_atomic(addr);
+	flush_dcache_page(page);
 	SetPageUptodate(page);
 }
 
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-07-20 15:57 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-16 15:00 [PATCH] iomap: Add missing flush_dcache_page Matthew Wilcox (Oracle)
2021-07-16 15:04 ` Christoph Hellwig
2021-07-16 17:28   ` Matthew Wilcox
2021-07-19  8:39     ` Christoph Hellwig
2021-07-20 15:56       ` Matthew Wilcox
2021-07-16 15:04 ` Gao Xiang

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).