* [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi
@ 2026-04-10 10:00 Chukun Pan
2026-04-10 10:00 ` [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S Chukun Pan
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: Chukun Pan @ 2026-04-10 10:00 UTC (permalink / raw)
To: Yixun Lan
Cc: Rob Herring, Paul Walmsley, Alexandre Ghiti, Albert Ou,
Palmer Dabbelt, Conor Dooley, Krzysztof Kozlowski, linux-riscv,
linux-kernel, devicetree, spacemit, Chukun Pan
Changes in v3:
- Drop OrangePi RV2 part to avoid conflicts
- Link to v2: https://lore.kernel.org/lkml/20260402100007.110201-1-amadeus@jmu.edu.cn/
Changes in v2:
- Drop common board dtsi and PCIe regulator
- Enable USB3 on OrangePi R2S and RV2 boards
- Link to v1: https://lore.kernel.org/lkml/20260116100001.208334-2-amadeus@jmu.edu.cn/
The schematic of OrangePi RV2 is available at:
https://drive.google.com/drive/folders/1pcI_U0C3VJKTCg8A1zj08CwNbohnONSR
Chukun Pan (2):
riscv: dts: spacemit: add fixed regulators for OrangePi R2S
riscv: dts: spacemit: enable USB3 on OrangePi R2S
.../boot/dts/spacemit/k1-orangepi-r2s.dts | 43 +++++++++++++++++++
1 file changed, 43 insertions(+)
--
2.34.1
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 9+ messages in thread* [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S 2026-04-10 10:00 [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan @ 2026-04-10 10:00 ` Chukun Pan 2026-05-11 7:07 ` Yixun Lan 2026-04-10 10:00 ` [PATCH v3 2/2] riscv: dts: spacemit: enable USB3 on " Chukun Pan ` (2 subsequent siblings) 3 siblings, 1 reply; 9+ messages in thread From: Chukun Pan @ 2026-04-10 10:00 UTC (permalink / raw) To: Yixun Lan Cc: Rob Herring, Paul Walmsley, Alexandre Ghiti, Albert Ou, Palmer Dabbelt, Conor Dooley, Krzysztof Kozlowski, linux-riscv, linux-kernel, devicetree, spacemit, Chukun Pan Define the power input and the 4V power as fixed regulator supplies. Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn> --- .../boot/dts/spacemit/k1-orangepi-r2s.dts | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts b/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts index de75f6aac740..409a6db269ae 100644 --- a/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts +++ b/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts @@ -21,6 +21,25 @@ aliases { chosen { stdout-path = "serial0"; }; + + vcc_5v0: regulator-vcc-5v0 { + compatible = "regulator-fixed"; + regulator-name = "vcc_5v0"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + }; + + vcc4v0: regulator-vcc4v0 { + compatible = "regulator-fixed"; + regulator-name = "vcc4v0"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <4000000>; + regulator-max-microvolt = <4000000>; + vin-supply = <&vcc_5v0>; + }; }; &emmc { -- 2.34.1 _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S 2026-04-10 10:00 ` [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S Chukun Pan @ 2026-05-11 7:07 ` Yixun Lan 2026-05-13 6:00 ` Chukun Pan 0 siblings, 1 reply; 9+ messages in thread From: Yixun Lan @ 2026-05-11 7:07 UTC (permalink / raw) To: Chukun Pan Cc: Rob Herring, Paul Walmsley, Alexandre Ghiti, Albert Ou, Palmer Dabbelt, Conor Dooley, Krzysztof Kozlowski, linux-riscv, linux-kernel, devicetree, spacemit Hi Chukun, On 18:00 Fri 10 Apr , Chukun Pan wrote: > Define the power input and the 4V power as fixed regulator supplies. > > Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn> > --- > .../boot/dts/spacemit/k1-orangepi-r2s.dts | 19 +++++++++++++++++++ > 1 file changed, 19 insertions(+) > > diff --git a/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts b/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts > index de75f6aac740..409a6db269ae 100644 > --- a/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts > +++ b/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts > @@ -21,6 +21,25 @@ aliases { > chosen { > stdout-path = "serial0"; > }; > + > + vcc_5v0: regulator-vcc-5v0 { > + compatible = "regulator-fixed"; > + regulator-name = "vcc_5v0"; > + regulator-always-on; > + regulator-boot-on; > + regulator-min-microvolt = <5000000>; > + regulator-max-microvolt = <5000000>; > + }; > + > + vcc4v0: regulator-vcc4v0 { > + compatible = "regulator-fixed"; > + regulator-name = "vcc4v0"; > + regulator-always-on; > + regulator-boot-on; > + regulator-min-microvolt = <4000000>; > + regulator-max-microvolt = <4000000>; > + vin-supply = <&vcc_5v0>; > + }; > }; please check my comment below, I think this patch has similar issue https://lore.kernel.org/all/20260511065338-GKA3624147@kernel.org/ -- Yixun Lan (dlan) _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S 2026-05-11 7:07 ` Yixun Lan @ 2026-05-13 6:00 ` Chukun Pan 2026-05-16 13:46 ` Yixun Lan 0 siblings, 1 reply; 9+ messages in thread From: Chukun Pan @ 2026-05-13 6:00 UTC (permalink / raw) To: dlan Cc: alex, amadeus, aou, conor+dt, devicetree, krzk+dt, linux-kernel, linux-riscv, palmer, pjw, robh, spacemit Hi, > please check my comment below, I think this patch has similar issue > > https://lore.kernel.org/all/20260511065338-GKA3624147@kernel.org/ I don't think this is an issue. Otherwise, these commits need to be fixed: https://github.com/torvalds/linux/commit/1df07a40453fd652132051419140950d47941fe9 https://github.com/torvalds/linux/commit/ae9d03f8aec76c1bff21083b67c211238d7c57b1 Let's confirm the current DT preferred: - regulator-fixed nodename: Preferred name is 'regulator-[0-9]v[0-9]' gpio/gpios: Preferred 'gpios' https://github.com/torvalds/linux/commit/12df2c182ccb850988d2680a422211a812fb5cb2 There is no specification or preference stating that regulators without software or GPIO control should be removed. This has been discussed many times, and people are used to describing DT according to the schematic: https://lore.kernel.org/all/44ba02e34d7bf6a6657894802a87b690@manjaro.org/ Therefore, if you consider these regulators unacceptable, we should remove them from other dts in spacemit, or allow such changes. Thanks, Chukun _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S 2026-05-13 6:00 ` Chukun Pan @ 2026-05-16 13:46 ` Yixun Lan 0 siblings, 0 replies; 9+ messages in thread From: Yixun Lan @ 2026-05-16 13:46 UTC (permalink / raw) To: Chukun Pan Cc: alex, aou, conor+dt, devicetree, krzk+dt, linux-kernel, linux-riscv, palmer, pjw, robh, spacemit Hi Chukun, On 14:00 Wed 13 May , Chukun Pan wrote: > Hi, > > > please check my comment below, I think this patch has similar issue > > > > https://lore.kernel.org/all/20260511065338-GKA3624147@kernel.org/ > > I don't think this is an issue. Otherwise, these commits need to be fixed: > https://github.com/torvalds/linux/commit/1df07a40453fd652132051419140950d47941fe9 > https://github.com/torvalds/linux/commit/ae9d03f8aec76c1bff21083b67c211238d7c57b1 > I agree, these patch was introduced before we learned the convention from DT maintainer, got no comment in that review phase, so it just slip in so yes, we should fix it, and patches are welcome.. > Let's confirm the current DT preferred: > > - regulator-fixed > > nodename: Preferred name is 'regulator-[0-9]v[0-9]' > > gpio/gpios: Preferred 'gpios' > https://github.com/torvalds/linux/commit/12df2c182ccb850988d2680a422211a812fb5cb2 > > There is no specification or preference stating that regulators without > software or GPIO control should be removed. Not exactly, if some device driver explicitly request regulator, then fixed regulators without software or GPIO control are still needed Please refer to this reply from Krzysztof, fixed, non-controllable regulator isn't really necessary if no driver/device used, will only waste memory, slow down boot time.. https://lore.kernel.org/all/90eafe45-7863-4c1d-b1e5-55a4fe32c806@kernel.org/ In this patch, I think both vcc_5v0 and vcc4v0 can be removed > > This has been discussed many times, and people are used to describing DT > according to the schematic: > https://lore.kernel.org/all/44ba02e34d7bf6a6657894802a87b690@manjaro.org/ > For Dragan Simic's reply, I see no ACK from DT maintainer > Therefore, if you consider these regulators unacceptable, we should remove > them from other dts in spacemit, or allow such changes. > I would prefer to remove it, see comments above > Thanks, > Chukun -- Yixun Lan (dlan) _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH v3 2/2] riscv: dts: spacemit: enable USB3 on OrangePi R2S 2026-04-10 10:00 [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan 2026-04-10 10:00 ` [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S Chukun Pan @ 2026-04-10 10:00 ` Chukun Pan 2026-04-30 10:18 ` [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan 2026-05-11 6:01 ` Chukun Pan 3 siblings, 0 replies; 9+ messages in thread From: Chukun Pan @ 2026-04-10 10:00 UTC (permalink / raw) To: Yixun Lan Cc: Rob Herring, Paul Walmsley, Alexandre Ghiti, Albert Ou, Palmer Dabbelt, Conor Dooley, Krzysztof Kozlowski, linux-riscv, linux-kernel, devicetree, spacemit, Chukun Pan Enable the DWC3 USB3.0 controller and its associated PHY on the OrangePi R2S. The USB regulator provides VBUS for USB2 and USB3 ports, but the USB2 ports are handled by a separate controller. Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn> --- .../boot/dts/spacemit/k1-orangepi-r2s.dts | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts b/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts index 409a6db269ae..bc68721e6263 100644 --- a/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts +++ b/arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts @@ -40,6 +40,20 @@ vcc4v0: regulator-vcc4v0 { regulator-max-microvolt = <4000000>; vin-supply = <&vcc_5v0>; }; + + vcc5v0_usb: regulator-vcc5v0-usb { + compatible = "regulator-fixed"; + enable-active-high; + gpios = <&gpio K1_GPIO(126) GPIO_ACTIVE_HIGH>; + regulator-name = "vcc5v0_usb"; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + vin-supply = <&vcc_5v0>; + }; +}; + +&combo_phy { + status = "okay"; }; &emmc { @@ -109,3 +123,13 @@ &uart0 { pinctrl-0 = <&uart0_2_cfg>; status = "okay"; }; + +&usbphy2 { + status = "okay"; +}; + +&usb_dwc3 { + dr_mode = "host"; + vbus-supply = <&vcc5v0_usb>; + status = "okay"; +}; -- 2.34.1 _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi 2026-04-10 10:00 [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan 2026-04-10 10:00 ` [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S Chukun Pan 2026-04-10 10:00 ` [PATCH v3 2/2] riscv: dts: spacemit: enable USB3 on " Chukun Pan @ 2026-04-30 10:18 ` Chukun Pan 2026-05-11 6:01 ` Chukun Pan 3 siblings, 0 replies; 9+ messages in thread From: Chukun Pan @ 2026-04-30 10:18 UTC (permalink / raw) To: amadeus Cc: alex, aou, conor+dt, devicetree, dlan, krzk+dt, linux-kernel, linux-riscv, palmer, pjw, robh, spacemit Hi, > riscv: dts: spacemit: add fixed regulators for OrangePi R2S > riscv: dts: spacemit: enable USB3 on OrangePi R2S Friendly ping _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi 2026-04-10 10:00 [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan ` (2 preceding siblings ...) 2026-04-30 10:18 ` [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan @ 2026-05-11 6:01 ` Chukun Pan 2026-05-11 7:05 ` Yixun Lan 3 siblings, 1 reply; 9+ messages in thread From: Chukun Pan @ 2026-05-11 6:01 UTC (permalink / raw) To: amadeus Cc: alex, aou, conor+dt, devicetree, dlan, krzk+dt, linux-kernel, linux-riscv, palmer, pjw, robh, spacemit Hi, > riscv: dts: spacemit: add fixed regulators for OrangePi R2S > riscv: dts: spacemit: enable USB3 on OrangePi R2S Ping... This patch seems to have been forgotten. _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi 2026-05-11 6:01 ` Chukun Pan @ 2026-05-11 7:05 ` Yixun Lan 0 siblings, 0 replies; 9+ messages in thread From: Yixun Lan @ 2026-05-11 7:05 UTC (permalink / raw) To: Chukun Pan Cc: alex, aou, conor+dt, devicetree, krzk+dt, linux-kernel, linux-riscv, palmer, pjw, robh, spacemit Hi Chukun, On 14:01 Mon 11 May , Chukun Pan wrote: > Hi, > > > riscv: dts: spacemit: add fixed regulators for OrangePi R2S > > riscv: dts: spacemit: enable USB3 on OrangePi R2S > > Ping... This patch seems to have been forgotten. Thanks for the ping.. Don't hesitate to ask if you think I've forgotten, or the patch has been ignored for too long.. Yixun Lan (dlan) _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2026-05-16 13:46 UTC | newest] Thread overview: 9+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2026-04-10 10:00 [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan 2026-04-10 10:00 ` [PATCH v3 1/2] riscv: dts: spacemit: add fixed regulators for OrangePi R2S Chukun Pan 2026-05-11 7:07 ` Yixun Lan 2026-05-13 6:00 ` Chukun Pan 2026-05-16 13:46 ` Yixun Lan 2026-04-10 10:00 ` [PATCH v3 2/2] riscv: dts: spacemit: enable USB3 on " Chukun Pan 2026-04-30 10:18 ` [PATCH v3 0/3] riscv: dts: spacemit: enable USB3 on OrangePi Chukun Pan 2026-05-11 6:01 ` Chukun Pan 2026-05-11 7:05 ` Yixun Lan
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox