1. 02 12月, 2013 1 次提交
    • A
      max17042_battery: Fix build errors caused by missing REGMAP_I2C config · 93353e80
      Austin Boyle 提交于
      max17042 now uses regmap interface but does not enable config option. This
      patch fixes the following build errors:
      
      drivers/power/max17042_battery.c:661:15: error: variable ‘max17042_regmap_config’ has initializer but incomplete type
      drivers/power/max17042_battery.c:662:2: error: unknown field ‘reg_bits’ specified in initializer
      drivers/power/max17042_battery.c:662:2: warning: excess elements in struct initializer
      drivers/power/max17042_battery.c:662:2: warning: (near initialization for ‘max17042_regmap_config’)
      drivers/power/max17042_battery.c:663:2: error: unknown field ‘val_bits’ specified in initializer
      drivers/power/max17042_battery.c:663:2: warning: excess elements in struct initializer
      drivers/power/max17042_battery.c:663:2: warning: (near initialization for ‘max17042_regmap_config’)
      drivers/power/max17042_battery.c:664:2: error: unknown field ‘val_format_endian’ specified in initializer
      drivers/power/max17042_battery.c:664:23: error: ‘REGMAP_ENDIAN_NATIVE’ undeclared here (not in a function)
      drivers/power/max17042_battery.c:664:2: warning: excess elements in struct initializer
      drivers/power/max17042_battery.c:664:2: warning: (near initialization for ‘max17042_regmap_config’)
      drivers/power/max17042_battery.c: In function ‘max17042_probe’:
      drivers/power/max17042_battery.c:684:2: error: implicit declaration of function ‘devm_regmap_init_i2c’
      Signed-off-by: NAustin Boyle <boyle.austin@gmail.com>
      Acked-by: NJonghwa Lee <jonghwa3.lee@samsung.com>
      Signed-off-by: NAnton Vorontsov <anton@enomsg.org>
      93353e80
  2. 26 10月, 2013 1 次提交
  3. 13 9月, 2013 1 次提交
  4. 31 8月, 2013 1 次提交
  5. 28 8月, 2013 1 次提交
    • M
      bq24190_charger: Add support for TI BQ24190 Battery Charger · d7bf353f
      Mark A. Greer 提交于
      Add driver support for the Texas Instruments BQ24190 battery charger.
      Some of the information provided by the device is about the charger and
      other information is about the battery so create two power_supply objects
      (one for each) and provide the appropriate information for each one.
      
      The device has many fields that go beyond what is reasonable to report or
      modify using the existing 'POWER_SUPPLY_PROP_*' properties so the driver
      exports the register fields via sysfs.  They are prefixed by 'f_' (for
      'field') to make it easier to distinguish between a register field and a
      "normal" sysfs file exported by the power_supply infrastructure.
      Signed-off-by: NMark A. Greer <mgreer@animalcreek.com>
      Signed-off-by: NAnton Vorontsov <anton@enomsg.org>
      d7bf353f
  6. 10 8月, 2013 1 次提交
  7. 11 5月, 2013 1 次提交
    • X
      bq27x00: Fix I2C dependency in KConfig · a2d0dbb4
      Xiong Zhou 提交于
      This patch fixes build failure(randconfig) of next-20130501. When config
      I2C as m, BATTERY_BQ27x00 as y, here comes the failure. The driver depends
      on I2C only if I2C is not disabled, as Lars commented. Last version of
      this patch make the driver depend on I2C unconditionally.
      
      Failure message:
      drivers/built-in.o: In function `bq27x00_read_i2c':
      bq27x00_battery.c:(.text+0x1082a7): undefined reference to `i2c_transfer'
      drivers/built-in.o: In function `bq27x00_battery_init':
      bq27x00_battery.c:(.init.text+0x6085): undefined reference to `i2c_register_driver'
      bq27x00_battery.c:(.init.text+0x60c7): undefined reference to `i2c_del_driver'
      drivers/built-in.o: In function `bq27x00_battery_exit':
      bq27x00_battery.c:(.exit.text+0xbf0): undefined reference to `i2c_del_driver'
      make: *** [vmlinux] Error 1
      Signed-off-by: NXiong Zhou <jencce.kernel@gmail.com>
      Cc: Lars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NAnton Vorontsov <anton@enomsg.org>
      a2d0dbb4
  8. 03 5月, 2013 1 次提交
    • R
      lp8788-charger: Fix kconfig dependency · 237a1b01
      Randy Dunlap 提交于
      Fix build errors in lp8788-charger by making it depend on IIO.
      Fixes errors when CONFIG_IIO=m and CHARGER_LP8788=y.
      
      lp8788-charger.c:(.text+0x2146b5): undefined reference to `iio_channel_get'
      lp8788-charger.c:(.text+0x2146ce): undefined reference to `iio_channel_get'
      lp8788-charger.c:(.text+0x214a86): undefined reference to `iio_read_channel_processed'
      lp8788-charger.c:(.text+0x214b51): undefined reference to `iio_read_channel_processed'
      lp8788-charger.c:(.text+0x214c30): undefined reference to `iio_read_channel_processed'
      lp8788-charger.c:(.text+0x214d93): undefined reference to `iio_channel_release'
      lp8788-charger.c:(.text+0x214dac): undefined reference to `iio_channel_release'
      Signed-off-by: NRandy Dunlap <rdunlap@infradead.org>
      Acked-by: NMilo Kim <milo.kim@ti.com>
      Signed-off-by: NAnton Vorontsov <anton@enomsg.org>
      237a1b01
  9. 19 3月, 2013 1 次提交
    • R
      power_supply: Add support for tps65090-charger · 6f8da5df
      Rhyland Klein 提交于
      This patch adds support for the tps65090 charger driver. This driver is
      responsible for controlling the charger aspect of the tps65090 mfd.
      Currently, this mainly consists of turning on and off the charger, but
      some features of the charger can be supported through this driver
      including:
      
      - Enable Auto Recharge based on Battery voltage
      - Fast Charge Safety Timer
      - Maximum battery discharge current
      - Maximum battery adapter current
      - Enable External Charge
      - Disable charging termination based on low charger current (supported)
      
      Once the driver is accepted, later patches can add support for the
      features above which are not yet supported.
      
      Based on work by:
      
        Syed Rafiuddin <srafiuddin@nvidia.com>
        Laxman Dewangan <ldewangan@nvidia.com>
      Signed-off-by: NRhyland Klein <rklein@nvidia.com>
      Signed-off-by: NAnton Vorontsov <anton@enomsg.org>
      6f8da5df
  10. 18 3月, 2013 1 次提交
  11. 07 3月, 2013 1 次提交
  12. 17 2月, 2013 1 次提交
  13. 03 2月, 2013 1 次提交
  14. 23 1月, 2013 1 次提交
  15. 24 11月, 2012 1 次提交
  16. 19 11月, 2012 3 次提交
  17. 22 9月, 2012 1 次提交
    • 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
  18. 21 9月, 2012 2 次提交
    • J
      power_supply: Enable battery-charger for 88pm860x · a830d28b
      Jett.Zhou 提交于
      There are charger and battery measurement feature for 88pm860x PMIC.
      
      For charger, it can support pre-charge with small current when battery is
      nearly exausted and then changed into fast-charge with CC&CV mode.
      
      For battery monitor, it can support battery measurement such as
      vbat,vsys,vchg and ibat etc,it can aslo accumulating the Coulomb value
      charged or discharged from battery based on Conlomb Counter, we use it
      to estimate battery capacity.
      Signed-off-by: NJett.Zhou <jtzhou@marvell.com>
      Signed-off-by: NAnton Vorontsov <anton.vorontsov@linaro.org>
      a830d28b
    • K
      power_supply: Add new lp8788 charger driver · 98a27664
      Kim, Milo 提交于
      TI LP8788 PMU supports regulators, battery charger, RTC, ADC, backlight
      driver and current sinks.
      
      This patch supports the charger operations including the charger
      interrupt handling.
      
      The LP8788 charger driver provides configurable platform data.  The
      charger platform data includes ADC input ID, maximum battery voltage,
      charging parameters and etc.
      
      The ADC input is used for getting the battery voltage and temperature.
      Charging parameters are used for updating the charger operations such
      like setting charging current and setting End-of-charge conditions.
      
      When the charging interrupt occurs, power supply uevents are generated
      in order to update the user-space information.  For platform specific
      charger action, the charger_event() function can be used in the
      platform side.
      Signed-off-by: NMilo(Woogyom) Kim <milo.kim@ti.com>
      Signed-off-by: NAnton Vorontsov <anton.vorontsov@linaro.org>
      98a27664
  19. 23 8月, 2012 1 次提交
  20. 16 7月, 2012 1 次提交
  21. 28 6月, 2012 1 次提交
  22. 01 6月, 2012 1 次提交
  23. 06 5月, 2012 2 次提交
  24. 05 5月, 2012 2 次提交
    • M
      smb347-charger: Convert to regmap API · 34298d40
      Mika Westerberg 提交于
      The smb347-charger driver does a lot of read-modify-write to the device
      registers. Instead of open-coding everything we can take advantage of
      regmap API which provides nice functions to do this kind of things.
      
      In addition there is no need for custom debugfs file for dumping
      registers as this is already provided by the regmap API.
      Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Signed-off-by: NAnton Vorontsov <anton.vorontsov@linaro.org>
      34298d40
    • A
      power_supply: Make the core a boolean instead of a tristate · 0d4ed4e2
      Anton Vorontsov 提交于
      On Mon, Apr 02, 2012 at 01:53:23PM +1000, Benjamin Herrenschmidt wrote:
      > > drivers/built-in.o: In function `.nouveau_pm_trigger':
      > > (.text+0xa56e8): undefined reference to `.power_supply_is_system_supplied'
      > >
      > > nouveau probably needs to depends on CONFIG_POWER_SUPPLY to force a module
      > > build with the latter is =m
      >
      > Ok, not that trivial...
      >
      > The problem is more like POWER_SUPPLY should be a bool, not a tristate.
      >
      > If you think about it: you don't want things like nouveau to depend on a
      > random subsystem like that, people will never get it. In fact,
      > POWER_SUPPLY provides empty inline stubs when not enabled, so that's
      > really designed to not have depends...
      >
      > However that -cannot- work if POWER_SUPPLY is modular and the drivers
      > who use it are not.
      >
      > The only fixes here that make sense I can think of
      > that don't also involve Kconfig horrors are:
      >
      >  - Ugly: in power_supply.h, use the extern variant if
      >
      >       defined(CONFIG_POWER_SUPPLY) ||
      >        (defined(CONFIG_POWER_SUPPLY_MODULE) && defined(MODULE))
      >
      > IE. use the stub if power supply is a module and what is being built is
      > built-in. Of course that's not only ugly, it somewhat sucks from a user
      > perspective as the subsystem now exists but can't be used by some
      > drivers...
      >
      >  - Better: Just make the bloody thing a bool :-) The power supply
      > framework itself is small enough, just make it a boolean option and
      > avoid the problem entirely. The actual power supply sub drivers can
      > remain modular of course.
      Suggested-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NAnton Vorontsov <cbouatmailru@gmail.com>
      0d4ed4e2
  25. 27 3月, 2012 3 次提交
  26. 09 3月, 2012 1 次提交
  27. 10 1月, 2012 1 次提交
    • A
      power_supply: Mark da9052 driver as broken · 6cfc2a23
      Anton Vorontsov 提交于
      There are some problems with MFD part of this driver, so the
      driver fails to build:
      
      drivers/power/da9052-battery.c: In function 'da9052_bat_read_volt':
      drivers/power/da9052-battery.c:293:2: error: implicit declaration of function 'da9052_adc_manual_read' [-Werror=implicit-function-declaration]
      drivers/power/da9052-battery.c: In function 'da9052_bat_check_presence':
      drivers/power/da9052-battery.c:306:2: error: implicit declaration of function 'da9052_adc_read_temp' [-Werror=implicit-function-declaration]
      drivers/power/da9052-battery.c: In function 'da9052_determine_vc_tbl_index':
      drivers/power/da9052-battery.c:348:1: warning: control reaches end of non-void function [-Wreturn-type]
      cc1: some warnings being treated as errors
      
      The fix for MFD part will probably go post -rc1 (or in the next merge
      window), so let's disable the driver for now.
      Reported-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NAnton Vorontsov <cbouatmailru@gmail.com>
      6cfc2a23
  28. 06 1月, 2012 2 次提交
  29. 04 1月, 2012 2 次提交
  30. 02 11月, 2011 1 次提交
  31. 08 7月, 2011 1 次提交