- 08 6月, 2017 2 次提交
-
-
由 Liam Breck 提交于
Previously there was no way to configure these chips in the event that the defaults didn't match the battery in question. For chips with RAM data memory (and also those with flash/NVM data memory if CONFIG_BATTERY_BQ27XXX_DT_UPDATES_NVM is defined and the user has not set module param dt_monitored_battery_updates_nvm=0) we now call power_supply_get_battery_info(), check its values, and write battery properties to chip data memory if there is a dm_regs table for the chip. Signed-off-by: NMatt Ranostay <matt@ranostay.consulting> Signed-off-by: NLiam Breck <kernel@networkimprov.net> Signed-off-by: NSebastian Reichel <sebastian.reichel@collabora.co.uk>
-
由 Tony Lindgren 提交于
On the CPCAP PMIC we can use the ADCs for monitoring the battery, and there is also a coulomb counter. So let's add basic support for the battery driver. I did not add any capacity prediction as that should probably be done in the user space. Or at least user space should tell the kernel some battery statistics and then the kernel driver could display the capacity based on that. Cc: devicetree@vger.kernel.org Cc: Marcel Partap <mpartap@gmx.net> Cc: Michael Scott <michael.scott@linaro.org> Cc: Rob Herring <robh@kernel.org> Signed-off-by: NTony Lindgren <tony@atomide.com> Signed-off-by: NSebastian Reichel <sebastian.reichel@collabora.co.uk>
-
- 15 5月, 2017 1 次提交
-
-
由 Mike Looijmans 提交于
The LTC3651 reports its status via GPIO lines. This driver translates the GPIO levels to battery charger status information via sysfs. It relies on devicetree to supply the IO configuration. Signed-off-by: NMike Looijmans <mike.looijmans@topic.nl> Signed-off-by: NSebastian Reichel <sebastian.reichel@collabora.co.uk>
-
- 01 5月, 2017 2 次提交
-
-
由 Arnd Bergmann 提交于
When CONFIG_IIO=m and the axp20x_usb_power driver is built-in, we get a link time error: drivers/power/built-in.o: In function `axp20x_usb_power_get_property': undefined reference to `iio_read_channel_processed' drivers/power/built-in.o: In function `axp20x_usb_power_probe': undefined reference to `devm_iio_channel_get' undefined reference to `devm_iio_channel_get' This adds the same dependency that we already have for the AC power driver to the USB power driver. For consistency, I'm also moving the two closer together in the Kconfig file. Fixes: 33863c93 ("power: supply: axp20x_usb_power: use IIO channels when available") Signed-off-by: NArnd Bergmann <arnd@arndb.de> Signed-off-by: NSebastian Reichel <sebastian.reichel@collabora.co.uk>
-
由 Quentin Schulz 提交于
The X-Powers AXP20X and AXP22X PMICs can have a battery as power supply. This patch adds the battery power supply driver to get various data from the PMIC, such as the battery status (charging, discharging, full, dead), current max limit, current current, battery capacity (in percentage), voltage max and min limits, current voltage and battery capacity (in Ah). This battery driver uses the AXP20X/AXP22X ADC driver as PMIC data provider. Signed-off-by: NQuentin Schulz <quentin.schulz@free-electrons.com> Acked-by: NJonathan Cameron <jic23@kernel.org> Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Acked-by: NChen-Yu Tsai <wens@csie.org> Signed-off-by: NSebastian Reichel <sebastian.reichel@collabora.co.uk>
-
- 14 4月, 2017 3 次提交
-
-
由 David Lechner 提交于
This adds a new driver for the LEGO MINDSTORMS EV3 battery. The EV3 is an embedded ARM device that can use 6 AA batteries or a special rechargeable Li-ion battery pack. The rechargeable battery pack presses a special key switch in the battery compartment to indicate that it is present. The EV3 is only capable of monitoring battery voltage and current. The charging circuit is built into the rechargeable battery pack and there is no way to communicate with is, so we can't provide any information about charging status. When not using the rechargeable battery pack, it is most common to use alkaline batteries to power the device, but it is also common for people to use rechargeable NiMH batteries. Since there is not a way to automatically differentiate between these, the technology property is made writable. Signed-off-by: NDavid Lechner <david@lechnology.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Tony Lindgren 提交于
The custom CPCAP PMIC used on Motorola phones such as Droid 4 has a USB battery charger. It can optionally also have a companion chip that is used for wireless charging. The charger on CPCAP also can feed VBUS for the USB host mode. This can be handled by the existing kernel phy_companion interface. Cc: devicetree@vger.kernel.org Cc: Marcel Partap <mpartap@gmx.net> Cc: Michael Scott <michael.scott@linaro.org> Signed-off-by: NTony Lindgren <tony@atomide.com> Acked-by: NRob Herring <robh@kernel.org> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Hans de Goede 提交于
Add support for monitoring an extcon device with USB SDP/CDP/DCP and HOST cables and adjust ilimit and enable/disable the 5V boost converter accordingly. This is necessary on systems where the PSEL pin is hardwired high and ILIM needs to be set by software based on the detected charger type, as well as on systems where the 5V boost converter is used, as that always needs to be enabled from software. Cc: Liam Breck <kernel@networkimprov.net> Cc: Tony Lindgren <tony@atomide.com> Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 30 1月, 2017 1 次提交
-
-
由 Quentin Schulz 提交于
The X-Powers AXP20X and AXP22X PMICs expose the status of AC power supply. Moreover, the AXP20X can also expose the current current and voltage values of the AC power supply. This adds the driver which exposes the status of the AC power supply of the AXP20X and AXP22X PMICs. Signed-off-by: NQuentin Schulz <quentin.schulz@free-electrons.com> Acked-by: NJonathan Cameron <jic23@kernel.org> Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com> [removed unused elements from struct axp20x_ac_power] Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 19 1月, 2017 1 次提交
-
-
由 Arnd Bergmann 提交于
The added regulator dependency in the smbb driver causes build errors when regulators are disabled, e.g. in randconfig build testing: drivers/power/supply/qcom_smbb.o: In function `smbb_chg_otg_is_enabled': qcom_smbb.c:(.text.smbb_chg_otg_is_enabled+0x18): undefined reference to `rdev_get_drvdata' drivers/power/supply/qcom_smbb.o: In function `smbb_charger_probe': qcom_smbb.c:(.text.smbb_charger_probe+0x410): undefined reference to `devm_regulator_register' This adds a Kconfig dependency to avoid the link error. Fixes: 61274eff ("power: supply: qcom_smbb: Add otg regulator for control of vbus") Signed-off-by: NArnd Bergmann <arnd@arndb.de> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 17 1月, 2017 1 次提交
-
-
由 Alexander Kurz 提交于
The MAX14656 USB charger detector, also known as "AL32" is used to detect the presence and capabilities of attached USB chargers. The device is attached via I2C plus one interrupt line to signalize events. The device can be found in LG smartphones like LS665 and LS770, compatible devices are present in 4th/5th generation Amazon Kindle readers referenced in source code packages as "Maxim AL32". The initial version of this driver has been extracted from LG source code package LGLS665_Android_Lollipop_LS665ZV3, enriched with information from the Kindle_src_4.1.3 source code package and adapted to the current power class sysfs interface. Non-Standard Apple chargers which the device may detect are mapped to the USB Battery Charging Specification Revision 1.2 class USB_DCP. Signed-off-by: NAlexander Kurz <akurz@blala.de> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 06 1月, 2017 1 次提交
-
-
由 Andy Shevchenko 提交于
The Moorestown support was removed by commit 1a8359e4 ("x86/mid: Remove Intel Moorestown"). Remove this leftover. Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 05 1月, 2017 1 次提交
-
-
由 Nicolas Saenz Julienne 提交于
This adds support for sbs-charger compilant chips as defined here: http://sbs-forum.org/specs/sbc110.pdf This was tested on a arm board connected to an LTC4100 battery charger chip. Signed-off-by: NNicolas Saenz Julienne <nicolas.saenz@prodys.net> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 11 8月, 2016 1 次提交
-
-
由 Sebastian Reichel 提交于
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: NSebastian Reichel <sre@kernel.org>
-
- 30 6月, 2016 1 次提交
-
-
由 Stephen Boyd 提交于
On these PMICs the usb cable connection/disconnection is indicated by the usb-valid interrupt being high or low respectively. Let's make an extcon for that, so we can notify usb drivers of the cable state. Cc: Bjorn Andersson <bjorn.andersson@linaro.org> Cc: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: NStephen Boyd <stephen.boyd@linaro.org> Reviewed-by: NChanwoo Choi <cw00.choi@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 21 6月, 2016 1 次提交
-
-
由 Felipe Balbi 提交于
instead of defining all functions as static inlines, let's move them to udc-core and export them with EXPORT_SYMBOL_GPL, that way we can make sure that only GPL drivers will use them. As a side effect, it'll be nicer to add tracepoints to the gadget API. While at that, also fix Kconfig dependencies to avoid randconfig build failures. Acked-By: NSebastian Reichel <sre@kernel.org> Acked-by: NPeter Chen <peter.chen@nxp.com> Signed-off-by: NFelipe Balbi <felipe.balbi@linux.intel.com>
-
- 25 2月, 2016 1 次提交
-
-
由 Wenyou Yang 提交于
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: NWenyou Yang <wenyou.yang@atmel.com> Reviewed-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com> [ add "|| COMPILE_TEST" to MFD_ACT8945A dependency ] Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 08 12月, 2015 1 次提交
-
-
由 Krzysztof Kozlowski 提交于
Currently the reset/power off handlers (POWER_RESET) and Adaptive Voltage Scaling class (POWER_AVS) are not built when POWER_SUPPLY is disabled. The POWER_RESET is also not visible in drivers main section of config. However they do not really depend on power supply so they can be built always. The objects for power supply drivers already depend on particular Kconfig symbols so there is no need for any changes in drivers/power/Makefile. This allows selecting POWER_RESET from main drivers config section and fixes following build warning (encountered on ARM exynos defconfig when POWER_SUPPLY is disabled manually): warning: (ARCH_HISI && ARCH_INTEGRATOR && ARCH_EXYNOS && ARCH_VEXPRESS && REALVIEW_DT) selects POWER_RESET which has unmet direct dependencies (POWER_SUPPLY) warning: (ARCH_EXYNOS) selects POWER_RESET_SYSCON which has unmet direct dependencies (POWER_SUPPLY && POWER_RESET && OF) warning: (ARCH_EXYNOS) selects POWER_RESET_SYSCON_POWEROFF which has unmet direct dependencies (POWER_SUPPLY && POWER_RESET && OF) Reported-by: NPavel Fedin <p.fedin@samsung.com> Signed-off-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 05 12月, 2015 1 次提交
-
-
由 Andrew F. Davis 提交于
Separate out I2C functionality into a module. This fixes several small issues and simplifies the driver initialization. Signed-off-by: NAndrew F. Davis <afd@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 19 10月, 2015 1 次提交
-
-
由 Andrew F. Davis 提交于
I2C is only required when using the config item BATTERY_BQ27XXX_I2C which already depends on the I2C subsystem, remove the unneeded dependency from BATTERY_BQ27XXX. Signed-off-by: NAndrew F. Davis <afd@ti.com> Acked-by: NPali Rohár <pali.rohar@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 16 10月, 2015 1 次提交
-
-
由 Sebastian Reichel 提交于
This driver fails to link without CONFIG_IIO, since there are no stubs for the iio_channels functions. Signed-off-by: NSebastian Reichel <sre@kernel.org> Acked-by: NMarek Belisko <marek@goldelico.com> Acked-by: NNikolaus Schaller <hns@goldelico.com>
-
- 13 10月, 2015 1 次提交
-
-
由 Adam Thomson 提交于
This adds power supply driver support for the Fuel-Gauge part of the DA9150 combined Charger and Fuel-Gauge device. Signed-off-by: NAdam Thomson <Adam.Thomson.Opensource@diasemi.com> Acked-by: NSebastian Reichel <sre@kernel.org> Signed-off-by: NLee Jones <lee.jones@linaro.org>
-
- 29 9月, 2015 1 次提交
-
-
由 Andreas Dannenberg 提交于
This patch adds basic support for bq24250 and bq24251 which are very similar to the bq24257 the driver was originally written for. Basic support means the ability to select a device through Kconfig, DT and ACPI, an instance variable allowing to check which chip is active, and the reporting back of the selected device through the model_name power supply sysfs property. This patch by itself is not sufficient to actually use those two added devices in a real-world setting due to some feature differences which are addressed by other patches in this series. Signed-off-by: NAndreas Dannenberg <dannenberg@ti.com> Reviewed-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 25 9月, 2015 1 次提交
-
-
由 Enric Balletbo i Serra 提交于
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: NEnric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 23 9月, 2015 1 次提交
-
-
由 Andrew F. Davis 提交于
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: NAndrew F. Davis <afd@ti.com> Acked-by: NTony Lindgren <tony@atomide.com> Acked-by: NGUAN Xuetao <gxt@mprc.pku.edu.cn> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 22 9月, 2015 2 次提交
-
-
由 Courtney Cavin 提交于
Add the Qualcomm Switch-Mode Battery Charger and Boost driver, found in pm8941. Signed-off-by: NCourtney Cavin <courtney.cavin@sonymobile.com> Signed-off-by: NBjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Hans de Goede 提交于
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: NLee Jones <lee.jones@linaro.org> Signed-off-by: NBruno Prémont <bonbons@linux-vserver.org> Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 05 8月, 2015 1 次提交
-
-
由 Geert Uytterhoeven 提交于
The GPIO subsystem provides dummy GPIO consumer functions if GPIOLIB is not enabled. Hence drivers that depend on GPIOLIB, but use GPIO consumer functionality only, can still be compiled if GPIOLIB is not enabled. Relax the dependency on GPIOLIB if COMPILE_TEST is enabled, where appropriate. Signed-off-by: NGeert Uytterhoeven <geert@linux-m68k.org> Acked-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 30 5月, 2015 1 次提交
-
-
由 Anda-Maria Nicolae 提交于
Based on the datasheet found here: http://www.richtek.com/download_ds.jsp?p=RT9455Signed-off-by: NAnda-Maria Nicolae <anda-maria.nicolae@intel.com> Reviewed-by: NKrzysztof Kozlowski <k.kozlowski.k@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 24 5月, 2015 3 次提交
-
-
由 Ramakrishna Pallala 提交于
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: NRamakrishna Pallala <ramakrishna.pallala@intel.com> Acked-by: NLee Jones <lee.jones@linaro.org> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Laurentiu Palcu 提交于
More details about the chip can be found here: http://www.ti.com/product/bq25890Signed-off-by: NLaurentiu Palcu <laurentiu.palcu@intel.com> Reviewed-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Laurentiu Palcu 提交于
Based on the datasheet found here: http://www.ti.com/lit/ds/symlink/bq24257.pdfSigned-off-by: NLaurentiu Palcu <laurentiu.palcu@intel.com> Reviewed-by: NKrzysztof Kozlowski <k.kozlowski.k@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 08 3月, 2015 1 次提交
-
-
由 Todd Brandt 提交于
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: NTodd Brandt <todd.e.brandt@linux.intel.com> Acked-by: NJacob Pan <jacob.jun.pan@linux.intel.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 26 2月, 2015 1 次提交
-
-
由 Adam Thomson 提交于
This patch adds support for DA9150 Charger & Fuel-Gauge IC Charger. Signed-off-by: NAdam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 22 1月, 2015 3 次提交
-
-
由 Mike Looijmans 提交于
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: NMike Looijmans <mike.looijmans@topic.nl> [ removed .owner field ] Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Jonghwa Lee 提交于
To guerantee proper charing and managing batteries even in suspend, charger-manager has used rtc device with rtc framework interface. However, it is better to use alarmtimer for cleaner and more appropriate operation. This patch makes driver to use alarmtimer for polling work in suspend and removes all deprecated codes related with using rtc interface. Signed-off-by: NJonghwa Lee <jonghwa3.lee@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Karol Wrona 提交于
This is only a small clean-up. The driver can be built without SYSFS as there exist stubs for used functions. Signed-off-by: NKarol Wrona <k.wrona@samsung.com> Reviewed-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 20 1月, 2015 2 次提交
-
-
由 Krzysztof Kozlowski 提交于
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: NKrzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Beomho Seo 提交于
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: NBeomho Seo <beomho.seo@samsung.com> Acked-by: NChanwoo Choi <cw00.choi@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 25 9月, 2014 1 次提交
-
-
由 Krzysztof Kozlowski 提交于
Make the max14577 charger driver depending on SYSFS instead selecting it. This fixes warning on x86_64 with allmodconfig: scripts/kconfig/conf --allmodconfig Kconfig fs/sysfs/Kconfig:1:error: recursive dependency detected! fs/sysfs/Kconfig:1: symbol SYSFS is selected by CHARGER_MAX14577 drivers/power/Kconfig:327: symbol CHARGER_MAX14577 depends on POWER_SUPPLY drivers/power/Kconfig:1: symbol POWER_SUPPLY is selected by HID_SONY drivers/hid/Kconfig:638: symbol HID_SONY depends on NEW_LEDS drivers/leds/Kconfig:8: symbol NEW_LEDS is selected by SENSORS_APPLESMC drivers/hwmon/Kconfig:299: symbol SENSORS_APPLESMC depends on HWMON drivers/hwmon/Kconfig:5: symbol HWMON is selected by EEEPC_LAPTOP drivers/platform/x86/Kconfig:496: symbol EEEPC_LAPTOP depends on HOTPLUG_PCI drivers/pci/hotplug/Kconfig:5: symbol HOTPLUG_PCI depends on SYSFS Signed-off-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com> Reported-by: NStephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-