summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/hwmon/ibmpowernv.c4
-rw-r--r--drivers/hwmon/pwm-fan.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/drivers/hwmon/ibmpowernv.c b/drivers/hwmon/ibmpowernv.c
index 8e3724728cce..594254d6a72d 100644
--- a/drivers/hwmon/ibmpowernv.c
+++ b/drivers/hwmon/ibmpowernv.c
@@ -456,9 +456,9 @@ static int populate_attr_groups(struct platform_device *pdev)
*/
if (!of_property_read_string(np, "label", &label))
sensor_groups[type].attr_count++;
- if (of_find_property(np, "sensor-data-min", NULL))
+ if (of_property_present(np, "sensor-data-min"))
sensor_groups[type].attr_count++;
- if (of_find_property(np, "sensor-data-max", NULL))
+ if (of_property_present(np, "sensor-data-max"))
sensor_groups[type].attr_count++;
}
diff --git a/drivers/hwmon/pwm-fan.c b/drivers/hwmon/pwm-fan.c
index 83a347ca35da..57928d270015 100644
--- a/drivers/hwmon/pwm-fan.c
+++ b/drivers/hwmon/pwm-fan.c
@@ -427,7 +427,7 @@ static int pwm_fan_of_get_cooling_data(struct device *dev,
struct device_node *np = dev->of_node;
int num, i, ret;
- if (!of_find_property(np, "cooling-levels", NULL))
+ if (!of_property_present(np, "cooling-levels"))
return 0;
ret = of_property_count_u32_elems(np, "cooling-levels");