Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: dts: r8a7779: Add BRG support for SCIF

Add the device node for the external SCIF_CLK.
The presence of the SCIF_CLK crystal and its clock frequency depends on
the actual board.

Add the two optional clock sources (S1 and SCIF_CLK for the internal
resp. external clock) for the Baud Rate Generator for External Clock
(BRG) to all SCIF device nodes.

This increases the range and accuracy of supported baud rates on SCIF.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>

authored by

Geert Uytterhoeven and committed by
Simon Horman
f2be5f00 5fb544da

+27 -12
+27 -12
arch/arm/boot/dts/r8a7779.dtsi
··· 215 215 "renesas,scif"; 216 216 reg = <0xffe40000 0x100>; 217 217 interrupts = <GIC_SPI 88 IRQ_TYPE_LEVEL_HIGH>; 218 - clocks = <&mstp0_clks R8A7779_CLK_SCIF0>; 219 - clock-names = "fck"; 218 + clocks = <&mstp0_clks R8A7779_CLK_SCIF0>, 219 + <&cpg_clocks R8A7779_CLK_S1>, <&scif_clk>; 220 + clock-names = "fck", "brg_int", "scif_clk"; 220 221 power-domains = <&cpg_clocks>; 221 222 status = "disabled"; 222 223 }; ··· 227 226 "renesas,scif"; 228 227 reg = <0xffe41000 0x100>; 229 228 interrupts = <GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>; 230 - clocks = <&mstp0_clks R8A7779_CLK_SCIF1>; 231 - clock-names = "fck"; 229 + clocks = <&mstp0_clks R8A7779_CLK_SCIF1>, 230 + <&cpg_clocks R8A7779_CLK_S1>, <&scif_clk>; 231 + clock-names = "fck", "brg_int", "scif_clk"; 232 232 power-domains = <&cpg_clocks>; 233 233 status = "disabled"; 234 234 }; ··· 239 237 "renesas,scif"; 240 238 reg = <0xffe42000 0x100>; 241 239 interrupts = <GIC_SPI 90 IRQ_TYPE_LEVEL_HIGH>; 242 - clocks = <&mstp0_clks R8A7779_CLK_SCIF2>; 243 - clock-names = "fck"; 240 + clocks = <&mstp0_clks R8A7779_CLK_SCIF2>, 241 + <&cpg_clocks R8A7779_CLK_S1>, <&scif_clk>; 242 + clock-names = "fck", "brg_int", "scif_clk"; 244 243 power-domains = <&cpg_clocks>; 245 244 status = "disabled"; 246 245 }; ··· 251 248 "renesas,scif"; 252 249 reg = <0xffe43000 0x100>; 253 250 interrupts = <GIC_SPI 91 IRQ_TYPE_LEVEL_HIGH>; 254 - clocks = <&mstp0_clks R8A7779_CLK_SCIF3>; 255 - clock-names = "fck"; 251 + clocks = <&mstp0_clks R8A7779_CLK_SCIF3>, 252 + <&cpg_clocks R8A7779_CLK_S1>, <&scif_clk>; 253 + clock-names = "fck", "brg_int", "scif_clk"; 256 254 power-domains = <&cpg_clocks>; 257 255 status = "disabled"; 258 256 }; ··· 263 259 "renesas,scif"; 264 260 reg = <0xffe44000 0x100>; 265 261 interrupts = <GIC_SPI 92 IRQ_TYPE_LEVEL_HIGH>; 266 - clocks = <&mstp0_clks R8A7779_CLK_SCIF4>; 267 - clock-names = "fck"; 262 + clocks = <&mstp0_clks R8A7779_CLK_SCIF4>, 263 + <&cpg_clocks R8A7779_CLK_S1>, <&scif_clk>; 264 + clock-names = "fck", "brg_int", "scif_clk"; 268 265 power-domains = <&cpg_clocks>; 269 266 status = "disabled"; 270 267 }; ··· 275 270 "renesas,scif"; 276 271 reg = <0xffe45000 0x100>; 277 272 interrupts = <GIC_SPI 93 IRQ_TYPE_LEVEL_HIGH>; 278 - clocks = <&mstp0_clks R8A7779_CLK_SCIF5>; 279 - clock-names = "fck"; 273 + clocks = <&mstp0_clks R8A7779_CLK_SCIF5>, 274 + <&cpg_clocks R8A7779_CLK_S1>, <&scif_clk>; 275 + clock-names = "fck", "brg_int", "scif_clk"; 280 276 power-domains = <&cpg_clocks>; 281 277 status = "disabled"; 282 278 }; ··· 451 445 /* This value must be overriden by the board. */ 452 446 clock-frequency = <0>; 453 447 clock-output-names = "extal"; 448 + }; 449 + 450 + /* External SCIF clock */ 451 + scif_clk: scif { 452 + compatible = "fixed-clock"; 453 + #clock-cells = <0>; 454 + /* This value must be overridden by the board. */ 455 + clock-frequency = <0>; 456 + status = "disabled"; 454 457 }; 455 458 456 459 /* Special CPG clocks */