- 29 9月, 2015 4 次提交
-
-
由 Andreas Dannenberg 提交于
Use the devm_* managed version of the function to register the power supply and remove the associated unregister function. This will simplify error handling moving forward as it allows the unregister to happen automatically. It also saves a few lines of code. As this changes the order of putting the bq24257 into reset vs. unregistering the power-supply during driver remove re-tested various driver unload scenario to make sure that this doesn't cause any unintended side effects such as erroneous interrupts. Signed-off-by: NAndreas Dannenberg <dannenberg@ti.com> Reviewed-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Andreas Dannenberg 提交于
The maximum amount of input current the charger should draw is dependent on the power supply and should only be (re-)configured when the power supply gets connected and disconnected. However the driver was also lowering the bq24257's input current limit setting to 500mA when the battery was removed and restored the previous setting according to the power supply capabilities when the battery was reconnected although these events are not impacting the amount of power that can be drawn from the supply. Furthermore, a re-configuration of the input current limit to 500mA when the battery gets disconnected is actually dangerous if the limit was set higher previously and the system draws more than 500mA in which case the system voltage would be reduced in order to maintain 500mA which could result in the system getting too low of a supply to maintain operation. Last but not least the mechanism itself used for battery re-connection detection did not work in corner cases such as when the device's input current loop becomes active and the bq24257 device clears its battery fault error resulting in incorrectly reporting that the battery got reconnected. This patches removes the impact the battery removal/insertion has on the input current limit configured for the bq24257 and simplifies the associated handler routine. Signed-off-by: NAndreas Dannenberg <dannenberg@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Andreas Dannenberg 提交于
At the time the driver was written GpioInt resources in ACPI were not passed to the driver in client->irq, as opposed to DT enumeration. To accommodate this use case, a "stat-gpios" property was introduced to allow configuring the IRQ. However this issue with ACPI was fixed in commit "845c8770 i2c / ACPI: Assign IRQ for devices that have GpioInt automatically" and makes this workaround no longer necessary, hence we can remove the support for the "stat-gpios" property and the associated code from the bq24257 driver. Signed-off-by: NAndreas Dannenberg <dannenberg@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Andrzej Hajda 提交于
We need flags to be signed for the error handling to work. The problem has been detected using proposed semantic patch scripts/coccinelle/tests/unsigned_lesser_than_zero.cocci [1]. [1]: http://permalink.gmane.org/gmane.linux.kernel/2038576 Fixes: 74aab849 ('power: bq27xxx_battery: Cleanup health checking') Signed-off-by: NAndrzej Hajda <a.hajda@samsung.com> Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com> Acked-By: NPali Rohár <pali.rohar@gmail.com> Acked-by: NAndrew F. Davis <afd@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 27 9月, 2015 3 次提交
-
-
由 Marek Belisko 提交于
If either twl4030_charger or twl4030_madc is configured as MODULE, we get build (link) errors. To solve, the direct call of twl4030_get_madc_conversion() is replaced by a call to iio_read_channel_processed(). Signed-off-by: NH. Nikolaus Schaller <hns@goldelico.com> Signed-off-by: NMarek Belisko <marek@goldelico.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Marek Belisko 提交于
Added new iio properties which are required for twl4030-charger driver and allow to use twl4030-madc indirectly. Signed-off-by: NMarek Belisko <marek@goldelico.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Valentin Rothberg 提交于
Since commit 1c6c6952 ("genirq: Reject bogus threaded irq requests") threaded IRQs without a primary handler need to be requested with IRQF_ONESHOT, otherwise the request will fail. scripts/coccinelle/misc/irqf_oneshot.cocci detected this issue. Fixes: b5874f33 ("wm831x_power: Use genirq") Signed-off-by: NValentin Rothberg <valentinrothberg@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 25 9月, 2015 3 次提交
-
-
由 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>
-
由 Enric Balletbo i Serra 提交于
The TPS65217 charger is a subnode of the TPS65217 MFD. Signed-off-by: NEnric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Dan Carpenter 提交于
"state" is a bool so it's never less than zero. The intent was to test "ret" instead. Fixes: 56d7df87 ('power: Add Qualcomm SMBB driver') Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 24 9月, 2015 1 次提交
-
-
由 Pali Rohár 提交于
Commit b68c3161 (bq2415x_charger: Allow to load and use driver even if notify device is not registered yet) introduced null pointer dereference in case bq is NULL. This patch fixes it. Fixes: b68c3161 ("bq2415x_charger: Allow to load and use driver even if notify device is not registered yet") Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NPali Rohár <pali.rohar@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 23 9月, 2015 6 次提交
-
-
由 Andrew F. Davis 提交于
Some devices have a pin that can generate an interrupt when the battery's status changes. Add an interrupt handler to read the new battery status. Signed-off-by: NAndrew F. Davis <afd@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Andrew F. Davis 提交于
Reorganize the logic checking battery health and add under temperature condition checking. 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>
-
由 Andrew F. Davis 提交于
Add support for additional devices and register equivalent family devices including the bq27010, bq27210, bq27500, bq27510, bq27520, bq27530, bq27531, bq27541, bq27542, bq27546, bq27545, bq27441, bq27421, and the bq27641. To facilitate this process the register mapings have been moved to tables and other small cleanups have been made. Signed-off-by: NAndrew F. Davis <afd@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Andrew F. Davis 提交于
Fix typos and change "relative state of charge" to "state of charge" as not all supported devices use relative state of charge. 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>
-
由 Andrew F. Davis 提交于
When initialized as a platform device the initializer must now specify a device. An empty device name is no longer valid. Signed-off-by: NAndrew F. Davis <afd@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 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 21 次提交
-
-
由 Andrew F. Davis 提交于
The MODULE_DEVICE_TABLE macro automatically adds all needed i2c MODULE_ALIASes so remove the extra MODULE_ALIAS. 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>
-
由 Vaishali Thakkar 提交于
Use managed resource function devm_power_supply_register instead of power_supply_register to simplify the error path by allowing unregister to happen automatically on error. To be compatible with the change, replace various gotos by direct returns and remove unneeded label err. Also, remove max8998_battery_remove as it is now redundant. Signed-off-by: NVaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Marcel Ziswiler 提交于
By accident I stumbled over a few misspelled words in the charger-manager header file which this patch fixes. Namely: - Extcon rather than Exton - constraint rather than constratint - existence rather than existance - difference rather than diffential While at it also add a missing space before a closing comment star forward-slash. Signed-off-by: NMarcel Ziswiler <marcel@ziswiler.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Luis de Bethencourt 提交于
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: NLuis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Vaishali Thakkar 提交于
Use managed resource functions devm_request_threaded_irq and devm_power_supply_register to simplify error handling. To be compatible with the change, various gotos are replaced with direct returns and unneeded labels are dropped. Also, remove max8903_remove as it is now redundant. Signed-off-by: NVaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Vaishali Thakkar 提交于
Use managed resource functions devm_request_threaded_irq and devm_power_supply_register to simplify error handling. Also, remove max17042_remove as it is now redundant. Signed-off-by: NVaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Nicolas Ferre 提交于
This diver doesn't applies only on SAM9 SoC families but on SAMA5 families as well. Signed-off-by: NNicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Alexandre Belloni 提交于
Commit dca1a4b5 ("clk: at91: keep slow clk enabled to prevent system hang") added a workaround for the slow clock as it is not properly handled by its users. Get and use the slow clock as it is necessary for the at91 shutdown controller. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Alexandre Belloni 提交于
It was not possible to compile at91-poweroff as a module. Implement .remove() to allow it. Also switch to module_platform_driver_probe() as it is not hotpluggable. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Alexandre Belloni 提交于
Commit dca1a4b5 ("clk: at91: keep slow clk enabled to prevent system hang") added a workaround for the slow clock as it is not properly handled by its users. Get and use the slow clock as it is necessary for the at91 reset controller. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Alexandre Belloni 提交于
It was not possible to compile at91-reset as a module. Implement .remove() to allow it. Also switch to module_platform_driver_probe() as it is not hotpluggable. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Alexandre Belloni 提交于
Since all the at91 platforms are now DT only, at91_reset_platform_probe() is now useless, remove it. Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Vaishali Thakkar 提交于
Use managed resource functions devm_request_threaded_irq and devm_power_supply_register to simplify error handling. To be compatible with the change, various gotos are replaced with direct returns and unneeded labels are dropped. Also, remove pm860x_battery_remove as it is now redundant. Signed-off-by: NVaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 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>
-
由 Courtney Cavin 提交于
Add the Qualcomm Switch-Mode Battery Charger and Boost device tree binding. 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>
-
由 Javier Martinez Canillas 提交于
These drivers already have an I2C device id table that is used to create module aliases and the used MODULE_ALIAS() was either already in the I2C table so it was redundant or wasn't a valid I2C id so it was never used. Signed-off-by: NJavier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Milo Kim 提交于
According to lp8727 bindings[*], charging parameter is optional. So parsing can be skipped in case those properties are undefined. However, 'debounce-ms' should be read prior to checking the properties. Otherwise, 'debounce-ms' property will be ignored even it is configured inside the DT. So, counting child is processed after updating 'debounce-ms'. [*] Documentation/devicetree/bindings/power_supply/lp8727_charger.txt Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Cc: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: NMilo Kim <milo.kim@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Milo Kim 提交于
Currently, lp8727 charger driver parses the DT and copies values into the 'cl->dev.platform_data' if 'of_node' exists. This may have architectural issue. Platform data is configurable through the DT or I2C board info inside the platform area. However, lp8727 driver changes this configuration when it is loaded. The driver should get data from the platform side and use the private data, 'lp8727_chg->pdata' instead of changing the original platform data. _probe() procedure is changed as follows. 1. lp8727_parse_dt() returns the pointer of lp8727_platform_data. The driver uses this allocated platform data. So it should keep original platform data, 'dev->platform_data'. 2. In _probe(), check the return value of lp8727_parse_dt(). If an error is found, then exit as PTR_ERR(pdata). 3. If 'of_node' is not found, then the driver just gets the platform data from the I2C device structure. 4. Map the platform data to private data structure. Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Cc: linux-pm@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: NMilo Kim <milo.kim@ti.com> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
由 Mark Brown 提交于
Signed-off-by: NMark Brown <broonie@kernel.org> 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>
-
由 Hans de Goede 提交于
Add binding documentation for the usb power supply part of the AXP20x pmic. Signed-off-by: NHans de Goede <hdegoede@redhat.com> Acked-by: NRob Herring <robh@kernel.org> Signed-off-by: NSebastian Reichel <sre@kernel.org>
-
- 21 9月, 2015 1 次提交
-
-
由 Linus Torvalds 提交于
-
- 20 9月, 2015 1 次提交
-
-
git://ftp.arm.linux.org.uk/~rmk/linux-arm由 Linus Torvalds 提交于
Pull ARM fixes from Russell King: "Three fixes and a resulting cleanup for -rc2: - Andre Przywara reported that he was seeing a warning with the new cast inside DMA_ERROR_CODE's definition, and fixed the incorrect use. - Doug Anderson noticed that kgdb causes a "scheduling while atomic" bug. - OMAP5 folk noticed that their Thumb-2 compiled X servers crashed when enabling support to cover ARMv6 CPUs due to a kernel bug leaking some conditional context into the signal handler" * 'fixes' of git://ftp.arm.linux.org.uk/~rmk/linux-arm: ARM: 8425/1: kgdb: Don't try to stop the machine when setting breakpoints ARM: 8437/1: dma-mapping: fix build warning with new DMA_ERROR_CODE definition ARM: get rid of needless #if in signal handling code ARM: fix Thumb2 signal handling when ARMv6 is enabled
-