Commit 1b9dac68 authored by Samuel Holland's avatar Samuel Holland Committed by Jernej Skrabec
Browse files

arm64: dts: allwinner: Use constants for RTC clock indexes



The binding header provides descriptive names for the RTC clock indexes,
since the indexes were arbitrarily chosen by the binding, not by the
hardware. Let's use the names, so the meaning is clearer.

Signed-off-by: default avatarSamuel Holland <samuel@sholland.org>
Acked-by: default avatarJernej Skrabec <jernej.skrabec@gmail.com>
Signed-off-by: default avatarJernej Skrabec <jernej.skrabec@gmail.com>
Link: https://lore.kernel.org/r/20220607012438.18183-2-samuel@sholland.org
parent 8cce5702
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -58,7 +58,7 @@ ov5640_ep: endpoint {

	wifi_pwrseq: wifi-pwrseq {
		compatible = "mmc-pwrseq-simple";
		clocks = <&rtc 1>;
		clocks = <&rtc CLK_OSC32K_FANOUT>;
		clock-names = "ext_clock";
		reset-gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* WL-PMU-EN: PL2 */
	};
+2 −2
Original line number Diff line number Diff line
@@ -56,7 +56,7 @@ led-2 {
	wifi_pwrseq: wifi_pwrseq {
		compatible = "mmc-pwrseq-simple";
		reset-gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */
		clocks = <&rtc 1>;
		clocks = <&rtc CLK_OSC32K_FANOUT>;
		clock-names = "ext_clock";
	};
};
@@ -355,7 +355,7 @@ &uart1 {

	bluetooth {
		compatible = "brcm,bcm43438-bt";
		clocks = <&rtc 1>;
		clocks = <&rtc CLK_OSC32K_FANOUT>;
		clock-names = "lpo";
		vbat-supply = <&reg_dldo2>;
		vddio-supply = <&reg_dldo4>;
+1 −1
Original line number Diff line number Diff line
@@ -43,7 +43,7 @@ led {

	wifi_pwrseq: wifi_pwrseq {
		compatible = "mmc-pwrseq-simple";
		clocks = <&rtc 1>;
		clocks = <&rtc CLK_OSC32K_FANOUT>;
		clock-names = "ext_clock";
		reset-gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */
	};
+2 −2
Original line number Diff line number Diff line
@@ -71,7 +71,7 @@ reg_usb1_vbus: usb1-vbus {
	wifi_pwrseq: wifi_pwrseq {
		compatible = "mmc-pwrseq-simple";
		reset-gpios = <&r_pio 0 8 GPIO_ACTIVE_LOW>; /* PL8 */
		clocks = <&rtc 1>;
		clocks = <&rtc CLK_OSC32K_FANOUT>;
		clock-names = "ext_clock";
	};
};
@@ -369,7 +369,7 @@ &uart1 {
	bluetooth {
		compatible = "brcm,bcm43438-bt";
		max-speed = <1500000>;
		clocks = <&rtc 1>;
		clocks = <&rtc CLK_OSC32K_FANOUT>;
		clock-names = "lpo";
		vbat-supply = <&reg_dldo2>;
		vddio-supply = <&reg_dldo4>;
+6 −4
Original line number Diff line number Diff line
@@ -4,6 +4,7 @@
//    Copyright (C) 2015 Jens Kuske <jenskuske@gmail.com>

#include <dt-bindings/clock/sun50i-a64-ccu.h>
#include <dt-bindings/clock/sun6i-rtc.h>
#include <dt-bindings/clock/sun8i-de2.h>
#include <dt-bindings/clock/sun8i-r-ccu.h>
#include <dt-bindings/interrupt-controller/arm-gic.h>
@@ -660,7 +661,7 @@ ohci1: usb@1c1b400 {
		ccu: clock@1c20000 {
			compatible = "allwinner,sun50i-a64-ccu";
			reg = <0x01c20000 0x400>;
			clocks = <&osc24M>, <&rtc 0>;
			clocks = <&osc24M>, <&rtc CLK_OSC32K>;
			clock-names = "hosc", "losc";
			#clock-cells = <1>;
			#reset-cells = <1>;
@@ -673,7 +674,8 @@ pio: pinctrl@1c20800 {
			interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>,
				     <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>,
				     <GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH>;
			clocks = <&ccu CLK_BUS_PIO>, <&osc24M>, <&rtc 0>;
			clocks = <&ccu CLK_BUS_PIO>, <&osc24M>,
				 <&rtc CLK_OSC32K>;
			clock-names = "apb", "hosc", "losc";
			gpio-controller;
			#gpio-cells = <3>;
@@ -1226,7 +1228,7 @@ hdmi: hdmi@1ee0000 {
			reg-io-width = <1>;
			interrupts = <GIC_SPI 88 IRQ_TYPE_LEVEL_HIGH>;
			clocks = <&ccu CLK_BUS_HDMI>, <&ccu CLK_HDMI_DDC>,
				 <&ccu CLK_HDMI>, <&rtc 0>;
				 <&ccu CLK_HDMI>, <&rtc CLK_OSC32K>;
			clock-names = "iahb", "isfr", "tmds", "cec";
			resets = <&ccu RST_BUS_HDMI1>;
			reset-names = "ctrl";
@@ -1287,7 +1289,7 @@ r_intc: interrupt-controller@1f00c00 {
		r_ccu: clock@1f01400 {
			compatible = "allwinner,sun50i-a64-r-ccu";
			reg = <0x01f01400 0x100>;
			clocks = <&osc24M>, <&rtc 0>, <&rtc 2>,
			clocks = <&osc24M>, <&rtc CLK_OSC32K>, <&rtc CLK_IOSC>,
				 <&ccu CLK_PLL_PERIPH0>;
			clock-names = "hosc", "losc", "iosc", "pll-periph";
			#clock-cells = <1>;
Loading