From: Johan Hovold <johan@kernel.org>
To: Krishna Kurapati <krishna.kurapati@oss.qualcomm.com>
Cc: Stephan Gerhold <stephan.gerhold@linaro.org>,
Bjorn Andersson <andersson@kernel.org>,
Konrad Dybcio <konradybcio@kernel.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Catalin Marinas <catalin.marinas@arm.com>,
Will Deacon <will@kernel.org>,
linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
Abel Vesa <abel.vesa@linaro.org>,
Krishna Kurapati <quic_kriskura@quicinc.com>,
Thinh Nguyen <Thinh.Nguyen@synopsys.com>,
linux-usb@vger.kernel.org
Subject: Re: [PATCH 1/2] arm64: dts: qcom: x1e80100-crd: Add USB multiport fingerprint reader
Date: Thu, 5 Dec 2024 09:16:03 +0100 [thread overview]
Message-ID: <Z1FhQ3OUI0t3k1_q@hovoldconsulting.com> (raw)
In-Reply-To: <98b2b88b-9690-44a7-9b22-2f23e6606e82@oss.qualcomm.com>
On Thu, Dec 05, 2024 at 01:32:29PM +0530, Krishna Kurapati wrote:
> On 12/3/2024 6:45 PM, Krishna Kurapati wrote:
> > On 12/3/2024 3:50 PM, Johan Hovold wrote:
> >> On Mon, Nov 18, 2024 at 11:34:29AM +0100, Stephan Gerhold wrote:
> >>> +&usb_mp_dwc3 {
> >>> + /* Limit to USB 2.0 and single port */
> >>> + maximum-speed = "high-speed";
> >>> + phys = <&usb_mp_hsphy1>;
> >>> + phy-names = "usb2-1";
> >>> +};
> >>
> >> The dwc3 driver determines (and acts on) the number of ports based on
> >> the port interrupts in DT and controller capabilities.
> >>
> >> I'm not sure we can (should) just drop the other HS PHY and the SS PHYs
> >> that would still be there in the SoC (possibly initialised by the boot
> >> firmware).
> >
> > The DWC3 core driver identifies number of ports based on xHCI registers.
> > The QC Wrapper reads this number via interrupts. But these two values
> > are independent of each other. The core driver uses these values to
> > identify and manipulate phys. Even if only one HS is given in multiport
> > it would be sufficient if the name is "usb2-1". If the others are
> > missing, those phys would be read by driver as NULL and any ops to phys
> > would be NOP.
No, the core driver still acts on these ports (to some extent) even if
there is no PHY specified (e.g. updates DWC3_GUSB2PHYCFG on suspend).
And IIRC I even had to specify more than just the fingerprint reader PHY
on the X13s to get it to enumerate. I never had time to fully determine
why this was the case though.
> However do we need to reduce the number of interrupts used in DTS ?
> We don't need to give all interrupts as there is only one port present.
> We don't want to enable all interrupts when ports are not exposed.
No, the interrupts are still there, wired up in the SoC, so we should
not change that.
With runtime PM eventually enabled and working as it should, the OS
should be able to power down any unused ports. And we could also
consider marking some ports as not physically accessible and not
connected as a further hint to the OS that they can be disabled even
sooner.
Johan
next prev parent reply other threads:[~2024-12-05 8:16 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-18 10:34 [PATCH 0/2] arm64: dts: qcom: x1e80100-crd: Add USB multiport fingerprint reader Stephan Gerhold
2024-11-18 10:34 ` [PATCH 1/2] " Stephan Gerhold
2024-12-02 14:32 ` Konrad Dybcio
2024-12-03 10:20 ` Johan Hovold
2024-12-03 11:30 ` [PATCH 1/2] arm64: dts: qcom: x1e80100-crd: Add USB multiport fingerprint readery Stephan Gerhold
2024-12-03 12:03 ` Abel Vesa
2024-12-03 15:11 ` Stephan Gerhold
2024-12-03 15:37 ` Krishna Kurapati
2024-12-03 16:05 ` Stephan Gerhold
2024-12-13 13:08 ` Konrad Dybcio
2024-12-03 13:15 ` [PATCH 1/2] arm64: dts: qcom: x1e80100-crd: Add USB multiport fingerprint reader Krishna Kurapati
2024-12-05 8:02 ` Krishna Kurapati
2024-12-05 8:16 ` Johan Hovold [this message]
2024-12-05 8:22 ` Krishna Kurapati
2024-12-05 8:56 ` Johan Hovold
2024-11-18 10:34 ` [PATCH 2/2] arm64: defconfig: enable NXP PTN3222 eUSB2 to USB2 redriver driver Stephan Gerhold
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=Z1FhQ3OUI0t3k1_q@hovoldconsulting.com \
--to=johan@kernel.org \
--cc=Thinh.Nguyen@synopsys.com \
--cc=abel.vesa@linaro.org \
--cc=andersson@kernel.org \
--cc=catalin.marinas@arm.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=konradybcio@kernel.org \
--cc=krishna.kurapati@oss.qualcomm.com \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=quic_kriskura@quicinc.com \
--cc=robh@kernel.org \
--cc=stephan.gerhold@linaro.org \
--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