From: Johan Hovold <johan@kernel.org>
To: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Cc: "Krzysztof Kozlowski" <krzysztof.kozlowski@linaro.org>,
"Johan Hovold" <johan+linaro@kernel.org>,
"Bjorn Andersson" <andersson@kernel.org>,
"Bjorn Helgaas" <bhelgaas@google.com>,
"Konrad Dybcio" <konrad.dybcio@linaro.org>,
"Lorenzo Pieralisi" <lpieralisi@kernel.org>,
"Krzysztof Wilczyński" <kw@linux.com>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzysztof.kozlowski+dt@linaro.org>,
"Conor Dooley" <conor+dt@kernel.org>,
linux-arm-msm@vger.kernel.org, linux-pci@vger.kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 02/10] dt-bindings: PCI: qcom: Do not require 'msi-map-mask'
Date: Wed, 21 Feb 2024 11:30:58 +0100 [thread overview]
Message-ID: <ZdXQ4h03J9pi81Vq@hovoldconsulting.com> (raw)
In-Reply-To: <20240221052607.GB11693@thinkpad>
On Wed, Feb 21, 2024 at 10:56:07AM +0530, Manivannan Sadhasivam wrote:
> On Tue, Feb 20, 2024 at 08:41:25AM +0100, Johan Hovold wrote:
> > On Fri, Feb 16, 2024 at 10:24:06PM +0530, Manivannan Sadhasivam wrote:
> > > msi-map-mask is definitely needed as it would allow all the devices under the
> > > same bus to reuse the MSI identifier. Currently, excluding this property will
> > > not cause any issue since there is a single device under each bus. But we cannot
> > > assume that is going to be the case on all boards.
> >
> > Are you saying that there is never a use case for an identity mapping?
> > Just on Qualcomm hardware or in general?
> >
> > It looks like we have a fairly large number of mainline devicetrees that
> > do use an identity mapping here (i.e. do not specify 'msi-map-mask') and
> > the binding document also has an explicit example of this.
> >
> > Documentation/devicetree/bindings/pci/pci-msi.txt
>
> I don't know how other platforms supposed to work without this property for more
> than one devices. Maybe they were not tested enough?
Seems a bit far fetched since it's also an example in the binding.
In fact, only the two Qualcomm platforms that you added 'msi-map-mask'
for use it.
> But for sure, Qcom SoCs require either per device MSI identifier or
> msi-map-mask.
But isn't the mapping set up by the boot firmware and can differ between
platforms?
The mapping on sc8280xp looks quite different from sm8450/sm8650:
msi-map = <0x0 &gic_its 0x5981 0x1>,
<0x100 &gic_its 0x5980 0x1>;
msi-map-mask = <0xff00>;
Here it's obvious that the mask is needed, whereas for sc8280xp:
msi-map = <0x0 &its 0xa0000 0x10000>;
it's not obvious what the mask should be. In fact, it looks like
Qualcomm intended a linear mapping here as the length is 0x10000 and
they left out the mask.
And after digging through the X13s ACPI tables, this is indeed how the
hardware is configured, which means that we should not use a
'msi-map-mask' property for sc8280xp and that this patch is correct.
Johan
next prev parent reply other threads:[~2024-02-21 10:30 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-12 16:50 [PATCH 00/10] arm64: dts: qcom: sc8280xp: enable GICv3 ITS for PCIe Johan Hovold
2024-02-12 16:50 ` [PATCH 01/10] dt-bindings: PCI: qcom: Allow 'required-opps' Johan Hovold
2024-02-14 11:57 ` Krzysztof Kozlowski
2024-02-14 11:57 ` Krzysztof Kozlowski
2024-02-12 16:50 ` [PATCH 02/10] dt-bindings: PCI: qcom: Do not require 'msi-map-mask' Johan Hovold
2024-02-14 12:01 ` Krzysztof Kozlowski
2024-02-14 12:54 ` Johan Hovold
2024-02-14 13:38 ` Krzysztof Kozlowski
2024-02-16 16:54 ` Manivannan Sadhasivam
2024-02-20 7:41 ` Johan Hovold
2024-02-20 8:42 ` Johan Hovold
2024-02-21 5:26 ` Manivannan Sadhasivam
2024-02-21 10:30 ` Johan Hovold [this message]
2024-02-22 3:53 ` Manivannan Sadhasivam
2024-02-12 16:50 ` [PATCH 03/10] arm64: dts: qcom: sc8280xp: add missing PCIe minimum OPP Johan Hovold
2024-02-12 16:50 ` [PATCH 04/10] arm64: dts: qcom: sc8280xp-crd: limit pcie4 link speed Johan Hovold
2024-02-15 20:47 ` Konrad Dybcio
2024-02-16 7:12 ` Johan Hovold
2024-02-16 12:04 ` Johan Hovold
2024-02-12 16:50 ` [PATCH 05/10] arm64: dts: qcom: sc8280xp-x13s: " Johan Hovold
2024-02-12 16:50 ` [PATCH 06/10] arm64: dts: qcom: sc8280xp: enable GICv3 ITS for PCIe Johan Hovold
2024-02-15 20:50 ` Konrad Dybcio
2024-02-12 16:50 ` [RFC 07/10] dt-bindings: PCI: qcom: Allow 'aspm-no-l0s' Johan Hovold
2024-02-12 16:50 ` [RFC 08/10] PCI: qcom: Add support for disabling ASPM L0s in devicetree Johan Hovold
2024-02-12 19:34 ` Bjorn Helgaas
2024-02-12 20:21 ` Johan Hovold
2024-02-12 16:50 ` [RFC 09/10] arm64: dts: qcom: sc8280xp-crd: disable ASPM L0s for NVMe Johan Hovold
2024-02-12 16:50 ` [PATCH 10/10] arm64: dts: qcom: sc8280xp-x13s: disable ASPM L0s for Wi-Fi Johan Hovold
2024-02-14 6:35 ` [PATCH 00/10] arm64: dts: qcom: sc8280xp: enable GICv3 ITS for PCIe Manivannan Sadhasivam
2024-02-14 11:09 ` Johan Hovold
2024-02-16 14:54 ` Manivannan Sadhasivam
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=ZdXQ4h03J9pi81Vq@hovoldconsulting.com \
--to=johan@kernel.org \
--cc=andersson@kernel.org \
--cc=bhelgaas@google.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=johan+linaro@kernel.org \
--cc=konrad.dybcio@linaro.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=kw@linux.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lpieralisi@kernel.org \
--cc=manivannan.sadhasivam@linaro.org \
--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