162306a36Sopenharmony_ciMulti-Function Devices (MFD)
262306a36Sopenharmony_ci
362306a36Sopenharmony_ciThese devices comprise a nexus for heterogeneous hardware blocks containing
462306a36Sopenharmony_cimore than one non-unique yet varying hardware functionality.
562306a36Sopenharmony_ci
662306a36Sopenharmony_ciA typical MFD can be:
762306a36Sopenharmony_ci
862306a36Sopenharmony_ci- A mixed signal ASIC on an external bus, sometimes a PMIC (Power Management
962306a36Sopenharmony_ci  Integrated Circuit) that is manufactured in a lower technology node (rough
1062306a36Sopenharmony_ci  silicon) that handles analog drivers for things like audio amplifiers, LED
1162306a36Sopenharmony_ci  drivers, level shifters, PHY (physical interfaces to things like USB or
1262306a36Sopenharmony_ci  ethernet), regulators etc.
1362306a36Sopenharmony_ci
1462306a36Sopenharmony_ci- A range of memory registers containing "miscellaneous system registers" also
1562306a36Sopenharmony_ci  known as a system controller "syscon" or any other memory range containing a
1662306a36Sopenharmony_ci  mix of unrelated hardware devices.
1762306a36Sopenharmony_ci
1862306a36Sopenharmony_ciOptional properties:
1962306a36Sopenharmony_ci
2062306a36Sopenharmony_ci- compatible : "simple-mfd" - this signifies that the operating system should
2162306a36Sopenharmony_ci  consider all subnodes of the MFD device as separate devices akin to how
2262306a36Sopenharmony_ci  "simple-bus" indicates when to see subnodes as children for a simple
2362306a36Sopenharmony_ci  memory-mapped bus. For more complex devices, when the nexus driver has to
2462306a36Sopenharmony_ci  probe registers to figure out what child devices exist etc, this should not
2562306a36Sopenharmony_ci  be used. In the latter case the child devices will be determined by the
2662306a36Sopenharmony_ci  operating system.
2762306a36Sopenharmony_ci
2862306a36Sopenharmony_ci- ranges: Describes the address mapping relationship to the parent. Should set
2962306a36Sopenharmony_ci  the child's base address to 0, the physical address within parent's address
3062306a36Sopenharmony_ci  space, and the length of the address map.
3162306a36Sopenharmony_ci
3262306a36Sopenharmony_ci- #address-cells: Specifies the number of cells used to represent physical base
3362306a36Sopenharmony_ci  addresses. Must be present if ranges is used.
3462306a36Sopenharmony_ci
3562306a36Sopenharmony_ci- #size-cells: Specifies the number of cells used to represent the size of an
3662306a36Sopenharmony_ci  address. Must be present if ranges is used.
3762306a36Sopenharmony_ci
3862306a36Sopenharmony_ciExample:
3962306a36Sopenharmony_ci
4062306a36Sopenharmony_cifoo@1000 {
4162306a36Sopenharmony_ci	compatible = "syscon", "simple-mfd";
4262306a36Sopenharmony_ci	reg = <0x01000 0x1000>;
4362306a36Sopenharmony_ci
4462306a36Sopenharmony_ci	led@8.0 {
4562306a36Sopenharmony_ci		compatible = "register-bit-led";
4662306a36Sopenharmony_ci		offset = <0x08>;
4762306a36Sopenharmony_ci		mask = <0x01>;
4862306a36Sopenharmony_ci		label = "myled";
4962306a36Sopenharmony_ci		default-state = "on";
5062306a36Sopenharmony_ci	};
5162306a36Sopenharmony_ci};
52