mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
To: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>,
	Rob Clark <robin.clark@oss.qualcomm.com>,
	Sean Paul <sean@poorly.run>,
	Konrad Dybcio <konradybcio@kernel.org>,
	Akhil P Oommen <akhilpo@oss.qualcomm.com>,
	Dmitry Baryshkov <lumag@kernel.org>,
	Abhinav Kumar <abhinav.kumar@linux.dev>,
	Jessica Zhang <jesszhan0024@gmail.com>,
	Marijn Suijten <marijn.suijten@somainline.org>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>
Cc: linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org,
	freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] drm/msm/a3xx: report CP protected mode faults
Date: Tue, 17 Nov 2026 16:53:34 +0100	[thread overview]
Message-ID: <079897df-fa2c-4ba0-bd45-7b357783b0a8@oss.qualcomm.com> (raw)
In-Reply-To: <20261111-a3xx-fix-me-v1-1-d81f50f1ba1e@oss.qualcomm.com>



On 11-Nov-26 14:05, Dmitry Baryshkov wrote:
> a3xx_irq() acks every interrupt without looking at it, so a write to a
> protected register shows up only as a hangcheck timeout with no hint of
> which register was hit. Print the faulting address the way a4xx and a5xx
> already do.
> 
> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
> ---
>  drivers/gpu/drm/msm/adreno/a3xx_gpu.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/msm/adreno/a3xx_gpu.c b/drivers/gpu/drm/msm/adreno/a3xx_gpu.c
> index 160d302e16a3..7e03b7305493 100644
> --- a/drivers/gpu/drm/msm/adreno/a3xx_gpu.c
> +++ b/drivers/gpu/drm/msm/adreno/a3xx_gpu.c
> @@ -419,7 +419,14 @@ static irqreturn_t a3xx_irq(struct msm_gpu *gpu)
>  	status = gpu_read(gpu, REG_A3XX_RBBM_INT_0_STATUS);
>  	DBG("%s: %08x", gpu->name, status);
>  
> -	// TODO
> +	if (status & A3XX_INT0_CP_REG_PROTECT_FAULT) {
> +		u32 val = gpu_read(gpu, REG_A3XX_CP_PROTECT_STATUS);
> +
> +		dev_err_ratelimited(gpu->dev->dev,
> +			"CP | protected mode error | %s | addr=0x%8.8X | status=0x%8.8X\n",
> +			val & (1 << 24) ? "WRITE" : "READ",
> +			(val & 0xFFFFF) >> 2, val);

I would really like BIT/GENMASK here..

Konrad

  reply	other threads:[~2026-11-17 15:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-11 13:05 [PATCH 0/3] drm/msm/a3xx: follow the msm-3.10 kgsl CP setup Dmitry Baryshkov
2026-11-11 13:05 ` [PATCH 1/3] drm/msm/a3xx: report CP protected mode faults Dmitry Baryshkov
2026-11-17 15:53   ` Konrad Dybcio [this message]
2026-11-11 13:05 ` [PATCH 2/3] drm/msm/a3xx: update the CP protected register ranges Dmitry Baryshkov
2026-11-11 13:05 ` [PATCH 3/3] drm/msm/a3xx: update the CP_ME_INIT data to msm-3.10 Dmitry Baryshkov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=079897df-fa2c-4ba0-bd45-7b357783b0a8@oss.qualcomm.com \
    --to=konrad.dybcio@oss.qualcomm.com \
    --cc=abhinav.kumar@linux.dev \
    --cc=airlied@gmail.com \
    --cc=akhilpo@oss.qualcomm.com \
    --cc=dmitry.baryshkov@oss.qualcomm.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=freedreno@lists.freedesktop.org \
    --cc=jesszhan0024@gmail.com \
    --cc=konradybcio@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lumag@kernel.org \
    --cc=marijn.suijten@somainline.org \
    --cc=robin.clark@oss.qualcomm.com \
    --cc=sean@poorly.run \
    --cc=simona@ffwll.ch \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®