1 Generic device tree bindings for I3C busses
2 ===========================================
4 This document describes generic bindings that should be used to describe I3C
5 busses in a device tree.
10 - #address-cells - should be <3>. Read more about addresses below.
11 - #size-cells - should be <0>.
12 - compatible - name of the I3C master controller driving the I3C bus
14 For other required properties e.g. to describe register sets,
15 clocks, etc. check the binding documentation of the specific driver.
16 The node describing an I3C bus should be named i3c-master.
21 These properties may not be supported by all I3C master drivers. Each I3C
22 master bindings should specify which of them are supported.
24 - i3c-scl-hz: frequency of the SCL signal used for I3C transfers.
25 When undefined the core sets it to 12.5MHz.
27 - i2c-scl-hz: frequency of the SCL signal used for I2C transfers.
28 When undefined, the core looks at LVR (Legacy Virtual Register)
29 values of I2C devices described in the device tree to determine
30 the maximum I2C frequency.
35 Each I2C device connected to the bus should be described in a subnode. All
36 properties described in Documentation/devicetree/bindings/i2c/i2c.txt are
37 valid here, but several new properties have been added.
39 New constraint on existing properties:
40 --------------------------------------
41 - reg: contains 3 cells
42 + first cell : still encoding the I2C address
44 + second cell: shall be 0
46 + third cell: shall encode the I3C LVR (Legacy Virtual Register)
47 bit[31:8]: unused/ignored
48 bit[7:5]: I2C device index. Possible values
49 * 0: I2C device has a 50 ns spike filter
50 * 1: I2C device does not have a 50 ns spike filter but supports high
52 * 2: I2C device does not have a 50 ns spike filter and is not tolerant
56 bit[4]: tell whether the device operates in FM (Fast Mode) or FM+ mode
63 The I2C node unit-address should always match the first cell of the reg
64 property: <device-type>@<i2c-address>.
69 All I3C devices are supposed to support DAA (Dynamic Address Assignment), and
70 are thus discoverable. So, by default, I3C devices do not have to be described
72 This being said, one might want to attach extra resources to these devices,
73 and those resources may have to be described in the device tree, which in turn
74 means we have to describe I3C devices.
76 Another use case for describing an I3C device in the device tree is when this
77 I3C device has a static I2C address and we want to assign it a specific I3C
78 dynamic address before the DAA takes place (so that other devices on the bus
79 can't take this dynamic address).
81 The I3C device should be names <device-type>@<static-i2c-address>,<i3c-pid>,
82 where device-type is describing the type of device connected on the bus
83 (gpio-controller, sensor, ...).
87 - reg: contains 3 cells
88 + first cell : encodes the static I2C address. Should be 0 if the device does
89 not have one (0 is not a valid I2C address).
91 + second and third cells: should encode the ProvisionalID. The second cell
92 contains the manufacturer ID left-shifted by 1.
93 The third cell contains ORing of the part ID
94 left-shifted by 16, the instance ID left-shifted
95 by 12 and the extra information. This encoding is
96 following the PID definition provided by the I3C
101 - assigned-address: dynamic address to be assigned to this device. This
102 property is only valid if the I3C device has a static
103 address (first cell of the reg property != 0).
109 compatible = "cdns,i3c-master";
110 clocks = <&coreclock>, <&i3csysclock>;
111 clock-names = "pclk", "sysclk";
113 reg = <0x0d040000 0x1000>;
114 #address-cells = <3>;
116 i2c-scl-hz = <100000>;
119 nunchuk: nunchuk@52 {
120 compatible = "nintendo,nunchuk";
121 reg = <0x52 0x0 0x10>;
124 /* I3C device with a static I2C address. */
125 thermal_sensor: sensor@68,39200144004 {
126 reg = <0x68 0x392 0x144004>;
127 assigned-address = <0xa>;
131 * I3C device without a static I2C address but requiring
132 * resources described in the DT.
134 sensor@0,39200154004 {
135 reg = <0x0 0x392 0x154004>;
136 clocks = <&clock_provider 0>;