Re: [PATCH v12 6/7] power: supply: Add driver for ASUS Transformer battery
From: Markus Elfring
Date: Tue Oct 20 2026 - 10:14:08 EST
…
> +++ b/drivers/power/supply/asus-transformer-ec-battery.c
> @@ -0,0 +1,289 @@
…
> +static const unsigned int asus_ec_battery_prop_offs[] = {
> + [POWER_SUPPLY_PROP_STATUS] = 1,
…
> +};
> +
> +static int asus_ec_battery_get_value(struct asus_ec_battery_data *priv,
> + enum power_supply_property psp)
> +{
> + int ret, offs;
> +
> + guard(mutex)(&priv->battery_lock);
> +
> + if (psp >= ARRAY_SIZE(asus_ec_battery_prop_offs))
> + return -EINVAL;
> +
> + offs = asus_ec_battery_prop_offs[psp];
…
What did hinder to make such data type specifications really consistent?
https://lore.kernel.org/linux-pm/9ac1d196-0e4c-4592-812f-c44c56e135b3@xxxxxx/
Regards,
Markus