Pasha Tatashin
889c695d41
mm: disable deferred struct page for 32-bit arches
Deferred struct page init is needed only on systems with large amount of
physical memory to improve boot performance. 32-bit systems do not
benefit from this feature.
Jiri reported a problem where deferred struct pages do not work well with
x86-32:
[ 0.035162] Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
[ 0.035725] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
[ 0.036269] Initializing CPU#0
[ 0.036513] Initializing HighMem for node 0 (00036ffe:0007ffe0)
[ 0.038459] page:f6780000 is uninitialized and poisoned
[ 0.038460] raw: ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff
[ 0.039509] page dumped because: VM_BUG_ON_PAGE(1 && PageCompound(page))
[ 0.040038] ------------[ cut here ]------------
[ 0.040399] kernel BUG at include/linux/page-flags.h:293!
[ 0.040823] invalid opcode: 0000 [#1] SMP PTI
[ 0.041166] CPU: 0 PID: 0 Comm: swapper Not tainted 4.19.0-rc1_pt_jiri #9
[ 0.041694] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.11.0-20171110_100015-anatol 04/01/2014
[ 0.042496] EIP: free_highmem_page+0x64/0x80
[ 0.042839] Code: 13 46 d8 c1 e8 18 5d 83 e0 03 8d 04 c0 c1 e0 06 ff 80 ec 5f 44 d8 c3 8d b4 26 00 00 00 00 ba 08 65 28 d8 89 d8 e8 fc 71 02 00 <0f> 0b 8d 76 00 8d bc 27 00 00 00 00 ba d0 b1 26 d8 89 d8 e8 e4 71
[ 0.044338] EAX: 0000003c EBX: f6780000 ECX: 00000000 EDX: d856cbe8
[ 0.044868] ESI: 0007ffe0 EDI: d838df20 EBP: d838df00 ESP: d838defc
[ 0.045372] DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068 EFLAGS: 00210086
[ 0.045913] CR0: 80050033 CR2: 00000000 CR3: 18556000 CR4: 00040690
[ 0.046413] DR0: 00000000 DR1: 00000000 DR2: 00000000 DR3: 00000000
[ 0.046913] DR6: fffe0ff0 DR7: 00000400
[ 0.047220] Call Trace:
[ 0.047419] add_highpages_with_active_regions+0xbd/0x10d
[ 0.047854] set_highmem_pages_init+0x5b/0x71
[ 0.048202] mem_init+0x2b/0x1e8
[ 0.048460] start_kernel+0x1d2/0x425
[ 0.048757] i386_start_kernel+0x93/0x97
[ 0.049073] startup_32_smp+0x164/0x168
[ 0.049379] Modules linked in:
[ 0.049626] ---[ end trace 337949378db0abbb ]---
We free highmem pages before their struct pages are initialized:
mem_init()
set_highmem_pages_init()
add_highpages_with_active_regions()
free_highmem_page()
.. Access uninitialized struct page here..
Because there is no reason to have this feature on 32-bit systems, just
disable it.
Link: http://lkml.kernel.org/r/20180831150506.31246-1-pavel.tatashin@microsoft.com
Fixes: 2e3ca40f03bb ("mm: relax deferred struct page requirements")
Signed-off-by: Pavel Tatashin <pavel.tatashin@microsoft.com>
Reported-by: Jiri Slaby <jslaby@suse.cz>
Acked-by: Michal Hocko <mhocko@suse.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-09-20 22:01:11 +02:00
..
2018-08-17 16:20:30 -07:00
2018-08-31 14:48:56 -06:00
2017-11-14 23:57:38 +02:00
2018-08-02 12:17:27 -06:00
2018-06-15 07:55:25 +09:00
2018-08-17 16:20:32 -07:00
2018-08-17 16:20:32 -07:00
2017-11-02 11:10:55 +01:00
2018-06-15 07:55:25 +09:00
2017-11-02 11:10:55 +01:00
2018-09-13 15:18:04 -10:00
2018-06-15 07:55:25 +09:00
2017-12-11 14:54:44 +01:00
2018-08-30 20:01:32 +02:00
2018-06-15 07:55:25 +09:00
2018-06-07 17:34:36 -07:00
2017-12-14 16:00:48 -08:00
2018-06-15 07:55:25 +09:00
2018-06-12 16:19:22 -07:00
2018-08-23 18:48:44 -07:00
2017-11-02 11:10:55 +01:00
2018-08-25 18:43:59 -07:00
2018-09-04 16:45:02 -07:00
2018-06-07 17:34:35 -07:00
2018-08-23 18:48:44 -07:00
2018-01-23 12:17:42 -06:00
2018-07-17 09:35:30 +02:00
2018-08-23 18:48:44 -07:00
2018-01-31 17:18:37 -08:00
2018-09-20 22:01:11 +02:00
2018-08-22 10:52:44 -07:00
2018-08-23 18:48:44 -07:00
2016-03-17 15:09:34 -07:00
2018-09-04 16:45:02 -07:00
2018-08-22 17:31:34 -07:00
2018-08-17 16:20:32 -07:00
2018-02-06 18:32:48 -08:00
2018-07-23 10:38:05 -07:00
2018-08-30 20:01:32 +02:00
2018-08-17 16:20:30 -07:00
2018-09-04 16:45:02 -07:00
2018-07-12 10:02:57 -04:00
2018-09-04 16:45:02 -07:00
2018-08-25 18:43:59 -07:00
2018-08-25 13:15:03 -07:00
2018-08-22 10:52:45 -07:00
2018-08-22 10:52:44 -07:00
2017-11-02 11:10:55 +01:00
2018-08-23 18:48:43 -07:00
2017-11-02 11:10:55 +01:00
2018-08-17 16:20:27 -07:00
2018-08-22 10:52:45 -07:00
2018-08-22 10:52:44 -07:00
2017-03-02 08:42:38 +01:00
2018-08-22 10:52:44 -07:00
2017-11-02 11:10:55 +01:00
2018-06-20 19:10:01 +02:00
2018-06-15 07:55:24 +09:00
2017-11-02 11:10:55 +01:00
2018-08-02 12:17:27 -06:00
2018-08-17 16:20:29 -07:00
2018-09-04 16:45:02 -07:00
2018-09-04 16:45:02 -07:00
2018-06-07 17:34:36 -07:00
2018-08-17 16:20:28 -07:00
2018-06-15 07:55:25 +09:00
2018-07-09 09:07:54 -06:00
2018-04-11 10:28:32 -07:00
2018-06-15 07:55:25 +09:00
2018-04-05 21:36:26 -07:00
2018-01-22 12:15:57 -08:00
2018-08-30 12:56:40 +02:00
2018-04-05 21:36:27 -07:00
2017-11-02 11:10:55 +01:00
2018-02-18 05:33:01 -08:00
2018-06-12 16:19:22 -07:00
2018-02-18 05:33:01 -08:00
2018-08-22 10:52:45 -07:00
2018-01-31 17:18:38 -08:00
2018-02-06 18:32:48 -08:00
2017-11-02 11:10:55 +01:00
2018-08-30 20:01:32 +02:00
2018-07-14 11:11:09 -07:00
2017-10-03 17:54:24 -07:00
2018-08-23 18:48:44 -07:00
2018-08-17 16:20:30 -07:00
2018-06-12 16:19:22 -07:00
2018-08-17 16:20:30 -07:00
2018-06-07 17:34:34 -07:00
2018-08-30 12:56:40 +02:00
2018-08-17 16:20:32 -07:00
2018-08-17 16:20:32 -07:00
2017-11-02 11:10:55 +01:00
2018-08-22 10:52:44 -07:00
2018-06-12 16:19:22 -07:00
2018-05-22 06:59:39 -07:00
2018-08-22 10:52:44 -07:00
2018-04-11 10:28:39 -07:00
2018-07-04 08:04:52 -07:00
2018-06-07 17:34:38 -07:00
2018-09-04 16:45:02 -07:00
2018-09-13 15:18:04 -10:00
2018-08-17 16:20:29 -07:00
2018-06-07 17:34:36 -07:00
2018-08-22 10:52:44 -07:00
2018-06-28 11:16:44 -07:00
2018-08-17 16:20:32 -07:00
2018-05-11 17:28:45 -07:00
2018-02-06 18:32:48 -08:00
2018-02-21 15:35:43 -08:00
2018-08-17 16:20:30 -07:00
2018-07-26 19:38:03 -07:00