i2c-mux.txt 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. Common i2c bus multiplexer/switch properties.
  2. An i2c bus multiplexer/switch will have several child busses that are
  3. numbered uniquely in a device dependent manner. The nodes for an i2c bus
  4. multiplexer/switch will have one child node for each child
  5. bus.
  6. Required properties:
  7. - #address-cells = <1>;
  8. - #size-cells = <0>;
  9. Required properties for child nodes:
  10. - #address-cells = <1>;
  11. - #size-cells = <0>;
  12. - reg : The sub-bus number.
  13. Optional properties for child nodes:
  14. - Other properties specific to the multiplexer/switch hardware.
  15. - Child nodes conforming to i2c bus binding
  16. Example :
  17. /*
  18. An NXP pca9548 8 channel I2C multiplexer at address 0x70
  19. with two NXP pca8574 GPIO expanders attached, one each to
  20. ports 3 and 4.
  21. */
  22. mux@70 {
  23. compatible = "nxp,pca9548";
  24. reg = <0x70>;
  25. #address-cells = <1>;
  26. #size-cells = <0>;
  27. i2c@3 {
  28. #address-cells = <1>;
  29. #size-cells = <0>;
  30. reg = <3>;
  31. gpio1: gpio@38 {
  32. compatible = "nxp,pca8574";
  33. reg = <0x38>;
  34. #gpio-cells = <2>;
  35. gpio-controller;
  36. };
  37. };
  38. i2c@4 {
  39. #address-cells = <1>;
  40. #size-cells = <0>;
  41. reg = <4>;
  42. gpio2: gpio@38 {
  43. compatible = "nxp,pca8574";
  44. reg = <0x38>;
  45. #gpio-cells = <2>;
  46. gpio-controller;
  47. };
  48. };
  49. };