Jan Kara
4628a64591
mm: Preserve _PAGE_DEVMAP across mprotect() calls
...
Currently _PAGE_DEVMAP bit is not preserved in mprotect(2) calls. As a
result we will see warnings such as:
BUG: Bad page map in process JobWrk0013 pte:800001803875ea25 pmd:7624381067
addr:00007f0930720000 vm_flags:280000f9 anon_vma: (null) mapping:ffff97f2384056f0 index:0
file:457-000000fe00000030-00000009-000000ca-00000001_2001.fileblock fault:xfs_filemap_fault [xfs] mmap:xfs_file_mmap [xfs] readpage: (null)
CPU: 3 PID: 15848 Comm: JobWrk0013 Tainted: G W 4.12.14-2.g7573215-default #1 SLE12-SP4 (unreleased)
Hardware name: Intel Corporation S2600WFD/S2600WFD, BIOS SE5C620.86B.01.00.0833.051120182255 05/11/2018
Call Trace:
dump_stack+0x5a/0x75
print_bad_pte+0x217/0x2c0
? enqueue_task_fair+0x76/0x9f0
_vm_normal_page+0xe5/0x100
zap_pte_range+0x148/0x740
unmap_page_range+0x39a/0x4b0
unmap_vmas+0x42/0x90
unmap_region+0x99/0xf0
? vma_gap_callbacks_rotate+0x1a/0x20
do_munmap+0x255/0x3a0
vm_munmap+0x54/0x80
SyS_munmap+0x1d/0x30
do_syscall_64+0x74/0x150
entry_SYSCALL_64_after_hwframe+0x3d/0xa2
...
when mprotect(2) gets used on DAX mappings. Also there is a wide variety
of other failures that can result from the missing _PAGE_DEVMAP flag
when the area gets used by get_user_pages() later.
Fix the problem by including _PAGE_DEVMAP in a set of flags that get
preserved by mprotect(2).
Fixes: 69660fd797
("x86, mm: introduce _PAGE_DEVMAP")
Fixes: ebd3119793
("powerpc/mm: Add devmap support for ppc64")
Cc: <stable@vger.kernel.org >
Signed-off-by: Jan Kara <jack@suse.cz >
Acked-by: Michal Hocko <mhocko@suse.com >
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de >
Signed-off-by: Dan Williams <dan.j.williams@intel.com >
2018-10-09 11:44:58 -07:00
..
2018-10-09 11:44:58 -07:00
2018-08-23 12:15:58 +10:00
2017-01-14 09:54:12 +01:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:13 +10:00
2018-07-30 22:48:16 +10:00
2018-07-30 22:48:16 +10:00
2018-08-10 22:12:35 +10:00
2018-08-17 11:32:50 -07:00
2017-11-02 11:10:55 +01:00
2018-08-08 00:32:24 +10:00
2018-07-30 22:48:13 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-01-22 11:44:24 +11:00
2018-06-04 00:39:19 +10:00
2018-07-30 22:47:54 +10:00
2017-11-02 11:10:55 +01:00
2018-06-04 00:39:19 +10:00
2018-07-30 22:48:16 +10:00
2018-08-08 00:32:25 +10:00
2018-08-08 00:32:25 +10:00
2018-04-20 16:20:13 +02:00
2017-11-02 11:10:55 +01:00
2018-08-17 16:20:28 -07:00
2018-01-20 23:29:02 -06:00
2017-11-02 11:10:55 +01:00
2018-01-20 23:29:02 -06:00
2017-11-02 11:10:55 +01:00
2016-07-21 20:33:57 +10:00
2018-07-31 19:56:44 +10:00
2018-07-30 22:48:17 +10:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:47:54 +10:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:17 +10:00
2018-07-30 22:48:17 +10:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:18 +10:00
2017-04-11 07:46:03 +10:00
2017-07-02 20:40:24 +10:00
2017-01-24 12:23:35 -05:00
2017-04-20 11:36:41 +10:00
2018-03-20 10:01:59 +01:00
2018-01-10 16:41:14 +01:00
2017-11-02 11:10:55 +01:00
2018-01-16 23:26:29 +11:00
2018-07-30 22:48:17 +10:00
2018-03-27 23:44:58 +11:00
2018-07-02 23:54:26 +10:00
2017-07-10 16:32:36 -07:00
2017-09-27 08:23:22 +10:00
2018-03-13 15:50:32 +11:00
2018-01-10 03:07:30 +11:00
2018-08-07 21:49:38 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-08-10 22:12:34 +10:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:16 +10:00
2018-07-30 22:48:17 +10:00
2018-08-10 22:12:33 +10:00
2017-10-19 16:37:08 +02:00
2017-08-10 23:32:12 +10:00
2017-02-27 18:43:46 -08:00
2016-03-04 23:50:27 -06:00
2018-06-03 20:32:02 +10:00
2018-07-30 22:48:16 +10:00
2017-11-02 11:10:55 +01:00
2018-06-07 10:23:33 -07:00
2018-08-07 21:49:38 +10:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:20 +10:00
2018-01-18 15:31:25 +11:00
2018-08-10 22:12:35 +10:00
2018-08-08 00:32:26 +10:00
2017-11-02 11:10:55 +01:00
2018-08-17 11:32:50 -07:00
2018-07-24 22:03:14 +10:00
2016-03-01 19:27:20 +11:00
2017-11-02 11:10:55 +01:00
2017-09-01 16:42:50 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-06-03 20:43:37 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-05-18 21:59:56 +10:00
2018-09-12 08:49:54 +10:00
2018-03-13 15:50:37 +11:00
2018-03-13 15:50:38 +11:00
2018-01-19 22:37:01 +11:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:16 +10:00
2018-01-03 09:02:11 -08:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-04-13 17:10:27 -07:00
2017-11-02 11:10:55 +01:00
2018-06-21 12:33:15 +02:00
2018-03-24 00:39:13 +11:00
2018-05-18 15:38:23 +10:00
2018-03-24 00:39:13 +11:00
2018-07-26 13:23:52 +10:00
2018-07-30 22:48:17 +10:00
2018-05-18 15:38:23 +10:00
2018-07-26 14:53:54 +10:00
2018-03-06 18:40:44 +01:00
2018-05-22 19:53:00 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2016-12-19 11:15:25 +01:00
2018-01-19 22:37:04 +11:00
2018-04-03 21:50:07 +10:00
2018-06-03 20:43:33 +10:00
2017-11-02 11:10:55 +01:00
2017-10-16 23:12:01 +11:00
2017-11-02 11:10:55 +01:00
2018-02-05 21:34:31 +01:00
2015-06-24 17:49:41 -07:00
2018-03-18 07:38:47 -07:00
2018-09-12 08:49:54 +10:00
2018-03-13 23:43:06 +11:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:20 +10:00
2018-05-15 22:29:10 +10:00
2018-07-30 22:48:17 +10:00
2017-11-02 11:10:55 +01:00
2018-06-11 09:16:29 +09:00
2017-11-02 11:10:55 +01:00
2015-10-22 16:06:08 +02:00
2018-05-25 12:04:42 +10:00
2015-10-22 15:19:40 +02:00
2017-11-02 11:10:55 +01:00
2016-09-20 20:57:12 +10:00
2018-01-21 15:06:16 +11:00
2017-11-02 11:10:55 +01:00
2015-10-05 21:32:50 +11:00
2018-06-19 23:03:50 +10:00
2017-11-02 11:10:55 +01:00
2018-08-08 00:32:34 +10:00
2018-08-20 20:19:54 +10:00
2018-08-07 21:49:29 +10:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:16 +10:00
2018-07-30 22:48:16 +10:00
2017-11-02 11:10:55 +01:00
2018-01-27 20:39:01 +11:00
2018-05-07 07:15:41 +02:00
2017-11-02 11:10:55 +01:00
2018-03-27 19:25:10 +11:00
2017-11-15 18:21:04 -08:00
2017-11-16 12:47:46 -08:00
2017-11-16 12:47:46 -08:00
2018-06-03 20:40:34 +10:00
2018-07-24 21:43:24 +10:00
2018-06-03 20:40:25 +10:00
2016-06-14 13:58:26 +10:00
2018-05-25 12:04:41 +10:00
2018-03-30 23:34:22 +11:00
2018-06-03 20:40:32 +10:00
2018-07-02 23:54:32 +10:00
2018-04-24 09:46:57 +10:00
2016-07-14 21:12:06 +10:00
2018-07-30 22:48:17 +10:00
2018-07-30 22:48:17 +10:00
2016-11-22 11:57:08 +11:00
2018-07-30 22:48:19 +10:00
2018-01-21 16:21:46 +11:00
2017-01-24 12:23:35 -05:00
2016-06-14 13:58:26 +10:00
2018-06-07 17:34:35 -07:00
2017-08-17 23:13:46 +10:00
2018-07-30 22:48:16 +10:00
2018-01-16 23:47:12 +11:00
2018-07-30 22:48:16 +10:00
2017-08-03 16:06:52 +10:00
2018-07-30 22:48:17 +10:00
2018-08-19 10:38:36 -07:00
2018-05-25 12:04:43 +10:00
2018-06-03 20:43:33 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-01-09 10:45:37 +01:00
2018-08-08 00:32:26 +10:00
2018-09-18 22:42:54 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-03-13 23:43:05 +11:00
2018-07-24 22:03:14 +10:00
2017-11-02 11:10:55 +01:00
2018-07-24 22:03:17 +10:00
2017-11-02 11:10:55 +01:00
2018-07-30 22:48:16 +10:00
2015-08-18 19:29:49 +10:00
2018-06-03 21:19:40 +10:00
2018-08-08 00:32:30 +10:00
2018-08-07 21:49:30 +10:00
2018-01-15 09:35:26 +01:00
2018-06-03 20:40:31 +10:00
2018-07-30 22:48:17 +10:00
2015-07-29 11:56:13 +10:00
2018-05-10 23:25:14 +10:00
2018-06-23 21:43:21 +10:00
2016-07-17 16:42:47 +10:00
2018-07-30 22:48:17 +10:00
2018-06-03 20:43:34 +10:00
2017-11-02 11:10:55 +01:00
2018-08-10 22:12:39 +10:00
2018-07-30 22:48:21 +10:00
2018-05-24 16:04:02 +10:00
2018-08-21 16:01:59 +10:00
2015-08-06 16:36:23 +10:00
2018-05-10 23:17:43 +10:00
2015-09-16 15:47:51 +02:00
2016-06-14 13:58:26 +10:00
2016-06-14 13:58:27 +10:00
2018-08-10 22:26:10 +10:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2018-06-23 21:43:21 +10:00
2017-11-02 11:10:55 +01:00
2017-11-12 09:03:10 +11:00
2015-11-26 22:11:17 +11:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2016-11-14 11:11:51 +11:00
2017-11-02 11:10:55 +01:00
2016-11-29 09:14:50 +00:00
2018-06-03 20:43:35 +10:00
2018-08-07 21:49:28 +10:00
2018-05-25 12:04:36 +10:00
2018-05-25 12:04:38 +10:00
2018-05-25 12:04:38 +10:00