* [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk [not found] <CGME20230714052025epcas2p46d5485a277c9f21ace14300dd9d7b4d8@epcas2p4.samsung.com> @ 2023-07-14 5:15 ` Jaewon Kim 2023-07-14 5:26 ` Krzysztof Kozlowski 0 siblings, 1 reply; 6+ messages in thread From: Jaewon Kim @ 2023-07-14 5:15 UTC (permalink / raw) To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Alim Akhtar Cc: devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel, Chanho Park, Jaewon Kim Add pwm node to support fan on exynosautov9-sadk board. PWM channel 3 of ExynosAutov9 is connected to fan for SoC cooling in SADK board. Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com> --- arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts | 6 ++++++ arch/arm64/boot/dts/exynos/exynosautov9.dtsi | 9 +++++++++ 2 files changed, 15 insertions(+) diff --git a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts index 898c2fc345ed..e717bb1cad81 100644 --- a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts +++ b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts @@ -50,6 +50,12 @@ }; }; +&pwm { + pinctrl-names = "default"; + pinctrl-0 = <&pwm_tout3>; + status = "okay"; +}; + &serial_0 { pinctrl-0 = <&uart0_bus_dual>; status = "okay"; diff --git a/arch/arm64/boot/dts/exynos/exynosautov9.dtsi b/arch/arm64/boot/dts/exynos/exynosautov9.dtsi index d3c5cdeff47f..e8860b03fe89 100644 --- a/arch/arm64/boot/dts/exynos/exynosautov9.dtsi +++ b/arch/arm64/boot/dts/exynos/exynosautov9.dtsi @@ -1560,6 +1560,15 @@ samsung,syscon-phandle = <&pmu_system_controller>; samsung,cluster-index = <1>; }; + + pwm: pwm@103f0000 { + compatible = "samsung,exynos4210-pwm"; + reg = <0x103f0000 0x100>; + samsung,pwm-outputs = <0>, <1>, <2>, <3>; + #pwm-cells = <3>; + clocks = <&xtcxo>; + clock-names = "timers"; + }; }; }; -- 2.17.1 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk 2023-07-14 5:15 ` [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk Jaewon Kim @ 2023-07-14 5:26 ` Krzysztof Kozlowski 2023-07-14 5:28 ` Jaewon Kim 2023-07-14 5:59 ` Chanho Park 0 siblings, 2 replies; 6+ messages in thread From: Krzysztof Kozlowski @ 2023-07-14 5:26 UTC (permalink / raw) To: Jaewon Kim, Rob Herring, Krzysztof Kozlowski, Conor Dooley, Alim Akhtar Cc: devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel, Chanho Park On 14/07/2023 07:15, Jaewon Kim wrote: > Add pwm node to support fan on exynosautov9-sadk board. > PWM channel 3 of ExynosAutov9 is connected to fan for SoC cooling > in SADK board. > > Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com> > --- > arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts | 6 ++++++ > arch/arm64/boot/dts/exynos/exynosautov9.dtsi | 9 +++++++++ > 2 files changed, 15 insertions(+) > > diff --git a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts > index 898c2fc345ed..e717bb1cad81 100644 > --- a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts > +++ b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts > @@ -50,6 +50,12 @@ > }; > }; > > +&pwm { > + pinctrl-names = "default"; > + pinctrl-0 = <&pwm_tout3>; > + status = "okay"; > +}; > + > &serial_0 { > pinctrl-0 = <&uart0_bus_dual>; > status = "okay"; > diff --git a/arch/arm64/boot/dts/exynos/exynosautov9.dtsi b/arch/arm64/boot/dts/exynos/exynosautov9.dtsi > index d3c5cdeff47f..e8860b03fe89 100644 > --- a/arch/arm64/boot/dts/exynos/exynosautov9.dtsi > +++ b/arch/arm64/boot/dts/exynos/exynosautov9.dtsi > @@ -1560,6 +1560,15 @@ > samsung,syscon-phandle = <&pmu_system_controller>; > samsung,cluster-index = <1>; > }; > + > + pwm: pwm@103f0000 { > + compatible = "samsung,exynos4210-pwm"; Thanks for the patch. I think we should change existing practice for Samsung SoC and start adding dedicated specific compatible for such blocks. It's the same practice we follow in other SoCs. It's also recommendation I give to other platforms. Therefore this should be "samsung,exynosautov9-pwm", "samsung,exynos4210-pwm". Feel free to update other DTS as well. > + reg = <0x103f0000 0x100>; > + samsung,pwm-outputs = <0>, <1>, <2>, <3>; > + #pwm-cells = <3>; > + clocks = <&xtcxo>; This does not look like correct clock. Are you sure XTCXO goes to PWM? Best regards, Krzysztof ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk 2023-07-14 5:26 ` Krzysztof Kozlowski @ 2023-07-14 5:28 ` Jaewon Kim 2023-07-14 5:59 ` Chanho Park 1 sibling, 0 replies; 6+ messages in thread From: Jaewon Kim @ 2023-07-14 5:28 UTC (permalink / raw) To: Krzysztof Kozlowski, Rob Herring, Krzysztof Kozlowski, Conor Dooley, Alim Akhtar Cc: devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel, Chanho Park Hi Krzysztof On 23. 7. 14. 14:26, Krzysztof Kozlowski wrote: > On 14/07/2023 07:15, Jaewon Kim wrote: >> Add pwm node to support fan on exynosautov9-sadk board. >> PWM channel 3 of ExynosAutov9 is connected to fan for SoC cooling >> in SADK board. >> >> Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com> >> --- >> arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts | 6 ++++++ >> arch/arm64/boot/dts/exynos/exynosautov9.dtsi | 9 +++++++++ >> 2 files changed, 15 insertions(+) >> >> diff --git a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts >> index 898c2fc345ed..e717bb1cad81 100644 >> --- a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts >> +++ b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts >> @@ -50,6 +50,12 @@ >> }; >> }; >> >> +&pwm { >> + pinctrl-names = "default"; >> + pinctrl-0 = <&pwm_tout3>; >> + status = "okay"; >> +}; >> + >> &serial_0 { >> pinctrl-0 = <&uart0_bus_dual>; >> status = "okay"; >> diff --git a/arch/arm64/boot/dts/exynos/exynosautov9.dtsi b/arch/arm64/boot/dts/exynos/exynosautov9.dtsi >> index d3c5cdeff47f..e8860b03fe89 100644 >> --- a/arch/arm64/boot/dts/exynos/exynosautov9.dtsi >> +++ b/arch/arm64/boot/dts/exynos/exynosautov9.dtsi >> @@ -1560,6 +1560,15 @@ >> samsung,syscon-phandle = <&pmu_system_controller>; >> samsung,cluster-index = <1>; >> }; >> + >> + pwm: pwm@103f0000 { >> + compatible = "samsung,exynos4210-pwm"; > Thanks for the patch. I think we should change existing practice for > Samsung SoC and start adding dedicated specific compatible for such > blocks. It's the same practice we follow in other SoCs. It's also > recommendation I give to other platforms. > > Therefore this should be "samsung,exynosautov9-pwm", > "samsung,exynos4210-pwm". Feel free to update other DTS as well. Okay, I will update "samsung,exynosautov9-pwm" compatible in next version. > >> + reg = <0x103f0000 0x100>; >> + samsung,pwm-outputs = <0>, <1>, <2>, <3>; >> + #pwm-cells = <3>; >> + clocks = <&xtcxo>; > This does not look like correct clock. Are you sure XTCXO goes to PWM? > > > > Best regards, > Krzysztof > > Thanks Jaewon Kim ^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk 2023-07-14 5:26 ` Krzysztof Kozlowski 2023-07-14 5:28 ` Jaewon Kim @ 2023-07-14 5:59 ` Chanho Park 2023-07-14 6:10 ` Jaewon Kim 2023-07-14 6:29 ` Krzysztof Kozlowski 1 sibling, 2 replies; 6+ messages in thread From: Chanho Park @ 2023-07-14 5:59 UTC (permalink / raw) To: 'Krzysztof Kozlowski', 'Jaewon Kim', 'Rob Herring', 'Krzysztof Kozlowski', 'Conor Dooley', 'Alim Akhtar' Cc: devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel > > + reg = <0x103f0000 0x100>; > > + samsung,pwm-outputs = <0>, <1>, <2>, <3>; > > + #pwm-cells = <3>; > > + clocks = <&xtcxo>; > > This does not look like correct clock. Are you sure XTCXO goes to PWM? Yes. XTXCO is the source clock of the pwm. Unlike any other exynos SoCs, the clock is directly derived from the external OSC. Thus, it cannot be controllable such as gating. Best Regards, Chanho Park ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk 2023-07-14 5:59 ` Chanho Park @ 2023-07-14 6:10 ` Jaewon Kim 2023-07-14 6:29 ` Krzysztof Kozlowski 1 sibling, 0 replies; 6+ messages in thread From: Jaewon Kim @ 2023-07-14 6:10 UTC (permalink / raw) To: Chanho Park, 'Krzysztof Kozlowski', 'Rob Herring', 'Krzysztof Kozlowski', 'Conor Dooley', 'Alim Akhtar' Cc: devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel On 23. 7. 14. 14:59, Chanho Park wrote: >>> + reg = <0x103f0000 0x100>; >>> + samsung,pwm-outputs = <0>, <1>, <2>, <3>; >>> + #pwm-cells = <3>; >>> + clocks = <&xtcxo>; >> This does not look like correct clock. Are you sure XTCXO goes to PWM? > Yes. XTXCO is the source clock of the pwm. Unlike any other exynos SoCs, the clock is directly derived from the external OSC. > Thus, it cannot be controllable such as gating. Thanks Chanho. I miss this comment. > > Best Regards, > Chanho Park > > Thanks Jaewon Kim ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk 2023-07-14 5:59 ` Chanho Park 2023-07-14 6:10 ` Jaewon Kim @ 2023-07-14 6:29 ` Krzysztof Kozlowski 1 sibling, 0 replies; 6+ messages in thread From: Krzysztof Kozlowski @ 2023-07-14 6:29 UTC (permalink / raw) To: Chanho Park, 'Jaewon Kim', 'Rob Herring', 'Krzysztof Kozlowski', 'Conor Dooley', 'Alim Akhtar' Cc: devicetree, linux-arm-kernel, linux-samsung-soc, linux-kernel On 14/07/2023 07:59, Chanho Park wrote: >>> + reg = <0x103f0000 0x100>; >>> + samsung,pwm-outputs = <0>, <1>, <2>, <3>; >>> + #pwm-cells = <3>; >>> + clocks = <&xtcxo>; >> >> This does not look like correct clock. Are you sure XTCXO goes to PWM? > > Yes. XTXCO is the source clock of the pwm. Unlike any other exynos SoCs, the clock is directly derived from the external OSC. > Thus, it cannot be controllable such as gating. Sure, thanks for clarifying. Best regards, Krzysztof ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-07-14 6:29 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <CGME20230714052025epcas2p46d5485a277c9f21ace14300dd9d7b4d8@epcas2p4.samsung.com>
2023-07-14 5:15 ` [PATCH] arm64: dts: exynos: add pwm node for exynosautov9-sadk Jaewon Kim
2023-07-14 5:26 ` Krzysztof Kozlowski
2023-07-14 5:28 ` Jaewon Kim
2023-07-14 5:59 ` Chanho Park
2023-07-14 6:10 ` Jaewon Kim
2023-07-14 6:29 ` Krzysztof Kozlowski
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox