From patchwork Fri Jan 23 22:42:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tyler Baker X-Patchwork-Id: 43707 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f72.google.com (mail-wg0-f72.google.com [74.125.82.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 9D060218DB for ; Fri, 23 Jan 2015 22:42:27 +0000 (UTC) Received: by mail-wg0-f72.google.com with SMTP id k14sf42852wgh.3 for ; Fri, 23 Jan 2015 14:42:26 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:mime-version:in-reply-to:references :date:message-id:subject:from:to:cc:content-type:sender:precedence :list-id:x-original-sender:x-original-authentication-results :mailing-list:list-post:list-help:list-archive:list-unsubscribe; bh=lkPr69GSYnuQ/glJbInLCXgwRjZhbf2F+WRi9SB65jk=; b=jf0l3u3RiIE2UeOT2UE3aJa+TAuFmlfGb8ELwMGdXy40Dfm9swsRxNmL0OfZw5N1By 0lf8c5VmFecRXC5gTEvhil6xvyYvpBz1Un3i6/Id3gzKR+r/yE1JNS4eaxeXagQamVC2 eqvLYnzc0oam8l9aT5bRBIUTCASALUyQrHaP5y4MXHXCFFlPUmizTg3cGWtwWw99y7Q6 kqMXg7REzmc5mdfIBl2qSpa3g+hScPOv3Js67AehH5ki1LEuOwSiWdJNcNuVUgygZOur uCqinpFkn0btfx5lwEq7kRsPYU505whc5B9BIUxJx/uWGMICK/IHmAZjrSQV1/8QjFcn ZyJw== X-Gm-Message-State: ALoCoQlF2tLmfd9HR97OIgyvcimcWnsMDO4SoaQdH+cLu2mS0c0YbkFq2AXvJpqYItxo3bAt6DTl X-Received: by 10.112.148.198 with SMTP id tu6mr1302102lbb.3.1422052946895; Fri, 23 Jan 2015 14:42:26 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.27.9 with SMTP id p9ls7839lag.86.gmail; Fri, 23 Jan 2015 14:42:26 -0800 (PST) X-Received: by 10.112.167.136 with SMTP id zo8mr9928728lbb.17.1422052946745; Fri, 23 Jan 2015 14:42:26 -0800 (PST) Received: from mail-la0-f49.google.com (mail-la0-f49.google.com. [209.85.215.49]) by mx.google.com with ESMTPS id oq1si2529020lbb.98.2015.01.23.14.42.26 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 23 Jan 2015 14:42:26 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.49 as permitted sender) client-ip=209.85.215.49; Received: by mail-la0-f49.google.com with SMTP id gf13so53391lab.8 for ; Fri, 23 Jan 2015 14:42:26 -0800 (PST) X-Received: by 10.112.125.41 with SMTP id mn9mr9774691lbb.80.1422052946534; Fri, 23 Jan 2015 14:42:26 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.35.133 with SMTP id h5csp50921lbj; Fri, 23 Jan 2015 14:42:25 -0800 (PST) X-Received: by 10.66.194.102 with SMTP id hv6mr15327487pac.138.1422052943140; Fri, 23 Jan 2015 14:42:23 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id xt17si3403759pac.212.2015.01.23.14.42.22; Fri, 23 Jan 2015 14:42:23 -0800 (PST) Received-SPF: none (google.com: linux-omap-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752641AbbAWWmV (ORCPT + 5 others); Fri, 23 Jan 2015 17:42:21 -0500 Received: from mail-wi0-f174.google.com ([209.85.212.174]:35326 "EHLO mail-wi0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752011AbbAWWmT (ORCPT ); Fri, 23 Jan 2015 17:42:19 -0500 Received: by mail-wi0-f174.google.com with SMTP id n3so96793wiv.1 for ; Fri, 23 Jan 2015 14:42:17 -0800 (PST) MIME-Version: 1.0 X-Received: by 10.180.91.201 with SMTP id cg9mr8272887wib.63.1422052937838; Fri, 23 Jan 2015 14:42:17 -0800 (PST) Received: by 10.27.125.195 with HTTP; Fri, 23 Jan 2015 14:42:17 -0800 (PST) In-Reply-To: <20150123202229.GA9038@node.dhcp.inet.fi> References: <54BD33DC.40200@ti.com> <20150119174317.GK20386@saruman> <20150120001643.7D15AA8@black.fi.intel.com> <20150120114555.GA11502@n2100.arm.linux.org.uk> <20150120140546.DDCB8D4@black.fi.intel.com> <20150123172736.GA15392@kahuna> <20150123183706.GA15791@kahuna> <20150123202229.GA9038@node.dhcp.inet.fi> Date: Fri, 23 Jan 2015 14:42:17 -0800 Message-ID: Subject: Re: [next-20150119]regression (mm)? From: Tyler Baker To: "Kirill A. Shutemov" Cc: Nishanth Menon , "Kirill A. Shutemov" , Russell King - ARM Linux , Felipe Balbi , linux-mm@kvack.org, linux-next , linux-omap , "linux-arm-kernel@lists.infradead.org" Sender: linux-omap-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: tyler.baker@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.49 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Hi Kirill, On 23 January 2015 at 12:22, Kirill A. Shutemov wrote: > On Fri, Jan 23, 2015 at 12:37:06PM -0600, Nishanth Menon wrote: >> On 09:39-20150123, Tyler Baker wrote: >> > Hi, >> > >> > On 23 January 2015 at 09:27, Nishanth Menon wrote: >> > > On 16:05-20150120, Kirill A. Shutemov wrote: >> > > [..] >> > >> Signed-off-by: Kirill A. Shutemov >> > >> Reported-by: Nishanth Menon >> > > Just to close on this thread: >> > > https://github.com/nmenon/kernel-test-logs/tree/next-20150123 looks good >> > > and back to old status. Thank you folks for all the help. >> > >> > I just reviewed the boot logs for next-20150123 and there still seems >> > to be a related issue. I've been boot testing >> > multi_v7_defconfig+CONFIG_ARM_LPAE=y kernel configurations which still >> > seem broken. >> > >> > For example here are two boots with exynos5250-arndale, one with >> > multi_v7_defconfig+CONFIG_ARM_LPAE=y [1] and the other with >> > multi_v7_defconfig[2]. You can see the kernel configurations with >> > CONFIG_ARM_LPAE=y show the splat: >> > >> > [ 14.605950] ------------[ cut here ]------------ >> > [ 14.609163] WARNING: CPU: 1 PID: 63 at ../mm/mmap.c:2858 >> > exit_mmap+0x1b8/0x224() >> > [ 14.616548] Modules linked in: >> > [ 14.619553] CPU: 1 PID: 63 Comm: init Not tainted 3.19.0-rc5-next-20150123 #1 >> > [ 14.626713] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree) >> > [ 14.632830] [] (unwind_backtrace) from [] (show_stack+0x10/0x14) >> > [ 14.640473] [] (show_stack) from [] (dump_stack+0x78/0x94) >> > [ 14.647678] [] (dump_stack) from [] (warn_slowpath_common+0x74/0xb0) >> > [ 14.655744] [] (warn_slowpath_common) from [] (warn_slowpath_null+0x1c/0x24) >> > [ 14.664510] [] (warn_slowpath_null) from [] (exit_mmap+0x1b8/0x224) >> > [ 14.672497] [] (exit_mmap) from [] (mmput+0x40/0xf8) >> > [ 14.679180] [] (mmput) from [] (flush_old_exec+0x328/0x604) >> > [ 14.686471] [] (flush_old_exec) from [] (load_elf_binary+0x26c/0x11f4) >> > [ 14.694715] [] (load_elf_binary) from [] (search_binary_handler+0x98/0x244) >> > [ 14.703395] [] (search_binary_handler) from [] >> > (do_execveat_common+0x4dc/0x5bc) >> > [ 14.712421] [] (do_execveat_common) from [] (do_execve+0x28/0x30) >> > [ 14.720235] [] (do_execve) from [] (ret_fast_syscall+0x0/0x34) >> > [ 14.727782] ---[ end trace 5e3ca48b454c7e0a ]--- >> > [ 14.733758] ------------[ cut here ]------------ >> > >> > Has anyone else tested with CONFIG_ARM_LPAE=y that can confirm my findings? >> Uggh... I missed since i was looking at non LPAE omap2plus_defconfig. >> >> Dual A15 OMAP5432 with multi_v7_defconfig + CONFIG_ARM_LPAE=y >> https://github.com/nmenon/kernel-test-logs/blob/next-20150123/multi_lpae_defconfig/omap5-evm.txt >> >> Dual A15 DRA7/AM572x with same configuration as above. >> https://raw.githubusercontent.com/nmenon/kernel-test-logs/next-20150123/multi_lpae_defconfig/dra7xx-evm.txt >> https://github.com/nmenon/kernel-test-logs/blob/next-20150123/multi_lpae_defconfig/am57xx-evm.txt >> >> Single A15 DRA72 with same configuration as above: >> https://raw.githubusercontent.com/nmenon/kernel-test-logs/next-20150123/multi_lpae_defconfig/dra72x-evm.txt >> >> You are right. the issue re-appears with LPAE on :( >> Apologies on missing that. > > Guys, could you instrument mm_{inc,dec}_nr_pmds() with dump_stack() + > printk() of the counter and add printk() on mmap_exit() then run a simple > program which triggers the issue? For reference, here is the patch I've applied for testing, mostly stolen from Felipe's debug patch above in this thread. I applied this patch to the tip of linux-next, configured for multi_v7_defconfig and set CONFIG_ARM_LPAE=y. The log for this arndale boot can be found here [1]. For good measure, I then rebuilt the kernel with CONFIG_ARM_LPAE=n and booted the same platform again. This log can be found here [2]. Happy hunting! > > -- > Kirill A. Shutemov [1] http://storage.kernelci.org/debug/mm/arndale-lpae-debug-next-20150123.html [2] http://storage.kernelci.org/debug/mm/arndale-no-lpae-debug-next-20150123.html Cheers, Tyler Tested-by: Tyler Baker --- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/include/linux/mm.h b/include/linux/mm.h index 1fbd0e8..e5b0444 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -1455,11 +1455,17 @@ static inline unsigned long mm_nr_pmds(struct mm_struct *mm) static inline void mm_inc_nr_pmds(struct mm_struct *mm) { atomic_long_inc(&mm->nr_pmds); + dump_stack(); + printk(KERN_INFO "===> %s nr_pmds %ld\n", __func__, + atomic_long_read(&mm->nr_pmds)); } static inline void mm_dec_nr_pmds(struct mm_struct *mm) { atomic_long_dec(&mm->nr_pmds); + dump_stack(); + printk(KERN_INFO "===> %s nr_pmds %ld\n", __func__, + atomic_long_read(&mm->nr_pmds)); } #endif diff --git a/mm/mmap.c b/mm/mmap.c index 6a7d36d..a16471f 100644 --- a/mm/mmap.c +++ b/mm/mmap.c @@ -2809,6 +2809,7 @@ EXPORT_SYMBOL(vm_brk); /* Release all mmaps. */ void exit_mmap(struct mm_struct *mm) { + printk(KERN_INFO "===> %s exit_mmap enter\n", __func__); struct mmu_gather tlb; struct vm_area_struct *vma; unsigned long nr_accounted = 0;