1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
4 $id: http://devicetree.org/schemas/i2c/st,stm32-i2c.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: I2C controller embedded in STMicroelectronics STM32 I2C platform
10 - Pierre-Yves MORDRET <pierre-yves.mordret@st.com>
13 - $ref: /schemas/i2c/i2c-controller.yaml#
22 i2c-scl-rising-time-ns:
25 i2c-scl-falling-time-ns:
29 description: Use to set Fast Mode Plus bit within SYSCFG when
30 Fast Mode Plus speed is selected by slave.
31 Format is phandle to syscfg / register offset within
32 syscfg / register bitmask for FMP bit.
34 - $ref: "/schemas/types.yaml#/definitions/phandle-array"
48 enum: [100000, 400000]
61 - description: interrupt ID for I2C event
62 - description: interrupt ID for I2C error
72 - description: RX DMA Channel phandle
73 - description: TX DMA Channel phandle
81 description: Desired I2C bus clock frequency in Hz. If not specified,
82 the default 100 kHz frequency will be used.
83 For STM32F7, STM32H7 and STM32MP1 SoCs, Standard-mode,
84 Fast-mode and Fast-mode Plus are supported, possible
85 values are 100000, 400000 and 1000000.
87 enum: [100000, 400000, 1000000]
98 #include <dt-bindings/mfd/stm32f7-rcc.h>
99 #include <dt-bindings/clock/stm32fx-clock.h>
100 //Example 1 (with st,stm32f4-i2c compatible)
102 compatible = "st,stm32f4-i2c";
103 #address-cells = <1>;
105 reg = <0x40005400 0x400>;
109 clocks = <&rcc 0 149>;
112 //Example 2 (with st,stm32f7-i2c compatible)
114 compatible = "st,stm32f7-i2c";
115 #address-cells = <1>;
117 reg = <0x40005800 0x400>;
120 resets = <&rcc STM32F7_APB1_RESET(I2C1)>;
121 clocks = <&rcc 1 CLK_I2C1>;
124 //Example 3 (with st,stm32f7-i2c compatible on stm32mp)
125 #include <dt-bindings/interrupt-controller/arm-gic.h>
126 #include <dt-bindings/clock/stm32mp1-clks.h>
127 #include <dt-bindings/reset/stm32mp1-resets.h>
129 compatible = "st,stm32f7-i2c";
130 #address-cells = <1>;
132 reg = <0x40013000 0x400>;
133 interrupts = <GIC_SPI 33 IRQ_TYPE_LEVEL_HIGH>,
134 <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
135 clocks = <&rcc I2C2_K>;
136 resets = <&rcc I2C2_R>;
137 i2c-scl-rising-time-ns = <185>;
138 i2c-scl-falling-time-ns = <20>;
139 st,syscfg-fmp = <&syscfg 0x4 0x2>;