[PATCH v2] z2-battery: Fix count of properties
Marek Vasut
marek.vasut at gmail.com
Fri Mar 11 16:36:14 EST 2011
On Friday 11 March 2011 14:09:32 Vasily Khoruzhick wrote:
> PROP_STATUS property was not counted, as result
> VOLTAGE_MIN property is missing in sysfs. Fix it.
>
> Signed-off-by: Vasily Khoruzhick <anarsoul at gmail.com>
You can have my:
Acked-by: Marek Vasut <marek.vasut at gmail.com>
on this one.
> ---
> v2: Align comment properly
>
> drivers/power/z2_battery.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/power/z2_battery.c b/drivers/power/z2_battery.c
> index 81304c0..2a9ab89 100644
> --- a/drivers/power/z2_battery.c
> +++ b/drivers/power/z2_battery.c
> @@ -134,6 +134,8 @@ static int z2_batt_ps_init(struct z2_charger *charger,
> int props) enum power_supply_property *prop;
> struct z2_battery_info *info = charger->info;
>
> + if (info->charge_gpio >= 0)
> + props++; /* POWER_SUPPLY_PROP_STATUS */
> if (info->batt_tech >= 0)
> props++; /* POWER_SUPPLY_PROP_TECHNOLOGY */
> if (info->batt_I2C_reg >= 0)
More information about the linux-arm-kernel
mailing list