Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp2157411pxy; Sat, 24 Apr 2021 06:53:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxOI4kRxQgsyltt+L7SLWuxasVVRfc0VRzVF+URUl9rTXlzuN8GiIkjGA5ubZIuqTV+zfad X-Received: by 2002:aa7:c9cb:: with SMTP id i11mr10462442edt.331.1619272405959; Sat, 24 Apr 2021 06:53:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619272405; cv=none; d=google.com; s=arc-20160816; b=i5ddKnVu7dtnPzULBquaVIMD8x2rsYeKxu3LSTgK/TjfSlPhv+3YR7Zjv9D0rodOZz ZYitI+HsgMM6SjSffVze2trtlQ8Pqf5oU0sp/W38BlBbhW1taShSvAxOF3AnKwMBs2vc 5iwzsiqK96hFRDjcIukmU9Tahppjx5+dW3dEnbv96yioha6o6dWL1mqH/Bz177eklA+C WFukOnFSOxhQ9nCMm7I+EH5/9LBVUuKa1dBf8mKjakjbzBoZjypmfO6QCm659MaKcb9t gTYwcc1v5VcjW+O9hEziDA43CXZlPat1khqqFX5tgG03xvVc/XzlYCR/Jms7xPTA+BEz 6xxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=jCOp7RZ+iu6cfzLw/VonyR2hYz8LTHhRBEdxzPYuVcg=; b=JVFSyTn7FcPJg9pb8kRj3LlKpp85Ur7Oe1u/OsBKTMllvk0y6HZMdXnjucpXUqQwjk EbV3WZG7czzmSjKOt7/t2/lffferP6vcpwDzfUCOQz9dhbF9k4J9ABNt8Pp43EyesGNt IRMXDA3m9Wy0ggDgs8kJHpVWNlUIaKAZXoXsKbQ89o2GJ0E4V9bl9eH3XPYuSMHA0t3e XWhYxWVMpoDuN5rMM6qeSpmGMGnAUstNQcgpA0vCmTaZHYKbLxl5ubcC2qcf8z6B6tlV t4Iztqtj+VguVi5kfsEN8JpfyuhPJ8Q4igRd/0t6DHVZLFx/q02XymLmx72IFlwDzjtu 8SGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=XzK4dnfU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ay25si8202275edb.80.2021.04.24.06.53.00; Sat, 24 Apr 2021 06:53:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=XzK4dnfU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237348AbhDXNwg (ORCPT + 99 others); Sat, 24 Apr 2021 09:52:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35644 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231836AbhDXNwf (ORCPT ); Sat, 24 Apr 2021 09:52:35 -0400 Received: from mail-lf1-x134.google.com (mail-lf1-x134.google.com [IPv6:2a00:1450:4864:20::134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 41D4CC061574 for ; Sat, 24 Apr 2021 06:51:57 -0700 (PDT) Received: by mail-lf1-x134.google.com with SMTP id 12so81330326lfq.13 for ; Sat, 24 Apr 2021 06:51:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=jCOp7RZ+iu6cfzLw/VonyR2hYz8LTHhRBEdxzPYuVcg=; b=XzK4dnfUjaa18YTv5ERftP59UulNix2QP1HZGGPY7zmpnt+C2OBLGwsn2qCXHIlt9h 53Tz6YR+Cfb7/Oa4RnaMsiSFxCgFt7mGpRi59uxVfarHRhx54VJe9oQYscLkZvGm8XAd ZxLHtbZQkp92s+8Hz0bxzlDDyJbR1xITI4j2TphaCDiNo9Q424354c7k93C1enUBwAX3 WVtNnI5Vpla+dLynsdWqW6uEOhJWjZSF5AItV9PZdnJR6iFjhq8M1qDEjkf74Ep77wfq 5ONu4xgqi5fhP2tLH3fDqv0/JfdO1cNKH960kGxjjscKrbwDtyYf1Ztm+s8W/OgX6/yg LKjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=jCOp7RZ+iu6cfzLw/VonyR2hYz8LTHhRBEdxzPYuVcg=; b=CeQVs6sZGNMAy9w0RK1e6XEII8s//9/V+rQ8yrI8T99NVfSg9oCSvn9Ef2L+vQXmrp GrF3eLuLCg1OEi7QSBdNsFTlp1cSZqOM77zLZbFnMKeLnDhKoQloYrMUcAJQHr+XIXRN nsn+eYki/LImAWEMp9LFm42fLinQtbx2H944cpy41kgq6gVHnwIaBWfzfH8MJ0A5pjnI sqCoKMoRlWPb8x28r7nlrxyWVvJcPBL4v47+lsZRYwg/8duhoFSu1ngI7q/KbZhF8bud bnhb+F454M58U0lPMneIVBdxcTlXdVpr+tfDRcFOG6yvREuqXhCWhj4RmBVX3JGZ2vjr stZA== X-Gm-Message-State: AOAM533RzR8Ql5+5q0zP6oTWMHGEbwjo9+nI1MM/xrprbISA2rDjCNoZ JtTUWTi0ub1EwZoSeqVXtBIubP8zFXAstGmb2+U= X-Received: by 2002:ac2:5042:: with SMTP id a2mr6027441lfm.650.1619272314835; Sat, 24 Apr 2021 06:51:54 -0700 (PDT) MIME-Version: 1.0 References: <20210422151022.17868-1-sxwjean@me.com> <20210422151022.17868-2-sxwjean@me.com> In-Reply-To: From: Xiongwei Song Date: Sat, 24 Apr 2021 21:51:28 +0800 Message-ID: Subject: Re: [PATCH 2/2] powerpc: Print esr register when hitting Program Interrupt To: Christophe Leroy Cc: Xiongwei Song , Michael Ellerman , Benjamin Herrenschmidt , Paul Mackerras , npiggin@gmail.com, ravi.bangoria@linux.ibm.com, mikey@neuling.org, aneesh.kumar@linux.ibm.com, 0x7f454c46@gmail.com, PowerPC , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 22, 2021 at 11:29 PM Christophe Leroy wrote: > > > > Le 22/04/2021 =C3=A0 17:10, Xiongwei Song a =C3=A9crit : > > From: Xiongwei Song > > > > The esr register has the details of Program Interrupt on BookE/4xx cpus= , > > printing its value is helpful. > > > > Signed-off-by: Xiongwei Song > > --- > > arch/powerpc/kernel/process.c | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/proces= s.c > > index 5c3830837f3a..664aecf8ee2e 100644 > > --- a/arch/powerpc/kernel/process.c > > +++ b/arch/powerpc/kernel/process.c > > @@ -1459,6 +1459,7 @@ static bool interrupt_detail_printable(int trap) > > case INTERRUPT_MACHINE_CHECK: > > case INTERRUPT_DATA_STORAGE: > > case INTERRUPT_ALIGNMENT: > > + case INTERRUPT_PROGRAM: > > With this, it will also print the DSISR on 8xx/6xx so it will print garba= ge. > > 8xx/6xx provide the information in SRR1. If you want to proceed, you have= to do the same as in ISI: > Copy the content of SRR1 into regs->dsisr in the assembly handler in head= _book3s_32.S and in the > instruction TLB error handler in head_8xx.S Good point.