aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Brown <broonie@linaro.org>2013-08-18 12:35:52 -0400
committerMark Brown <broonie@linaro.org>2013-08-19 05:47:15 -0400
commit9e059bacecf1c46c1784cb6f6826f85629b4a1be (patch)
treeb81aac3ab2d0fead5797dc8d499c4ae8a2731053
parent7d748971c0c04122cc7a06bc0573e27e106efe6a (diff)
hwmon: (sht15) Use devm_regulator_get_optional()
Since the sht15 driver supports operation without an external vref regulator the driver should use the new devm_regulator_get_optional() to indicate that a stub regulator should not be provided. Signed-off-by: Mark Brown <broonie@linaro.org> Acked-by: Guenter Roeck <linux@roeck-us.net>
-rw-r--r--drivers/hwmon/sht15.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/sht15.c b/drivers/hwmon/sht15.c
index 2507f902fb7a..ab5dc3af4cfb 100644
--- a/drivers/hwmon/sht15.c
+++ b/drivers/hwmon/sht15.c
@@ -957,7 +957,7 @@ static int sht15_probe(struct platform_device *pdev)
957 * If a regulator is available, 957 * If a regulator is available,
958 * query what the supply voltage actually is! 958 * query what the supply voltage actually is!
959 */ 959 */
960 data->reg = devm_regulator_get(data->dev, "vcc"); 960 data->reg = devm_regulator_get_optional(data->dev, "vcc");
961 if (!IS_ERR(data->reg)) { 961 if (!IS_ERR(data->reg)) {
962 int voltage; 962 int voltage;
963 963