1. 22 9月, 2012 3 次提交
    • A
      power: battery: Generic battery driver using IIO · e60fea79
      anish kumar 提交于
      Driver to allow use of the ADC drivers supported by the IIO
      subsystem for battery status monitoring. Connecting this
      driver to the relevant IIO device requires registration of
      the appropriate iio_map structure array by the IIO device
      driver (usually from platform data).  If specified the driver
      will also make use of a gpio to provide interrupt driven
      notification that the battery is fully charged.
      
      In last version:
      Addressed concerns raised by lars:
      a. made the adc_bat per device.
      b. get the IIO channel using hardcoded channel names.
      c. Minor issues related to gpio_is_valid and some code
         refactoring.
      
      In V1:
      Addressed concerns raised by Anton:
      a. changed the struct name to gab(generic adc battery).
      b. Added some functions to neaten the code.
      c. Some minor coding guidelines changes.
      d. Used the latest function introduce by lars:
         iio_read_channel_processed to streamline the code.
      
      In V2:
      Addressed concerns by lars:
      a. No need of allocating memory for channels.Make it array.
      b. Code restructring, coding style and following kernel guidelines changes
         suggested by him.
      
      In V3:
      Addressed conerns by Anton:
      a. Added the copyright.
      b. Coding guidelines changes suggested by him.
      c. Added Makefile and Kconfig
      Signed-off-by: Nanish kumar <anish198519851985@gmail.com>
      Acked-by: NAnton Vorontsov <cbouatmailru@gmail.com>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      e60fea79
    • P
      pda_power: Remove ac_draw_failed goto and label · c10a002a
      Paul Parsons 提交于
      A previous patch added the ac_draw_failed goto and label to
      pda_power_probe(). The goto would be invoked after a failed call to
      regulator_get().
      
      However the way ac_draw is used - always after a check for NULL - suggests
      that a failed call to regulator_get() was not fatal.
      
      This patch removes the ac_draw_failed goto and label, partly reverting the
      previous patch.
      
      This patch also removes the assignment of an error code to ret after a
      failed call to regulator_get(), since the error code is now never used.
      Signed-off-by: NPaul Parsons <lost.distance@yahoo.com>
      Cc: Philipp Zabel <philipp.zabel@gmail.com>
      Signed-off-by: NAnton Vorontsov <anton.vorontsov@linaro.org>
      c10a002a
    • C
      charger-manager: Add support sysfs entry for charger · 3950c786
      Chanwoo Choi 提交于
      This patch add support sysfs entry for each charger(regulator).
      Charger-manager use one or more chargers for charging battery but some
      charger isn't necessary on specific scenario. So, if some charger isn't
      needed, can disable specific charger through 'externally_control' entry
      while system is on state and confirm the information(name, state) of
      charger.
      
      The list of added sysfs entry
      - /sys/class/power_supply/battery/chargers/charger.[index]/name
        show name of charger(regulator)
      - /sys/class/power_supply/battery/chargers/charger.[index]/state
        show either enabled or disabled state of charger
      - /sys/class/power_supply/battery/chargers/charger.[index]/externally_control
      
      If 'externally_control' of specific charger is 1, Charger-manager cannot
      enable regulator for charging when charger cable is attached and charger
      must be maintained with disabled state. If 'externally_control' is zero,
      Charger-manager usually can control to enable/disable regulator.
      Signed-off-by: NChanwoo Choi <cw00.choi@samsung.com>
      Signed-off-by: NMyungjoo Ham <myungjoo.ham@samsung.com>
      Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
      Signed-off-by: NAnton Vorontsov <anton.vorontsov@linaro.org>
      3950c786
  2. 21 9月, 2012 33 次提交
  3. 13 9月, 2012 1 次提交
  4. 23 8月, 2012 3 次提交