Files
android_kernel_xiaomi_sm8450/include/linux
Jan Kara 0911d0041c mm: avoid returning VM_FAULT_RETRY from ->page_mkwrite handlers
Some ->page_mkwrite handlers may return VM_FAULT_RETRY as its return
code (GFS2 or Lustre can definitely do this).  However VM_FAULT_RETRY
from ->page_mkwrite is completely unhandled by the mm code and results
in locking and writeably mapping the page which definitely is not what
the caller wanted.

Fix Lustre and block_page_mkwrite_ret() used by other filesystems
(notably GFS2) to return VM_FAULT_NOPAGE instead which results in
bailing out from the fault code, the CPU then retries the access, and we
fault again effectively doing what the handler wanted.

Link: http://lkml.kernel.org/r/20170203150729.15863-1-jack@suse.cz
Signed-off-by: Jan Kara <jack@suse.cz>
Reported-by: Al Viro <viro@ZenIV.linux.org.uk>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Cc: Matthew Wilcox <willy@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-02-08 15:41:43 -08:00
..
2016-11-17 23:19:00 +01:00
2016-07-08 16:23:11 +02:00
2016-12-22 22:58:37 -05:00
2016-10-19 14:34:36 -04:00
2017-01-13 15:17:04 -07:00
2016-12-08 13:31:11 -05:00
2016-08-11 09:41:35 -06:00
2016-10-25 11:08:28 +08:00
2016-12-08 16:37:33 -08:00
2016-09-27 21:20:53 -04:00
2016-10-07 18:46:30 -07:00
2016-12-05 19:01:16 -05:00
2016-10-28 08:48:16 -06:00
2016-11-25 10:15:13 -08:00
2016-12-05 19:01:16 -05:00
2017-01-16 14:03:31 -05:00
2016-12-25 17:21:22 +01:00
2016-12-25 17:21:22 +01:00
2016-11-30 14:36:01 +11:00
2016-09-14 09:18:09 -06:00
2016-08-10 11:23:44 -04:00
2016-12-12 18:55:06 -08:00
2016-12-25 17:21:23 +01:00
2016-09-27 12:33:47 +02:00
2016-12-06 11:05:46 +01:00
2016-07-29 12:17:52 -07:00
2016-08-28 23:32:41 -04:00
2016-11-16 18:32:02 -05:00
2016-12-19 17:29:44 -05:00
2016-12-12 18:55:07 -08:00
2016-11-10 17:03:35 +01:00
2016-12-06 10:17:03 +02:00
2016-10-31 16:18:30 -04:00
2016-10-14 11:36:59 -07:00
2016-07-12 19:25:38 -07:00
2016-09-27 21:52:00 -04:00
2016-11-15 16:34:27 -08:00
2016-07-06 10:51:14 +01:00
2016-09-20 04:43:36 -04:00
2016-10-31 15:45:18 -07:00
2016-06-14 10:54:40 -07:00
2016-10-05 18:23:36 -04:00
2017-01-10 18:31:55 -08:00
2016-12-25 17:21:22 +01:00
2017-01-10 18:31:55 -08:00
2016-07-19 17:43:38 +03:00
2016-12-09 22:12:21 -05:00
2016-12-12 18:55:08 -08:00
2016-12-25 17:21:22 +01:00