aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/power/Makefile (follow)
AgeCommit message (Collapse)AuthorFilesLines
2020-10-22PM: AVS: Drop the avs directory and the corresponding KconfigUlf Hansson1-1/+0
All avs drivers have now been moved to their corresponding soc specific directories. Additionally, they don't depend on the POWER_AVS Kconfig anymore. Therefore, let's simply drop the drivers/power/avs directory altogether. Cc: Nishanth Menon <nm@ti.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Reviewed-by: Nishanth Menon <nm@ti.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2019-05-21treewide: Add SPDX license identifier - Makefile/KconfigThomas Gleixner1-0/+1
Add SPDX license identifiers to all Make/Kconfig files which: - Have no license information of any form These files fall under the project license, GPL v2 only. The resulting SPDX license identifier is: GPL-2.0-only Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-08-11power: move power supply drivers to power/supplySebastian Reichel1-74/+1
This moves all power supply drivers from drivers/power/ to drivers/power/supply/. The intention is a cleaner source tree, since drivers/power/ also contains frameworks unrelated to power supply, like adaptive voltage scaling. Signed-off-by: Sebastian Reichel <sre@kernel.org>
2016-02-24power: act8945a: add charger driver for ACT8945AWenyou Yang1-0/+1
This patch adds new driver for Active-semi ACT8945A ActivePath charger (part of ACT8945A MFD driver) providing power supply class information to userspace. The driver can be configured through DT (such as, total timer, precondition timer and input over-voltage threshold). Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> [ add "|| COMPILE_TEST" to MFD_ACT8945A dependency ] Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-12-05power: bq27xxx_battery: Reorganize I2C into a moduleAndrew F. Davis1-0/+1
Separate out I2C functionality into a module. This fixes several small issues and simplifies the driver initialization. Signed-off-by: Andrew F. Davis <afd@ti.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-11-06Merge tag 'mfd-for-linus-4.4' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfdLinus Torvalds1-0/+1
Pull MFD updates from Lee Jones: "New Device Support: - Add support for 88pm860; 88pm80x - Add support for 24c08 EEPROM; at24 - Add support for Broxton Whiskey Cove; intel* - Add support for RTS522A; rts5227 - Add support for I2C devices; intel_quark_i2c_gpio New Functionality: - Add microphone support; arizona - Add general purpose switch support; arizona - Add fuel-gauge support; da9150-core - Add shutdown support; sec-core - Add charger support; tps65217 - Add flexible serial communication unit support; atmel-flexcom - Add power button support; axp20x - Add led-flash support; rt5033 Core Frameworks: - Supply a generic macro for defining Regmap IRQs - Rework ACPI child device matching Fix-ups: - Use Regmap to access registers; tps6105x - Use DEFINE_RES_IRQ_NAMED() macro; da9150 - Re-arrange device registration order; intel_quark_i2c_gpio - Allow OF matching; cros_ec_i2c, atmel-hlcdc, hi6421-pmic, max8997, sm501 - Handle deferred probe; twl6040 - Improve accuracy of headphone detect; arizona - Unnecessary MODULE_ALIAS() removal; bcm590xx, rt5033 - Remove unused code; htc-i2cpld, arizona, pcf50633-irq, sec-core - Simplify code; kempld, rts5209, da903x, lm3533, da9052, arizona - Remove #iffery; arizona - DT binding adaptions; many Bug Fixes: - Fix possible NULL pointer dereference; wm831x, tps6105x - Fix 64bit bug; intel_soc_pmic_bxtwc - Fix signedness issue; arizona" * tag 'mfd-for-linus-4.4' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (73 commits) bindings: mfd: s2mps11: Add documentation for s2mps15 PMIC mfd: sec-core: Remove unused s2mpu02-rtc and s2mpu02-clk children extcon: arizona: Add extcon specific device tree binding document MAINTAINERS: Add binding docs for Cirrus Logic/Wolfson Arizona devices mfd: arizona: Remove bindings covered in new subsystem specific docs mfd: rt5033: Add RT5033 Flash led sub device mfd: lpss: Add Intel Broxton PCI IDs mfd: lpss: Add Broxton ACPI IDs mfd: arizona: Signedness bug in arizona_runtime_suspend() mfd: axp20x: Add a cell for the power button part of the, axp288 PMICs mfd: dt-bindings: Document pulled down WRSTBI pin on S2MPS1X mfd: sec-core: Disable buck voltage reset on watchdog falling edge mfd: sec-core: Dump PMIC revision to find out the HW mfd: arizona: Use correct type ID for device tree config mfd: arizona: Remove use of codec build config #ifdefs mfd: arizona: Simplify adding subdevices mfd: arizona: Downgrade type mismatch messages to dev_warn mfd: arizona: Factor out checking of jack detection state mfd: arizona: Factor out DCVDD isolation control mfd: Make TPS6105X select REGMAP_I2C ...
2015-10-13power: Add support for DA9150 Fuel-GaugeAdam Thomson1-0/+1
This adds power supply driver support for the Fuel-Gauge part of the DA9150 combined Charger and Fuel-Gauge device. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Acked-by: Sebastian Reichel <sre@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
2015-09-24power_supply: Add support for tps65217-charger.Enric Balletbo i Serra1-0/+1
This patch adds support for the tps65217 charger driver. This driver is responsible for controlling the charger aspect of the tps65217 mfd. Currently, this mainly consists of turning on and off the charger, but some other features of the charger can be supported through this driver. Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-09-23power: bq27x00_battery: Renaming for consistencyAndrew F. Davis1-1/+1
Rename functions that are used by multiple devices. New devices have been added and the function names and driver name are no longer general enough for the functionality they provide. Signed-off-by: Andrew F. Davis <afd@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> Acked-by: GUAN Xuetao <gxt@mprc.pku.edu.cn> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-09-22power: Add Qualcomm SMBB driverCourtney Cavin1-0/+1
Add the Qualcomm Switch-Mode Battery Charger and Boost driver, found in pm8941. Signed-off-by: Courtney Cavin <courtney.cavin@sonymobile.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-09-22power: Add an axp20x-usb-power driverHans de Goede1-0/+1
This adds a driver for the usb power_supply bits of the axp20x PMICs. I initially started writing my own driver, before coming aware of Bruno Prémont's excellent earlier RFC with a driver for this. My driver was lacking CURRENT_MAX and VOLTAGE_MIN support Bruno's drvier has, so I've copied the code for those from his driver. Note that the AC-power-supply and battery charger bits will need separate drivers. Each one needs its own devictree child-node so that other devicetree nodes can reference the right power-supply, and thus each one will get its own mfd-cell / platform_device and platform-driver. Cc: Bruno Prémont <bonbons@linux-vserver.org> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Bruno Prémont <bonbons@linux-vserver.org> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-05-30power_supply: Add support for Richtek RT9455 battery chargerAnda-Maria Nicolae1-0/+1
Based on the datasheet found here: http://www.richtek.com/download_ds.jsp?p=RT9455 Signed-off-by: Anda-Maria Nicolae <anda-maria.nicolae@intel.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski.k@gmail.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-05-24power: axp288_charger: axp288 charger driverRamakrishna Pallala1-0/+1
This patch adds new power supply charger driver support for X-Power AXP288 PMIC integrated charger. This driver interfaces with the axp20x mfd driver as a cell and listens to extcon cable events for setting up charging. Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-05-23power_supply: Add support for TI BQ25890 charger chipLaurentiu Palcu1-0/+1
More details about the chip can be found here: http://www.ti.com/product/bq25890 Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-05-23power_supply: Add TI BQ24257 charger driverLaurentiu Palcu1-0/+1
Based on the datasheet found here: http://www.ti.com/lit/ds/symlink/bq24257.pdf Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Reviewed-by: Krzysztof Kozlowski <k.kozlowski.k@gmail.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-03-07X-Power AXP288 PMIC Fuel Gauge DriverTodd Brandt1-0/+1
New power_supply driver at driver/power which interfaces with the axp20x mfd driver as a cell. Provides battery info, monitors for changes, and generates alerts on temperature and capacity issues Signed-off-by: Todd Brandt <todd.e.brandt@linux.intel.com> Acked-by: Jacob Pan <jacob.jun.pan@linux.intel.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-02-25power: Use subdir-ccflags-* to inherit debug flagGeert Uytterhoeven1-1/+1
Use subdir-ccflags-* instead of ccflags-* to inherit the debug settings from Kconfig when traversing subdirectories. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-02-25power: Add support for DA9150 ChargerAdam Thomson1-0/+1
This patch adds support for DA9150 Charger & Fuel-Gauge IC Charger. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-01-22Add LTC2941/LTC2943 Battery Gauge DriverMike Looijmans1-0/+1
Both the LTC2941 and LTC2943 measure battery capacity. The LTC2943 is compatible with the LTC2941, it adds voltage and temperature monitoring, and uses a slightly different conversion formula for the charge counter. To avoid confusion with e.g. the LTC2945, the driver is called LTC2941 instead of LTC294X. v2: Fix units of measurement: uV, uA and centidegrees. v3: Correctly set configuration register. Allow negative values for the sense resistor. v4: Run checkpatch.pl and fix all errors and warnings. v5: Prefix "lltc," to devicetree properties. Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl> [ removed .owner field ] Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-01-20power: max77693: Add charger driver for Maxim 77693Krzysztof Kozlowski1-0/+1
Add new driver for Maxim 77693 switch-mode charger (part of max77693 MFD driver) providing power supply class information to userspace. The charger has +20V tolerant input. Current input can be set from 0 to 2.58 A. The charger can deliver up to 2.1 A to the battery or 3.5 A to the system (when supplying additional current from battery to system). The driver is configured through DTS (battery and system related settings) and sysfs entries (timers and top-off charging threshold). Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2015-01-20power: rt5033_battery: Add RT5033 Fuel gauge device driverBeomho Seo1-0/+1
This patch adds device driver of Richtek PMIC. The driver support battery fuel gauge. Fuel gauge calculates and determines the battery state of charge (SOC) according to battery open circuit voltage (OCV). Also, this driver provides battery average voltage, voltage and battery present property. Cc: Sebastian Reichel <sre@kernel.org> Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Cc: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Beomho Seo <beomho.seo@samsung.com> Acked-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2014-07-24power: add driver for battery reading on iPaq h3xxxDmitry Artamonow1-0/+1
This adds a driver for reading the battery status of the battery connected to the Atmel microcontroller on the iPAQ h3xxx series. Based on a driver from handhelds.org 2.6.21 kernel, written by Alessandro GARDICH. Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Sebastian Reichel <sre@kernel.org>
2013-12-23power_supply: Add charger support for Maxim 14577Krzysztof Kozlowski1-0/+1
MAX14577 chip is a multi-function device which includes MUIC, charger and voltage regulator. The driver is located in drivers/mfd. This patch supports battery charging control of MAX14577 chip and provides power supply class information to userspace. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Anton Vorontsov <anton@enomsg.org>
2013-10-25power_supply: Add support for bq24735 chargerDarbha Sriharsha1-0/+1
Adds support for the bq24735 charger chipset. The bq24735 is a high-efficiency, synchronous battery charger. It allows control of the charging current, input current, and the charger voltage DAC's through SMBus. Signed-off-by: Darbha Sriharsha <dsriharsha@nvidia.com> Signed-off-by: Rhyland Klein <rklein@nvidia.com> Thanks-to: Stephen Warren <swarren@wwwdotorg.org> Thanks-to: Thierry Reding <thierry.reding@gmail.com> Thanks-to: Manish Badarkhe <badarkhe.manish@gmail.com> Signed-off-by: Anton Vorontsov <anton@enomsg.org>
2013-08-30power: Add twl4030_madc battery driver.Marek Belisko1-0/+1
This driver is used and tested on gta04 phone. It's using twl4030_madc (similar to rx51 existing driver). Driver also implement charging and discharging calibration data so user can define ranges and level. Signed-off-by: Marek Belisko <marek@goldelico.com> Signed-off-by: Lukas Märdian <lukas@goldelico.com> Signed-off-by: Anton Vorontsov <anton@enomsg.org>
2013-08-27bq24190_charger: Add support for TI BQ24190 Battery ChargerMark A. Greer1-0/+1
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: Mark A. Greer <mgreer@animalcreek.com> Signed-off-by: Anton Vorontsov <anton@enomsg.org>
2013-03-18power_supply: Add support for tps65090-chargerRhyland Klein1-0/+1
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: Rhyland Klein <rklein@nvidia.com> Signed-off-by: Anton Vorontsov <anton@enomsg.org>
2013-03-07pm2301-charger: Always compile the PM2301 Charger driver with AB8500 Battery MgntMarcus Cooper1-2/+1
The PM2301 Charger should always be available when using the AB8500 Battery Management system, we're ensuring this will be the case. Signed-off-by: Marcus Cooper <marcus.xm.cooper@stericsson.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Reviewed-by: Hakan BERG <hakan.berg@stericsson.com> Reviewed-by: Mian Yousaf KAUKAB <mian.yousaf.kaukab@stericsson.com>
2013-02-02Merge branch 'tb-power-2' of git://git.linaro.org/people/ljones/linux-3.0-ux500Anton Vorontsov1-0/+1
Pull a huge ab8500/pm2301 pile of changes from Lee Jones. Lee did an awesome job cleaning this stuff up and thus brought ab8500 Stericsson's development tree much closer to the mainline. Even more changes to come, though. Conflicts: drivers/power/Kconfig
2013-02-02power: Add battery driver for goldfish emulatorMike Lockwood1-0/+1
Add the emulated power driver for the Goldfish platform. This folds together the code from the Google tree, Jun Nakajima's cleanups and x86 porting work, and then a tidy up to pass checkpatch. Signed-off-by: Mike A. Chan <mikechan@google.com> [cleanup and x86 support] Signed-off-by: Sheng Yang <sheng@linux.intel.com> Signed-off-by: Yunhong Jiang <yunhong.jiang@intel.com> Signed-off-by: Xiaohui Xin <xiaohui.xin@intel.com> Signed-off-by: Jun Nakajima <jun.nakajima@intel.com> Signed-off-by: Bruce Beare <bruce.j.beare@intel.com> [ported to 3.4] Signed-off-by: Tom Keel <thomas.keel@intel.com> [ported to 3.7 and final tidy] Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Anton Vorontsov <anton@enomsg.org>
2013-01-23pm2301: Provide u9540 support for the pm2301 chargerMichel JAOUEN1-0/+1
AC charger driver for the DB9540 based platforms. Signed-off-by: Rajkumar Kasirajan <rajkumar.kasirajan@stericsson.com> Signed-off-by: Loic Pallardy <loic.pallardy@stericsson.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Reviewed-by: Michel JAOUEN <michel.jaouen@stericsson.com> Tested-by: Michel JAOUEN <michel.jaouen@stericsson.com>
2013-01-05Merge branch 'for-anton' of git://git.linaro.org/people/ljones/linux-3.0-ux500Anton Vorontsov1-1/+1
2012-12-13Merge tag 'for-v3.8-merged' of git://git.infradead.org/battery-2.6Linus Torvalds1-1/+3
Pull battery subsystem updates from Anton Vorontsov: "Highlights: - Two new drivers from Pali Rohár and N900 hackers: rx51_battery and bq2415x_charger. The drivers are a part of a solution to replace the proprietary Nokia BME stack - Power supply core now registers devices with a thermal cooling subsystem, so we can now automatically throttle charging. Thanks to Ramakrishna Pallala! - Device tree support for ab8500 and max8925_power drivers - Random fixups and enhancements for a bunch of drivers." * tag 'for-v3.8-merged' of git://git.infradead.org/battery-2.6: (22 commits) max8925_power: Add support for device-tree initialization ab8500: Add devicetree support for chargalg ab8500: Add devicetree support for charger ab8500: Add devicetree support for btemp ab8500: Add devicetree support for fuelgauge twl4030_charger: Change TWL4030_MODULE_* ids to TWL_MODULE_* jz4740-battery: Use devm_request_and_ioremap jz4740-battery: Use devm_kzalloc bq27x00_battery: Fixup nominal available capacity reporting bq2415x_charger: Fix style issues bq2415x_charger: Add Kconfig/Makefile entries power_supply: Add bq2415x charger driver power_supply: Add new Nokia RX-51 (N900) power supply battery driver max17042_battery: Fix missing verify_model_lock() return value check ds2782_battery: Fix signedness bug in ds278x_read_reg16() lp8788-charger: Fix ADC channel names lp8788-charger: Fix wrong ADC conversion lp8788-charger: Use consumer device name on setting IIO channels power_supply: Register power supply for thermal cooling device power_supply: Add support for CHARGE_CONTROL_* attributes ...
2012-12-11ab8500: remove explicit handling of battery typeRajanikanth H.V1-1/+1
property, battery-type shall be one of supported technology type instead blank - refer: Documentation/devicetree/bindings/power_supply/ab8500/fg.txt for the list supported types - this patch appends to ab8500 bm devs DT binding patch set ref: commit-id e0f1abeba5c2d8a2183566717d99294fd1a29c2e git://git.infradead.org/battery-2.6.git - promote ab8500_fg probe to happen before ab8500_btemp probe as btemp driver depends on fuelgauge list, ref: ab8500_fg_get(...) Signed-off-by: Rajanikanth H.V <rajanikanth.hv@stericsson.com>
2012-11-24power: Add simple poweroff-gpio driverJamie Lentin1-0/+1
Given appropriate devicetree bindings, this driver registers a pm_power_off function to set a GPIO line high/low to power down your board. Signed-off-by: Jamie Lentin <jm@lentin.co.uk> Signed-off-by: Andrew Lunn <andrew@lunn.ch> Tested-by:Simon Baatz <gmbnomis@gmail.com> Signed-off-by: Jason Cooper <jason@lakedaemon.net>
2012-11-18ab8500: Add devicetree support for fuelgaugeRajanikanth H.V1-1/+1
- This patch adds device tree support for fuelgauge driver - optimize bm devices platform_data usage and of_probe(...) Note: of_probe() routine for battery managed devices is made common across all bm drivers. - test status: - interrupt numbers assigned differs between legacy and FDT mode. Signed-off-by: Rajanikanth H.V <rajanikanth.hv@stericsson.com> Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
2012-11-18bq2415x_charger: Add Kconfig/Makefile entriesAnton Vorontsov1-0/+1
This commit adds Kconfig and Makefile entries so that we could actually build the driver. Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>
2012-11-18power_supply: Add new Nokia RX-51 (N900) power supply battery driverPali Rohár1-0/+1
This driver exporting battery design capacity, temperature and voltage for battery in Nokia RX-51. This driver is needed for open source battery management on Nokia RX-51 (N900). Signed-off-by: Pali Rohár <pali.rohar@gmail.com> Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
2012-10-07Merge tag 'for-v3.7' of git://git.infradead.org/battery-2.6Linus Torvalds1-0/+3
Pull battery updates from Anton Vorontsov: "1. New drivers: - Marvell 88pm860x charger and battery drivers; - Texas Instruments LP8788 charger driver; 2. Two new power supply properties: whether a battery is authentic, and chargers' maximal currents and voltages; 3. A lot of TI LP8727 Charger cleanups; 4. New features for Charger Manager, mainly now we can disable specific regulators; 5. Random fixes and cleanups for other drivers." Fix up trivial conflicts in <linux/mfd/88pm860x.h> * tag 'for-v3.7' of git://git.infradead.org/battery-2.6: (52 commits) pda_power: Remove ac_draw_failed goto and label charger-manager: Add support sysfs entry for charger charger-manager: Support limit of maximum possible charger-manager: Check fully charged state of battery periodically lp8727_charger: More pure cosmetic improvements lp8727_charger: Fix checkpatch warning lp8727_charger: Add description in the private data lp8727_charger: Fix a typo - chg_parm to chg_param lp8727_charger: Make some cosmetic changes in lp8727_delayed_func() lp8727_charger: Clean up lp8727_charger_changed() lp8727_charger: Return if the battery is discharging lp8727_charger: Make lp8727_charger_get_propery() simpler lp8727_charger: Make lp8727_ctrl_switch() inline lp8727_charger: Make lp8727_init_device() shorter lp8727_charger: Clean up lp8727_is_charger_attached() lp8727_charger: Use specific definition lp8727_charger: Clean up lp8727 definitions lp8727_charger: Use the definition rather than enum lp8727_charger: Fix code for getting battery temp lp8727_charger: Clear interrrupts at inital time ...
2012-09-22power: battery: Generic battery driver using IIOanish kumar1-0/+1
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: anish kumar <anish198519851985@gmail.com> Acked-by: Anton Vorontsov <cbouatmailru@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2012-09-20power_supply: Enable battery-charger for 88pm860xJett.Zhou1-0/+2
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: Jett.Zhou <jtzhou@marvell.com> Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
2012-09-20power_supply: Add new lp8788 charger driverKim, Milo1-0/+1
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: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
2012-05-31ARM: OMAP: SmartReflex: Move smartreflex driver to drivers/Jean Pihet1-0/+1
After a clean-up of the interfaces the OMAP Smartreflex IP driver is now a generic driver. Move it to drivers/power/avs/. The build is controlled by the following Kconfig options: . CONFIG_POWER_AVS: general knob for Adaptive Voltage Scaling support, . CONFIG_POWER_AVS_OMAP: AVS(Adaptive Voltage Scaling) support on OMAP containing the version 1 or version 2 of the SmartReflex IP, . CONFIG_POWER_AVS_OMAP_CLASS3: Class 3 implementation of Smartreflex. Signed-off-by: Jean Pihet <j-pihet@ti.com> Signed-off-by: J Keerthy <j-keerthy@ti.com> Acked-by: Rafael J. Wysocki <rjw@sisk.pl> Reviewed-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
2012-03-30Merge tag 'for-v3.4-rc1' of git://git.infradead.org/battery-2.6Linus Torvalds1-0/+2
Pull battery updates from Anton Vorontsov: "Various small bugfixes and enhancements, plus two new drivers: - A quite complex ab8500 charger driver, submitted by Arun Murthy @ ST-Ericsson; - Summit Microelectronics SMB347 Battery Charger, submitted by Bruce E Robertson and Alan Cox @ Intel. And that's all." * tag 'for-v3.4-rc1' of git://git.infradead.org/battery-2.6: (36 commits) max17042_battery: Clean up interrupt handling Revert "max8998_charger: Include linux/module.h just once" ab8500_fg: Fix some build warnings on x86_64 max17042_battery: Fix CHARGE_FULL representation. max8998_charger: Include linux/module.h just once power_supply: Convert i2c drivers to module_i2c_driver lp8727_charger: Add MODULE_DEVICE_TABLE charger-manager: Simplify charger_get_property(), get rid of a warning charger-manager: Clean up for better readability da9052-battery: Convert to use module_platform_driver da9052-battery: Fix a memory leak when unload the module da9052-battery: Add missing platform_set_drvdata ab8500: Turn unneeded global symbols into local ones ab8500_fg: Fix copy-paste error ab8500_fg: Get rid of 'struct battery_type' ab8500_fg: Get rid of 'struct v_to_cap' ab8500_btemp: Get rid of 'enum adc_therm' ab8500_charger: Convert to the new USB OTG calls ab8500-btemp: AB8500 battery temperature driver ab8500-fg: A8500 fuel gauge driver ...
2012-03-26ab8500-btemp: AB8500 battery temperature driverArun Murthy1-0/+1
This driver is responsible for battery detection, obtaining battery temperature and monitor the battery temperature by taking precautionary measurements when battery temperature goes beyond or below the thresholds. Signed-off-by: Arun Murthy <arun.murthy@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
2012-03-26Add I2C driver for Summit Microelectronics SMB347 Battery Charger.Bruce E. Robertson1-0/+1
Driver support for the Summit I²C battery charger. This is used in some Intel devices. Signed-off-by: Bruce E. Robertson <bruce.e.robertson@intel.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
2012-03-08DS2781 Maxim Stand-Alone Fuel Gauge battery and w1 slave driversRenata Sayakhova1-0/+1
Signed-off-by: Renata Sayakhova <rsayakhova@gmail.com> Acked-by: Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-01-06power_supply: Add DA9052 battery driverAshish Jangam1-0/+1
Driver for DA9052 battery charger. This driver depends on DA9052 MFD core dirver for definitions and methods. This patch is functionally tested on Samsung SMDKV6410. Signed-off-by: David Dajun Chen <dchen@diasemi.com> Signed-off-by: Ashish Jangam <ashish.jangam@kpitcummins.com> Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>
2012-01-06bq20z75: Rename to sbs-batteryRhyland Klein1-1/+1
This driver for the bq20z75 implemented the register spec defined by the SBS standard. As this is not unique to this the TI part this was originally written for, we can generalize this driver to show its support for any SBS compliant battery. Signed-off-by: Rhyland Klein <rklein@nvidia.com> Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>
2012-01-04power_supply: Add LP8727 charger driverWoogyom Kim1-0/+1
National Semiconductor LP8727 is the battery charger with Micro/Mini USB interface. This IC includes below functions: - I2C interface for accessing user registers - Single input Li-Ion battery charger - Charger input ID detection from Micro/Mini USB - Multiplexing switches on USB, UART Signed-off-by: Woogyom Kim <milo.kim@ti.com> Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>