Files
linux-stable-mirror/fs
Matthew Wilcox (Oracle)andGreg Kroah-Hartman fc99f4e2d2 ubifs: Set page uptodate in the correct place
[ Upstream commit 723012cab7 ]

Page cache reads are lockless, so setting the freshly allocated page
uptodate before we've overwritten it with the data it's supposed to have
in it will allow a simultaneous reader to see old data.  Move the call
to SetPageUptodate into ubifs_write_end(), which is after we copied the
new data into the page.

Fixes: 1e51764a3c ("UBIFS: add new flash file system")
Cc: stable@vger.kernel.org
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Reviewed-by: Zhihao Cheng <chengzhihao1@huawei.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-04-03 15:28:20 +02:00
..
2024-02-05 20:14:32 +00:00
2023-08-29 17:45:22 -04:00
2023-08-31 12:07:34 -05:00
2024-03-26 18:19:57 -04:00
2024-02-23 09:25:13 +01:00
2024-03-26 18:19:17 -04:00
2023-08-21 13:46:25 -07:00
2023-08-19 12:12:12 +02:00
2023-08-31 12:47:15 +02:00