xref: /freebsd/sys/contrib/device-tree/Bindings/bus/moxtet.txt (revision c66ec88fed842fbaad62c30d510644ceb7bd2d71)
1*c66ec88fSEmmanuel VadotTurris Mox module status and configuration bus (over SPI)
2*c66ec88fSEmmanuel Vadot
3*c66ec88fSEmmanuel VadotRequired properties:
4*c66ec88fSEmmanuel Vadot - compatible		: Should be "cznic,moxtet"
5*c66ec88fSEmmanuel Vadot - #address-cells	: Has to be 1
6*c66ec88fSEmmanuel Vadot - #size-cells		: Has to be 0
7*c66ec88fSEmmanuel Vadot - spi-cpol		: Required inverted clock polarity
8*c66ec88fSEmmanuel Vadot - spi-cpha		: Required shifted clock phase
9*c66ec88fSEmmanuel Vadot - interrupts		: Must contain reference to the shared interrupt line
10*c66ec88fSEmmanuel Vadot - interrupt-controller	: Required
11*c66ec88fSEmmanuel Vadot - #interrupt-cells	: Has to be 1
12*c66ec88fSEmmanuel Vadot
13*c66ec88fSEmmanuel VadotFor other required and optional properties of SPI slave nodes please refer to
14*c66ec88fSEmmanuel Vadot../spi/spi-bus.txt.
15*c66ec88fSEmmanuel Vadot
16*c66ec88fSEmmanuel VadotRequired properties of subnodes:
17*c66ec88fSEmmanuel Vadot - reg			: Should be position on the Moxtet bus (how many Moxtet
18*c66ec88fSEmmanuel Vadot			  modules are between this module and CPU module, so
19*c66ec88fSEmmanuel Vadot			  either 0 or a positive integer)
20*c66ec88fSEmmanuel Vadot
21*c66ec88fSEmmanuel VadotThe driver finds the devices connected to the bus by itself, but it may be
22*c66ec88fSEmmanuel Vadotneeded to reference some of them from other parts of the device tree. In that
23*c66ec88fSEmmanuel Vadotcase the devices can be defined as subnodes of the moxtet node.
24*c66ec88fSEmmanuel Vadot
25*c66ec88fSEmmanuel VadotExample:
26*c66ec88fSEmmanuel Vadot
27*c66ec88fSEmmanuel Vadot	moxtet@1 {
28*c66ec88fSEmmanuel Vadot		compatible = "cznic,moxtet";
29*c66ec88fSEmmanuel Vadot		#address-cells = <1>;
30*c66ec88fSEmmanuel Vadot		#size-cells = <0>;
31*c66ec88fSEmmanuel Vadot		reg = <1>;
32*c66ec88fSEmmanuel Vadot		spi-max-frequency = <10000000>;
33*c66ec88fSEmmanuel Vadot		spi-cpol;
34*c66ec88fSEmmanuel Vadot		spi-cpha;
35*c66ec88fSEmmanuel Vadot		interrupt-controller;
36*c66ec88fSEmmanuel Vadot		#interrupt-cells = <1>;
37*c66ec88fSEmmanuel Vadot		interrupt-parent = <&gpiosb>;
38*c66ec88fSEmmanuel Vadot		interrupts = <5 IRQ_TYPE_EDGE_FALLING>;
39*c66ec88fSEmmanuel Vadot
40*c66ec88fSEmmanuel Vadot		moxtet_sfp: gpio@0 {
41*c66ec88fSEmmanuel Vadot			compatible = "cznic,moxtet-gpio";
42*c66ec88fSEmmanuel Vadot			gpio-controller;
43*c66ec88fSEmmanuel Vadot			#gpio-cells = <2>;
44*c66ec88fSEmmanuel Vadot			reg = <0>;
45*c66ec88fSEmmanuel Vadot		}
46*c66ec88fSEmmanuel Vadot	};
47