charger-manager.txt 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. charger-manager bindings
  2. ~~~~~~~~~~~~~~~~~~~~~~~~
  3. Required properties :
  4. - compatible : "charger-manager"
  5. - <>-supply : for regulator consumer
  6. - cm-num-chargers : number of chargers
  7. - cm-chargers : name of chargers
  8. - cm-fuel-gauge : name of battery fuel gauge
  9. - subnode <regulator> :
  10. - cm-regulator-name : name of charger regulator
  11. - subnode <cable> :
  12. - cm-cable-name : name of charger cable
  13. - cm-cable-extcon : name of extcon dev
  14. (optional) - cm-cable-min : minimum current of cable
  15. (optional) - cm-cable-max : maximum current of cable
  16. Optional properties :
  17. - cm-name : charger manager's name (default : "battery")
  18. - cm-poll-mode : polling mode (enum polling_modes)
  19. - cm-poll-interval : polling interval
  20. - cm-battery-stat : battery status (enum data_source)
  21. - cm-fullbatt-* : data for full battery checking
  22. - cm-thermal-zone : name of external thermometer's thermal zone
  23. - cm-battery-* : threshold battery temperature for charging
  24. -cold : critical cold temperature of battery for charging
  25. -cold-in-minus : flag that cold temperature is in minus degrees
  26. -hot : critical hot temperature of battery for charging
  27. -temp-diff : temperature difference to allow recharging
  28. - cm-dis/charging-max = limits of charging duration
  29. Example :
  30. charger-manager@0 {
  31. compatible = "charger-manager";
  32. chg-reg-supply = <&charger_regulator>;
  33. cm-name = "battery";
  34. /* Always polling ON : 30s */
  35. cm-poll-mode = <1>;
  36. cm-poll-interval = <30000>;
  37. cm-fullbatt-vchkdrop-ms = <30000>;
  38. cm-fullbatt-vchkdrop-volt = <150000>;
  39. cm-fullbatt-soc = <100>;
  40. cm-battery-stat = <3>;
  41. cm-num-chargers = <3>;
  42. cm-chargers = "charger0", "charger1", "charger2";
  43. cm-fuel-gauge = "fuelgauge0";
  44. cm-thermal-zone = "thermal_zone.1"
  45. /* in deci centigrade */
  46. cm-battery-cold = <50>;
  47. cm-battery-cold-in-minus;
  48. cm-battery-hot = <800>;
  49. cm-battery-temp-diff = <100>;
  50. /* Allow charging for 5hr */
  51. cm-charging-max = <18000000>;
  52. /* Allow discharging for 2hr */
  53. cm-discharging-max = <7200000>;
  54. regulator@0 {
  55. cm-regulator-name = "chg-reg";
  56. cable@0 {
  57. cm-cable-name = "USB";
  58. cm-cable-extcon = "extcon-dev.0";
  59. cm-cable-min = <475000>;
  60. cm-cable-max = <500000>;
  61. };
  62. cable@1 {
  63. cm-cable-name = "TA";
  64. cm-cable-extcon = "extcon-dev.0";
  65. cm-cable-min = <650000>;
  66. cm-cable-max = <675000>;
  67. };
  68. };
  69. };