Commit 74386da4 authored by Olof Johansson's avatar Olof Johansson

Merge tag 'sunxi-dt-for-4.5' of...

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

Allwinner DT changes for 4.5

Allwinner device-tree related patches for the 4.5 merge window.
  * Support for the H3
  * Addition of the RSB to the relevant devices (sun8i, sun9i)
  * Addition of the Video Engine clocks for the older SoCs (sun4i, sun7i)
  * Addition of the DRAM gates for the older SoCs (sun4i, sun7i)
  * Addition of the audio codec to a bunch of boards
  * New board: ICNova SWAC

* tag 'sunxi-dt-for-4.5' of https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux: (40 commits)
  ARM: dts: sun7i: Olimex A20-SOM-EVB: Enable mmc3 (baseboard SD socket)
  ARM: dts: sun7i: Olimex A20-SOM-EVB: Add LRADC keys
  ARM: dts: sun9i: cubieboard4: Enable Reduced Serial Bus controller
  ARM: dts: sun9i: cubieboard4: Enable consumer IR receiver
  ARM: dts: sun9i: cubieboard4: Enable LEDs
  ARM: dts: sun7i: Add VE (Video Engine) module clock node
  ARM: dts: sun4i: Add VE (Video Engine) module clock node
  ARM: dts: sun8i: Add Orange Pi Plus support
  ARM: dts: sunxi: Add Allwinner H3 DTSI
  ARM: dts: sun7i: Add DRAM gates
  ARM: dts: sun4i: Add DRAM gates
  ARM: dts: sun9i: Add NMI controller device node
  ARM: dts: sun9i: optimus: Enable Reduced Serial Bus controller
  ARM: dts: sun9i: Add Reduced Serial Bus controller device node to A80 dtsi
  ARM: dts: sun9i: optimus: Enable consumer IR receiver
  ARM: dts: sun9i: Add consumer IR receiver device node and pinmux settings
  ARM: dts: sun9i: optimus: Enable LED3
  ARM: dts: sun9i: Add A80 R_PIO pin controller device node
  ARM: dts: sun9i: Add TODO comments for the main and low power clocks
  ARM: dts: sun9i: Add A80 PRCM clocks and reset control nodes
  ...
Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
parents 69c8e667 2367cee5
...@@ -651,6 +651,7 @@ dtb-$(CONFIG_MACH_SUN7I) += \ ...@@ -651,6 +651,7 @@ dtb-$(CONFIG_MACH_SUN7I) += \
sun7i-a20-cubietruck.dtb \ sun7i-a20-cubietruck.dtb \
sun7i-a20-hummingbird.dtb \ sun7i-a20-hummingbird.dtb \
sun7i-a20-i12-tvbox.dtb \ sun7i-a20-i12-tvbox.dtb \
sun7i-a20-icnova-swac.dtb \
sun7i-a20-m3.dtb \ sun7i-a20-m3.dtb \
sun7i-a20-mk808c.dtb \ sun7i-a20-mk808c.dtb \
sun7i-a20-olimex-som-evb.dtb \ sun7i-a20-olimex-som-evb.dtb \
...@@ -673,7 +674,8 @@ dtb-$(CONFIG_MACH_SUN8I) += \ ...@@ -673,7 +674,8 @@ dtb-$(CONFIG_MACH_SUN8I) += \
sun8i-a33-ga10h-v1.1.dtb \ sun8i-a33-ga10h-v1.1.dtb \
sun8i-a33-ippo-q8h-v1.2.dtb \ sun8i-a33-ippo-q8h-v1.2.dtb \
sun8i-a33-q8-tablet.dtb \ sun8i-a33-q8-tablet.dtb \
sun8i-a33-sinlinx-sina33.dtb sun8i-a33-sinlinx-sina33.dtb \
sun8i-h3-orangepi-plus.dtb
dtb-$(CONFIG_MACH_SUN9I) += \ dtb-$(CONFIG_MACH_SUN9I) += \
sun9i-a80-optimus.dtb \ sun9i-a80-optimus.dtb \
sun9i-a80-cubieboard4.dtb sun9i-a80-cubieboard4.dtb
......
...@@ -65,12 +65,19 @@ chosen { ...@@ -65,12 +65,19 @@ chosen {
/* /*
* TODO: * TODO:
* 2x cameras via CSI * 2x cameras via CSI
* audio * audio input
* AXP battery management * AXP battery management
* NAND * NAND
* OTG * OTG
* Touchscreen - gt801_2plus1 @ i2c adapter 2 @ 0x48 * Touchscreen - gt801_2plus1 @ i2c adapter 2 @ 0x48
*/ */
&codec {
status = "okay";
};
&cpu0 {
cpu-supply = <&reg_dcdc2>;
};
&ehci0 { &ehci0 {
status = "okay"; status = "okay";
...@@ -86,15 +93,13 @@ &i2c0 { ...@@ -86,15 +93,13 @@ &i2c0 {
status = "okay"; status = "okay";
axp209: pmic@34 { axp209: pmic@34 {
compatible = "x-powers,axp209";
reg = <0x34>; reg = <0x34>;
interrupts = <0>; interrupts = <0>;
interrupt-controller;
#interrupt-cells = <1>;
}; };
}; };
#include "axp209.dtsi"
&i2c1 { &i2c1 {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&i2c1_pins_a>; pinctrl-0 = <&i2c1_pins_a>;
...@@ -110,7 +115,7 @@ bma250@18 { ...@@ -110,7 +115,7 @@ bma250@18 {
}; };
&lradc { &lradc {
vref-supply = <&reg_vcc3v0>; vref-supply = <&reg_ldo2>;
status = "okay"; status = "okay";
...@@ -146,6 +151,31 @@ &mmc0 { ...@@ -146,6 +151,31 @@ &mmc0 {
status = "okay"; status = "okay";
}; };
&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_usb1_vbus { &reg_usb1_vbus {
status = "okay"; status = "okay";
}; };
......
...@@ -47,6 +47,7 @@ ...@@ -47,6 +47,7 @@
#include <dt-bindings/input/input.h> #include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/pinctrl/sun4i-a10.h> #include <dt-bindings/pinctrl/sun4i-a10.h>
#include <dt-bindings/pwm/pwm.h>
/ { / {
model = "iNet-1"; model = "iNet-1";
...@@ -56,11 +57,25 @@ aliases { ...@@ -56,11 +57,25 @@ aliases {
serial0 = &uart0; serial0 = &uart0;
}; };
backlight: backlight {
compatible = "pwm-backlight";
pinctrl-names = "default";
pinctrl-0 = <&bl_en_pin_inet>;
pwms = <&pwm 0 50000 PWM_POLARITY_INVERTED>;
brightness-levels = <0 10 20 30 40 50 60 70 80 90 100>;
default-brightness-level = <8>;
enable-gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; /* PH7 */
};
chosen { chosen {
stdout-path = "serial0:115200n8"; stdout-path = "serial0:115200n8";
}; };
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
}; };
...@@ -104,6 +119,19 @@ &i2c2 { ...@@ -104,6 +119,19 @@ &i2c2 {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&i2c2_pins_a>; pinctrl-0 = <&i2c2_pins_a>;
status = "okay"; status = "okay";
ft5x: touchscreen@38 {
compatible = "edt,edt-ft5406";
reg = <0x38>;
interrupt-parent = <&pio>;
interrupts = <7 21 IRQ_TYPE_EDGE_FALLING>;
pinctrl-names = "default";
pinctrl-0 = <&touchscreen_wake_pin>;
wake-gpios = <&pio 1 13 GPIO_ACTIVE_HIGH>; /* PB13 */
touchscreen-size-x = <600>;
touchscreen-size-y = <1024>;
touchscreen-swapped-x-y;
};
}; };
&lradc { &lradc {
...@@ -151,6 +179,20 @@ &otg_sram { ...@@ -151,6 +179,20 @@ &otg_sram {
}; };
&pio { &pio {
bl_en_pin_inet: bl_en_pin@0 {
allwinner,pins = "PH7";
allwinner,function = "gpio_out";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
touchscreen_wake_pin: touchscreen_wake_pin@0 {
allwinner,pins = "PB13";
allwinner,function = "gpio_out";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
usb0_id_detect_pin: usb0_id_detect_pin@0 { usb0_id_detect_pin: usb0_id_detect_pin@0 {
allwinner,pins = "PH4"; allwinner,pins = "PH4";
allwinner,function = "gpio_in"; allwinner,function = "gpio_in";
...@@ -166,6 +208,12 @@ usb0_vbus_detect_pin: usb0_vbus_detect_pin@0 { ...@@ -166,6 +208,12 @@ usb0_vbus_detect_pin: usb0_vbus_detect_pin@0 {
}; };
}; };
&pwm {
pinctrl-names = "default";
pinctrl-0 = <&pwm0_pins_a>;
status = "okay";
};
&reg_dcdc2 { &reg_dcdc2 {
regulator-always-on; regulator-always-on;
regulator-min-microvolt = <1000000>; regulator-min-microvolt = <1000000>;
......
...@@ -59,6 +59,159 @@ aliases { ...@@ -59,6 +59,159 @@ aliases {
chosen { chosen {
stdout-path = "serial0:115200n8"; stdout-path = "serial0:115200n8";
}; };
gpio_keys {
compatible = "gpio-keys-polled";
pinctrl-names = "default";
pinctrl-0 = <&key_pins_inet9f>;
#address-cells = <1>;
#size-cells = <0>;
poll-interval = <20>;
button@0 {
label = "Left Joystick Left";
linux,code = <ABS_X>;
linux,input-type = <EV_ABS>;
linux,input-value = <0xffffffff>; /* -1 */
gpios = <&pio 0 6 GPIO_ACTIVE_LOW>; /* PA6 */
};
button@1 {
label = "Left Joystick Right";
linux,code = <ABS_X>;
linux,input-type = <EV_ABS>;
linux,input-value = <1>;
gpios = <&pio 0 5 GPIO_ACTIVE_LOW>; /* PA5 */
};
button@2 {
label = "Left Joystick Up";
linux,code = <ABS_Y>;
linux,input-type = <EV_ABS>;
linux,input-value = <0xffffffff>; /* -1 */
gpios = <&pio 0 8 GPIO_ACTIVE_LOW>; /* PA8 */
};
button@3 {
label = "Left Joystick Down";
linux,code = <ABS_Y>;
linux,input-type = <EV_ABS>;
linux,input-value = <1>;
gpios = <&pio 0 9 GPIO_ACTIVE_LOW>; /* PA9 */
};
button@4 {
label = "Right Joystick Left";
linux,code = <ABS_Z>;
linux,input-type = <EV_ABS>;
linux,input-value = <0xffffffff>; /* -1 */
gpios = <&pio 0 1 GPIO_ACTIVE_LOW>; /* PA1 */
};
button@5 {
label = "Right Joystick Right";
linux,code = <ABS_Z>;
linux,input-type = <EV_ABS>;
linux,input-value = <1>;
gpios = <&pio 0 0 GPIO_ACTIVE_LOW>; /* PA0 */
};
button@6 {
label = "Right Joystick Up";
linux,code = <ABS_RZ>;
linux,input-type = <EV_ABS>;
linux,input-value = <0xffffffff>; /* -1 */
gpios = <&pio 0 3 GPIO_ACTIVE_LOW>; /* PA3 */
};
button@7 {
label = "Right Joystick Down";
linux,code = <ABS_RZ>;
linux,input-type = <EV_ABS>;
linux,input-value = <1>;
gpios = <&pio 0 4 GPIO_ACTIVE_LOW>; /* PA4 */
};
button@8 {
label = "DPad Left";
linux,code = <ABS_HAT0X>;
linux,input-type = <EV_ABS>;
linux,input-value = <0xffffffff>; /* -1 */
gpios = <&pio 7 23 GPIO_ACTIVE_LOW>; /* PH23 */
};
button@9 {
label = "DPad Right";
linux,code = <ABS_HAT0X>;
linux,input-type = <EV_ABS>;
linux,input-value = <1>;
gpios = <&pio 7 24 GPIO_ACTIVE_LOW>; /* PH24 */
};
button@10 {
label = "DPad Up";
linux,code = <ABS_HAT0Y>;
linux,input-type = <EV_ABS>;
linux,input-value = <0xffffffff>; /* -1 */
gpios = <&pio 7 25 GPIO_ACTIVE_LOW>; /* PH25 */
};
button@11 {
label = "DPad Down";
linux,code = <ABS_HAT0Y>;
linux,input-type = <EV_ABS>;
linux,input-value = <1>;
gpios = <&pio 7 26 GPIO_ACTIVE_LOW>; /* PH26 */
};
button@12 {
label = "Button X";
linux,code = <BTN_X>;
gpios = <&pio 0 16 GPIO_ACTIVE_LOW>; /* PA16 */
};
button@13 {
label = "Button Y";
linux,code = <BTN_Y>;
gpios = <&pio 0 14 GPIO_ACTIVE_LOW>; /* PA14 */
};
button@14 {
label = "Button A";
linux,code = <BTN_A>;
gpios = <&pio 0 17 GPIO_ACTIVE_LOW>; /* PA17 */
};
button@15 {
label = "Button B";
linux,code = <BTN_B>;
gpios = <&pio 0 15 GPIO_ACTIVE_LOW>; /* PA15 */
};
button@16 {
label = "Select Button";
linux,code = <BTN_SELECT>;
gpios = <&pio 0 11 GPIO_ACTIVE_LOW>; /* PA11 */
};
button@17 {
label = "Start Button";
linux,code = <BTN_START>;
gpios = <&pio 0 12 GPIO_ACTIVE_LOW>; /* PA12 */
};
button@18 {
label = "Top Left Button";
linux,code = <BTN_TL>;
gpios = <&pio 7 22 GPIO_ACTIVE_LOW>; /* PH22 */
};
button@19 {
label = "Top Right Button";
linux,code = <BTN_TR>;
gpios = <&pio 0 13 GPIO_ACTIVE_LOW>; /* PA13 */
};
};
}; };
&cpu0 { &cpu0 {
...@@ -157,6 +310,17 @@ &otg_sram { ...@@ -157,6 +310,17 @@ &otg_sram {
}; };
&pio { &pio {
key_pins_inet9f: key_pins@0 {
allwinner,pins = "PA0", "PA1", "PA3", "PA4",
"PA5", "PA6", "PA8", "PA9",
"PA11", "PA12", "PA13",
"PA14", "PA15", "PA16", "PA17",
"PH22", "PH23", "PH24", "PH25", "PH26";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
usb0_id_detect_pin: usb0_id_detect_pin@0 { usb0_id_detect_pin: usb0_id_detect_pin@0 {
allwinner,pins = "PH4"; allwinner,pins = "PH4";
allwinner,function = "gpio_in"; allwinner,function = "gpio_in";
......
...@@ -47,6 +47,7 @@ ...@@ -47,6 +47,7 @@
#include <dt-bindings/input/input.h> #include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/pinctrl/sun4i-a10.h> #include <dt-bindings/pinctrl/sun4i-a10.h>
#include <dt-bindings/pwm/pwm.h>
/ { / {
model = "Point of View Protab2-IPS9"; model = "Point of View Protab2-IPS9";
...@@ -56,6 +57,16 @@ aliases { ...@@ -56,6 +57,16 @@ aliases {
serial0 = &uart0; serial0 = &uart0;
}; };
backlight: backlight {
compatible = "pwm-backlight";
pinctrl-names = "default";
pinctrl-0 = <&bl_en_pin_protab>;
pwms = <&pwm 0 50000 PWM_POLARITY_INVERTED>;
brightness-levels = <0 10 20 30 40 50 60 70 80 90 100>;
default-brightness-level = <8>;
enable-gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; /* PH7 */
};
chosen { chosen {
stdout-path = "serial0:115200n8"; stdout-path = "serial0:115200n8";
}; };
...@@ -93,6 +104,22 @@ &i2c2 { ...@@ -93,6 +104,22 @@ &i2c2 {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&i2c2_pins_a>; pinctrl-0 = <&i2c2_pins_a>;
status = "okay"; status = "okay";
pixcir_ts@5c {
pinctrl-names = "default";
pinctrl-0 = <&touchscreen_pins>;
compatible = "pixcir,pixcir_tangoc";
reg = <0x5c>;
interrupt-parent = <&pio>;
interrupts = <7 21 IRQ_TYPE_EDGE_FALLING>; /* EINT21 (PH21) */
attb-gpio = <&pio 7 21 GPIO_ACTIVE_HIGH>; /* PH21 */
enable-gpios = <&pio 0 5 GPIO_ACTIVE_LOW>;
wake-gpios = <&pio 1 13 GPIO_ACTIVE_LOW>;
touchscreen-size-x = <1024>;
touchscreen-size-y = <768>;
touchscreen-inverted-x;
touchscreen-inverted-y;
};
}; };
&lradc { &lradc {
...@@ -129,6 +156,20 @@ &otg_sram { ...@@ -129,6 +156,20 @@ &otg_sram {
}; };
&pio { &pio {
bl_en_pin_protab: bl_en_pin@0 {
allwinner,pins = "PH7";
allwinner,function = "gpio_out";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
touchscreen_pins: touchscreen_pins@0 {
allwinner,pins = "PA5", "PB13";
allwinner,function = "gpio_out";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
usb0_id_detect_pin: usb0_id_detect_pin@0 { usb0_id_detect_pin: usb0_id_detect_pin@0 {
allwinner,pins = "PH4"; allwinner,pins = "PH4";
allwinner,function = "gpio_in"; allwinner,function = "gpio_in";
...@@ -144,6 +185,12 @@ usb0_vbus_detect_pin: usb0_vbus_detect_pin@0 { ...@@ -144,6 +185,12 @@ usb0_vbus_detect_pin: usb0_vbus_detect_pin@0 {
}; };
}; };
&pwm {
pinctrl-names = "default";
pinctrl-0 = <&pwm0_pins_a>;
status = "okay";
};
&reg_dcdc2 { &reg_dcdc2 {
regulator-always-on; regulator-always-on;
regulator-min-microvolt = <1000000>; regulator-min-microvolt = <1000000>;
......
...@@ -66,7 +66,7 @@ framebuffer@0 { ...@@ -66,7 +66,7 @@ framebuffer@0 {
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_be0-lcd0-hdmi"; allwinner,pipeline = "de_be0-lcd0-hdmi";
clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 43>, clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 43>,
<&ahb_gates 44>; <&ahb_gates 44>, <&dram_gates 26>;
status = "disabled"; status = "disabled";
}; };
...@@ -75,7 +75,8 @@ framebuffer@1 { ...@@ -75,7 +75,8 @@ framebuffer@1 {
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_fe0-de_be0-lcd0-hdmi"; allwinner,pipeline = "de_fe0-de_be0-lcd0-hdmi";
clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 43>, clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 43>,
<&ahb_gates 44>, <&ahb_gates 46>; <&ahb_gates 44>, <&ahb_gates 46>,
<&dram_gates 25>, <&dram_gates 26>;
status = "disabled"; status = "disabled";
}; };
...@@ -84,7 +85,8 @@ framebuffer@2 { ...@@ -84,7 +85,8 @@ framebuffer@2 {
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_fe0-de_be0-lcd0"; allwinner,pipeline = "de_fe0-de_be0-lcd0";
clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 44>, clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 44>,
<&ahb_gates 46>; <&ahb_gates 46>, <&dram_gates 25>,
<&dram_gates 26>;
status = "disabled"; status = "disabled";
}; };
...@@ -93,7 +95,8 @@ framebuffer@3 { ...@@ -93,7 +95,8 @@ framebuffer@3 {
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_fe0-de_be0-lcd0-tve0"; allwinner,pipeline = "de_fe0-de_be0-lcd0-tve0";
clocks = <&pll5 1>, <&ahb_gates 34>, <&ahb_gates 36>, clocks = <&pll5 1>, <&ahb_gates 34>, <&ahb_gates 36>,
<&ahb_gates 44>, <&ahb_gates 46>; <&ahb_gates 44>, <&ahb_gates 46>,
<&dram_gates 25>, <&dram_gates 26>;
status = "disabled"; status = "disabled";
}; };
}; };
...@@ -492,6 +495,40 @@ spi3_clk: clk@01c200d4 { ...@@ -492,6 +495,40 @@ spi3_clk: clk@01c200d4 {
clock-output-names = "spi3"; clock-output-names = "spi3";
}; };
dram_gates: clk@01c20100 {
#clock-cells = <1>;
compatible = "allwinner,sun4i-a10-dram-gates-clk";
reg = <0x01c20100 0x4>;
clocks = <&pll5 0>;
clock-indices = <0>,
<1>, <2>,
<3>,
<4>,
<5>, <6>,
<15>,
<24>, <25>,
<26>, <27>,
<28>, <29>;
clock-output-names = "dram_ve",
"dram_csi0", "dram_csi1",
"dram_ts",
"dram_tvd",
"dram_tve0", "dram_tve1",
"dram_output",
"dram_de_fe1", "dram_de_fe0",
"dram_de_be0", "dram_de_be1",
"dram_de_mp", "dram_ace";
};
ve_clk: clk@01c2013c {
#clock-cells = <0>;
#reset-cells = <0>;
compatible = "allwinner,sun4i-a10-ve-clk";
reg = <0x01c2013c 0x4>;
clocks = <&pll4>;
clock-output-names = "ve";
};
codec_clk: clk@01c20140 { codec_clk: clk@01c20140 {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun4i-a10-codec-clk"; compatible = "allwinner,sun4i-a10-codec-clk";
......
...@@ -86,6 +86,20 @@ &ehci0 { ...@@ -86,6 +86,20 @@ &ehci0 {
status = "okay"; status = "okay";
}; };
&i2c0 {
pinctrl-names = "default";
pinctrl-0 = <&i2c0_pins_a>;
status = "okay";
axp152: pmic@30 {
compatible = "x-powers,axp152";
reg = <0x30>;
interrupts = <0>;
interrupt-controller;
#interrupt-cells = <1>;
};
};
&mmc0 { &mmc0 {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_t004>; pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_t004>;
......
...@@ -47,11 +47,21 @@ ...@@ -47,11 +47,21 @@
#include <dt-bindings/input/input.h> #include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/pinctrl/sun4i-a10.h> #include <dt-bindings/pinctrl/sun4i-a10.h>
#include <dt-bindings/pwm/pwm.h>
/ { / {
model = "Utoo P66"; model = "Utoo P66";
compatible = "utoo,p66", "allwinner,sun5i-a13"; compatible = "utoo,p66", "allwinner,sun5i-a13";
backlight: backlight {
compatible = "pwm-backlight";
pwms = <&pwm 0 50000 PWM_POLARITY_INVERTED>;
/* Note levels of 10 / 20% result in backlight off */
brightness-levels = <0 30 40 50 60 70 80 90 100>;
default-brightness-level = <6>;
/* TODO: backlight uses axp gpio1 as enable pin */
};
i2c_lcd: i2c@0 { i2c_lcd: i2c@0 {
/* The lcd panel i2c interface is hooked up via gpios */ /* The lcd panel i2c interface is hooked up via gpios */
compatible = "i2c-gpio"; compatible = "i2c-gpio";
...@@ -201,6 +211,12 @@ usb0_vbus_pin_a: usb0_vbus_pin@0 { ...@@ -201,6 +211,12 @@ usb0_vbus_pin_a: usb0_vbus_pin@0 {
}; };
}; };
&pwm {
pinctrl-names = "default";
pinctrl-0 = <&pwm0_pins>;
status = "okay";
};
&reg_dcdc2 { &reg_dcdc2 {
regulator-always-on; regulator-always-on;
regulator-min-microvolt = <1000000>; regulator-min-microvolt = <1000000>;
......
...@@ -113,18 +113,83 @@ &mmc0_pins_a { ...@@ -113,18 +113,83 @@ &mmc0_pins_a {
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>; allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
}; };
&reg_usb1_vbus { &p2wi {
gpio = <&pio 7 27 GPIO_ACTIVE_HIGH>;
status = "okay"; status = "okay";
axp22x: pmic@68 {
compatible = "x-powers,axp221";
reg = <0x68>;
interrupt-parent = <&nmi_intc>;
interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
};
}; };
&usb1_vbus_pin_a { #include "axp22x.dtsi"
allwinner,pins = "PH27";
&reg_aldo3 {
regulator-always-on;
regulator-min-microvolt = <2700000>;
regulator-max-microvolt = <3300000>;
regulator-name = "avcc";
}; };
&usbphy { &reg_dc1sw {
usb1_vbus-supply = <&reg_usb1_vbus>; regulator-name = "vcc-lcd-usb2";
status = "okay"; regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
};
&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";
};
&reg_dldo1 {
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-name = "vcc-wifi";
};
/* Voltage source for I2C pullup resistors for I2C Bus 0 */
&reg_dldo3 {
regulator-min-microvolt = <2800000>;
regulator-max-microvolt = <2800000>;
regulator-name = "vddio-csi";
}; };
&uart0 { &uart0 {
...@@ -132,3 +197,9 @@ &uart0 { ...@@ -132,3 +197,9 @@ &uart0 {
pinctrl-0 = <&uart0_pins_a>; pinctrl-0 = <&uart0_pins_a>;
status = "okay"; status = "okay";
}; };
&usbphy {
usb1_vbus-supply = <&reg_dldo1>;
usb2_vbus-supply = <&reg_dc1sw>;
status = "okay";
};
...@@ -92,6 +92,10 @@ &ahci { ...@@ -92,6 +92,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
operating-points = < operating-points = <
......
/*
* Copyright 2015 Stefan Roese <sr@denx.de>
*
* 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 "sun7i-a20.dtsi"
#include "sunxi-common-regulators.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
/ {
model = "ICnova-A20 SWAC";
compatible = "swac,icnova-a20-swac", "incircuit,icnova-a20", "allwinner,sun7i-a20";
aliases {
serial0 = &uart0;
};
chosen {
stdout-path = "serial0:115200n8";
};
};
&cpu0 {
cpu-supply = <&reg_dcdc2>;
};
&ehci0 {
status = "okay";
};
&ehci1 {
status = "okay";
};
&gmac {
pinctrl-names = "default";
pinctrl-0 = <&gmac_pins_mii_a>;
phy = <&phy1>;
phy-mode = "mii";
status = "okay";
phy1: ethernet-phy@1 {
reg = <1>;
};
};
&i2c0 {
pinctrl-names = "default";
pinctrl-0 = <&i2c0_pins_a>;
status = "okay";
axp209: pmic@34 {
reg = <0x34>;
interrupt-parent = <&nmi_intc>;
interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
};
};
&i2c1 {
pinctrl-names = "default";
pinctrl-0 = <&i2c1_pins_a>;
status = "okay";
};
&mmc0 {
pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>;
vmmc-supply = <&reg_vcc3v3>;
bus-width = <4>;
cd-gpios = <&pio 8 5 GPIO_ACTIVE_HIGH>; /* PI5 */
cd-inverted;
status = "okay";
};
&ohci0 {
status = "okay";
};
&ohci1 {
status = "okay";
};
#include "axp209.dtsi"
&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 = <1000000>;
regulator-max-microvolt = <1400000>;
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_usb1_vbus {
status = "okay";
};
&reg_usb2_vbus {
status = "okay";
};
&uart0 {
pinctrl-names = "default";
pinctrl-0 = <&uart0_pins_a>;
status = "okay";
};
&usbphy {
usb1_vbus-supply = <&reg_usb1_vbus>;
usb2_vbus-supply = <&reg_usb2_vbus>;
status = "okay";
};
/* /*
* Copyright 2015 - Marcus Cooper <codekipper@gmail.com> * Copyright 2015 - Marcus Cooper <codekipper@gmail.com>
* Copyright 2015 - Karsten Merker <merker@debian.org>
* *
* This file is dual-licensed: you can use it either under the terms * 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 * of the GPL or the X11 license, at your option. Note that this dual
...@@ -45,6 +46,7 @@ ...@@ -45,6 +46,7 @@
#include "sunxi-common-regulators.dtsi" #include "sunxi-common-regulators.dtsi"
#include <dt-bindings/gpio/gpio.h> #include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/pinctrl/sun4i-a10.h> #include <dt-bindings/pinctrl/sun4i-a10.h>
...@@ -86,6 +88,10 @@ &ehci1 { ...@@ -86,6 +88,10 @@ &ehci1 {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&gmac { &gmac {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&gmac_pins_rgmii_a>; pinctrl-0 = <&gmac_pins_rgmii_a>;
...@@ -110,6 +116,60 @@ axp209: pmic@34 { ...@@ -110,6 +116,60 @@ axp209: pmic@34 {
}; };
}; };
&lradc {
vref-supply = <&reg_vcc3v0>;
status = "okay";
button@190 {
label = "Volume Up";
linux,code = <KEY_VOLUMEUP>;
channel = <0>;
voltage = <190000>;
};
button@390 {
label = "Volume Down";
linux,code = <KEY_VOLUMEDOWN>;
channel = <0>;
voltage = <390000>;
};
button@600 {
label = "Menu";
linux,code = <KEY_MENU>;
channel = <0>;
voltage = <600000>;
};
button@800 {
label = "Search";
linux,code = <KEY_SEARCH>;
channel = <0>;
voltage = <800000>;
};
button@980 {
label = "Home";
linux,code = <KEY_HOMEPAGE>;
channel = <0>;
voltage = <980000>;
};
button@1180 {
label = "Esc";
linux,code = <KEY_ESC>;
channel = <0>;
voltage = <1180000>;
};
button@1400 {
label = "Enter";
linux,code = <KEY_ENTER>;
channel = <0>;
voltage = <1400000>;
};
};
&mmc0 { &mmc0 {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>; pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>;
...@@ -120,6 +180,16 @@ &mmc0 { ...@@ -120,6 +180,16 @@ &mmc0 {
status = "okay"; status = "okay";
}; };
&mmc3 {
pinctrl-names = "default";
pinctrl-0 = <&mmc3_pins_a>, <&mmc3_cd_pin_olimex_som_evb>;
vmmc-supply = <&reg_vcc3v3>;
bus-width = <4>;
cd-gpios = <&pio 7 0 GPIO_ACTIVE_HIGH>; /* PH0 */
cd-inverted;
status = "okay";
};
&ohci0 { &ohci0 {
status = "okay"; status = "okay";
}; };
...@@ -142,6 +212,13 @@ led_pins_olimex_som_evb: led_pins@0 { ...@@ -142,6 +212,13 @@ led_pins_olimex_som_evb: led_pins@0 {
allwinner,drive = <SUN4I_PINCTRL_20_MA>; allwinner,drive = <SUN4I_PINCTRL_20_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
}; };
mmc3_cd_pin_olimex_som_evb: mmc3_cd_pin@0 {
allwinner,pins = "PH0";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
}; };
&reg_ahci_5v { &reg_ahci_5v {
......
...@@ -95,6 +95,10 @@ &ahci { ...@@ -95,6 +95,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&ehci0 { &ehci0 {
status = "okay"; status = "okay";
}; };
......
...@@ -82,6 +82,10 @@ &ahci { ...@@ -82,6 +82,10 @@ &ahci {
status = "okay"; status = "okay";
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
}; };
......
...@@ -111,6 +111,10 @@ &ahci_pwr_pin_a { ...@@ -111,6 +111,10 @@ &ahci_pwr_pin_a {
allwinner,pins = "PH2"; allwinner,pins = "PH2";
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
}; };
......
...@@ -62,6 +62,10 @@ chosen { ...@@ -62,6 +62,10 @@ chosen {
}; };
}; };
&codec {
status = "okay";
};
&cpu0 { &cpu0 {
cpu-supply = <&reg_dcdc2>; cpu-supply = <&reg_dcdc2>;
}; };
......
...@@ -68,7 +68,7 @@ framebuffer@0 { ...@@ -68,7 +68,7 @@ framebuffer@0 {
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_be0-lcd0-hdmi"; allwinner,pipeline = "de_be0-lcd0-hdmi";
clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 43>, clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 43>,
<&ahb_gates 44>; <&ahb_gates 44>, <&dram_gates 26>;
status = "disabled"; status = "disabled";
}; };
...@@ -76,7 +76,8 @@ framebuffer@1 { ...@@ -76,7 +76,8 @@ framebuffer@1 {
compatible = "allwinner,simple-framebuffer", compatible = "allwinner,simple-framebuffer",
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_be0-lcd0"; allwinner,pipeline = "de_be0-lcd0";
clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 44>; clocks = <&pll5 1>, <&ahb_gates 36>, <&ahb_gates 44>,
<&dram_gates 26>;
status = "disabled"; status = "disabled";
}; };
...@@ -85,7 +86,7 @@ framebuffer@2 { ...@@ -85,7 +86,7 @@ framebuffer@2 {
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_be0-lcd0-tve0"; allwinner,pipeline = "de_be0-lcd0-tve0";
clocks = <&pll5 1>, <&ahb_gates 34>, <&ahb_gates 36>, clocks = <&pll5 1>, <&ahb_gates 34>, <&ahb_gates 36>,
<&ahb_gates 44>; <&ahb_gates 44>, <&dram_gates 26>;
status = "disabled"; status = "disabled";
}; };
}; };
...@@ -501,6 +502,40 @@ spi3_clk: clk@01c200d4 { ...@@ -501,6 +502,40 @@ spi3_clk: clk@01c200d4 {
clock-output-names = "spi3"; clock-output-names = "spi3";
}; };
dram_gates: clk@01c20100 {
#clock-cells = <1>;
compatible = "allwinner,sun4i-a10-dram-gates-clk";
reg = <0x01c20100 0x4>;
clocks = <&pll5 0>;
clock-indices = <0>,
<1>, <2>,
<3>,
<4>,
<5>, <6>,
<15>,
<24>, <25>,
<26>, <27>,
<28>, <29>;
clock-output-names = "dram_ve",
"dram_csi0", "dram_csi1",
"dram_ts",
"dram_tvd",
"dram_tve0", "dram_tve1",
"dram_output",
"dram_de_fe1", "dram_de_fe0",
"dram_de_be0", "dram_de_be1",
"dram_de_mp", "dram_ace";
};
ve_clk: clk@01c2013c {
#clock-cells = <0>;
#reset-cells = <0>;
compatible = "allwinner,sun4i-a10-ve-clk";
reg = <0x01c2013c 0x4>;
clocks = <&pll4>;
clock-output-names = "ve";
};
codec_clk: clk@01c20140 { codec_clk: clk@01c20140 {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun4i-a10-codec-clk"; compatible = "allwinner,sun4i-a10-codec-clk";
......
...@@ -56,7 +56,7 @@ chosen { ...@@ -56,7 +56,7 @@ chosen {
#size-cells = <1>; #size-cells = <1>;
ranges; ranges;
framebuffer@0 { simplefb_lcd: framebuffer@0 {
compatible = "allwinner,simple-framebuffer", compatible = "allwinner,simple-framebuffer",
"simple-framebuffer"; "simple-framebuffer";
allwinner,pipeline = "de_be0-lcd0"; allwinner,pipeline = "de_be0-lcd0";
......
/*
* Copyright (C) 2015 Jens Kuske <jenskuske@gmail.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 "sun8i-h3.dtsi"
#include "sunxi-common-regulators.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
/ {
model = "Xunlong Orange Pi Plus";
compatible = "xunlong,orangepi-plus", "allwinner,sun8i-h3";
aliases {
serial0 = &uart0;
};
chosen {
stdout-path = "serial0:115200n8";
};
};
&mmc0 {
pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin>;
vmmc-supply = <&reg_vcc3v3>;
bus-width = <4>;
cd-gpios = <&pio 5 6 GPIO_ACTIVE_HIGH>; /* PF6 */
cd-inverted;
status = "okay";
};
&uart0 {
pinctrl-names = "default";
pinctrl-0 = <&uart0_pins_a>;
status = "okay";
};
/*
* Copyright (C) 2015 Jens Kuske <jenskuske@gmail.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.
*/
#include "skeleton.dtsi"
#include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
/ {
interrupt-parent = <&gic>;
cpus {
#address-cells = <1>;
#size-cells = <0>;
cpu@0 {
compatible = "arm,cortex-a7";
device_type = "cpu";
reg = <0>;
};
cpu@1 {
compatible = "arm,cortex-a7";
device_type = "cpu";
reg = <1>;
};
cpu@2 {
compatible = "arm,cortex-a7";
device_type = "cpu";
reg = <2>;
};
cpu@3 {
compatible = "arm,cortex-a7";
device_type = "cpu";
reg = <3>;
};
};
timer {
compatible = "arm,armv7-timer";
interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
<GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
<GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
<GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
};
clocks {
#address-cells = <1>;
#size-cells = <1>;
ranges;
osc24M: osc24M_clk {
#clock-cells = <0>;
compatible = "fixed-clock";
clock-frequency = <24000000>;
clock-output-names = "osc24M";
};
osc32k: osc32k_clk {
#clock-cells = <0>;
compatible = "fixed-clock";
clock-frequency = <32768>;
clock-output-names = "osc32k";
};
pll1: clk@01c20000 {
#clock-cells = <0>;
compatible = "allwinner,sun8i-a23-pll1-clk";
reg = <0x01c20000 0x4>;
clocks = <&osc24M>;
clock-output-names = "pll1";
};
/* dummy clock until actually implemented */
pll5: pll5_clk {
#clock-cells = <0>;
compatible = "fixed-clock";
clock-frequency = <0>;
clock-output-names = "pll5";
};
pll6: clk@01c20028 {
#clock-cells = <1>;
compatible = "allwinner,sun6i-a31-pll6-clk";
reg = <0x01c20028 0x4>;
clocks = <&osc24M>;
clock-output-names = "pll6", "pll6x2";
};
pll6d2: pll6d2_clk {
#clock-cells = <0>;
compatible = "fixed-factor-clock";
clock-div = <2>;
clock-mult = <1>;
clocks = <&pll6 0>;
clock-output-names = "pll6d2";
};
/* dummy clock until pll6 can be reused */
pll8: pll8_clk {
#clock-cells = <0>;
compatible = "fixed-clock";
clock-frequency = <1>;
clock-output-names = "pll8";
};
cpu: cpu_clk@01c20050 {
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-cpu-clk";
reg = <0x01c20050 0x4>;
clocks = <&osc32k>, <&osc24M>, <&pll1>, <&pll1>;
clock-output-names = "cpu";
};
axi: axi_clk@01c20050 {
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-axi-clk";
reg = <0x01c20050 0x4>;
clocks = <&cpu>;
clock-output-names = "axi";
};
ahb1: ahb1_clk@01c20054 {
#clock-cells = <0>;
compatible = "allwinner,sun6i-a31-ahb1-clk";
reg = <0x01c20054 0x4>;
clocks = <&osc32k>, <&osc24M>, <&axi>, <&pll6 0>;
clock-output-names = "ahb1";
};
ahb2: ahb2_clk@01c2005c {
#clock-cells = <0>;
compatible = "allwinner,sun8i-h3-ahb2-clk";
reg = <0x01c2005c 0x4>;
clocks = <&ahb1>, <&pll6d2>;
clock-output-names = "ahb2";
};
apb1: apb1_clk@01c20054 {
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-apb0-clk";
reg = <0x01c20054 0x4>;
clocks = <&ahb1>;
clock-output-names = "apb1";
};
apb2: apb2_clk@01c20058 {
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-apb1-clk";
reg = <0x01c20058 0x4>;
clocks = <&osc32k>, <&osc24M>, <&pll6 0>, <&pll6 0>;
clock-output-names = "apb2";
};
bus_gates: clk@01c20060 {
#clock-cells = <1>;
compatible = "allwinner,sun8i-h3-bus-gates-clk";
reg = <0x01c20060 0x14>;
clocks = <&ahb1>, <&ahb2>, <&apb1>, <&apb2>;
clock-names = "ahb1", "ahb2", "apb1", "apb2";
clock-indices = <5>, <6>, <8>,
<9>, <10>, <13>,
<14>, <17>, <18>,
<19>, <20>,
<21>, <23>,
<24>, <25>,
<26>, <27>,
<28>, <29>,
<30>, <31>, <32>,
<35>, <36>, <37>,
<40>, <41>, <43>,
<44>, <52>, <53>,
<54>, <64>,
<65>, <69>, <72>,
<76>, <77>, <78>,
<96>, <97>, <98>,
<112>, <113>,
<114>, <115>,
<116>, <128>, <135>;
clock-output-names = "bus_ce", "bus_dma", "bus_mmc0",
"bus_mmc1", "bus_mmc2", "bus_nand",
"bus_sdram", "bus_gmac", "bus_ts",
"bus_hstimer", "bus_spi0",
"bus_spi1", "bus_otg",
"bus_otg_ehci0", "bus_ehci1",
"bus_ehci2", "bus_ehci3",
"bus_otg_ohci0", "bus_ohci1",
"bus_ohci2", "bus_ohci3", "bus_ve",
"bus_lcd0", "bus_lcd1", "bus_deint",
"bus_csi", "bus_tve", "bus_hdmi",
"bus_de", "bus_gpu", "bus_msgbox",
"bus_spinlock", "bus_codec",
"bus_spdif", "bus_pio", "bus_ths",
"bus_i2s0", "bus_i2s1", "bus_i2s2",
"bus_i2c0", "bus_i2c1", "bus_i2c2",
"bus_uart0", "bus_uart1",
"bus_uart2", "bus_uart3",
"bus_scr", "bus_ephy", "bus_dbg";
};
mmc0_clk: clk@01c20088 {
#clock-cells = <1>;
compatible = "allwinner,sun4i-a10-mmc-clk";
reg = <0x01c20088 0x4>;
clocks = <&osc24M>, <&pll6 0>, <&pll8>;
clock-output-names = "mmc0",
"mmc0_output",
"mmc0_sample";
};
mmc1_clk: clk@01c2008c {
#clock-cells = <1>;
compatible = "allwinner,sun4i-a10-mmc-clk";
reg = <0x01c2008c 0x4>;
clocks = <&osc24M>, <&pll6 0>, <&pll8>;
clock-output-names = "mmc1",
"mmc1_output",
"mmc1_sample";
};
mmc2_clk: clk@01c20090 {
#clock-cells = <1>;
compatible = "allwinner,sun4i-a10-mmc-clk";
reg = <0x01c20090 0x4>;
clocks = <&osc24M>, <&pll6 0>, <&pll8>;
clock-output-names = "mmc2",
"mmc2_output",
"mmc2_sample";
};
mbus_clk: clk@01c2015c {
#clock-cells = <0>;
compatible = "allwinner,sun8i-a23-mbus-clk";
reg = <0x01c2015c 0x4>;
clocks = <&osc24M>, <&pll6 1>, <&pll5>;
clock-output-names = "mbus";
};
};
soc {
compatible = "simple-bus";
#address-cells = <1>;
#size-cells = <1>;
ranges;
dma: dma-controller@01c02000 {
compatible = "allwinner,sun8i-h3-dma";
reg = <0x01c02000 0x1000>;
interrupts = <GIC_SPI 50 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bus_gates 6>;
resets = <&ahb_rst 6>;
#dma-cells = <1>;
};
mmc0: mmc@01c0f000 {
compatible = "allwinner,sun5i-a13-mmc";
reg = <0x01c0f000 0x1000>;
clocks = <&bus_gates 8>,
<&mmc0_clk 0>,
<&mmc0_clk 1>,
<&mmc0_clk 2>;
clock-names = "ahb",
"mmc",
"output",
"sample";
resets = <&ahb_rst 8>;
reset-names = "ahb";
interrupts = <GIC_SPI 60 IRQ_TYPE_LEVEL_HIGH>;
status = "disabled";
#address-cells = <1>;
#size-cells = <0>;
};
mmc1: mmc@01c10000 {
compatible = "allwinner,sun5i-a13-mmc";
reg = <0x01c10000 0x1000>;
clocks = <&bus_gates 9>,
<&mmc1_clk 0>,
<&mmc1_clk 1>,
<&mmc1_clk 2>;
clock-names = "ahb",
"mmc",
"output",
"sample";
resets = <&ahb_rst 9>;
reset-names = "ahb";
interrupts = <GIC_SPI 61 IRQ_TYPE_LEVEL_HIGH>;
status = "disabled";
#address-cells = <1>;
#size-cells = <0>;
};
mmc2: mmc@01c11000 {
compatible = "allwinner,sun5i-a13-mmc";
reg = <0x01c11000 0x1000>;
clocks = <&bus_gates 10>,
<&mmc2_clk 0>,
<&mmc2_clk 1>,
<&mmc2_clk 2>;
clock-names = "ahb",
"mmc",
"output",
"sample";
resets = <&ahb_rst 10>;
reset-names = "ahb";
interrupts = <GIC_SPI 62 IRQ_TYPE_LEVEL_HIGH>;
status = "disabled";
#address-cells = <1>;
#size-cells = <0>;
};
pio: pinctrl@01c20800 {
compatible = "allwinner,sun8i-h3-pinctrl";
reg = <0x01c20800 0x400>;
interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bus_gates 69>;
gpio-controller;
#gpio-cells = <3>;
interrupt-controller;
#interrupt-cells = <2>;
uart0_pins_a: uart0@0 {
allwinner,pins = "PA4", "PA5";
allwinner,function = "uart0";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
mmc0_pins_a: mmc0@0 {
allwinner,pins = "PF0", "PF1", "PF2", "PF3",
"PF4", "PF5";
allwinner,function = "mmc0";
allwinner,drive = <SUN4I_PINCTRL_30_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
mmc0_cd_pin: mmc0_cd_pin@0 {
allwinner,pins = "PF6";
allwinner,function = "gpio_in";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
mmc1_pins_a: mmc1@0 {
allwinner,pins = "PG0", "PG1", "PG2", "PG3",
"PG4", "PG5";
allwinner,function = "mmc1";
allwinner,drive = <SUN4I_PINCTRL_30_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
};
ahb_rst: reset@01c202c0 {
#reset-cells = <1>;
compatible = "allwinner,sun6i-a31-ahb1-reset";
reg = <0x01c202c0 0xc>;
};
apb1_rst: reset@01c202d0 {
#reset-cells = <1>;
compatible = "allwinner,sun6i-a31-clock-reset";
reg = <0x01c202d0 0x4>;
};
apb2_rst: reset@01c202d8 {
#reset-cells = <1>;
compatible = "allwinner,sun6i-a31-clock-reset";
reg = <0x01c202d8 0x4>;
};
timer@01c20c00 {
compatible = "allwinner,sun4i-a10-timer";
reg = <0x01c20c00 0xa0>;
interrupts = <GIC_SPI 18 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&osc24M>;
};
wdt0: watchdog@01c20ca0 {
compatible = "allwinner,sun6i-a31-wdt";
reg = <0x01c20ca0 0x20>;
interrupts = <GIC_SPI 25 IRQ_TYPE_LEVEL_HIGH>;
};
uart0: serial@01c28000 {
compatible = "snps,dw-apb-uart";
reg = <0x01c28000 0x400>;
interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
reg-shift = <2>;
reg-io-width = <4>;
clocks = <&bus_gates 112>;
resets = <&apb2_rst 16>;
dmas = <&dma 6>, <&dma 6>;
dma-names = "rx", "tx";
status = "disabled";
};
uart1: serial@01c28400 {
compatible = "snps,dw-apb-uart";
reg = <0x01c28400 0x400>;
interrupts = <GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH>;
reg-shift = <2>;
reg-io-width = <4>;
clocks = <&bus_gates 113>;
resets = <&apb2_rst 17>;
dmas = <&dma 7>, <&dma 7>;
dma-names = "rx", "tx";
status = "disabled";
};
uart2: serial@01c28800 {
compatible = "snps,dw-apb-uart";
reg = <0x01c28800 0x400>;
interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
reg-shift = <2>;
reg-io-width = <4>;
clocks = <&bus_gates 114>;
resets = <&apb2_rst 18>;
dmas = <&dma 8>, <&dma 8>;
dma-names = "rx", "tx";
status = "disabled";
};
uart3: serial@01c28c00 {
compatible = "snps,dw-apb-uart";
reg = <0x01c28c00 0x400>;
interrupts = <GIC_SPI 3 IRQ_TYPE_LEVEL_HIGH>;
reg-shift = <2>;
reg-io-width = <4>;
clocks = <&bus_gates 115>;
resets = <&apb2_rst 19>;
dmas = <&dma 9>, <&dma 9>;
dma-names = "rx", "tx";
status = "disabled";
};
gic: interrupt-controller@01c81000 {
compatible = "arm,cortex-a7-gic", "arm,cortex-a15-gic";
reg = <0x01c81000 0x1000>,
<0x01c82000 0x1000>,
<0x01c84000 0x2000>,
<0x01c86000 0x2000>;
interrupt-controller;
#interrupt-cells = <3>;
interrupts = <GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
};
rtc: rtc@01f00000 {
compatible = "allwinner,sun6i-a31-rtc";
reg = <0x01f00000 0x54>;
interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 41 IRQ_TYPE_LEVEL_HIGH>;
};
};
};
...@@ -62,9 +62,31 @@ chosen { ...@@ -62,9 +62,31 @@ chosen {
stdout-path = "serial0:115200n8"; stdout-path = "serial0:115200n8";
}; };
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
pinctrl-0 = <&led_pins_cubieboard4>;
green {
label = "cubieboard4:green:usr";
gpios = <&pio 7 17 GPIO_ACTIVE_HIGH>; /* PH17 */
};
red {
label = "cubieboard4:red:usr";
gpios = <&pio 7 6 GPIO_ACTIVE_HIGH>; /* PH6 */
};
};
}; };
&pio { &pio {
led_pins_cubieboard4: led-pins@0 {
allwinner,pins = "PH6", "PH17";
allwinner,function = "gpio_out";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
mmc0_cd_pin_cubieboard4: mmc0_cd_pin@0 { mmc0_cd_pin_cubieboard4: mmc0_cd_pin@0 {
allwinner,pins = "PH18"; allwinner,pins = "PH18";
allwinner,function = "gpio_in"; allwinner,function = "gpio_in";
...@@ -92,6 +114,14 @@ &mmc2 { ...@@ -92,6 +114,14 @@ &mmc2 {
status = "okay"; status = "okay";
}; };
&r_ir {
status = "okay";
};
&r_rsb {
status = "okay";
};
&uart0 { &uart0 {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&uart0_pins_a>; pinctrl-0 = <&uart0_pins_a>;
......
...@@ -65,7 +65,7 @@ chosen { ...@@ -65,7 +65,7 @@ chosen {
leds { leds {
compatible = "gpio-leds"; compatible = "gpio-leds";
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&led_pins_optimus>; pinctrl-0 = <&led_pins_optimus>, <&led_r_pins_optimus>;
/* The LED names match those found on the board */ /* The LED names match those found on the board */
...@@ -74,7 +74,10 @@ led2 { ...@@ -74,7 +74,10 @@ led2 {
gpios = <&pio 7 1 GPIO_ACTIVE_HIGH>; gpios = <&pio 7 1 GPIO_ACTIVE_HIGH>;
}; };
/* led3 is on PM15, in R_PIO */ led3 {
label = "optimus:led3:usr";
gpios = <&r_pio 1 15 GPIO_ACTIVE_HIGH>; /* PM15 */
};
led4 { led4 {
label = "optimus:led4:usr"; label = "optimus:led4:usr";
...@@ -180,6 +183,23 @@ &reg_usb1_vbus { ...@@ -180,6 +183,23 @@ &reg_usb1_vbus {
status = "okay"; status = "okay";
}; };
&r_ir {
status = "okay";
};
&r_pio {
led_r_pins_optimus: led-pins@1 {
allwinner,pins = "PM15";
allwinner,function = "gpio_out";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
};
&r_rsb {
status = "okay";
};
&uart0 { &uart0 {
pinctrl-names = "default"; pinctrl-names = "default";
pinctrl-0 = <&uart0_pins_a>; pinctrl-0 = <&uart0_pins_a>;
......
...@@ -128,6 +128,17 @@ clocks { ...@@ -128,6 +128,17 @@ clocks {
*/ */
ranges = <0 0 0 0x20000000>; ranges = <0 0 0 0x20000000>;
/*
* This clock is actually configurable from the PRCM address
* space. The external 24M oscillator can be turned off, and
* the clock switched to an internal 16M RC oscillator. Under
* normal operation there's no reason to do this, and the
* default is to use the external good one, so just model this
* as a fixed clock. Also it is not entirely clear if the
* osc24M mux in the PRCM affects the entire clock tree, which
* would also throw all the PLL clock rates off, or just the
* downstream clocks in the PRCM.
*/
osc24M: osc24M_clk { osc24M: osc24M_clk {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "fixed-clock"; compatible = "fixed-clock";
...@@ -135,6 +146,13 @@ osc24M: osc24M_clk { ...@@ -135,6 +146,13 @@ osc24M: osc24M_clk {
clock-output-names = "osc24M"; clock-output-names = "osc24M";
}; };
/*
* The 32k clock is from an external source, normally the
* AC100 codec/RTC chip. This clock is by default enabled
* and clocked at 32768 Hz, from the oscillator connected
* to the AC100. It is configurable, but no such driver or
* bindings exist yet.
*/
osc32k: osc32k_clk { osc32k: osc32k_clk {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "fixed-clock"; compatible = "fixed-clock";
...@@ -164,6 +182,14 @@ usb_phy_clk: clk@00a08004 { ...@@ -164,6 +182,14 @@ usb_phy_clk: clk@00a08004 {
"usb_phy2", "usb_hsic_12M"; "usb_phy2", "usb_hsic_12M";
}; };
pll3: clk@06000008 {
/* placeholder until implemented */
#clock-cells = <0>;
compatible = "fixed-clock";
clock-rate = <0>;
clock-output-names = "pll3";
};
pll4: clk@0600000c { pll4: clk@0600000c {
#clock-cells = <0>; #clock-cells = <0>;
compatible = "allwinner,sun9i-a80-pll4-clk"; compatible = "allwinner,sun9i-a80-pll4-clk";
...@@ -350,6 +376,68 @@ apb1_gates: clk@06000594 { ...@@ -350,6 +376,68 @@ apb1_gates: clk@06000594 {
"apb1_uart2", "apb1_uart3", "apb1_uart2", "apb1_uart3",
"apb1_uart4", "apb1_uart5"; "apb1_uart4", "apb1_uart5";
}; };
cpus_clk: clk@08001410 {
compatible = "allwinner,sun9i-a80-cpus-clk";
reg = <0x08001410 0x4>;
#clock-cells = <0>;
clocks = <&osc32k>, <&osc24M>, <&pll4>, <&pll3>;
clock-output-names = "cpus";
};
ahbs: ahbs_clk {
compatible = "fixed-factor-clock";
#clock-cells = <0>;
clock-div = <1>;
clock-mult = <1>;
clocks = <&cpus_clk>;
clock-output-names = "ahbs";
};
apbs: clk@0800141c {
compatible = "allwinner,sun8i-a23-apb0-clk";
reg = <0x0800141c 0x4>;
#clock-cells = <0>;
clocks = <&ahbs>;
clock-output-names = "apbs";
};
apbs_gates: clk@08001428 {
compatible = "allwinner,sun9i-a80-apbs-gates-clk";
reg = <0x08001428 0x4>;
#clock-cells = <1>;
clocks = <&apbs>;
clock-indices = <0>, <1>,
<2>, <3>,
<4>, <5>,
<6>, <7>,
<12>, <13>,
<16>, <17>,
<18>, <20>;
clock-output-names = "apbs_pio", "apbs_ir",
"apbs_timer", "apbs_rsb",
"apbs_uart", "apbs_1wire",
"apbs_i2c0", "apbs_i2c1",
"apbs_ps2_0", "apbs_ps2_1",
"apbs_dma", "apbs_i2s0",
"apbs_i2s1", "apbs_twd";
};
r_1wire_clk: clk@08001450 {
reg = <0x08001450 0x4>;
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-mod0-clk";
clocks = <&osc32k>, <&osc24M>;
clock-output-names = "r_1wire";
};
r_ir_clk: clk@08001454 {
reg = <0x08001454 0x4>;
#clock-cells = <0>;
compatible = "allwinner,sun4i-a10-mod0-clk";
clocks = <&osc32k>, <&osc24M>;
clock-output-names = "r_ir";
};
}; };
soc { soc {
...@@ -764,14 +852,83 @@ r_wdt: watchdog@08001000 { ...@@ -764,14 +852,83 @@ r_wdt: watchdog@08001000 {
interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>; interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>;
}; };
apbs_rst: reset@080014b0 {
reg = <0x080014b0 0x4>;
compatible = "allwinner,sun6i-a31-clock-reset";
#reset-cells = <1>;
};
nmi_intc: interrupt-controller@080015a0 {
compatible = "allwinner,sun9i-a80-nmi";
interrupt-controller;
#interrupt-cells = <2>;
reg = <0x080015a0 0xc>;
interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>;
};
r_ir: ir@08002000 {
compatible = "allwinner,sun5i-a13-ir";
interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
pinctrl-names = "default";
pinctrl-0 = <&r_ir_pins>;
clocks = <&apbs_gates 1>, <&r_ir_clk>;
clock-names = "apb", "ir";
resets = <&apbs_rst 1>;
reg = <0x08002000 0x40>;
status = "disabled";
};
r_uart: serial@08002800 { r_uart: serial@08002800 {
compatible = "snps,dw-apb-uart"; compatible = "snps,dw-apb-uart";
reg = <0x08002800 0x400>; reg = <0x08002800 0x400>;
interrupts = <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>; interrupts = <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>;
reg-shift = <2>; reg-shift = <2>;
reg-io-width = <4>; reg-io-width = <4>;
clocks = <&osc24M>; clocks = <&apbs_gates 4>;
resets = <&apbs_rst 4>;
status = "disabled";
};
r_pio: pinctrl@08002c00 {
compatible = "allwinner,sun9i-a80-r-pinctrl";
reg = <0x08002c00 0x400>;
interrupts = <GIC_SPI 45 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 46 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&apbs_gates 0>;
resets = <&apbs_rst 0>;
gpio-controller;
interrupt-controller;
#address-cells = <1>;
#size-cells = <0>;
#gpio-cells = <3>;
r_ir_pins: r_ir {
allwinner,pins = "PL6";
allwinner,function = "s_cir_rx";
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};
r_rsb_pins: r_rsb {
allwinner,pins = "PN0", "PN1";
allwinner,function = "s_rsb";
allwinner,drive = <SUN4I_PINCTRL_20_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
};
r_rsb: i2c@08003400 {
compatible = "allwinner,sun8i-a23-rsb";
reg = <0x08003400 0x400>;
interrupts = <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&apbs_gates 3>;
clock-frequency = <3000000>;
resets = <&apbs_rst 3>;
pinctrl-names = "default";
pinctrl-0 = <&r_rsb_pins>;
status = "disabled"; status = "disabled";
#address-cells = <1>;
#size-cells = <0>;
}; };
}; };
}; };
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