aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/power
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/power')
-rw-r--r--drivers/power/power_supply_sysfs.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/power/power_supply_sysfs.c b/drivers/power/power_supply_sysfs.c
index 08144393d64b..c790e0c77d4b 100644
--- a/drivers/power/power_supply_sysfs.c
+++ b/drivers/power/power_supply_sysfs.c
@@ -65,7 +65,10 @@ static ssize_t power_supply_show_property(struct device *dev,
65 ret = psy->get_property(psy, off, &value); 65 ret = psy->get_property(psy, off, &value);
66 66
67 if (ret < 0) { 67 if (ret < 0) {
68 if (ret != -ENODEV) 68 if (ret == -ENODATA)
69 dev_dbg(dev, "driver has no data for `%s' property\n",
70 attr->attr.name);
71 else if (ret != -ENODEV)
69 dev_err(dev, "driver failed to report `%s' property\n", 72 dev_err(dev, "driver failed to report `%s' property\n",
70 attr->attr.name); 73 attr->attr.name);
71 return ret; 74 return ret;