1*c66ec88fSEmmanuel VadotMulti-Function Devices (MFD)
2*c66ec88fSEmmanuel Vadot
3*c66ec88fSEmmanuel VadotThese devices comprise a nexus for heterogeneous hardware blocks containing
4*c66ec88fSEmmanuel Vadotmore than one non-unique yet varying hardware functionality.
5*c66ec88fSEmmanuel Vadot
6*c66ec88fSEmmanuel VadotA typical MFD can be:
7*c66ec88fSEmmanuel Vadot
8*c66ec88fSEmmanuel Vadot- A mixed signal ASIC on an external bus, sometimes a PMIC (Power Management
9*c66ec88fSEmmanuel Vadot  Integrated Circuit) that is manufactured in a lower technology node (rough
10*c66ec88fSEmmanuel Vadot  silicon) that handles analog drivers for things like audio amplifiers, LED
11*c66ec88fSEmmanuel Vadot  drivers, level shifters, PHY (physical interfaces to things like USB or
12*c66ec88fSEmmanuel Vadot  ethernet), regulators etc.
13*c66ec88fSEmmanuel Vadot
14*c66ec88fSEmmanuel Vadot- A range of memory registers containing "miscellaneous system registers" also
15*c66ec88fSEmmanuel Vadot  known as a system controller "syscon" or any other memory range containing a
16*c66ec88fSEmmanuel Vadot  mix of unrelated hardware devices.
17*c66ec88fSEmmanuel Vadot
18*c66ec88fSEmmanuel VadotOptional properties:
19*c66ec88fSEmmanuel Vadot
20*c66ec88fSEmmanuel Vadot- compatible : "simple-mfd" - this signifies that the operating system should
21*c66ec88fSEmmanuel Vadot  consider all subnodes of the MFD device as separate devices akin to how
22*c66ec88fSEmmanuel Vadot  "simple-bus" indicates when to see subnodes as children for a simple
23*c66ec88fSEmmanuel Vadot  memory-mapped bus. For more complex devices, when the nexus driver has to
24*c66ec88fSEmmanuel Vadot  probe registers to figure out what child devices exist etc, this should not
25*c66ec88fSEmmanuel Vadot  be used. In the latter case the child devices will be determined by the
26*c66ec88fSEmmanuel Vadot  operating system.
27*c66ec88fSEmmanuel Vadot
28*c66ec88fSEmmanuel Vadot- ranges: Describes the address mapping relationship to the parent. Should set
29*c66ec88fSEmmanuel Vadot  the child's base address to 0, the physical address within parent's address
30*c66ec88fSEmmanuel Vadot  space, and the length of the address map.
31*c66ec88fSEmmanuel Vadot
32*c66ec88fSEmmanuel Vadot- #address-cells: Specifies the number of cells used to represent physical base
33*c66ec88fSEmmanuel Vadot  addresses. Must be present if ranges is used.
34*c66ec88fSEmmanuel Vadot
35*c66ec88fSEmmanuel Vadot- #size-cells: Specifies the number of cells used to represent the size of an
36*c66ec88fSEmmanuel Vadot  address. Must be present if ranges is used.
37*c66ec88fSEmmanuel Vadot
38*c66ec88fSEmmanuel VadotExample:
39*c66ec88fSEmmanuel Vadot
40*c66ec88fSEmmanuel Vadotfoo@1000 {
41*c66ec88fSEmmanuel Vadot	compatible = "syscon", "simple-mfd";
42*c66ec88fSEmmanuel Vadot	reg = <0x01000 0x1000>;
43*c66ec88fSEmmanuel Vadot
44*c66ec88fSEmmanuel Vadot	led@8.0 {
45*c66ec88fSEmmanuel Vadot		compatible = "register-bit-led";
46*c66ec88fSEmmanuel Vadot		offset = <0x08>;
47*c66ec88fSEmmanuel Vadot		mask = <0x01>;
48*c66ec88fSEmmanuel Vadot		label = "myled";
49*c66ec88fSEmmanuel Vadot		default-state = "on";
50*c66ec88fSEmmanuel Vadot	};
51*c66ec88fSEmmanuel Vadot};
52