Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 648badd7 authored by Quentin Schulz's avatar Quentin Schulz Committed by Sebastian Reichel
Browse files

power: supply: axp20x_battery: use data struct for variant specific code



We used to use IDs to select a function or a feature depending on the
variant. It's easier to maintain the code by adding data structure
storing the few differences between variants so that we don't add a pile
of if conditions.

Let's use this data structure and update the code to use it.

Signed-off-by: default avatarQuentin Schulz <quentin.schulz@bootlin.com>
Reviewed-by: default avatarChen-Yu Tsai <wens@csie.org>
[updated POWER_SUPPLY_PROP_VOLTAGE_MAX_DESIGN write property to use
the introduced set_max_voltage() callback]
Signed-off-by: default avatarSebastian Reichel <sebastian.reichel@collabora.co.uk>
parent d47c1e4b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment