Commit 32fe18d0 authored by Hans de Goede's avatar Hans de Goede Committed by Sebastian Reichel

power: supply: twl4030_madc_battery: Refactor twl4030_madc_bat_ext_changed()

twl4030_madc_bat_ext_changed() is a wrapper around
"power_supply_changed(psy);" and it has the same prototype.

Remove it, replacing it with making the external_power_changed
callback directly point to power_supply_changed.
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarSebastian Reichel <sebastian.reichel@collabora.com>
parent 1269774a
......@@ -168,19 +168,13 @@ static int twl4030_madc_bat_get_property(struct power_supply *psy,
return 0;
}
static void twl4030_madc_bat_ext_changed(struct power_supply *psy)
{
power_supply_changed(psy);
}
static const struct power_supply_desc twl4030_madc_bat_desc = {
.name = "twl4030_battery",
.type = POWER_SUPPLY_TYPE_BATTERY,
.properties = twl4030_madc_bat_props,
.num_properties = ARRAY_SIZE(twl4030_madc_bat_props),
.get_property = twl4030_madc_bat_get_property,
.external_power_changed = twl4030_madc_bat_ext_changed,
.external_power_changed = power_supply_changed,
};
static int twl4030_cmp(const void *a, const void *b)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment