summaryrefslogtreecommitdiffstats
path: root/drivers/power/supply/max8997_charger.c
Commit message (Collapse)AuthorAgeFilesLines
* power: supply: max8997_charger: Using device managed API and remove OOM printSrikant Ritolia2017-01-041-13/+2Star
| | | | | | | | | | | | | Use managed resource function devm_power_supply_register instead of power_supply_register to simplify the error path by allowing unregistering to happen automatically on error and remove. Removing max8997_battery_remove function also as it is now redundant. Also removing out of memory printk message after kzalloc as there is already enough information on failure. Signed-off-by: Srikant Ritolia <s.ritolia@samsung.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
* power: supply: max8997_charger: Fix module autoloadJavier Martinez Canillas2016-10-191-0/+1
| | | | | | | | | | | | | | | | | | | | | If the driver is built as a module, autoload won't work because the module alias information is not filled. So user-space can't match the registered device with the corresponding module. Export the module alias information using the MODULE_DEVICE_TABLE() macro. Before this patch: $ modinfo drivers/power/supply/max8997_charger.ko | grep alias $ After this patch: $ modinfo drivers/power/supply/max8997_charger.ko | grep alias alias: platform:max8997-battery Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Sebastian Reichel <sre@kernel.org>
* power: move power supply drivers to power/supplySebastian Reichel2016-08-111-0/+211
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>