devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Konrad Dybcio <konradybcio@kernel.org>
To: Luca Weiss <luca.weiss@fairphone.com>,
	Konrad Dybcio <konradybcio@kernel.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	cros-qcom-dts-watchers@chromium.org
Cc: Marijn Suijten <marijn.suijten@somainline.org>,
	linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Konrad Dybcio <quic_kdybcio@quicinc.com>
Subject: Re: [PATCH RFC 07/11] arm64: dts: qcom: sm6350: Affirm IDR0.CCTW on apps_smmu
Date: Tue, 24 Sep 2024 12:04:10 +0200	[thread overview]
Message-ID: <2a1b199b-b426-4895-be8f-2b7629e84fcd@kernel.org> (raw)
In-Reply-To: <D4ECC1Y7MLX2.2072IIRC7SJV3@fairphone.com>

On 24.09.2024 9:37 AM, Luca Weiss wrote:
> On Tue Sep 24, 2024 at 9:15 AM CEST, Luca Weiss wrote:
>> On Thu Sep 19, 2024 at 12:57 AM CEST, Konrad Dybcio wrote:
>>> From: Konrad Dybcio <quic_kdybcio@quicinc.com>
>>>
>>> On RPMh-based SoCs, the APPS SMMU advertizes support for cache-coherent
>>> pagetable walk via the IDR0 register. This however is not respected by
>>> the arm-smmu driver unless dma-coherent is set.
>>>
>>> Mark the node as dma-coherent to ensure this (and other) implementations
>>> take this coherency into account.
>>
>> Hi Konrad!
>>
>> Similar to [0] everything seems to look fine on SM7225 Fairphone 4.
>>
>> [    0.190433] arm-smmu 15000000.iommu: probing hardware configuration...
>> [    0.190459] arm-smmu 15000000.iommu: SMMUv2 with:
>> [    0.190499] arm-smmu 15000000.iommu:         stage 1 translation
>> [    0.190515] arm-smmu 15000000.iommu:         coherent table walk
>> [    0.190531] arm-smmu 15000000.iommu:         stream matching with 71 register groups
>> [    0.190560] arm-smmu 15000000.iommu:         63 context banks (0 stage-2 only)
>> [    0.191097] arm-smmu 15000000.iommu:         Supported page sizes: 0x61311000
>> [    0.191114] arm-smmu 15000000.iommu:         Stage-1: 36-bit VA -> 36-bit IPA
>> [    0.191299] arm-smmu 15000000.iommu:         preserved 0 boot mappings
>>
>> The Adreno SMMU still has non-coherent table walk.
>>
>> [    1.141215] arm-smmu 3d40000.iommu: probing hardware configuration...
>> [    1.141243] arm-smmu 3d40000.iommu: SMMUv2 with:
>> [    1.141270] arm-smmu 3d40000.iommu:  stage 1 translation
>> [    1.141279] arm-smmu 3d40000.iommu:  address translation ops
>> [    1.141288] arm-smmu 3d40000.iommu:  non-coherent table walk
>> [    1.141296] arm-smmu 3d40000.iommu:  (IDR0.CTTW overridden by FW configuration)
>> [    1.141307] arm-smmu 3d40000.iommu:  stream matching with 5 register groups
>> [    1.141326] arm-smmu 3d40000.iommu:  5 context banks (0 stage-2 only)
>> [    1.141347] arm-smmu 3d40000.iommu:  Supported page sizes: 0x63315000
>> [    1.141356] arm-smmu 3d40000.iommu:  Stage-1: 48-bit VA -> 36-bit IPA
>> [    1.141568] arm-smmu 3d40000.iommu:  preserved 0 boot mappings
>>
>>
>> Tested-by: Luca Weiss <luca.weiss@fairphone.com> # sm7225-fairphone-fp4
>>
>> [0] https://lore.kernel.org/linux-arm-msm/CAD=FV=Xrbe1NO+trk1SJ30gHm5jLFjd0bAeG3H46gD+vNFZa1w@mail.gmail.com/
> 
> FWIW adding 'dma-coherent;' to &adreno_smmu also doesn't seem to
> explode:
> 
> [    1.451965] arm-smmu 3d40000.iommu: probing hardware configuration...
> [    1.455547] arm-smmu 3d40000.iommu: SMMUv2 with:
> [    1.459041] arm-smmu 3d40000.iommu:  stage 1 translation
> [    1.462446] arm-smmu 3d40000.iommu:  address translation ops
> [    1.465843] arm-smmu 3d40000.iommu:  coherent table walk
> [    1.469216] arm-smmu 3d40000.iommu:  stream matching with 5 register groups
> [    1.472645] arm-smmu 3d40000.iommu:  5 context banks (0 stage-2 only)
> [    1.476067] arm-smmu 3d40000.iommu:  Supported page sizes: 0x63315000
> [    1.479458] arm-smmu 3d40000.iommu:  Stage-1: 48-bit VA -> 36-bit IPA
> [    1.483152] arm-smmu 3d40000.iommu:  preserved 0 boot mappings
> 
> And kmscube still runs as expected.

Thanks, I'll look into adreno separately

Konrad

  reply	other threads:[~2024-09-24 10:04 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-18 22:57 [RFC PATCH 00/11] Affirm SMMU coherent pagetable walker capability on RPMh SoCs Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 01/11] arm64: dts: qcom: qdu1000: Affirm IDR0.CCTW on apps_smmu Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 02/11] arm64: dts: qcom: sc7180: " Konrad Dybcio
2024-09-20 13:44   ` Doug Anderson
2024-09-18 22:57 ` [PATCH RFC 03/11] arm64: dts: qcom: sc8180x: " Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 04/11] arm64: dts: qcom: sc8280xp: " Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 05/11] arm64: dts: qcom: sdm670: " Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 06/11] arm64: dts: qcom: sdm845: " Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 07/11] arm64: dts: qcom: sm6350: " Konrad Dybcio
2024-09-24  7:15   ` Luca Weiss
2024-09-24  7:37     ` Luca Weiss
2024-09-24 10:04       ` Konrad Dybcio [this message]
2024-09-18 22:57 ` [PATCH RFC 08/11] arm64: dts: qcom: sm8150: " Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 09/11] arm64: dts: qcom: sm8350: " Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 10/11] arm64: dts: qcom: sm8450: " Konrad Dybcio
2024-09-18 22:57 ` [PATCH RFC 11/11] arm64: dts: qcom: x1e80100: " Konrad Dybcio
2024-09-19  7:00 ` [RFC PATCH 00/11] Affirm SMMU coherent pagetable walker capability on RPMh SoCs Luca Weiss
2024-09-19 10:07   ` Konrad Dybcio
2024-09-19 18:48     ` Steev Klimaszewski
2024-09-20  7:35 ` neil.armstrong
2024-10-07 14:25 ` Bjorn Andersson

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=2a1b199b-b426-4895-be8f-2b7629e84fcd@kernel.org \
    --to=konradybcio@kernel.org \
    --cc=andersson@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=cros-qcom-dts-watchers@chromium.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luca.weiss@fairphone.com \
    --cc=marijn.suijten@somainline.org \
    --cc=quic_kdybcio@quicinc.com \
    --cc=robh@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;
as well as URLs for NNTP newsgroup(s).