power: supply: rt5033_charger: Simplify initialization of rt5033_charger_data
authorJakob Hauser <jahau@rocketmail.com>
Sun, 1 Oct 2023 13:17:43 +0000 (15:17 +0200)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Wed, 4 Oct 2023 20:27:34 +0000 (22:27 +0200)
commit1c6877f1768a34c04e3a82f9f950f78488a1753b
treedf0274cc622955f67f41097109944c85efe722fe
parent8242336dc8a8009b93fb7c4506d79a8c894b3583
power: supply: rt5033_charger: Simplify initialization of rt5033_charger_data

Currently the struct "rt5033_charger_data" is initialized rather complicated.
The cause lies inside of the struct "rt5033_charger", where struct
"rt5033_charger_data" is implemented as a pointer *chg.

Therefore, inside of struct "rt5033_charger" change the struct
"rt5033_charger_data" to non-pointer "chg". It is then initialized right
away and can be accessed more easily.

Signed-off-by: Jakob Hauser <jahau@rocketmail.com>
Link: https://lore.kernel.org/r/0aff8c2a18cf4b88ec3333f6679a8419dd76ca29.1696165240.git.jahau@rocketmail.com
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/rt5033_charger.c