60 lines
1.7 KiB
Diff
60 lines
1.7 KiB
Diff
From a4d7117cd49715e3114d30c7d7b303dbd4f45f76 Mon Sep 17 00:00:00 2001
|
|
From: brian <brian@vamrs.com>
|
|
Date: Fri, 15 Mar 2019 19:41:30 +0800
|
|
Subject: [PATCH 39/97] arm64: overlays: add spi dev for rockpi4
|
|
|
|
---
|
|
.../arm64/boot/dts/rockchip/overlays/Makefile | 3 ++-
|
|
.../dts/rockchip/overlays/devspi-overlay.dts | 25 +++++++++++++++++++
|
|
2 files changed, 27 insertions(+), 1 deletion(-)
|
|
create mode 100644 arch/arm64/boot/dts/rockchip/overlays/devspi-overlay.dts
|
|
|
|
diff --git a/arch/arm64/boot/dts/rockchip/overlays/Makefile b/arch/arm64/boot/dts/rockchip/overlays/Makefile
|
|
index 0e06b7e1748f..0c691d2237af 100644
|
|
--- a/arch/arm64/boot/dts/rockchip/overlays/Makefile
|
|
+++ b/arch/arm64/boot/dts/rockchip/overlays/Makefile
|
|
@@ -4,7 +4,8 @@ dtbo-$(CONFIG_ARCH_ROCKCHIP) += \
|
|
console-on-uart4.dtbo \
|
|
console-disabled.dtbo \
|
|
two-color-led.dtbo \
|
|
- at24c02.dtbo
|
|
+ at24c02.dtbo \
|
|
+ devspi.dtbo
|
|
|
|
targets += dtbs dtbs_install
|
|
targets += $(dtbo-y)
|
|
diff --git a/arch/arm64/boot/dts/rockchip/overlays/devspi-overlay.dts b/arch/arm64/boot/dts/rockchip/overlays/devspi-overlay.dts
|
|
new file mode 100644
|
|
index 000000000000..a3972b856660
|
|
--- /dev/null
|
|
+++ b/arch/arm64/boot/dts/rockchip/overlays/devspi-overlay.dts
|
|
@@ -0,0 +1,25 @@
|
|
+/dts-v1/;
|
|
+/plugin/;
|
|
+
|
|
+/ {
|
|
+ model = "ROCK PI 4B";
|
|
+ compatible = "rockchip,rockpi","rockchip,rk3399";
|
|
+
|
|
+ fragment@0 {
|
|
+ target = <&spi1>;
|
|
+
|
|
+ __overlay__ {
|
|
+ max-freq = <50000000>;
|
|
+ dmas = <&dmac_peri 10>, <&dmac_peri 11>;
|
|
+ dma-names = "tx","rx";
|
|
+ #address-cells = <1>;
|
|
+ #size-cells = <0>;
|
|
+ devspi@0 {
|
|
+ status = "okay";
|
|
+ reg = <0>;
|
|
+ compatible ="rockchip,spidev";
|
|
+ spi-max-frequency = <50000000>;
|
|
+ };
|
|
+ };
|
|
+ };
|
|
+};
|
|
--
|
|
2.25.1
|
|
|