mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
ODROID-XU4: add overlay support
This commit is contained in:
@@ -55,3 +55,5 @@ dtb-$(CONFIG_ARCH_S5PV210) += \
|
||||
s5pv210-smdkc110.dtb \
|
||||
s5pv210-smdkv210.dtb \
|
||||
s5pv210-torbreck.dtb
|
||||
|
||||
subdir-y += overlays
|
||||
|
||||
@@ -91,3 +91,38 @@
|
||||
&usbdrd_dwc3_1 {
|
||||
dr_mode = "host";
|
||||
};
|
||||
|
||||
&i2c_1 {
|
||||
status = "disabled";
|
||||
samsung,i2c-max-bus-freq = <400000>;
|
||||
};
|
||||
|
||||
&hsi2c_5 {
|
||||
status = "disabled";
|
||||
samsung,hs-mode;
|
||||
clock-frequency = <400000>;
|
||||
};
|
||||
|
||||
&spi_1 {
|
||||
status = "disabled";
|
||||
samsung,spi-src-clk = <0>;
|
||||
num-cs = <2>;
|
||||
cs-gpios = <&gpa2 5 GPIO_ACTIVE_HIGH>, <&gpx2 1 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
&serial_0 {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&serial_1 {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&serial_2 {
|
||||
// Debugging UART port
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&serial_3 {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
16
arch/arm/boot/dts/samsung/overlays/Makefile
Normal file
16
arch/arm/boot/dts/samsung/overlays/Makefile
Normal file
@@ -0,0 +1,16 @@
|
||||
# Overlays for the Odroid platform
|
||||
|
||||
dtbo-y += \
|
||||
spi0.dtbo \
|
||||
i2c0.dtbo \
|
||||
i2c1.dtbo \
|
||||
uart0.dtbo \
|
||||
hktft32.dtbo \
|
||||
hktft35.dtbo \
|
||||
ads7846.dtbo \
|
||||
sx865x-i2c1.dtbo \
|
||||
onewire.dtbo \
|
||||
hktft-cs-ogst.dtbo
|
||||
|
||||
targets += $(dtbo-y)
|
||||
always-y := $(dtbo-y)
|
||||
58
arch/arm/boot/dts/samsung/overlays/ads7846.dts
Normal file
58
arch/arm/boot/dts/samsung/overlays/ads7846.dts
Normal file
@@ -0,0 +1,58 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
#include <dt-bindings/pinctrl/samsung.h>
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
// spi_1 aliased with spi0
|
||||
target = <&spi_1>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
ads7846: ads7846@1 {
|
||||
status = "okay";
|
||||
|
||||
reg = <1>;
|
||||
compatible = "ti,ads7846";
|
||||
interrupt-parent = <&gpa0>;
|
||||
interrupts = <3 0>;
|
||||
spi-max-frequency = <1000000>;
|
||||
|
||||
/* GPA0.3 Pull-up enable */
|
||||
pinctrl-0 = <&ts_pendown_gpio>;
|
||||
pinctrl-names = "default";
|
||||
|
||||
pendown-gpio = <&gpa0 3 GPIO_ACTIVE_HIGH>;
|
||||
vcc-supply = <&ldo30_reg>;
|
||||
|
||||
ti,swap-xy = <1>;
|
||||
ti,x-min = /bits/ 16 <0>;
|
||||
ti,x-max = /bits/ 16 <8000>;
|
||||
ti,y-min = /bits/ 16 <0>;
|
||||
ti,y-max = /bits/ 16 <4800>;
|
||||
ti,x-plate-ohms = /bits/ 16 <40>;
|
||||
ti,pressure-max = /bits/ 16 <255>;
|
||||
|
||||
linux,wakeup;
|
||||
|
||||
ts_pendown_gpio: ts-pendown-gpio {
|
||||
samsung,pins = "gpa0-3";
|
||||
samsung,pin-function = <EXYNOS_PIN_FUNC_INPUT>;
|
||||
samsung,pin-pud = <EXYNOS_PIN_PULL_UP>;
|
||||
samsung,pin-drv = <EXYNOS5420_PIN_DRV_LV1>;
|
||||
};
|
||||
|
||||
controller-data {
|
||||
cs-gpio = <&gpx2 1 GPIO_ACTIVE_HIGH>;
|
||||
samsung,spi-feedback-delay = <0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
48
arch/arm/boot/dts/samsung/overlays/hktft-cs-ogst.dts
Normal file
48
arch/arm/boot/dts/samsung/overlays/hktft-cs-ogst.dts
Normal file
@@ -0,0 +1,48 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
// spi_1 aliased with spi0
|
||||
target = <&spi_1>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
hktft_cs_ogst: hktft_cs_ogst@0 {
|
||||
status = "okay";
|
||||
compatible = "odroid,hktft32";
|
||||
reg = <0>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&hktft_cs_ogst_pins>;
|
||||
|
||||
spi-max-frequency = <40000000>;
|
||||
rotate = <270>;
|
||||
bgr;
|
||||
backlight;
|
||||
fps = <20>;
|
||||
bpp = <16>;
|
||||
reset-gpios = <&gpx1 5 GPIO_ACTIVE_HIGH>;
|
||||
dc-gpios = <&gpx1 6 GPIO_ACTIVE_HIGH>;
|
||||
led-gpios = <&gpx1 2 GPIO_ACTIVE_LOW>;
|
||||
debug = <0>;
|
||||
|
||||
hktft_cs_ogst_pins: hktft_cs_ogst_pins {
|
||||
samsung,pins = "gpx1-5", /* reset */
|
||||
"gpx1-6", /* dc */
|
||||
"gpx1-2"; /* led */
|
||||
};
|
||||
|
||||
controller-data {
|
||||
cs-gpio = <&gpa2 5 GPIO_ACTIVE_HIGH>;
|
||||
samsung,spi-feedback-delay = <0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
46
arch/arm/boot/dts/samsung/overlays/hktft32.dts
Normal file
46
arch/arm/boot/dts/samsung/overlays/hktft32.dts
Normal file
@@ -0,0 +1,46 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
// spi_1 aliased with spi0
|
||||
target = <&spi_1>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
hktft32: hktft32@0 {
|
||||
status = "okay";
|
||||
compatible = "odroid,hktft32";
|
||||
reg = <0>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&hktft32_pins>;
|
||||
|
||||
spi-max-frequency = <40000000>;
|
||||
rotate = <90>;
|
||||
bgr;
|
||||
backlight;
|
||||
fps = <20>;
|
||||
bpp = <16>;
|
||||
reset-gpios = <&gpx1 5 GPIO_ACTIVE_HIGH>;
|
||||
dc-gpios = <&gpx1 6 GPIO_ACTIVE_HIGH>;
|
||||
debug = <0>;
|
||||
|
||||
hktft32_pins: hktft32_pins {
|
||||
samsung,pins = "gpx1-5", /* reset */
|
||||
"gpx1-6"; /* dc */
|
||||
};
|
||||
|
||||
controller-data {
|
||||
cs-gpio = <&gpa2 5 GPIO_ACTIVE_HIGH>;
|
||||
samsung,spi-feedback-delay = <0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
55
arch/arm/boot/dts/samsung/overlays/hktft35.dts
Normal file
55
arch/arm/boot/dts/samsung/overlays/hktft35.dts
Normal file
@@ -0,0 +1,55 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
target-path = "/";
|
||||
|
||||
__overlay__ {
|
||||
hktft35: hktft35 {
|
||||
status = "okay";
|
||||
compatible = "odroid,hktft35";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&hktft35_pins>;
|
||||
|
||||
rotate = <270>;
|
||||
bgr;
|
||||
fps = <20>;
|
||||
bpp = <16>;
|
||||
reset-gpios = <&gpa0 3 GPIO_ACTIVE_HIGH>;
|
||||
dc-gpios = <&gpx2 4 GPIO_ACTIVE_HIGH>;
|
||||
wr-gpios = <&gpa2 5 GPIO_ACTIVE_HIGH>;
|
||||
cs-gpios = <&gpa0 2 GPIO_ACTIVE_HIGH>;
|
||||
led-gpios = <&gpx2 7 GPIO_ACTIVE_HIGH>;
|
||||
db-gpios = <&gpx1 7 GPIO_ACTIVE_HIGH>,
|
||||
<&gpx2 0 GPIO_ACTIVE_HIGH>,
|
||||
<&gpx1 3 GPIO_ACTIVE_HIGH>,
|
||||
<&gpa2 4 GPIO_ACTIVE_HIGH>,
|
||||
<&gpa2 6 GPIO_ACTIVE_HIGH>,
|
||||
<&gpa2 7 GPIO_ACTIVE_HIGH>,
|
||||
<&gpx1 6 GPIO_ACTIVE_HIGH>,
|
||||
<&gpx1 5 GPIO_ACTIVE_HIGH>;
|
||||
debug = <0>;
|
||||
|
||||
hktft35_pins: hktft35_pins {
|
||||
samsung,pins = "gpa0-3", /* reset */
|
||||
"gpx2-4", /* dc */
|
||||
"gpa2-5", /* wr */
|
||||
"gpa0-2", /* cs */
|
||||
"gpx2-7", /* led */
|
||||
"gpx1-7", /* db00 */
|
||||
"gpx2-0", /* db01 */
|
||||
"gpx1-3", /* db02 */
|
||||
"gpa2-4", /* db03 */
|
||||
"gpa2-6", /* db04 */
|
||||
"gpa2-7", /* db05 */
|
||||
"gpx1-6", /* db06 */
|
||||
"gpx1-5"; /* db07 */
|
||||
samsung,pin-function = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
13
arch/arm/boot/dts/samsung/overlays/i2c0.dts
Normal file
13
arch/arm/boot/dts/samsung/overlays/i2c0.dts
Normal file
@@ -0,0 +1,13 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
// i2c_1 aliased with i2c0
|
||||
target = <&i2c_1>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
};
|
||||
13
arch/arm/boot/dts/samsung/overlays/i2c1.dts
Normal file
13
arch/arm/boot/dts/samsung/overlays/i2c1.dts
Normal file
@@ -0,0 +1,13 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
// hsi2c_5 alised with i2c1
|
||||
target = <&hsi2c_5>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
};
|
||||
16
arch/arm/boot/dts/samsung/overlays/onewire.dts
Normal file
16
arch/arm/boot/dts/samsung/overlays/onewire.dts
Normal file
@@ -0,0 +1,16 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
target-path = "/";
|
||||
|
||||
__overlay__ {
|
||||
onewire: onewire {
|
||||
compatible = "w1-gpio";
|
||||
gpios = <&gpx2 0 0>;
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
30
arch/arm/boot/dts/samsung/overlays/spi0.dts
Normal file
30
arch/arm/boot/dts/samsung/overlays/spi0.dts
Normal file
@@ -0,0 +1,30 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
// spi_1 aliased with spi0
|
||||
target = <&spi_1>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
spidev: spidev@0 {
|
||||
status = "okay";
|
||||
reg = <0>;
|
||||
compatible = "odroid,spidev";
|
||||
spi-max-frequency = <1000000>;
|
||||
|
||||
controller-data {
|
||||
cs-gpio = <&gpa2 5 GPIO_ACTIVE_HIGH>;
|
||||
samsung,spi-feedback-delay = <0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
34
arch/arm/boot/dts/samsung/overlays/sx865x-i2c1.dts
Normal file
34
arch/arm/boot/dts/samsung/overlays/sx865x-i2c1.dts
Normal file
@@ -0,0 +1,34 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
// hsi2c_5 alised with i2c1
|
||||
target = <&hsi2c_5>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
sx865x: sx865x@49 {
|
||||
status = "okay";
|
||||
compatible = "semtech,sx8650";
|
||||
reg = <0x49>;
|
||||
#clock-cells = <0>;
|
||||
|
||||
/* H/W Pin control setup */
|
||||
gpio-pendown = <&gpx3 1 GPIO_ACTIVE_HIGH>;
|
||||
gpio-reset = <&gpx2 5 GPIO_ACTIVE_LOW>;
|
||||
|
||||
/* platform data setup */
|
||||
invert-x = <0>;
|
||||
invert-y = <1>;
|
||||
swap-xy = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
12
arch/arm/boot/dts/samsung/overlays/uart0.dts
Normal file
12
arch/arm/boot/dts/samsung/overlays/uart0.dts
Normal file
@@ -0,0 +1,12 @@
|
||||
/dts-v1/;
|
||||
/plugin/;
|
||||
|
||||
/ {
|
||||
fragment@0 {
|
||||
target = <&serial_0>;
|
||||
|
||||
__overlay__ {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
};
|
||||
Reference in New Issue
Block a user