From patchwork Thu Jan 14 20:11:09 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Grygorii Strashko X-Patchwork-Id: 8035311 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 14BF6BEEE5 for ; Thu, 14 Jan 2016 20:13:27 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2F814204E0 for ; Thu, 14 Jan 2016 20:13:26 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4F596204DE for ; Thu, 14 Jan 2016 20:13:25 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1aJoFH-0001G6-CK; Thu, 14 Jan 2016 20:11:47 +0000 Received: from arroyo.ext.ti.com ([192.94.94.40]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1aJoFD-0001Es-RT for linux-arm-kernel@lists.infradead.org; Thu, 14 Jan 2016 20:11:44 +0000 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id u0EKBCwZ017066; Thu, 14 Jan 2016 14:11:12 -0600 Received: from DLEE71.ent.ti.com (dlee71.ent.ti.com [157.170.170.114]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id u0EKBCY6012382; Thu, 14 Jan 2016 14:11:12 -0600 Received: from dflp32.itg.ti.com (10.64.6.15) by DLEE71.ent.ti.com (157.170.170.114) with Microsoft SMTP Server id 14.3.224.2; Thu, 14 Jan 2016 14:11:11 -0600 Received: from [172.22.235.13] (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id u0EKBAFQ025324; Thu, 14 Jan 2016 14:11:10 -0600 Subject: Re: [4.4-rc6-rt1 PATCH 0/2] ARM: am437x: boot test report To: Sebastian Andrzej Siewior References: <1451325611-21678-1-git-send-email-grygorii.strashko@ti.com> <20160112171556.GB31009@linutronix.de> <569637ED.1030304@ti.com> <5696B025.8020909@ti.com> From: Grygorii Strashko Message-ID: <569800DD.7090102@ti.com> Date: Thu, 14 Jan 2016 22:11:09 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 In-Reply-To: <5696B025.8020909@ti.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160114_121144_009583_44B4B646 X-CRM114-Status: GOOD ( 17.98 ) X-Spam-Score: -6.9 (------) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sekhar Nori , linux-rt-users@vger.kernel.org, linux-arm , linux-kernel@vger.kernel.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi Sebastian, On 01/13/2016 10:14 PM, Grygorii Strashko wrote: > On 01/13/2016 01:41 PM, Grygorii Strashko wrote: >> On 01/12/2016 07:15 PM, Sebastian Andrzej Siewior wrote: >>> * Grygorii Strashko | 2015-12-28 20:00:09 [+0200]: >>> >>> >>>> 3) Seems there are some problem with HIGHMEM :(. System crashes if I'm trying >>>> to run hackbench (see log 1). I can run hackbench only if HIGHMEM is disabled. >>>> I've also tried to disable CONFIG_CPU_SW_DOMAIN_PAN, CONFIG_ARM_PATCH_PHYS_VIRT, >>>> and CONFIG_CPUSETS, before disabling HIGHMEM. >>>> Sorry, I'll not able to investigate it further because of Christmas holidays here. >>> >>> I see. It seems not to trigger anything on x86. >> >> Yah. I saw other reports - it seems this issue is not triggered on ARM SMP also >> (as per report from Tim Sander). Will try to dig deeper. >> > > I did more tests, but still don't know what is wrong. > 1) vanilla 4.4 - no issue > 2) 4.4-rt: CONFIG_PREEMPT_RT_BASE=n and CONFIG_PREEMPT_RT_FULL=n -- no issue > 3) 4.4-rt: CONFIG_DEBUG_HIGHMEM=y -- issue is present log1 > 4) 4.4-rt: this is interesting ;) > I can run hackbench few times without issues If I run hackbench with RT priority (log2) > But I got crash immediately once I run it using non-RT priorities. Seems I've found root cause of the issue - FIX_KMAP_BEGIN offset need to be taken into account in switch_kmaps() and below diff fixes this issue for me. What I'm not fully understand is why I'm the only one who hit this issue :( New functionality was added by commit: commit a5f4c561b3b19a9bc43a81da6382b0098ebbc1fb ARM: 8415/1: early fixmap support for earlycon and it is enabled by default. Luckiness :( diff --git a/arch/arm/mm/highmem.c b/arch/arm/mm/highmem.c index deabc36..b9b4f9c 100644 --- a/arch/arm/mm/highmem.c +++ b/arch/arm/mm/highmem.c @@ -167,7 +167,7 @@ void switch_kmaps(struct task_struct *prev_p, struct task_struct *next_p) * Clear @prev's kmap_atomic mappings */ for (i = 0; i < prev_p->kmap_idx; i++) { - int idx = i + KM_TYPE_NR * smp_processor_id(); + int idx = FIX_KMAP_BEGIN + i + KM_TYPE_NR * smp_processor_id(); set_fixmap_pte(idx, __pte(0)); } @@ -175,7 +175,7 @@ void switch_kmaps(struct task_struct *prev_p, struct task_struct *next_p) * Restore @next_p's kmap_atomic mappings */ for (i = 0; i < next_p->kmap_idx; i++) { - int idx = i + KM_TYPE_NR * smp_processor_id(); + int idx = FIX_KMAP_BEGIN + i + KM_TYPE_NR * smp_processor_id(); if (!pte_none(next_p->kmap_pte[i])) set_fixmap_pte(idx, next_p->kmap_pte[i]);