]> git.baikalelectronics.ru Git - kernel.git/commit
mfd: ab8500-gpadc: Complain if we fail to enable vtvout LDO
authorAxel Lin <axel.lin@ingics.com>
Sat, 9 Mar 2013 09:46:45 +0000 (17:46 +0800)
committerSamuel Ortiz <sameo@linux.intel.com>
Tue, 12 Mar 2013 08:34:39 +0000 (09:34 +0100)
commitc663ee5bd2cce6c274fbae893bd74c85f7d09928
treeff0b6d1bbc7d1f88a2f33cf9909f392ba32b0a93
parentd9cef5ddc9ac86ae6a56b61ec0672350c47b0dac
mfd: ab8500-gpadc: Complain if we fail to enable vtvout LDO

Since commit c8801a8e
"regulator: core: Mark all get and enable calls as __must_check",
we must check return value of regulator_enable() to silence below build warning.

  CC      drivers/mfd/ab8500-gpadc.o
drivers/mfd/ab8500-gpadc.c: In function 'ab8500_gpadc_runtime_resume':
drivers/mfd/ab8500-gpadc.c:598:18: warning: ignoring return value of 'regulator_enable', declared with attribute warn_unused_result [-Wunused-result]
drivers/mfd/ab8500-gpadc.c: In function 'ab8500_gpadc_probe':
drivers/mfd/ab8500-gpadc.c:655:18: warning: ignoring return value of 'regulator_enable', declared with attribute warn_unused_result [-Wunused-result]

Also convert to devm_regulator_get(), this fixes a missing regulator_put() call
in ab8500_gpadc_remove().

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
drivers/mfd/ab8500-gpadc.c