Commit 3d2ef3b3 authored by Olof Johansson's avatar Olof Johansson

Merge tag 'sunxi-dt-for-4.4-3' of...

Merge tag 'sunxi-dt-for-4.4-3' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux into next/dt

Allwinner DT changes for 4.4, round 3

A bunch of new boards, but mostly enable the support for the Audio Codec
on the older SoCs (A10, A10s, A13, A20, R8) and enable it on various
boards.

* tag 'sunxi-dt-for-4.4-3' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux:
  ARM: dts: sun6i: Add dts file for MSI Primo81 tablet
  ARM: dts: sun6i: Add simplefb node labels to reference at board level
  ARM: dts: sun4i: Enable audio codec on Marsboard A10.
  ARM: dts: sun4i: Add dts file for the pov protab2-ips9 tablet
  ARM: sun4i: Enable cubieboard audio codec
  ARM: sun5i: chip: Enable the audio codec
  ARM: sun4i: Enable audio-codec on Mele A1000
  ARM: sun7i: Enable cubieboard2 audio codec
  ARM: sun7i: dt: enable audio codec on Cubietruck
  ARM: sun7i: Add sunxi codec device node
  ARM: sun5i: Add the Audio codec DT node
  ARM: sun4i: Add sunxi codec device node
  ARM: sun7i: Add audio codec clock
  ARM: sun5i: Add audio codec clock
  ARM: sun4i: Add audio codec clock
  ARM: sun7i: Add audio PLL
  ARM: sun5i: Add audio PLL
  ARM: sun4i: Add audio PLL
  ARM: dts: sun7i: Enable USB DRC on pcDuino v3 Nano
  ARM: dts: sun6i: Add support for Sinlinx A31s SDK board
Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
parents edd2a06d a5ea06d0
...@@ -603,7 +603,8 @@ dtb-$(CONFIG_MACH_SUN4I) += \ ...@@ -603,7 +603,8 @@ dtb-$(CONFIG_MACH_SUN4I) += \
sun4i-a10-mk802ii.dtb \ sun4i-a10-mk802ii.dtb \
sun4i-a10-olinuxino-lime.dtb \ sun4i-a10-olinuxino-lime.dtb \
sun4i-a10-pcduino.dtb \ sun4i-a10-pcduino.dtb \
sun4i-a10-pcduino2.dtb sun4i-a10-pcduino2.dtb \
sun4i-a10-pov-protab2-ips9.dtb
dtb-$(CONFIG_MACH_SUN5I) += \ dtb-$(CONFIG_MACH_SUN5I) += \
sun5i-a10s-auxtek-t003.dtb \ sun5i-a10s-auxtek-t003.dtb \
sun5i-a10s-auxtek-t004.dtb \ sun5i-a10s-auxtek-t004.dtb \
...@@ -626,6 +627,8 @@ dtb-$(CONFIG_MACH_SUN6I) += \ ...@@ -626,6 +627,8 @@ dtb-$(CONFIG_MACH_SUN6I) += \
sun6i-a31-m9.dtb \ sun6i-a31-m9.dtb \
sun6i-a31-mele-a1000g-quad.dtb \ sun6i-a31-mele-a1000g-quad.dtb \
sun6i-a31s-cs908.dtb \ sun6i-a31s-cs908.dtb \
sun6i-a31s-primo81.dtb \
sun6i-a31s-sina31s.dtb \
sun6i-a31s-sinovoip-bpi-m2.dtb \ sun6i-a31s-sinovoip-bpi-m2.dtb \
sun6i-a31s-yones-toptech-bs1078-v2.dtb sun6i-a31s-yones-toptech-bs1078-v2.dtb
dtb-$(CONFIG_MACH_SUN7I) += \ dtb-$(CONFIG_MACH_SUN7I) += \
......
...@@ -93,6 +93,10 @@ &ahci { ...@@ -93,6 +93,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&ehci0 { &ehci0 {
status = "okay"; status = "okay";
}; };
......
...@@ -83,6 +83,10 @@ &ahci { ...@@ -83,6 +83,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
}; };
......
...@@ -91,6 +91,10 @@ &ahci { ...@@ -91,6 +91,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&ehci0 { &ehci0 {
status = "okay"; status = "okay";
}; };
......
/*
* Copyright 2015 Hans de Goede <hdegoede@redhat.com>
*
* This file is dual-licensed: you can use it either under the terms
* of the GPL or the X11 license, at your option. Note that this dual
* licensing only applies to this file, and not this project as a
* whole.
*
* a) This file is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* Or, alternatively,
*
* b) Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following
* conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
* OTHER DEALINGS IN THE SOFTWARE.
*/
/dts-v1/;
#include "sun4i-a10.dtsi"
#include "sunxi-common-regulators.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
/ {
model = "Point of View Protab2-IPS9";
compatible = "pov,protab2-ips9", "allwinner,sun4i-a10";
aliases {
serial0 = &uart0;
};
chosen {
stdout-path = "serial0:115200n8";
};
};
&cpu0 {
cpu-supply = <&reg_dcdc2>;
};
&ehci0 {
status = "okay";
};
&i2c0 {
pinctrl-names = "default";
pinctrl-0 = <&i2c0_pins_a>;
status = "okay";
axp209: pmic@34 {
reg = <0x34>;
interrupts = <0>;
};
};
#include "axp209.dtsi"
&i2c1 {
pinctrl-names = "default";
pinctrl-0 = <&i2c1_pins_a>;
/* pull-ups and devices require AXP209 LDO3 */
status = "failed";
};
&i2c2 {
pinctrl-names = "default";
pinctrl-0 = <&i2c2_pins_a>;
status = "okay";
};
&lradc {
vref-supply = <&reg_ldo2>;
status = "okay";
button@400 {
label = "Volume Up";
linux,code = <KEY_VOLUMEUP>;
channel = <0>;
voltage = <400000>;
};
button@800 {
label = "Volume Down";
linux,code = <KEY_VOLUMEDOWN>;
channel = <0>;
voltage = <800000>;
};
};
&mmc0 {
pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>;
vmmc-supply = <&reg_vcc3v3>;
bus-width = <4>;
cd-gpios = <&pio 7 1 GPIO_ACTIVE_HIGH>; /* PH1 */
cd-inverted;
status = "okay";
};
&otg_sram {
status = "okay";
};
&pio {
usb0_id_detect_pin: usb0_id_detect_pin@0 {
allwinner,pins = "PH4";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
usb0_vbus_detect_pin: usb0_vbus_detect_pin@0 {
allwinner,pins = "PH5";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_DOWN>;
};
};
&reg_dcdc2 {
regulator-always-on;
regulator-min-microvolt = <1000000>;
regulator-max-microvolt = <1400000>;
regulator-name = "vdd-cpu";
};
&reg_dcdc3 {
regulator-always-on;
regulator-min-microvolt = <1250000>;
regulator-max-microvolt = <1250000>;
regulator-name = "vdd-int-dll";
};
&reg_ldo1 {
regulator-name = "vdd-rtc";
};
&reg_ldo2 {
regulator-always-on;
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-name = "avcc";
};
&reg_usb0_vbus {
status = "okay";
};
&reg_usb1_vbus {
status = "okay";
};
&uart0 {
pinctrl-names = "default";
pinctrl-0 = <&uart0_pins_a>;
status = "okay";
};
&usb_otg {
dr_mode = "otg";
status = "okay";
};
&usbphy {
pinctrl-names = "default";
pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
usb0_vbus-supply = <&reg_usb0_vbus>;
usb1_vbus-supply = <&reg_usb1_vbus>;
status = "okay";
};
...@@ -45,6 +45,7 @@ ...@@ -45,6 +45,7 @@
#include <dt-bindings/thermal/thermal.h> #include <dt-bindings/thermal/thermal.h>
#include <dt-bindings/clock/sun4i-a10-pll2.h>
#include <dt-bindings/dma/sun4i-a10.h> #include <dt-bindings/dma/sun4i-a10.h>
#include <dt-bindings/pinctrl/sun4i-a10.h> #include <dt-bindings/pinctrl/sun4i-a10.h>
...@@ -195,6 +196,15 @@ pll1: clk@01c20000 { ...@@ -195,6 +196,15 @@ pll1: clk@01c20000 {
clock-output-names = "pll1"; clock-output-names = "pll1";
}; };
pll2: clk@01c20008 {
#clock-cells = <1>;
compatible = "allwinner,sun4i-a10-pll2-clk";
reg = <0x01c20008 0x8>;
clocks = <&osc24M>;
clock-output-names = "pll2-1x", "pll2-2x",
"pll2-4x", "pll2-8x";
};
pll4: clk@01c20018 { pll4: clk@01c20018 {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun4i-a10-pll1-clk"; compatible = "allwinner,sun4i-a10-pll1-clk";
...@@ -481,6 +491,14 @@ spi3_clk: clk@01c200d4 { ...@@ -481,6 +491,14 @@ spi3_clk: clk@01c200d4 {
clocks = <&osc24M>, <&pll6 1>, <&pll5 1>; clocks = <&osc24M>, <&pll6 1>, <&pll5 1>;
clock-output-names = "spi3"; clock-output-names = "spi3";
}; };
codec_clk: clk@01c20140 {
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-codec-clk";
reg = <0x01c20140 0x4>;
clocks = <&pll2 SUN4I_A10_PLL2_1X>;
clock-output-names = "codec";
};
}; };
soc@01c00000 { soc@01c00000 {
...@@ -1004,6 +1022,19 @@ lradc: lradc@01c22800 { ...@@ -1004,6 +1022,19 @@ lradc: lradc@01c22800 {
status = "disabled"; status = "disabled";
}; };
codec: codec@01c22c00 {
#sound-dai-cells = <0>;
compatible = "allwinner,sun4i-a10-codec";
reg = <0x01c22c00 0x40>;
interrupts = <30>;
clocks = <&apb0_gates 0>, <&codec_clk>;
clock-names = "apb", "codec";
dmas = <&dma SUN4I_DMA_NORMAL 19>,
<&dma SUN4I_DMA_NORMAL 19>;
dma-names = "rx", "tx";
status = "disabled";
};
sid: eeprom@01c23800 { sid: eeprom@01c23800 {
compatible = "allwinner,sun4i-a10-sid"; compatible = "allwinner,sun4i-a10-sid";
reg = <0x01c23800 0x10>; reg = <0x01c23800 0x10>;
......
...@@ -66,6 +66,10 @@ chosen { ...@@ -66,6 +66,10 @@ chosen {
}; };
}; };
&codec {
status = "okay";
};
&ehci0 { &ehci0 {
status = "okay"; status = "okay";
}; };
......
...@@ -44,6 +44,7 @@ ...@@ -44,6 +44,7 @@
#include "skeleton.dtsi" #include "skeleton.dtsi"
#include <dt-bindings/clock/sun4i-a10-pll2.h>
#include <dt-bindings/dma/sun4i-a10.h> #include <dt-bindings/dma/sun4i-a10.h>
#include <dt-bindings/pinctrl/sun4i-a10.h> #include <dt-bindings/pinctrl/sun4i-a10.h>
...@@ -102,6 +103,15 @@ pll1: clk@01c20000 { ...@@ -102,6 +103,15 @@ pll1: clk@01c20000 {
clock-output-names = "pll1"; clock-output-names = "pll1";
}; };
pll2: clk@01c20008 {
#clock-cells = <1>;
compatible = "allwinner,sun5i-a13-pll2-clk";
reg = <0x01c20008 0x8>;
clocks = <&osc24M>;
clock-output-names = "pll2-1x", "pll2-2x",
"pll2-4x", "pll2-8x";
};
pll4: clk@01c20018 { pll4: clk@01c20018 {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun4i-a10-pll1-clk"; compatible = "allwinner,sun4i-a10-pll1-clk";
...@@ -285,6 +295,14 @@ usb_clk: clk@01c200cc { ...@@ -285,6 +295,14 @@ usb_clk: clk@01c200cc {
clock-output-names = "usb_ohci0", "usb_phy"; clock-output-names = "usb_ohci0", "usb_phy";
}; };
codec_clk: clk@01c20140 {
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-codec-clk";
reg = <0x01c20140 0x4>;
clocks = <&pll2 SUN4I_A10_PLL2_1X>;
clock-output-names = "codec";
};
mbus_clk: clk@01c2015c { mbus_clk: clk@01c2015c {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun5i-a13-mbus-clk"; compatible = "allwinner,sun5i-a13-mbus-clk";
...@@ -571,6 +589,19 @@ lradc: lradc@01c22800 { ...@@ -571,6 +589,19 @@ lradc: lradc@01c22800 {
status = "disabled"; status = "disabled";
}; };
codec: codec@01c22c00 {
#sound-dai-cells = <0>;
compatible = "allwinner,sun4i-a10-codec";
reg = <0x01c22c00 0x40>;
interrupts = <30>;
clocks = <&apb0_gates 0>, <&codec_clk>;
clock-names = "apb", "codec";
dmas = <&dma SUN4I_DMA_NORMAL 19>,
<&dma SUN4I_DMA_NORMAL 19>;
dma-names = "rx", "tx";
status = "disabled";
};
sid: eeprom@01c23800 { sid: eeprom@01c23800 {
compatible = "allwinner,sun4i-a10-sid"; compatible = "allwinner,sun4i-a10-sid";
reg = <0x01c23800 0x10>; reg = <0x01c23800 0x10>;
......
...@@ -61,7 +61,7 @@ chosen { ...@@ -61,7 +61,7 @@ chosen {
#size-cells = <1>; #size-cells = <1>;
ranges; ranges;
framebuffer@0 { simplefb_hdmi: framebuffer@0 {
compatible = "allwinner,simple-framebuffer", compatible = "allwinner,simple-framebuffer",
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_be0-lcd0-hdmi"; allwinner,pipeline = "de_be0-lcd0-hdmi";
...@@ -69,7 +69,7 @@ framebuffer@0 { ...@@ -69,7 +69,7 @@ framebuffer@0 {
status = "disabled"; status = "disabled";
}; };
framebuffer@1 { simplefb_lcd: framebuffer@1 {
compatible = "allwinner,simple-framebuffer", compatible = "allwinner,simple-framebuffer",
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_be0-lcd0"; allwinner,pipeline = "de_be0-lcd0";
......
/*
* Copyright 2014 Siarhei Siamashka <siarhei.siamashka@gmail.com>
* Copyright 2015 Karsten Merker <merker@debian.org>
* Copyright 2015 Chen-Yu Tsai <wens@csie.org>
*
* This file is dual-licensed: you can use it either under the terms
* of the GPL or the X11 license, at your option. Note that this dual
* licensing only applies to this file, and not this project as a
* whole.
*
* a) This file is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* Or, alternatively,
*
* b) Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following
* conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
* OTHER DEALINGS IN THE SOFTWARE.
*/
/dts-v1/;
#include "sun6i-a31s.dtsi"
#include "sunxi-common-regulators.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
/ {
model = "MSI Primo81 tablet";
compatible = "msi,primo81", "allwinner,sun6i-a31s";
};
&cpu0 {
cpu-supply = <&reg_dcdc3>;
};
&ehci0 {
/* rtl8188etv wifi is connected here */
status = "okay";
};
&i2c0 {
/* pull-ups and device VDDIO use AXP221 DLDO3 */
pinctrl-names = "default";
pinctrl-0 = <&i2c0_pins_a>;
status = "failed";
};
&i2c1 {
pinctrl-names = "default";
pinctrl-0 = <&i2c1_pins_a>;
status = "okay";
ctp@5d {
pinctrl-names = "default";
pinctrl-0 = <&gt911_int_primo81>;
compatible = "goodix,gt911";
reg = <0x5d>;
interrupt-parent = <&pio>;
interrupts = <0 3 IRQ_TYPE_LEVEL_HIGH>; /* PA3 */
};
};
&i2c2 {
pinctrl-names = "default";
pinctrl-0 = <&i2c2_pins_a>;
status = "okay";
accelerometer@1c {
pinctrl-names = "default";
pinctrl-0 = <&mma8452_int_primo81>;
compatible = "fsl,mma8452";
reg = <0x1c>;
interrupt-parent = <&pio>;
interrupts = <0 9 IRQ_TYPE_LEVEL_HIGH>; /* PA9 */
#io-channel-cells = <1>;
};
};
&lradc {
vref-supply = <&reg_aldo3>;
status = "okay";
button@158 {
label = "Volume Up";
linux,code = <KEY_VOLUMEUP>;
channel = <0>;
voltage = <158730>;
};
button@349 {
label = "Volume Down";
linux,code = <KEY_VOLUMEDOWN>;
channel = <0>;
voltage = <349206>;
};
};
&mmc0 {
pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_primo81>;
vmmc-supply = <&reg_dcdc1>;
bus-width = <4>;
cd-gpios = <&pio 0 8 GPIO_ACTIVE_HIGH>; /* PA8 */
cd-inverted;
status = "okay";
};
&pio {
gt911_int_primo81: gt911_int_pin@0 {
allwinner,pins = "PA3";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
mma8452_int_primo81: mma8452_int_pin@0 {
allwinner,pins = "PA9";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
mmc0_cd_pin_primo81: mmc0_cd_pin@0 {
allwinner,pins = "PA8";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
};
&p2wi {
status = "okay";
axp22x: pmic@68 {
compatible = "x-powers,axp221";
reg = <0x68>;
interrupt-parent = <&nmi_intc>;
interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
};
};
#include "axp22x.dtsi"
&reg_aldo3 {
regulator-always-on;
regulator-min-microvolt = <2700000>;
regulator-max-microvolt = <3300000>;
regulator-name = "avcc";
};
&reg_dc1sw {
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-name = "vcc-lcd";
};
&reg_dc5ldo {
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-cpus"; /* This is an educated guess */
};
&reg_dcdc1 {
regulator-always-on;
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-name = "vcc-3v0";
};
&reg_dcdc2 {
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-gpu";
};
&reg_dcdc3 {
regulator-always-on;
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-cpu";
};
&reg_dcdc4 {
regulator-always-on;
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-sys-dll";
};
&reg_dcdc5 {
regulator-always-on;
regulator-min-microvolt = <1500000>;
regulator-max-microvolt = <1500000>;
regulator-name = "vcc-dram";
};
&reg_dldo1 {
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-name = "vcc-wifi";
};
&reg_dldo3 {
regulator-min-microvolt = <2800000>;
regulator-max-microvolt = <2800000>;
regulator-name = "vddio-csi";
};
&reg_eldo3 {
regulator-min-microvolt = <1080000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-mipi-bridge";
};
&simplefb_lcd {
vcc-lcd-supply = <&reg_dc1sw>;
vdd-mipi-bridge-supply = <&reg_eldo3>;
};
&usb_otg {
/* otg support requires support for AXP221 usb-power-supply and GPIO */
dr_mode = "host";
status = "okay";
};
&usbphy {
usb1_vbus-supply = <&reg_dldo1>;
status = "okay";
};
/*
* Copyright 2015 Chen-Yu Tsai <wens@csie.org>
*
* This file is dual-licensed: you can use it either under the terms
* of the GPL or the X11 license, at your option. Note that this dual
* licensing only applies to this file, and not this project as a
* whole.
*
* a) This file is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* Or, alternatively,
*
* b) Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following
* conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
* OTHER DEALINGS IN THE SOFTWARE.
*/
/dts-v1/;
#include "sun6i-a31s.dtsi"
#include "sunxi-common-regulators.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
/ {
model = "Sinlinx SinA31s Core Board";
compatible = "sinlinx,sina31s", "allwinner,sun6i-a31s";
aliases {
serial0 = &uart0;
};
};
&cpu0 {
cpu-supply = <&reg_dcdc3>;
};
/* eMMC on core board */
&mmc2 {
pinctrl-names = "default";
pinctrl-0 = <&mmc2_8bit_emmc_pins>;
vmmc-supply = <&reg_dcdc1>;
bus-width = <8>;
non-removable;
status = "okay";
};
/* AXP221s PMIC on core board */
&p2wi {
status = "okay";
axp22x: pmic@68 {
compatible = "x-powers,axp221";
reg = <0x68>;
interrupt-parent = <&nmi_intc>;
interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
};
};
#include "axp22x.dtsi"
&reg_aldo3 {
regulator-always-on;
regulator-min-microvolt = <2700000>;
regulator-max-microvolt = <3300000>;
regulator-name = "avcc";
};
&reg_dc5ldo {
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-cpus";
};
&reg_dcdc1 {
regulator-always-on;
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-name = "vcc-3v0";
};
&reg_dcdc2 {
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-gpu";
};
&reg_dcdc3 {
regulator-always-on;
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-cpu";
};
&reg_dcdc4 {
regulator-always-on;
regulator-min-microvolt = <700000>;
regulator-max-microvolt = <1320000>;
regulator-name = "vdd-sys-dll";
};
&reg_dcdc5 {
regulator-always-on;
regulator-min-microvolt = <1500000>;
regulator-max-microvolt = <1500000>;
regulator-name = "vcc-dram";
};
/* UART0 pads available on core board */
&uart0 {
pinctrl-names = "default";
pinctrl-0 = <&uart0_pins_a>;
status = "okay";
};
/*
* Copyright 2015 Chen-Yu Tsai <wens@csie.org>
*
* This file is dual-licensed: you can use it either under the terms
* of the GPL or the X11 license, at your option. Note that this dual
* licensing only applies to this file, and not this project as a
* whole.
*
* a) This file is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* Or, alternatively,
*
* b) Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following
* conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
* OTHER DEALINGS IN THE SOFTWARE.
*/
/* The SinA31s development board has the SinA31s core board soldered on */
#include "sun6i-a31s-sina31s-core.dtsi"
#include <dt-bindings/input/input.h>
/ {
model = "Sinlinx SinA31s Development Board";
compatible = "sinlinx,sina31s-sdk", "allwinner,sun6i-a31s";
chosen {
stdout-path = "serial0:115200n8";
};
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
pinctrl-0 = <&led_pin_sina31s>;
status {
label = "sina31s:status:usr";
gpios = <&pio 7 13 GPIO_ACTIVE_HIGH>; /* PH13 */
};
};
};
&ehci0 {
/* USB 2.0 4 port hub IC */
status = "okay";
};
&ehci1 {
status = "okay";
};
&gmac {
pinctrl-names = "default";
pinctrl-0 = <&gmac_pins_mii_a>;
phy = <&phy1>;
phy-mode = "mii";
phy-supply = <&reg_dldo1>;
status = "okay";
phy1: ethernet-phy@1 {
reg = <1>;
};
};
&ir {
pinctrl-names = "default";
pinctrl-0 = <&ir_pins_a>;
status = "okay";
};
&lradc {
vref-supply = <&reg_aldo3>;
status = "okay";
button@158 {
label = "Volume Up";
linux,code = <KEY_VOLUMEUP>;
channel = <0>;
voltage = <158730>;
};
button@349 {
label = "Volume Down";
linux,code = <KEY_VOLUMEDOWN>;
channel = <0>;
voltage = <349206>;
};
};
&mmc0 {
pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_sina31s>;
vmmc-supply = <&reg_dcdc1>;
bus-width = <4>;
cd-gpios = <&pio 0 4 GPIO_ACTIVE_HIGH>; /* PA4 */
cd-inverted;
status = "okay";
};
&ohci1 {
status = "okay";
};
&pio {
led_pin_sina31s: led_pin@0 {
allwinner,pins = "PH13";
allwinner,function = "gpio_out";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
mmc0_cd_pin_sina31s: mmc0_cd_pin@0 {
allwinner,pins = "PA4";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
};
&reg_dldo1 {
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-name = "vcc-gmac-phy";
};
&usbphy {
status = "okay";
};
...@@ -84,6 +84,10 @@ &ahci { ...@@ -84,6 +84,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
}; };
......
...@@ -101,6 +101,10 @@ &ahci { ...@@ -101,6 +101,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
}; };
......
...@@ -142,6 +142,10 @@ &ohci1 { ...@@ -142,6 +142,10 @@ &ohci1 {
status = "okay"; status = "okay";
}; };
&otg_sram {
status = "okay";
};
&pio { &pio {
ahci_pwr_pin_pcduino3_nano: ahci_pwr_pin@0 { ahci_pwr_pin_pcduino3_nano: ahci_pwr_pin@0 {
allwinner,pins = "PH2"; allwinner,pins = "PH2";
...@@ -157,6 +161,13 @@ led_pins_pcduino3_nano: led_pins@0 { ...@@ -157,6 +161,13 @@ led_pins_pcduino3_nano: led_pins@0 {
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
}; };
usb0_id_detect_pin: usb0_id_detect_pin@0 {
allwinner,pins = "PH4";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
usb1_vbus_pin_pcduino3_nano: usb1_vbus_pin@0 { usb1_vbus_pin_pcduino3_nano: usb1_vbus_pin@0 {
allwinner,pins = "PD2"; allwinner,pins = "PD2";
allwinner,function = "gpio_out"; allwinner,function = "gpio_out";
...@@ -211,7 +222,15 @@ &uart0 { ...@@ -211,7 +222,15 @@ &uart0 {
status = "okay"; status = "okay";
}; };
&usb_otg {
dr_mode = "otg";
status = "okay";
};
&usbphy { &usbphy {
pinctrl-names = "default";
pinctrl-0 = <&usb0_id_detect_pin>;
usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
usb1_vbus-supply = <&reg_usb1_vbus>; usb1_vbus-supply = <&reg_usb1_vbus>;
usb2_vbus-supply = <&reg_usb1_vbus>; usb2_vbus-supply = <&reg_usb1_vbus>;
status = "okay"; status = "okay";
......
...@@ -47,6 +47,7 @@ ...@@ -47,6 +47,7 @@
#include <dt-bindings/interrupt-controller/arm-gic.h> #include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/thermal/thermal.h> #include <dt-bindings/thermal/thermal.h>
#include <dt-bindings/clock/sun4i-a10-pll2.h>
#include <dt-bindings/dma/sun4i-a10.h> #include <dt-bindings/dma/sun4i-a10.h>
#include <dt-bindings/pinctrl/sun4i-a10.h> #include <dt-bindings/pinctrl/sun4i-a10.h>
...@@ -199,6 +200,15 @@ pll1: clk@01c20000 { ...@@ -199,6 +200,15 @@ pll1: clk@01c20000 {
clock-output-names = "pll1"; clock-output-names = "pll1";
}; };
pll2: clk@01c20008 {
#clock-cells = <1>;
compatible = "allwinner,sun4i-a10-pll2-clk";
reg = <0x01c20008 0x8>;
clocks = <&osc24M>;
clock-output-names = "pll2-1x", "pll2-2x",
"pll2-4x", "pll2-8x";
};
pll4: clk@01c20018 { pll4: clk@01c20018 {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun7i-a20-pll4-clk"; compatible = "allwinner,sun7i-a20-pll4-clk";
...@@ -491,6 +501,14 @@ spi3_clk: clk@01c200d4 { ...@@ -491,6 +501,14 @@ spi3_clk: clk@01c200d4 {
clock-output-names = "spi3"; clock-output-names = "spi3";
}; };
codec_clk: clk@01c20140 {
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-codec-clk";
reg = <0x01c20140 0x4>;
clocks = <&pll2 SUN4I_A10_PLL2_1X>;
clock-output-names = "codec";
};
mbus_clk: clk@01c2015c { mbus_clk: clk@01c2015c {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun5i-a13-mbus-clk"; compatible = "allwinner,sun5i-a13-mbus-clk";
...@@ -1198,6 +1216,19 @@ lradc: lradc@01c22800 { ...@@ -1198,6 +1216,19 @@ lradc: lradc@01c22800 {
status = "disabled"; status = "disabled";
}; };
codec: codec@01c22c00 {
#sound-dai-cells = <0>;
compatible = "allwinner,sun7i-a20-codec";
reg = <0x01c22c00 0x40>;
interrupts = <GIC_SPI 30 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&apb0_gates 0>, <&codec_clk>;
clock-names = "apb", "codec";
dmas = <&dma SUN4I_DMA_NORMAL 19>,
<&dma SUN4I_DMA_NORMAL 19>;
dma-names = "rx", "tx";
status = "disabled";
};
sid: eeprom@01c23800 { sid: eeprom@01c23800 {
compatible = "allwinner,sun7i-a20-sid"; compatible = "allwinner,sun7i-a20-sid";
reg = <0x01c23800 0x200>; reg = <0x01c23800 0x200>;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment