From 80ee72e7e9acee39e66db4037a2235f23236ab94 Mon Sep 17 00:00:00 2001 From: Chen-Yu Tsai Date: Thu, 17 Nov 2016 17:34:38 +0800 Subject: ARM: dts: sunxi: Explicitly enable pull-ups for MMC pins In the past, all the MMC pins had allwinner,pull = ; which was actually a no-op. We were relying on U-boot to set the bias pull up for us. These properties were removed as part of the fix up to actually support no bias on the pins. During the transition some boards experienced regular MMC time-outs during normal operation, while others completely failed to initialize the SD card. Given that MMC starts in open-drain mode and the pull-ups are required, it's best to enable it for all the pin settings. Signed-off-by: Chen-Yu Tsai Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun8i-a23-a33.dtsi | 3 +++ 1 file changed, 3 insertions(+) (limited to 'arch/arm/boot/dts/sun8i-a23-a33.dtsi') diff --git a/arch/arm/boot/dts/sun8i-a23-a33.dtsi b/arch/arm/boot/dts/sun8i-a23-a33.dtsi index ecb49a5a7615..bc3e936edfcf 100644 --- a/arch/arm/boot/dts/sun8i-a23-a33.dtsi +++ b/arch/arm/boot/dts/sun8i-a23-a33.dtsi @@ -293,6 +293,7 @@ "PF3", "PF4", "PF5"; function = "mmc0"; drive-strength = <30>; + bias-pull-up; }; mmc1_pins_a: mmc1@0 { @@ -300,6 +301,7 @@ "PG3", "PG4", "PG5"; function = "mmc1"; drive-strength = <30>; + bias-pull-up; }; mmc2_8bit_pins: mmc2_8bit { @@ -309,6 +311,7 @@ "PC15", "PC16"; function = "mmc2"; drive-strength = <30>; + bias-pull-up; }; pwm0_pins: pwm0 { -- cgit From 7d1be43fe08969da84567ebb55f779e32aaf4229 Mon Sep 17 00:00:00 2001 From: Icenowy Zheng Date: Tue, 13 Dec 2016 23:22:49 +0800 Subject: ARM: dts: sun8i: add a cpu0 label to cpu@0 node on A23/33 A "cpu0" label is needed on cpu@0 for cpufreq-dt to work. Add such a label, in order to prepare for cpufreq support of A23/33. Signed-off-by: Icenowy Zheng Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun8i-a23-a33.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch/arm/boot/dts/sun8i-a23-a33.dtsi') diff --git a/arch/arm/boot/dts/sun8i-a23-a33.dtsi b/arch/arm/boot/dts/sun8i-a23-a33.dtsi index bc3e936edfcf..46bae51d2ba6 100644 --- a/arch/arm/boot/dts/sun8i-a23-a33.dtsi +++ b/arch/arm/boot/dts/sun8i-a23-a33.dtsi @@ -84,7 +84,7 @@ #address-cells = <1>; #size-cells = <0>; - cpu@0 { + cpu0: cpu@0 { compatible = "arm,cortex-a7"; device_type = "cpu"; reg = <0>; -- cgit From 7f5d64f369f482df8005dd076bd6b2c94493247c Mon Sep 17 00:00:00 2001 From: Chen-Yu Tsai Date: Fri, 25 Nov 2016 20:34:37 +0800 Subject: ARM: dts: sun8i: Add codec analog path controls node in PRCM for A23/A33 On the A23/A33, the internal codec's analog path controls are located in the PRCM node. Add a sub-device node to the PRCM for it. Signed-off-by: Chen-Yu Tsai Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun8i-a23-a33.dtsi | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'arch/arm/boot/dts/sun8i-a23-a33.dtsi') diff --git a/arch/arm/boot/dts/sun8i-a23-a33.dtsi b/arch/arm/boot/dts/sun8i-a23-a33.dtsi index 46bae51d2ba6..597f2fce6c31 100644 --- a/arch/arm/boot/dts/sun8i-a23-a33.dtsi +++ b/arch/arm/boot/dts/sun8i-a23-a33.dtsi @@ -538,6 +538,10 @@ compatible = "allwinner,sun6i-a31-clock-reset"; #reset-cells = <1>; }; + + codec_analog: codec-analog { + compatible = "allwinner,sun8i-a23-codec-analog"; + }; }; cpucfg@01f01c00 { -- cgit From e7f68403f49e901732df3c02731b6e714cfbe417 Mon Sep 17 00:00:00 2001 From: Maxime Ripard Date: Mon, 23 Jan 2017 11:41:51 +0100 Subject: ARM: sun8i: a23/a33: Enable the real LOSC and use it So far, the LOSC was generated through the RTC internal oscillator, which was a pretty poor and inaccurate choice. Now that the RTC properly exposes its internal mux between its oscillator and the external oscillator, we can use it were relevant. Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun8i-a23-a33.dtsi | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'arch/arm/boot/dts/sun8i-a23-a33.dtsi') diff --git a/arch/arm/boot/dts/sun8i-a23-a33.dtsi b/arch/arm/boot/dts/sun8i-a23-a33.dtsi index 597f2fce6c31..da7f2476bc6c 100644 --- a/arch/arm/boot/dts/sun8i-a23-a33.dtsi +++ b/arch/arm/boot/dts/sun8i-a23-a33.dtsi @@ -109,11 +109,11 @@ clock-output-names = "osc24M"; }; - osc32k: osc32k_clk { + ext_osc32k: ext_osc32k_clk { #clock-cells = <0>; compatible = "fixed-clock"; clock-frequency = <32768>; - clock-output-names = "osc32k"; + clock-output-names = "ext-osc32k"; }; }; @@ -256,7 +256,7 @@ ccu: clock@01c20000 { reg = <0x01c20000 0x400>; - clocks = <&osc24M>, <&osc32k>; + clocks = <&osc24M>, <&rtc 0>; clock-names = "hosc", "losc"; #clock-cells = <1>; #reset-cells = <1>; @@ -266,7 +266,7 @@ /* compatible gets set in SoC specific dtsi file */ reg = <0x01c20800 0x400>; /* interrupts get set in SoC specific dtsi file */ - clocks = <&ccu CLK_BUS_PIO>, <&osc24M>, <&osc32k>; + clocks = <&ccu CLK_BUS_PIO>, <&osc24M>, <&rtc 0>; clock-names = "apb", "hosc", "losc"; gpio-controller; interrupt-controller; @@ -486,6 +486,9 @@ reg = <0x01f00000 0x54>; interrupts = , ; + clock-output-names = "osc32k"; + clocks = <&ext_osc32k>; + #clock-cells = <1>; }; nmi_intc: interrupt-controller@01f00c0c { @@ -564,7 +567,7 @@ compatible = "allwinner,sun8i-a23-r-pinctrl"; reg = <0x01f02c00 0x400>; interrupts = ; - clocks = <&apb0_gates 0>, <&osc24M>, <&osc32k>; + clocks = <&apb0_gates 0>, <&osc24M>, <&rtc 0>; clock-names = "apb", "hosc", "losc"; resets = <&apb0_rst 0>; gpio-controller; -- cgit From fc26feeb2eff08720b1035ba72097fc14f95f7af Mon Sep 17 00:00:00 2001 From: Maxime Ripard Date: Mon, 23 Jan 2017 11:41:52 +0100 Subject: ARM: sun8i: a23/a33: Add the oscillators accuracy The datasheet provided by Allwinner requires oscillators with an accuracy of 50ppm. Add it to our fixed clocks so that we can properly track the accuracy chain. Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun8i-a23-a33.dtsi | 2 ++ 1 file changed, 2 insertions(+) (limited to 'arch/arm/boot/dts/sun8i-a23-a33.dtsi') diff --git a/arch/arm/boot/dts/sun8i-a23-a33.dtsi b/arch/arm/boot/dts/sun8i-a23-a33.dtsi index da7f2476bc6c..d92fdf5a7b26 100644 --- a/arch/arm/boot/dts/sun8i-a23-a33.dtsi +++ b/arch/arm/boot/dts/sun8i-a23-a33.dtsi @@ -106,6 +106,7 @@ #clock-cells = <0>; compatible = "fixed-clock"; clock-frequency = <24000000>; + clock-accuracy = <50000>; clock-output-names = "osc24M"; }; @@ -113,6 +114,7 @@ #clock-cells = <0>; compatible = "fixed-clock"; clock-frequency = <32768>; + clock-accuracy = <50000>; clock-output-names = "ext-osc32k"; }; }; -- cgit