aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/regulator/pv88090-regulator.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2019-05-03regulator: pv880x0: Switch to SPDX identifierAxel Lin1-14/+4
Convert Powerventure Semiconductor PV88060/PV88080/PV88090 regulator drivers to SPDX identifier. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-03-13regulator: pv88090: Fix notifier mutex lock warningSteve Twiss1-0/+4
The mutex for the regulator_dev must be controlled by the caller of the regulator_notifier_call_chain(), as described in the comment for that function. Failure to mutex lock and unlock surrounding the notifier call results in a kernel WARN_ON_ONCE() which will dump a backtrace for the regulator_notifier_call_chain() when that function call is first made. The mutex can be controlled using the regulator_lock/unlock() API. Fixes: c90456e36d9c ("regulator: pv88090: new regulator driver") Suggested-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Steve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2019-03-04regulator: pv88090: Convert to use regulator_set/get_current_limit_regmapAxel Lin1-45/+8
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Steve Twiss <stwiss.opensource@diasemi.com>; Signed-off-by: Mark Brown <broonie@kernel.org>
2019-02-19regulator: pv88090: Fix array out-of-bounds accessAxel Lin1-1/+1
Fix off-by-one while iterating current_limits array. The valid index should be 0 ~ n_current_limits -1. Fixes: c90456e36d9c ("regulator: pv88090: new regulator driver") Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-08-30regulator: pv88090: Exception handling for out of boundsEric Jeong1-3/+8
This is a patch for exception handlding that the index of array is out of bounds. And the definitions have been updated to use proper device name. Signed-off-by: Eric Jeong <eric.jeong.opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-01-31regulator: pv88090-regulator: constify regulator_ops structureBhumika Goyal1-2/+2
Declare regulator_ops structure as const as it is only stored in the ops field of a regulator_desc structure. This field is of type const, so regulator_ops structures having this property can be made const too. File size before: drivers/regulator/pv88090-regulator.o text data bss dec hex filename 2829 2032 8 4869 1305 regulator/pv88090-regulator.o File size after: drivers/regulator/pv88090-regulator.o text data bss dec hex filename 3341 1520 8 4869 1305 regulator/pv88090-regulator.o Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-05-30regulator: pv880x0: Clean up unnecessary header inclusionAxel Lin1-3/+0
Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-03-07regulator: pv88090: fix incorrect clear of event registerJames Ban1-4/+4
This is a patch to fix incorrect clear of event register. Signed-off-by: James Ban <James.Ban.opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2015-12-12regulator: pv88090: logical vs bitwise AND typoDan Carpenter1-5/+5
These were supposed to be bitwise AND instead of logical. Also kernel style is for the operator to be on the first line and I removed some extra parenthesis. Fixes: c90456e36d9c ('regulator: pv88090: new regulator driver') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2015-12-12regulator: pv88090: Fix irq leakAxel Lin1-1/+1
Use devm_request_threaded_irq to ensure the irq is freed when unload the module. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2015-12-08regulator: pv88090: new regulator driverJames Ban1-0/+458
This is the driver for the Powerventure PV88090 BUCKs and LDOs regulator. It communicates via an I2C bus to the device. Signed-off-by: James Ban <James.Ban.opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org>