mbox series

[0/3] arm64: dts: qcom: pm6150: Add typec support for PM6150

Message ID 20240217163201.32989-1-danila@jiaxyga.com
Headers show
Series arm64: dts: qcom: pm6150: Add typec support for PM6150 | expand

Message

Danila Tikhonov Feb. 17, 2024, 4:31 p.m. UTC
This series adds typec support for PM6150. Was tested on SM7150
(xiaomi-surya).

To: Bjorn Andersson <andersson@kernel.org>
To: Konrad Dybcio <konrad.dybcio@linaro.org>
To: Liam Girdwood <lgirdwood@gmail.com>
To: Mark Brown <broonie@kernel.org>
To: Rob Herring <robh@kernel.org>
To: Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>
To: Conor Dooley <conor+dt@kernel.org>
To: "Bryan O'Donoghue" <bryan.odonoghue@linaro.org>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Wesley Cheng <quic_wcheng@quicinc.com>
Cc: linux-arm-msm@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Cc: devicetree@vger.kernel.org
Cc: linux-usb@vger.kernel.org
Signed-off-by: Danila Tikhonov <danila@jiaxyga.com>

Danila Tikhonov (3):
  dt-bindings: regulator: qcom,usb-vbus-regulator: Add PM6150 compatible
  dt-bindings: usb: qcom,pmic-typec: Add support for the PM6150 PMIC
  arm64: dts: qcom: pm6150: define USB-C related blocks

 .../regulator/qcom,usb-vbus-regulator.yaml    |  9 +++-
 .../bindings/usb/qcom,pmic-typec.yaml         |  9 +++-
 arch/arm64/boot/dts/qcom/pm6150.dtsi          | 46 +++++++++++++++++++
 3 files changed, 60 insertions(+), 4 deletions(-)

Comments

Bryan O'Donoghue Feb. 17, 2024, 11:19 p.m. UTC | #1
On 17/02/2024 16:32, Danila Tikhonov wrote:
> Define VBUS regulator and the Type-C handling block as present on the
> Quacomm PM6150 PMIC.
> 
> Signed-off-by: Danila Tikhonov <danila@jiaxyga.com>

> +		pm6150_typec: typec@1500 {
> +			compatible = "qcom,pm6150-typec,
> +				      qcom,pm8150b-typec";
> +			reg = <0x1500>, <0x1700>;
> +			interrupts = <0x0 0x15 0x00 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x15 0x01 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x15 0x02 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x15 0x03 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x15 0x04 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x15 0x05 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x15 0x06 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x15 0x07 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x00 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x01 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x02 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x03 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x04 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x05 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x06 IRQ_TYPE_EDGE_RISING>,
> +				     <0x0 0x17 0x07 IRQ_TYPE_EDGE_RISING>;
> +			interrupt-names = "or-rid-detect-change",
> +					  "vpd-detect",
> +					  "cc-state-change",
> +					  "vconn-oc",
> +					  "vbus-change",
> +					  "attach-detach",
> +					  "legacy-cable-detect",
> +					  "try-snk-src-detect",
> +					  "sig-tx",
> +					  "sig-rx",
> +					  "msg-tx",
> +					  "msg-rx",
> +					  "msg-tx-failed",
> +					  "msg-tx-discarded",
> +					  "msg-rx-discarded",
> +					  "fr-swap";
> +			status = "disabled";
> +		};

Should all of these be rising ? Looks incorrect to me.

Please review: arch/arm64/boot/dts/qcom/pm8150b.dtsi

pm8150b_typec: typec@1500 {
         compatible = "qcom,pm8150b-typec";
         status = "disabled";
         reg = <0x1500>,
               <0x1700>;

	interrupts = <0x2 0x15 0x00 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x15 0x01 IRQ_TYPE_EDGE_BOTH>,
		     <0x2 0x15 0x02 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x15 0x03 IRQ_TYPE_EDGE_BOTH>,
		     <0x2 0x15 0x04 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x15 0x05 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x15 0x06 IRQ_TYPE_EDGE_BOTH>,
		     <0x2 0x15 0x07 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x00 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x01 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x02 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x03 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x04 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x05 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x06 IRQ_TYPE_EDGE_RISING>,
		     <0x2 0x17 0x07 IRQ_TYPE_EDGE_RISING>;

		interrupt-names = "or-rid-detect-change",
				  "vpd-detect",
				  "cc-state-change",
				  "vconn-oc",
				  "vbus-change",
				  "attach-detach",
				  "legacy-cable-detect",
				  "try-snk-src-detect",
				  "sig-tx",
				  "sig-rx",
				  "msg-tx",
				  "msg-rx",
				  "msg-tx-failed",
				  "msg-tx-discarded",
				  "msg-rx-discarded",
				  "fr-swap";
}

---
bod
Mark Brown Feb. 19, 2024, 4:23 p.m. UTC | #2
On Sat, 17 Feb 2024 19:31:58 +0300, Danila Tikhonov wrote:
> This series adds typec support for PM6150. Was tested on SM7150
> (xiaomi-surya).
> 
> To: Bjorn Andersson <andersson@kernel.org>
> To: Konrad Dybcio <konrad.dybcio@linaro.org>
> To: Liam Girdwood <lgirdwood@gmail.com>
> To: Mark Brown <broonie@kernel.org>
> To: Rob Herring <robh@kernel.org>
> To: Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>
> To: Conor Dooley <conor+dt@kernel.org>
> To: "Bryan O'Donoghue" <bryan.odonoghue@linaro.org>
> To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> To: Wesley Cheng <quic_wcheng@quicinc.com>
> Cc: linux-arm-msm@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> Cc: devicetree@vger.kernel.org
> Cc: linux-usb@vger.kernel.org
> Signed-off-by: Danila Tikhonov <danila@jiaxyga.com>
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/3] dt-bindings: regulator: qcom,usb-vbus-regulator: Add PM6150 compatible
      commit: ec29a4d9b7c7329afc61e7932cb91e9b292b2b74

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark