Commit be6299c6 authored by Thomas Weißschuh's avatar Thomas Weißschuh Committed by Sebastian Reichel
Browse files

power: supply: sysfs: use power_supply_property_is_writeable()

parent 29832ada
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -379,8 +379,7 @@ static umode_t power_supply_attr_is_visible(struct kobject *kobj,
		int property = psy->desc->properties[i];

		if (property == attrno) {
			if (psy->desc->property_is_writeable &&
			    psy->desc->property_is_writeable(psy, property) > 0)
			if (power_supply_property_is_writeable(psy, property) > 0)
				mode |= S_IWUSR;

			return mode;