From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.5 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_PASS, URIBL_BLOCKED,USER_AGENT_MUTT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 658D2C43381 for ; Tue, 26 Mar 2019 01:31:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2646F2084D for ; Tue, 26 Mar 2019 01:31:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1553563879; bh=jkAx+kty5v2H1VmV7W7HMAjMJbh3KwIEB+4/f8+km9I=; h=Date:From:To:Cc:Subject:References:In-Reply-To:List-ID:From; b=XF3UlYnNyR4qJ8JcaAx6AlJzrgZU6xGxiyjTv8v9B86qKQjFRmMEHY1Cdu2Hos0cv Jgyu+y8F+O65bRIE3cmYYWf5Efwd06f+NMgWfBpVKZi8AyzcbdKqAoPUGgqrjy0mQk tD/ysgpLKmvL3PZLk7Fhv0TD02VxSKLQguvh0DJg= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730821AbfCZBbR (ORCPT ); Mon, 25 Mar 2019 21:31:17 -0400 Received: from mail.kernel.org ([198.145.29.99]:36250 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727427AbfCZBbQ (ORCPT ); Mon, 25 Mar 2019 21:31:16 -0400 Received: from localhost (li1825-44.members.linode.com [172.104.248.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id CF1A120848; Tue, 26 Mar 2019 01:31:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1553563876; bh=jkAx+kty5v2H1VmV7W7HMAjMJbh3KwIEB+4/f8+km9I=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=P2ar99z8/QbHDBGHJuB0vlFRl4THKXFatW+qTa5LhVeM2PBWSL6ZFCrb6bZGupP+N ahILmhUTUfzH4H45hhHc6mGSffZRhq1p45CxO0u6ZeR7u2DKv0eBRePd/S95u0WTeg CVGaEt20m0JEhKlgUXgXCi6bIDmcE1yKa/Xdmxws= Date: Tue, 26 Mar 2019 10:31:09 +0900 From: Greg KH To: Arnd Bergmann Cc: stable@vger.kernel.org, Catalin Marinas , Will Deacon , Mark Rutland , "Eric W. Biederman" , Marc Zyngier , Anshuman Khandual , Andrey Konovalov , Qiao Zhou , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [BACKPORT 4.4.y 21/25] arm64: traps: disable irq in die() Message-ID: <20190326013109.GB21198@kroah.com> References: <20190322154425.3852517-1-arnd@arndb.de> <20190322154425.3852517-22-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190322154425.3852517-22-arnd@arndb.de> User-Agent: Mutt/1.11.4 (2019-03-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 22, 2019 at 04:44:12PM +0100, Arnd Bergmann wrote: > From: Qiao Zhou > > In current die(), the irq is disabled for __die() handle, not > including the possible panic() handling. Since the log in __die() > can take several hundreds ms, new irq might come and interrupt > current die(). > > If the process calling die() holds some critical resource, and some > other process scheduled later also needs it, then it would deadlock. > The first panic will not be executed. > > So here disable irq for the whole flow of die(). > > Signed-off-by: Qiao Zhou > Signed-off-by: Will Deacon > (cherry picked from commit 6f44a0bacb79a03972c83759711832b382b1b8ac) > Signed-off-by: Arnd Bergmann > --- > arch/arm64/kernel/traps.c | 8 ++++++-- > 1 file changed, 6 insertions(+), 2 deletions(-) also added to 4.9.y From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.5 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_PASS, URIBL_BLOCKED,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3E865C43381 for ; Tue, 26 Mar 2019 01:31:38 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0E11B20848 for ; Tue, 26 Mar 2019 01:31:37 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="LgzPzkG/"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="P2ar99z8" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0E11B20848 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linuxfoundation.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ciDguGZnLK9a1P3D/tjDy4Fb4/O7zH9HqFlk14XUiNQ=; b=LgzPzkG/mP0X/+ KPUFqHd9zDE5CiRGNE5S48DTJBM7Hm8bANhvfZ2gjU/zGX5T7m4kqPjW8b5DQ2aB+JibDpAyiA+w/ trqJ/DXyosrdKwUtsHT4eR2GmNtyJCpQqeKKubYk4uwfLX5ZW22dqSVagVgZT2VyISI8BqG1InTNz cv84r1q1+ihFRi+5vEBUzloGG91Dhcn14eYY1Qe5mJBXAlI6dfke1LCJ9JFfzsurJ93DH69cYnQCS WOKdV3ou3HBsXLN3YcpcfY+Wf8s8aRtvudIdae7d94g946hzZxnAiioU2bcM5SsEiKUxvoXy664az gDROwVce1jbryy2ecIow==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1h8aw1-0003a6-K2; Tue, 26 Mar 2019 01:31:25 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h8avx-0003Z8-Ko for linux-arm-kernel@lists.infradead.org; Tue, 26 Mar 2019 01:31:23 +0000 Received: from localhost (li1825-44.members.linode.com [172.104.248.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id CF1A120848; Tue, 26 Mar 2019 01:31:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1553563876; bh=jkAx+kty5v2H1VmV7W7HMAjMJbh3KwIEB+4/f8+km9I=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=P2ar99z8/QbHDBGHJuB0vlFRl4THKXFatW+qTa5LhVeM2PBWSL6ZFCrb6bZGupP+N ahILmhUTUfzH4H45hhHc6mGSffZRhq1p45CxO0u6ZeR7u2DKv0eBRePd/S95u0WTeg CVGaEt20m0JEhKlgUXgXCi6bIDmcE1yKa/Xdmxws= Date: Tue, 26 Mar 2019 10:31:09 +0900 From: Greg KH To: Arnd Bergmann Subject: Re: [BACKPORT 4.4.y 21/25] arm64: traps: disable irq in die() Message-ID: <20190326013109.GB21198@kroah.com> References: <20190322154425.3852517-1-arnd@arndb.de> <20190322154425.3852517-22-arnd@arndb.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20190322154425.3852517-22-arnd@arndb.de> User-Agent: Mutt/1.11.4 (2019-03-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190325_183121_708701_04F1186F X-CRM114-Status: GOOD ( 14.40 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Qiao Zhou , Anshuman Khandual , Marc Zyngier , Catalin Marinas , Will Deacon , linux-kernel@vger.kernel.org, stable@vger.kernel.org, "Eric W. Biederman" , Andrey Konovalov , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Mar 22, 2019 at 04:44:12PM +0100, Arnd Bergmann wrote: > From: Qiao Zhou > > In current die(), the irq is disabled for __die() handle, not > including the possible panic() handling. Since the log in __die() > can take several hundreds ms, new irq might come and interrupt > current die(). > > If the process calling die() holds some critical resource, and some > other process scheduled later also needs it, then it would deadlock. > The first panic will not be executed. > > So here disable irq for the whole flow of die(). > > Signed-off-by: Qiao Zhou > Signed-off-by: Will Deacon > (cherry picked from commit 6f44a0bacb79a03972c83759711832b382b1b8ac) > Signed-off-by: Arnd Bergmann > --- > arch/arm64/kernel/traps.c | 8 ++++++-- > 1 file changed, 6 insertions(+), 2 deletions(-) also added to 4.9.y _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel