summarylogtreecommitdiffstats
path: root/kernel-5.14-backport.patch
blob: a2d303b4cdbda9a669d2b4c1cb56f8da6276aa02 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
--- a/file.c
+++ b/file.c
@@ -1034,10 +1034,10 @@
 			size_t cp, tail = PAGE_SIZE - off;
 
 			page = pages[ip];
-			cp = copy_page_from_iter_atomic(page, off,
-							min(tail, bytes), from);
+			cp = iov_iter_copy_from_user_atomic(page, from, off,
+							    min(tail, bytes));
 			flush_dcache_page(page);
-
+			iov_iter_advance(from, cp);
 			copied += cp;
 			bytes -= cp;
 			if (!bytes || !cp)