build/patch/kernel/archive/odroidxu4-5.12/0006-ODROID-N2-ARM64-dts-add-i2c2-i2c3-node.patch

92 lines
2.0 KiB
Diff
Raw Normal View History

From 46beaaabd6bcf65d0d6d37be56852482870b8086 Mon Sep 17 00:00:00 2001
From: Hyeonki Hong <hhk7734@gmail.com>
Date: Fri, 27 Mar 2020 16:54:02 +0900
Subject: [PATCH 006/109] ODROID-N2: ARM64/dts: add i2c2, i2c3 node
Change-Id: I00e3748a6f8474a99d05200afc60b8d794f75c96
---
.../boot/dts/amlogic/meson-g12b-odroid-n2.dts | 53 +++++++++++++++++++
1 file changed, 53 insertions(+)
diff --git a/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dts b/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dts
index f5a993ef93a5..7d4de0335873 100644
--- a/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dts
+++ b/arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dts
@@ -15,6 +15,8 @@ / {
aliases {
ethernet0 = &ethmac;
+ i2c1 = &i2c2;
+ i2c2 = &i2c3;
serial0 = &uart_AO;
serial1 = &uart_A;
};
@@ -520,6 +522,35 @@ hdmi_tx_tmds_out: endpoint {
};
};
+&i2c2 {
+ status = "okay";
+
+ /*
+ * 40 Pin Header : SDA(GPIOX.17->3 Pin)
+ * SCL(GPIOX.18->5 Pin)
+ */
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c2_master_pins1>;
+
+ /* default 400k */
+ clock-frequency = <400000>;
+};
+
+&i2c3 {
+ /* default i2c clock-frequency is 100Khz */
+ status = "okay";
+
+ /*
+ * 40 Pin Header : SDA(GPIOA.14->27 Pin)
+ * SCL(GPIOA.15->28 Pin)
+ */
+ pinctrl-names = "default";
+ pinctrl-0 = <&i2c3_master_pins2>;
+
+ /* default 100k */
+ clock-frequency = <100000>;
+};
+
&ir {
status = "okay";
pinctrl-0 = <&remote_input_ao_pins>;
@@ -527,6 +558,28 @@ &ir {
linux,rc-map-name = "rc-odroid";
};
+&periphs_pinctrl {
+ i2c2_master_pins1:i2c2-master-pins1 {
+ mux {
+ groups = "i2c2_sda_x",
+ "i2c2_sck_x";
+ function = "i2c2";
+ bias-pull-up;
+ drive-strength-microamp = <3000>;
+ };
+ };
+
+ i2c3_master_pins2:i2c2-master-pins2 {
+ mux {
+ groups = "i2c3_sda_a",
+ "i2c3_sck_a";
+ function = "i2c3";
+ bias-pull-up;
+ drive-strength-microamp = <3000>;
+ };
+ };
+};
+
&pwm_ab {
pinctrl-0 = <&pwm_a_e_pins>;
pinctrl-names = "default";
--
2.25.1