riscv: sophgo: cv18xx: dts rework, part 2
Subsystems (4)
Inochi Amaoto
maintainerv2 cover riscv: sophgo: cv18xx: dts rework, part 2
The part 2 of dts rework replaces precise compatible for existed clock device with old wildcard one.
Changed from v1:
- https://lore.kernel.org/all/[email protected]/
1. patch 1: reused sophgo,sg2000-clk for sg2002.
2. patch 1: mention sg2002 refer to a real device, not a wildcard one in commit message.
3. patch 2: fix wrong data for sophgo,cv1812h-clk.
4. patch 2: remove compatible sophgo,sg2002-clk.
5. patch 3: adapt the change of patch 1,2.
Inochi Amaoto (3):
dt-bindings: clock: sophgo: Use precise compatible for CV1800 series
SoC
clk: sophgo: Add support for newly added precise compatible
riscv: dts: sophgo: switch precise compatible for existed clock device
for CV18XX
.../bindings/clock/sophgo,cv1800-clk.yaml | 16 ++++++++++++---- arch/riscv/boot/dts/sophgo/cv1800b.dtsi | 2 +- arch/riscv/boot/dts/sophgo/cv1812h.dtsi | 2 +- arch/riscv/boot/dts/sophgo/sg2002.dtsi | 2 +- drivers/clk/sophgo/clk-cv1800.c | 2 ++ 5 files changed, 17 insertions(+), 7 deletions(-)
base-commit: 0af2f6be1b4281385b618cb86ad946eded089ac8
prerequisite-patch-id: 94fb3d26e017cf839b4dcb4bf85624614a94b9ac
prerequisite-patch-id: 8f4a8bdead0e4e3d6904adbc0fd150b7dffefc85
prerequisite-patch-id: b30e850690903c3ddc3d8bb77a99e97934dc9dde
prerequisite-patch-id: 6e1117694a53a0059b145ad4751ec204cae0db35 --
2.49.0
Inochi Amaoto
maintainerPATCH v2 1/3 dt-bindings: clock: sophgo: Use precise compatible for CV1800 series SoC
As previous binding uses a wildcard compatible for existed clock device of CV1800 series SoC, it is not suitable for existed requirement. The only exception is sophgo,sg2000-clk, it does match a real device, so keep it as is.
Add new precise compatible for existed clock devices of CV1800 series SoCs and make old wildcard compatible deprecated.
--- .../bindings/clock/sophgo,cv1800-clk.yaml | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)
Documentation/devicetree/bindings/clock/sophgo,cv1800-clk.yaml +12 -4
@@ -11,10 +11,18 @@ maintainers: properties: compatible: - enum: - - sophgo,cv1800-clk - - sophgo,cv1810-clk - - sophgo,sg2000-clk + oneOf: + - enum: + - sophgo,cv1800b-clk + - sophgo,cv1812h-clk + - sophgo,sg2000-clk + - items: + - const: sophgo,sg2002-clk + - const: sophgo,sg2000-clk + - const: sophgo,cv1800-clk + deprecated: true + - const: sophgo,cv1810-clk + deprecated: true reg: maxItems: 1
Signature · 1 line
2.49.0
Re: [PATCH v2 1/3] dt-bindings: clock: sophgo: Use precise compatible for CV1800 series SoC
Quoted 9 lines · Inochi Amaoto
As previous binding uses a wildcard compatible for existed clock device of CV1800 series SoC, it is not suitable for existed requirement. The only exception is sophgo,sg2000-clk, it does match a real device, so keep it as is.
Add new precise compatible for existed clock devices of CV1800 series SoCs and make old wildcard compatible deprecated.
Signed-off-by Inochi Amaoto <[email protected]>
Inochi Amaoto
maintainerPATCH v2 2/3 clk: sophgo: Add support for newly added precise compatible
In reply to Inochi AmaotoAdd of device id definition for newly added precise compatible.
--- drivers/clk/sophgo/clk-cv1800.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/clk/sophgo/clk-cv1800.c +2 -0
@@ -1519,7 +1519,9 @@ static int cv1800_clk_probe(struct platform_device *pdev)static const struct of_device_id cv1800_clk_ids[] = { { .compatible ="sophgo,cv1800-clk" , .data = &cv1800_desc }, + { .compatible ="sophgo,cv1800b-clk" , .data = &cv1800_desc }, { .compatible ="sophgo,cv1810-clk" , .data = &cv1810_desc }, + { .compatible ="sophgo,cv1812h-clk" , .data = &cv1810_desc }, { .compatible ="sophgo,sg2000-clk" , .data = &sg2000_desc }, { } };
Signature · 1 line
2.49.0
Re: [PATCH v2 2/3] clk: sophgo: Add support for newly added precise compatible
Quoted 3 lines · Inochi Amaoto
Add of device id definition for newly added precise compatible.
Signed-off-by Inochi Amaoto <[email protected]>
Quoted 18 lines
---
drivers/clk/sophgo/clk-cv1800.c | 2 ++1 file changed, 2 insertions(+)drivers/clk/sophgo/clk-cv1800.c +0
-0@@ -1519,7 +1519,9 @@ static int cv1800_clk_probe(struct platform_device *pdev)
static const structof_device_idcv1800_clk_ids[] = {
{ .compatible = "sophgo,cv1800-clk", .data =&cv1800_desc},drivers/clk/sophgo/clk-cv1800.c +1
-0+ { .compatible = "sophgo,cv1800b-clk", .data = &cv1800_desc },{ .compatible = "sophgo,cv1810-clk", .data =
&cv1810_desc},drivers/clk/sophgo/clk-cv1800.c +1
-0+ { .compatible = "sophgo,cv1812h-clk", .data = &cv1810_desc },{ .compatible = "sophgo,sg2000-clk", .data =
&sg2000_desc}, { }
};
Signature · 1 line
Alexander Sverdlin.
Inochi Amaoto
maintainerPATCH v2 3/3 riscv: dts: sophgo: switch precise compatible for existed clock device for CV18XX
In reply to Inochi Amaotoreplace newly added precise compatible with old one for existed clock device of CV18XX series SoCs.
--- arch/riscv/boot/dts/sophgo/cv1800b.dtsi | 2 +- arch/riscv/boot/dts/sophgo/cv1812h.dtsi | 2 +- arch/riscv/boot/dts/sophgo/sg2002.dtsi | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
arch/riscv/boot/dts/sophgo/cv1800b.dtsi +1 -1
@@ -29,7 +29,7 @@ pinctrl: pinctrl@3001000 { }; clk: clock-controller@3002000 { - compatible = "sophgo,cv1800-clk"; + compatible = "sophgo,cv1800b-clk"; reg = <0x03002000 0x1000>; clocks = <&osc>; #clock-cells = <1>;
arch/riscv/boot/dts/sophgo/cv1812h.dtsi +1 -1
@@ -31,7 +31,7 @@ pinctrl: pinctrl@3001000 { }; clk: clock-controller@3002000 { - compatible = "sophgo,cv1810-clk"; + compatible = "sophgo,cv1812h-clk"; reg = <0x03002000 0x1000>; clocks = <&osc>; #clock-cells = <1>;
arch/riscv/boot/dts/sophgo/sg2002.dtsi +1 -1
@@ -31,7 +31,7 @@ pinctrl: pinctrl@3001000 { }; clk: clock-controller@3002000 { - compatible = "sophgo,sg2000-clk"; + compatible = "sophgo,sg2002-clk", "sophgo,sg2000-clk"; reg = <0x03002000 0x1000>; clocks = <&osc>; #clock-cells = <1>;
Signature · 1 line
2.49.0
Re: [PATCH v2 3/3] riscv: dts: sophgo: switch precise compatible for existed clock device for CV18XX
Quoted 4 lines · Inochi Amaoto
replace newly added precise compatible with old one for existed clock device of CV18XX series SoCs.
Signed-off-by Inochi Amaoto <[email protected]>
Quoted 5 lines
---
arch/riscv/boot/dts/sophgo/cv1800b.dtsi | 2 +-
arch/riscv/boot/dts/sophgo/cv1812h.dtsi | 2 +-
arch/riscv/boot/dts/sophgo/sg2002.dtsi | 2 +-3 files changed, 3 insertions(+), 3 deletions(-)
Signature · 1 line
Alexander Sverdlin.
Re: (subset) [PATCH v2 0/3] riscv: sophgo: cv18xx: dts rework, part 2
In reply to Inochi AmaotoQuoted 12 lines · Inochi Amaoto
The part 2 of dts rework replaces precise compatible for existed clock device with old wildcard one.
Changed from v1:
- https://lore.kernel.org/all/[email protected]/
1. patch 1: reused sophgo,sg2000-clk for sg2002.
2. patch 1: mention sg2002 refer to a real device, not a wildcard one in commit message.
3. patch 2: fix wrong data for sophgo,cv1812h-clk.
4. patch 2: remove compatible sophgo,sg2002-clk.
5. patch 3: adapt the change of patch 1,2.
Quoted 1 line
[...]
Applied to sophgo-clk-for-6.16-rc1, thanks!
[1/3] dt-bindings: clock: sophgo: Use precise compatible for CV1800 series SoC
https://github.com/sophgo/linux/commit/6d880961f5f9b84d13fb4a0208c7405966bc3489 [2/3] clk: sophgo: Add support for newly added precise compatible https://github.com/sophgo/linux/commit/dd8bbae9fefeead76f20cd410a5a8299fcbad220
Thanks,
Inochi
Re: (subset) [PATCH v2 0/3] riscv: sophgo: cv18xx: dts rework, part 2
In reply to Inochi AmaotoQuoted 12 lines · Inochi Amaoto
The part 2 of dts rework replaces precise compatible for existed clock device with old wildcard one.
Changed from v1:
- https://lore.kernel.org/all/[email protected]/
1. patch 1: reused sophgo,sg2000-clk for sg2002.
2. patch 1: mention sg2002 refer to a real device, not a wildcard one in commit message.
3. patch 2: fix wrong data for sophgo,cv1812h-clk.
4. patch 2: remove compatible sophgo,sg2002-clk.
5. patch 3: adapt the change of patch 1,2.
Quoted 1 line
[...]
Applied to for-next, thanks!
[3/3] riscv: dts: sophgo: switch precise compatible for existed clock device for CV18XX
https://github.com/sophgo/linux/commit/6493272ec02706dcb2a32a1c7b14e47432ce6d6a
Thanks,
Inochi