64 lines
1.8 KiB
Diff
64 lines
1.8 KiB
Diff
|
From 6c46208e3ec462d67912388b31579385b2566846 Mon Sep 17 00:00:00 2001
|
||
|
From: Yang Deokgyu <secugyu@gmail.com>
|
||
|
Date: Thu, 14 Nov 2019 13:45:22 +0900
|
||
|
Subject: [PATCH 040/109] ODROID-XU4: Add support for SPI1 on the 40 pin header
|
||
|
|
||
|
Signed-off-by: Yang Deokgyu <secugyu@gmail.com>
|
||
|
Change-Id: I0b1d16b0f445838509eeb0cc8093239fa1805605
|
||
|
---
|
||
|
arch/arm/boot/dts/exynos5422-odroidxu4.dts | 20 ++++++++++++++++++++
|
||
|
drivers/spi/spidev.c | 2 ++
|
||
|
2 files changed, 22 insertions(+)
|
||
|
|
||
|
diff --git a/arch/arm/boot/dts/exynos5422-odroidxu4.dts b/arch/arm/boot/dts/exynos5422-odroidxu4.dts
|
||
|
index c953346dfabc..297df752199e 100644
|
||
|
--- a/arch/arm/boot/dts/exynos5422-odroidxu4.dts
|
||
|
+++ b/arch/arm/boot/dts/exynos5422-odroidxu4.dts
|
||
|
@@ -11,6 +11,7 @@
|
||
|
/dts-v1/;
|
||
|
#include <dt-bindings/sound/samsung-i2s.h>
|
||
|
#include "exynos5422-odroidxu3-common.dtsi"
|
||
|
+#include <dt-bindings/gpio/gpio.h>
|
||
|
|
||
|
/ {
|
||
|
model = "Hardkernel Odroid XU4";
|
||
|
@@ -103,3 +104,22 @@ &hsi2c_5 {
|
||
|
samsung,hs-mode;
|
||
|
clock-frequency = <400000>;
|
||
|
};
|
||
|
+
|
||
|
+&spi_1 {
|
||
|
+ status = "okay";
|
||
|
+ samsung,spi-src-clk = <0>;
|
||
|
+ num-cs = <2>;
|
||
|
+ cs-gpios = <&gpa2 5 GPIO_ACTIVE_HIGH>, <&gpx2 1 GPIO_ACTIVE_HIGH>;
|
||
|
+
|
||
|
+ 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>;
|
||
|
+ };
|
||
|
+ };
|
||
|
+};
|
||
|
diff --git a/drivers/spi/spidev.c b/drivers/spi/spidev.c
|
||
|
index 8cb4d923aeaa..c177bba9c5bc 100644
|
||
|
--- a/drivers/spi/spidev.c
|
||
|
+++ b/drivers/spi/spidev.c
|
||
|
@@ -683,6 +683,8 @@ static const struct of_device_id spidev_dt_ids[] = {
|
||
|
{ .compatible = "dh,dhcom-board" },
|
||
|
{ .compatible = "menlo,m53cpld" },
|
||
|
{ .compatible = "cisco,spi-petra" },
|
||
|
+ /* ODROID Modification */
|
||
|
+ { .compatible = "odroid,spidev" },
|
||
|
{},
|
||
|
};
|
||
|
MODULE_DEVICE_TABLE(of, spidev_dt_ids);
|
||
|
--
|
||
|
2.25.1
|
||
|
|