Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758612AbcLOPjr (ORCPT ); Thu, 15 Dec 2016 10:39:47 -0500 Received: from mail-sn1nam01on0045.outbound.protection.outlook.com ([104.47.32.45]:62240 "EHLO NAM01-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1757941AbcLOPjp (ORCPT ); Thu, 15 Dec 2016 10:39:45 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Robert.Richter@cavium.com; Date: Thu, 15 Dec 2016 16:39:30 +0100 From: Robert Richter To: Ard Biesheuvel CC: , , , , , , , , Subject: Re: [PATCH 2/2] arm64: mm: enable CONFIG_HOLES_IN_ZONE for NUMA Message-ID: <20161215153930.GA8111@rric.localdomain> References: <1481706707-6211-1-git-send-email-ard.biesheuvel@linaro.org> <1481706707-6211-3-git-send-email-ard.biesheuvel@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <1481706707-6211-3-git-send-email-ard.biesheuvel@linaro.org> User-Agent: Mutt/1.5.23 (2014-03-12) X-Originating-IP: [92.224.61.108] X-ClientProxiedBy: VI1PR06CA0027.eurprd06.prod.outlook.com (10.162.116.165) To CY1PR07MB2346.namprd07.prod.outlook.com (10.166.194.145) X-MS-Office365-Filtering-Correlation-Id: d8b0dbe3-406b-4902-ee05-08d425009703 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(22001);SRVR:CY1PR07MB2346; X-Microsoft-Exchange-Diagnostics: 1;CY1PR07MB2346;3:oXf6hqqJ24JM4iVFZjSnKUB6k2MWqtaHhe3e20jGseV4pVmaotfcA+Drl3qyH9FwvyX7AJD7hnaXD13AyBQjITJ+cgjbROmqsfZQaXvRz4PU31RIrJGyhyVYwDHvh85OEBJcBvBz8otmMnp8K1I99zq2E5INqtIMWRwBV6YkCtyhEe2wYnBgSbdrfy8eyd+XwJe3radBCLqPdLO58l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3WHlpEX3CYsTVh11p07w22JBfC42x6GbEgwV5yMJy99iKHTPNcg1lXV+RfMOdjtkRDB4LlK249Ihw9tkmgmclWiyN/1hM6mradZw1K0IgUclZ3DcOpnV38iR1fnJkotF0E48OZInjpJ24cc4kep46uNgwuaeN8wk5jx4F8tg9jV8h7PHAdeCyxJwwlzQh2atJ4k0Fq6WWpfc9IDzjS8DbJuvSvW1jOn6dwn5X0lslwMCjTuFDdjchdTwuPTLg+EQQeDdfbPS1Tc2+3EbLd4MLl6J+bU8QmBZUsKW73TzdBUCIFU X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040375)(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046)(6041248)(20161123564025)(20161123562025)(20161123555025)(20161123558021)(20161123560025)(6072148);SRVR:CY1PR07MB2346;BCL:0;PCL:0;RULEID:;SRVR:CY1PR07MB2346; X-Microsoft-Exchange-Diagnostics: 1;CY1PR07MB2346;4:W9SW97Pjeqo3KNZ1IwKW8e0daQ2ngoL2tbufHNfyAc/SMdqCGwaOpHzu+yvvP4Xbx6qRyTjHTTk7EfV0rRl+r3pJ91IG8/DSbZg2QZmJOA+w1JAUpMbPhVn0f/Ldls9iAw2H8UAhC3lAqkN62rmM8i08815GvFfDBNEWB+6jauZ0kSAcAFSVpudG2S/K0BxiJ3tK0ABaAfHILrD4MJIEHZMOzFty1YIjQ032CriAWPifLwx1G55ZBplVc29pCKIM4ubBrjyShYg7Xx0iF01ftdiLkjS0IC+BBlU9nFjWAB33PmyiOdvbQl/X/SSNuQdCarexw1p1a2UVEEw4h6iI62q2I5h6HlhBVlIiVKdGtrVGGB23DELjXRJTEd0xPWLT7BNGqacxvxLRR1Qe8o5hi7wltcHN5iFDwVmnZDvjwhP/B6RMILgL6KfpWAhSDRaVPeH2rti551yyPPobeCQFOu3f3DNR8qPCkv+XbGikFn0BZ6p7i4RvASpQkftvv9v3kj1pxenp9Y42VpDiv0/aU5G9RhBjfCbpGRrlmojA3RsqluUEpBQslZ5mu70Wg4+eGqqe2KYdgQg4i12zhvQtxLvcxdT9ZKkYIh654CS2yHQ= X-Forefront-PRVS: 0157DEB61B X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(4630300001)(6009001)(7916002)(39410400002)(39450400003)(39840400002)(189002)(199003)(24454002)(25786008)(97756001)(92566002)(5660300001)(38730400001)(7416002)(4326007)(33656002)(2906002)(66066001)(50986999)(101416001)(47776003)(15974865002)(5890100001)(54356999)(189998001)(305945005)(76176999)(105586002)(1076002)(6506006)(7736002)(6666003)(2950100002)(42186005)(229853002)(3846002)(6116002)(23726003)(110136003)(9686002)(4001350100001)(81166006)(81156014)(8676002)(106356001)(97736004)(575784001)(50466002)(83506001)(86362001)(46406003)(6916009)(68736007)(18370500001);DIR:OUT;SFP:1101;SCL:1;SRVR:CY1PR07MB2346;H:rric.localdomain;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;CY1PR07MB2346;23:JJKphImUncWTsroFj83A1LX5hVDAijh1JxFtWRbFu?= =?us-ascii?Q?s81O0TSaDx+Akt0siKPVBdR5C81FpDRfdJHw08OmHAJt7f9jiaSKq7tDWgsQ?= =?us-ascii?Q?zdH+dNW5w+WwIFTYGuLv5o/Z2ZJK/XY4AX0Zq5af4KhZgF1fEb4Nqzl15iXm?= =?us-ascii?Q?OeuKg0G1zLB0QhYNh9oYW607nQVEt5bdOs4mujhaiubxb4CH/ESjpjr+JzJU?= =?us-ascii?Q?YqjGkH1Adjmh9x3KKcYnwCa+wY1PHOw1PHtpY40Mho8sSIk4UGGMdWLRH2ZV?= =?us-ascii?Q?9kU1lSu+6rBxp6aohtypntry6W+bMLzpJNQsThl36jv/rvomylbd6IwBt6N7?= =?us-ascii?Q?sWVmHb6oLyy+ph+4E46P8es2VJ4r45mcetEJIph0cwzYuW0gH6/hmtV4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nweZrHSf9HtFRzqIH4V+f9gwDNnyHWX4p?= =?us-ascii?Q?aukZ3J/4ZANAAtk157BdavFqHoabSxxw9xIb/0fVnjf?= X-Microsoft-Exchange-Diagnostics: 1;CY1PR07MB2346;6:b/NZrAEBmq8Gk5mb6CkjlTePnBoe3IcUwwMxYBtU608Px//wpeTe9hL5bXFS9WhB9DygTjG23ndEWbqWtOk3JI8Dtc0JTqkipqUl0IuK8GwyTf2HZ2AbEFUFN1qFG7cIVBxTwuUUmb+QUWzs6bYO8a8xM5oHNKaHJu9wOCMhBZObhH/FVgRAHn8mDOcgYtnMYsSfNFQQf031+BNYSIxwIWOKkKkAtB1jU/ebrNpM1AP73vCK2/mAhZI9f5matqHc9+MmxBym01Ezm0CRz5CCBwr17tKwfOwQ4hh1kOksfrV0zqOwkUGXXPBQ04hu9UbDuRmnE2QaYEgslcMH2tMvpp3avPs17LpskokUzj4Z8ACO8XnfbqTdDgztdtfVk3h+v/k1znE0KdjIM52vQbcF8FxhF+Cfwk6OPYUKRKsAV+g=;5:IppPulxdFbrk2DQjanlAtJDxrFy9ujNHQ1dSJk0hwrkdyKQSfI2fhwwTfm505HKSz6rmmQeHPkPfxu5lg/iFQ0ptPkCT5ADF2JiZ4y73JprAhd847HrZXnLgpRxpmTFUluu4nfVI6g0Cgtt4YkJBoA==;24:T4F/bA1PwNMJoDewjYfeKxuk4Ur4lnsUNFX+1oPRzx7QIDOFzx7mar0ez+ov6utRkV+VVki6d1Oz2uRCIywLMzvLV/Qo3FRhGH1ekG8sZRU= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;CY1PR07MB2346;7:kHK7088pTq6i82adVqbGbMZyyEvJzVD+wbcddziZk0Zw35MvlFlz6Yh7azccYlMxKgrWE+zdl6PJnsTdOPnRcbNFynUk+6HKtGw9LoX8jz0RH1fx6Cm1VrBod7zeaRvTCylQLEuLPTDyPXShrmtSNg3GhBHiqGVACc9S3c5glojMPKz0P/kRkt0NcQDEET3NZvtR6GPcg3d5TVTz0fAAlyC/ChKN0DbaM2YHzj/hpnwHEKBxrLX84IqffLRpbxzR5dZZ5lX7kfl6REv3b6jn99aAuzUO0oqOYIQInNU9aLzha+nqnsL/8v0DCxG3uj/cgBelLIeMHLs4AZ6RvHwHhKxR+EX5ECvUh5gxjquGhM/MGiASwVXmW94WKby4LUU0ZNCs3m1VBlSeK6jB1ZfzQEx07ZK77GPbMs9xrJw1wqlf1tQFtHzFtHLllwiuVzPcXSmZUB/W7nX50Am9rcR2OA== X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 15 Dec 2016 15:39:40.6278 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY1PR07MB2346 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 4155 Lines: 88 I was going to do some measurements but my kernel crashes now with a page fault in efi_rtc_probe(): [ 21.663393] Unable to handle kernel paging request at virtual address 20251000 [ 21.663396] pgd = ffff000009090000 [ 21.663401] [20251000] *pgd=0000010ffff90003 [ 21.663402] , *pud=0000010ffff90003 [ 21.663404] , *pmd=0000000fdc030003 [ 21.663405] , *pte=00e8832000250707 The sparsemem config requires the whole section to be initialized. Your patches do not address this. On 14.12.16 09:11:47, Ard Biesheuvel wrote: > +config HOLES_IN_ZONE > + def_bool y > + depends on NUMA This enables pfn_valid_within() for arm64 and causes the check for each page of a section. The arm64 implementation of pfn_valid() is already expensive (traversing memblock areas). Now, this is increased by a factor of 2^18 for 4k page size (16384 for 64k). We need to initialize the whole section to avoid that. -Robert [ 21.663393] Unable to handle kernel paging request at virtual address 20251000 [ 21.663396] pgd = ffff000009090000 [ 21.663401] [20251000] *pgd=0000010ffff90003 [ 21.663402] , *pud=0000010ffff90003 [ 21.663404] , *pmd=0000000fdc030003 [ 21.663405] , *pte=00e8832000250707 [ 21.663405] [ 21.663411] Internal error: Oops: 96000047 [#1] SMP [ 21.663416] Modules linked in: [ 21.663425] CPU: 49 PID: 1 Comm: swapper/0 Tainted: G W 4.9.0.0.vanilla10-00002-g429605e9ab0a #1 [ 21.663426] Hardware name: www.cavium.com ThunderX CRB-2S/ThunderX CRB-2S, BIOS 0.3 Sep 13 2016 [ 21.663429] task: ffff800feee6bc00 task.stack: ffff800fec050000 [ 21.663433] PC is at 0x201ff820 [ 21.663434] LR is at 0x201fdfc0 [ 21.663435] pc : [<00000000201ff820>] lr : [<00000000201fdfc0>] pstate: 20000045 [ 21.663437] sp : ffff800fec053b70 [ 21.663440] x29: ffff800fec053bc0 x28: 0000000000000000 [ 21.663443] x27: ffff000008ce3e08 x26: ffff000008c52568 [ 21.663445] x25: ffff000008bf045c x24: ffff000008bdb828 [ 21.663448] x23: 0000000000000000 x22: 0000000000000040 [ 21.663451] x21: ffff800fec053bb8 x20: 0000000020251000 [ 21.663453] x19: ffff800fec053c20 x18: 0000000000000000 [ 21.663456] x17: 0000000000000000 x16: 00000000bbb67a65 [ 21.663459] x15: ffffffffffffffff x14: ffff810016ea291c [ 21.663461] x13: ffff810016ea2181 x12: 0000000000000030 [ 21.663464] x11: 0101010101010101 x10: 7f7f7f7f7f7f7f7f [ 21.663467] x9 : feff716475687163 x8 : ffffffffffffffff [ 21.663469] x7 : 83f0680000000000 x6 : 0000000000000000 [ 21.663472] x5 : ffff800fc187aab9 x4 : 0002000000000000 [ 21.663474] x3 : ffff800fec053bb8 x2 : 0000000000000000 [ 21.663477] x1 : 83f0680000000000 x0 : 0000000020251000 [ 21.663478] [ 21.663479] Process swapper/0 (pid: 1, stack limit = 0xffff800fec050020) ... [ 21.663605] [<00000000201ff820>] 0x201ff820 [ 21.663617] [] efi_rtc_probe+0x24/0x78 [ 21.663625] [] platform_drv_probe+0x60/0xc8 [ 21.663636] [] driver_probe_device+0x26c/0x420 [ 21.663639] [] __driver_attach+0x124/0x128 [ 21.663642] [] bus_for_each_dev+0x70/0xb0 [ 21.663644] [] driver_attach+0x30/0x40 [ 21.663647] [] bus_add_driver+0x200/0x2b8 [ 21.663650] [] driver_register+0x68/0x100 [ 21.663652] [] __platform_driver_probe+0x84/0x128 [ 21.663654] [] efi_rtc_driver_init+0x20/0x28 [ 21.663658] [] do_one_initcall+0x44/0x138 [ 21.663665] [] kernel_init_freeable+0x1ac/0x24c [ 21.663673] [] kernel_init+0x18/0x110 [ 21.663675] [] ret_from_fork+0x10/0x20 [ 21.663679] Code: f9400000 d5033d9f d65f03c0 d5033e9f (f9000001) [ 21.663688] ---[ end trace e420ef9636e3c9b2 ]--- [ 21.663711] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b [ 21.663711] [ 21.663713] SMP: stopping secondary CPUs [ 21.670234] Kernel Offset: disabled [ 21.670235] Memory Limit: none [ 22.681333] ---[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b