diff options
Diffstat (limited to 'drivers/hwmon/sht15.c')
-rw-r--r-- | drivers/hwmon/sht15.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/hwmon/sht15.c b/drivers/hwmon/sht15.c index 9594cdb1cd0f..bbfa1e3a9f9c 100644 --- a/drivers/hwmon/sht15.c +++ b/drivers/hwmon/sht15.c @@ -926,7 +926,13 @@ static int __devinit sht15_probe(struct platform_device *pdev) if (voltage) data->supply_uV = voltage; - regulator_enable(data->reg); + ret = regulator_enable(data->reg); + if (ret != 0) { + dev_err(&pdev->dev, + "failed to enable regulator: %d\n", ret); + return ret; + } + /* * Setup a notifier block to update this if another device * causes the voltage to change |