From: Sebastian Reichel <sebastian.reichel@collabora.com>
To: "Heiko Stübner" <heiko@sntech.de>
Cc: aiyengar1990@gmail.com, Will Deacon <will@kernel.org>,
Robin Murphy <robin.murphy@arm.com>,
"Joerg Roedel (AMD)" <joro@8bytes.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Niklas Cassel <cassel@kernel.org>,
Shawn Lin <shawn.lin@rock-chips.com>,
linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-rockchip@lists.infradead.org,
Simon Xue <xxm@rock-chips.com>,
"finley.xiao" <finley.xiao@rock-chips.com>
Subject: Re: [PATCH 0/5] iommu/arm-smmu-v3: power domain and clock of the RK3588 PCIe SMMU
Date: Thu, 12 Nov 2026 04:50:53 +0100 [thread overview]
Message-ID: <avU2I_QzCiBPVTDC@venus> (raw)
In-Reply-To: <9_7qTfdNSViwtNUGq9D13w@sntech.de>
[-- Attachment #1.1: Type: text/plain, Size: 3389 bytes --]
Hi,
On Wed, Nov 11, 2026 at 10:53:28AM +0100, Heiko Stübner wrote:
> Am Mittwoch, 11. November 2026, 09:02:30 Mitteleuropäische Normalzeit schrieb Shawn Lin:
> > Hi Heiko
> >
> > 在 2026/11/10 星期二 16:49, Heiko Stübner 写道:
> > > Am Dienstag, 10. November 2026, 09:40:44 Mitteleuropäische Normalzeit schrieb Shawn Lin:
> > >> Cc: Simon and Finley
> > >>
> > >> 在 2026/11/10 星期二 15:11, Arun Iyengar via B4 Relay 写道:
> > >>> The MMU-600 in front of the PCIe controllers of the Rockchip RK3588
> > >>> (mmu600_pcie) is enabled for every RK3588 board, but its node describes
> > >>> neither the power domain it lives in (RK3588_PD_PCIE) nor its clock
> > >>> (ACLK_MMU_PCIE). Both are held by any enabled PCIe controller, which is
> > >>> why nobody noticed: on a board that enables no PCIe controller in that
> > >>> domain (an Orange Pi 5 with its M.2 slot in SATA mode, or any RK3588
> > >>> board without PCIe), genpd powers the domain off and the clock framework
> > >>> gates the clock as unused after boot, while arm-smmu-v3 stays bound.
> > >>> At reboot, arm_smmu_device_shutdown() then writes CR0 and polls CR0ACK on
> > >>> the dead block, the interconnect stalls, "reboot: Restarting system" is
> > >>> never reached and the board only comes back ~90 s later when the
> > >>> watchdog fires.
> > >
> > > We have a work-around for that in some boards, manually disabling the
> > > smmu until now. As the SMMU is part of the SoC and always present
> > > the general DT practice is to have it always enabled, as it does not
> > > depend on the actual board design.
> > >
> > > Hence we end up in the situation described above.
> > >
> >
> > I notice that mmu600_php is disabled in rk3588-base.dtsi. If describing
> > the SMMU that way is incorrect, should we enable mmu600_php as well? I'm
> > asking because I see a different picture in the RK3588 TRM: both
> > mmu600_php and mmu600_pcie reside under PD_PHP, not PD_PCIE. Therefore,
> > even without any PCIe controller enabled, PD_PHP should remain powered
> > on (it is never added in rk3588-base.dtsi, so it should be outside the
> > kernel’s scope). How does the original problem occur in that case?
>
> The original problem is the smmu probing (probably during boot when
> everything is still powered), not doing anything with it and on shutdown
> the smmu driver wanting to access the smmu registers and thus ending
> in a hang.
>
> So the problem is not necessarily the power-domain, but can also be
> the clocks getting turned off during clk_disable_unused.
>
>
> As for not disabling it, the case is also the some for things like the
> video-encoders - they are also present all the time, so we don't have
> devicetree wiggling for them.
>
> The fully correct thing would be, power-domain + clock handling
> and adding runtime-pm to the smmu for when it is not in use.
> So this would then not require any special thinking
>
> And yes, I think the other smmu should also use the same handling.
>
> @Arun care to also add a runtime-pm patch? :-)
Adding runtime PM support is already WIP:
https://lore.kernel.org/all/20260929034510.2023173-1-praan@google.com/
(this is also needed to avoid potential crashes with system
suspend/resume on RK3588, since we enable PCIe IOMMU by default)
Greetings,
-- Sebastian
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
[-- Attachment #2: Type: text/plain, Size: 170 bytes --]
_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip
next prev parent reply other threads:[~2026-11-12 3:51 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-10 7:11 [PATCH 0/5] iommu/arm-smmu-v3: power domain and clock of the RK3588 PCIe SMMU Arun Iyengar via B4 Relay
2026-11-10 7:11 ` [PATCH 1/5] dt-bindings: iommu: arm,smmu-v3: allow a power domain Arun Iyengar via B4 Relay
2026-11-10 14:51 ` Sebastian Reichel
2026-11-10 7:11 ` [PATCH 2/5] dt-bindings: iommu: arm,smmu-v3: allow clocks Arun Iyengar via B4 Relay
2026-11-10 14:55 ` Sebastian Reichel
2026-11-10 7:11 ` [PATCH 3/5] iommu/arm-smmu-v3: enable optional clocks Arun Iyengar via B4 Relay
2026-11-10 14:53 ` Sebastian Reichel
2026-11-10 7:11 ` [PATCH 4/5] arm64: dts: rockchip: add the PCIe power domain to the RK3588 PCIe SMMU Arun Iyengar via B4 Relay
2026-11-10 15:00 ` Sebastian Reichel
2026-11-11 6:53 ` Shawn Lin
2026-11-10 7:11 ` [PATCH 5/5] arm64: dts: rockchip: add the clock of " Arun Iyengar via B4 Relay
2026-11-10 15:07 ` Sebastian Reichel
2026-11-10 8:40 ` [PATCH 0/5] iommu/arm-smmu-v3: power domain and " Shawn Lin
2026-11-10 8:49 ` Heiko Stübner
2026-11-11 8:02 ` Shawn Lin
2026-11-11 9:53 ` Heiko Stübner
2026-11-12 3:50 ` Sebastian Reichel [this message]
2026-11-10 15:13 ` Sebastian Reichel
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=avU2I_QzCiBPVTDC@venus \
--to=sebastian.reichel@collabora.com \
--cc=aiyengar1990@gmail.com \
--cc=cassel@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=finley.xiao@rock-chips.com \
--cc=heiko@sntech.de \
--cc=iommu@lists.linux.dev \
--cc=joro@8bytes.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=robh@kernel.org \
--cc=robin.murphy@arm.com \
--cc=shawn.lin@rock-chips.com \
--cc=will@kernel.org \
--cc=xxm@rock-chips.com \
/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