]> git.baikalelectronics.ru Git - kernel.git/commit
Input: mms114 - Fix regulator enable and disable paths
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 4 Mar 2013 04:21:30 +0000 (20:21 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Mon, 11 Mar 2013 01:34:07 +0000 (18:34 -0700)
commit61e7b1becfbd507bf95918069f0ebf4a7f49894f
tree68ed54427b3ee2db2b95a3d1a7ff25d55e0fdc61
parentaeb77a4690a15079715043e146982659456f1eb2
Input: mms114 - Fix regulator enable and disable paths

When it uses regulators the mms114 driver checks to see if it managed to
acquire regulators and ignores errors. This is not the intended usage and
not great style in general.

Since the driver already refuses to probe if it fails to allocate the
regulators simply make the enable and disable calls unconditional and
add appropriate error handling, including adding cleanup of the
regulators if setup_reg() fails.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/touchscreen/mms114.c