From: Rob Clark <robdclark@gmail.com>
To: dri-devel@lists.freedesktop.org
Cc: "Yangtao Li" <tiny.windzz@gmail.com>,
"Konrad Dybcio" <konrad.dybcio@somainline.org>,
"Akhil P Oommen" <akhilpo@codeaurora.org>,
"open list" <linux-kernel@vger.kernel.org>,
"Will Deacon" <will@kernel.org>,
"Rob Clark" <robdclark@chromium.org>,
"Jonathan Marek" <jonathan@marek.ca>,
"Joerg Roedel" <jroedel@suse.de>,
"open list:DRM DRIVER FOR MSM ADRENO GPU"
<linux-arm-msm@vger.kernel.org>,
"Sharat Masetty" <smasetty@codeaurora.org>,
"Stephen Boyd" <swboyd@chromium.org>,
linux-arm-kernel@lists.infradead.org,
"Isaac J. Manjarres" <isaacm@codeaurora.org>,
"Robin Murphy" <robin.murphy@arm.com>,
"Douglas Anderson" <dianders@chromium.org>,
"open list:IOMMU DRIVERS" <iommu@lists.linux-foundation.org>,
freedreno@lists.freedesktop.org,
"Christian König" <christian.koenig@amd.com>
Subject: [PATCH v2 0/3] io-pgtable-arm + drm/msm: Extend iova fault debugging
Date: Tue, 5 Oct 2021 08:16:24 -0700 [thread overview]
Message-ID: <20211005151633.1738878-1-robdclark@gmail.com> (raw)
From: Rob Clark <robdclark@chromium.org>
This series extends io-pgtable-arm with a method to retrieve the page
table entries traversed in the process of address translation, and then
beefs up drm/msm gpu devcore dump to include this (and additional info)
in the devcore dump.
The motivation is tracking down an obscure iova fault triggered crash on
the address of the IB1 cmdstream. This is one of the few places where
the GPU address written into the cmdstream is soley under control of the
kernel mode driver, so I don't think it can be a userspace bug. The
logged cmdstream from the devcore's I've looked at look correct, and the
TTBR0 read back from arm-smmu agrees with the kernel emitted cmdstream.
Unfortunately it happens infrequently enough (something like once per
1000hrs of usage, from what I can tell from our telemetry) that actually
reproducing it with an instrumented debug kernel is not an option. So
further spiffying out the devcore dumps and hoping we can spot a clue is
the plan I'm shooting for.
See https://gitlab.freedesktop.org/drm/msm/-/issues/8 for more info on
the issue I'm trying to debug.
v2: Fix an armv7/32b build error in the last patch
Rob Clark (3):
iommu/io-pgtable-arm: Add way to debug pgtable walk
drm/msm: Show all smmu info for iova fault devcore dumps
drm/msm: Extend gpu devcore dumps with pgtbl info
drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 2 +-
drivers/gpu/drm/msm/adreno/adreno_gpu.c | 35 +++++++++++++++++-----
drivers/gpu/drm/msm/msm_gpu.c | 10 +++++++
drivers/gpu/drm/msm/msm_gpu.h | 10 ++++++-
drivers/gpu/drm/msm/msm_iommu.c | 17 +++++++++++
drivers/gpu/drm/msm/msm_mmu.h | 2 ++
drivers/iommu/io-pgtable-arm.c | 40 ++++++++++++++++++++-----
include/linux/io-pgtable.h | 9 ++++++
8 files changed, 107 insertions(+), 18 deletions(-)
--
2.31.1
_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu
next reply other threads:[~2021-10-05 15:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-05 15:16 Rob Clark [this message]
2021-10-05 15:16 ` [PATCH v2 1/3] iommu/io-pgtable-arm: Add way to debug pgtable walk Rob Clark
2021-12-14 15:37 ` Will Deacon
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=20211005151633.1738878-1-robdclark@gmail.com \
--to=robdclark@gmail.com \
--cc=akhilpo@codeaurora.org \
--cc=christian.koenig@amd.com \
--cc=dianders@chromium.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=iommu@lists.linux-foundation.org \
--cc=isaacm@codeaurora.org \
--cc=jonathan@marek.ca \
--cc=jroedel@suse.de \
--cc=konrad.dybcio@somainline.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robdclark@chromium.org \
--cc=robin.murphy@arm.com \
--cc=smasetty@codeaurora.org \
--cc=swboyd@chromium.org \
--cc=tiny.windzz@gmail.com \
--cc=will@kernel.org \
/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