Commit 6a1ca035 authored by Durai Manickam KR's avatar Durai Manickam KR Committed by Nicolas Ferre

ARM: dts: at91-sama5d27_som1_ek: Added I2C bus recovery support

SDA and SCL is configured as GPIO for I2C bus to recover during
I2C bus malfunction.
Signed-off-by: default avatarDurai Manickam KR <durai.manickamkr@microchip.com>
Signed-off-by: default avatarNicolas Ferre <nicolas.ferre@microchip.com>
Link: https://lore.kernel.org/r/20210914052113.85695-1-durai.manickamkr@microchip.com
parent 6b97032b
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
*/ */
#include "sama5d2.dtsi" #include "sama5d2.dtsi"
#include "sama5d2-pinfunc.h" #include "sama5d2-pinfunc.h"
#include <dt-bindings/gpio/gpio.h>
/ { / {
model = "Atmel SAMA5D27 SoM1"; model = "Atmel SAMA5D27 SoM1";
...@@ -95,8 +96,11 @@ ethernet-phy@7 { ...@@ -95,8 +96,11 @@ ethernet-phy@7 {
i2c0: i2c@f8028000 { i2c0: i2c@f8028000 {
dmas = <0>, <0>; dmas = <0>, <0>;
pinctrl-names = "default"; pinctrl-names = "default", "gpio";
pinctrl-0 = <&pinctrl_i2c0_default>; pinctrl-0 = <&pinctrl_i2c0_default>;
pinctrl-1 = <&pinctrl_i2c0_gpio>;
sda-gpios = <&pioA PIN_PD21 GPIO_ACTIVE_HIGH>;
scl-gpios = <&pioA PIN_PD22 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
status = "okay"; status = "okay";
at24@50 { at24@50 {
...@@ -113,6 +117,12 @@ pinctrl_i2c0_default: i2c0_default { ...@@ -113,6 +117,12 @@ pinctrl_i2c0_default: i2c0_default {
bias-disable; bias-disable;
}; };
pinctrl_i2c0_gpio: i2c0_gpio {
pinmux = <PIN_PD21__GPIO>,
<PIN_PD22__GPIO>;
bias-disable;
};
pinctrl_qspi1_default: qspi1_default { pinctrl_qspi1_default: qspi1_default {
sck_cs { sck_cs {
pinmux = <PIN_PB5__QSPI1_SCK>, pinmux = <PIN_PB5__QSPI1_SCK>,
......
...@@ -131,8 +131,11 @@ i2c3: i2c@600 { ...@@ -131,8 +131,11 @@ i2c3: i2c@600 {
i2c-analog-filter; i2c-analog-filter;
i2c-digital-filter; i2c-digital-filter;
i2c-digital-filter-width-ns = <35>; i2c-digital-filter-width-ns = <35>;
pinctrl-names = "default"; pinctrl-names = "default", "gpio";
pinctrl-0 = <&pinctrl_mikrobus_i2c>; pinctrl-0 = <&pinctrl_mikrobus_i2c>;
pinctrl-1 = <&pinctrl_i2c3_gpio>;
sda-gpios = <&pioA PIN_PA24 GPIO_ACTIVE_HIGH>;
scl-gpios = <&pioA PIN_PA23 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
status = "okay"; status = "okay";
}; };
}; };
...@@ -216,8 +219,11 @@ i2c1: i2c@fc028000 { ...@@ -216,8 +219,11 @@ i2c1: i2c@fc028000 {
i2c-analog-filter; i2c-analog-filter;
i2c-digital-filter; i2c-digital-filter;
i2c-digital-filter-width-ns = <35>; i2c-digital-filter-width-ns = <35>;
pinctrl-names = "default"; pinctrl-names = "default", "gpio";
pinctrl-0 = <&pinctrl_i2c1_default>; pinctrl-0 = <&pinctrl_i2c1_default>;
pinctrl-1 = <&pinctrl_i2c1_gpio>;
sda-gpios = <&pioA PIN_PD4 GPIO_ACTIVE_HIGH>;
scl-gpios = <&pioA PIN_PD5 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
status = "okay"; status = "okay";
}; };
...@@ -253,6 +259,13 @@ pinctrl_i2c1_default: i2c1_default { ...@@ -253,6 +259,13 @@ pinctrl_i2c1_default: i2c1_default {
bias-disable; bias-disable;
}; };
pinctrl_i2c1_gpio: i2c1_gpio {
pinmux = <PIN_PD4__GPIO>,
<PIN_PD5__GPIO>;
bias-disable;
};
pinctrl_isc_base: isc_base { pinctrl_isc_base: isc_base {
pinmux = <PIN_PC21__ISC_PCK>, pinmux = <PIN_PC21__ISC_PCK>,
<PIN_PC22__ISC_VSYNC>, <PIN_PC22__ISC_VSYNC>,
...@@ -442,6 +455,12 @@ pinctrl_mikrobus_i2c: mikrobus1_i2c { ...@@ -442,6 +455,12 @@ pinctrl_mikrobus_i2c: mikrobus1_i2c {
bias-disable; bias-disable;
}; };
pinctrl_i2c3_gpio: i2c3_gpio {
pinmux = <PIN_PA24__GPIO>,
<PIN_PA23__GPIO>;
bias-disable;
};
pinctrl_flx4_default: flx4_uart_default { pinctrl_flx4_default: flx4_uart_default {
pinmux = <PIN_PC28__FLEXCOM4_IO0>, pinmux = <PIN_PC28__FLEXCOM4_IO0>,
<PIN_PC29__FLEXCOM4_IO1>, <PIN_PC29__FLEXCOM4_IO1>,
......
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