sbs,sbs-manager.txt 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. Binding for sbs-manager
  2. Required properties:
  3. - compatible: "<vendor>,<part-number>", "sbs,sbs-charger" as fallback. The part
  4. number compatible string might be used in order to take care of vendor
  5. specific registers.
  6. - reg: integer, i2c address of the device. Should be <0xa>.
  7. Optional properties:
  8. - gpio-controller: Marks the port as GPIO controller.
  9. See "gpio-specifier" in .../devicetree/bindings/gpio/gpio.txt.
  10. - #gpio-cells: Should be <2>. The first cell is the pin number, the second cell
  11. is used to specify optional parameters:
  12. See "gpio-specifier" in .../devicetree/bindings/gpio/gpio.txt.
  13. From OS view the device is basically an i2c-mux used to communicate with up to
  14. four smart battery devices at address 0xb. The driver actually implements this
  15. behaviour. So standard i2c-mux nodes can be used to register up to four slave
  16. batteries. Channels will be numerated starting from 1 to 4.
  17. Example:
  18. batman@a {
  19. compatible = "lltc,ltc1760", "sbs,sbs-manager";
  20. reg = <0x0a>;
  21. #address-cells = <1>;
  22. #size-cells = <0>;
  23. gpio-controller;
  24. #gpio-cells = <2>;
  25. i2c@1 {
  26. #address-cells = <1>;
  27. #size-cells = <0>;
  28. reg = <1>;
  29. battery@b {
  30. compatible = "ti,bq2060", "sbs,sbs-battery";
  31. reg = <0x0b>;
  32. sbs,battery-detect-gpios = <&batman 1 1>;
  33. };
  34. };
  35. i2c@2 {
  36. #address-cells = <1>;
  37. #size-cells = <0>;
  38. reg = <2>;
  39. battery@b {
  40. compatible = "ti,bq2060", "sbs,sbs-battery";
  41. reg = <0x0b>;
  42. sbs,battery-detect-gpios = <&batman 2 1>;
  43. };
  44. };
  45. i2c@3 {
  46. #address-cells = <1>;
  47. #size-cells = <0>;
  48. reg = <3>;
  49. battery@b {
  50. compatible = "ti,bq2060", "sbs,sbs-battery";
  51. reg = <0x0b>;
  52. sbs,battery-detect-gpios = <&batman 3 1>;
  53. };
  54. };
  55. };