diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2023-09-20 12:33:07 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2023-09-20 14:32:23 +0200 |
commit | 28cfaed2e28e748e9f916fa848214cc0ef98699a (patch) | |
tree | 36d866c40edc3268876bdab3f98b0dda60e09f2d /include/regulator.h | |
parent | c28ffd5cd58880dc81a2eddf02c1b42e802c3068 (diff) | |
download | barebox-28cfaed2e28e748e9f916fa848214cc0ef98699a.tar.gz barebox-28cfaed2e28e748e9f916fa848214cc0ef98699a.tar.xz |
regulator: merge struct regulator_internal fields into struct regulator_dev
Each struct regulator_dev instance has a struct regulator_internal
associated with it. The idea was that core internal fields are seen
by the core only. In the end this is more confusing than helpful. We
have a ri->rdev link, but no rdev->ri link so that we can't get a
rdev from a ri pointer. We could add that link, but instead make the
whole stuff a bit easier by just merging everything from struct
regulator_internal to struct regulator_dev.
Reviewed-by: Marco Felsch <m.felsch@pengutronix.de>
Link: https://lore.barebox.org/20230920103316.2758383-3-s.hauer@pengutronix.de
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/regulator.h')
-rw-r--r-- | include/regulator.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/regulator.h b/include/regulator.h index b0a500434c..5eb236e602 100644 --- a/include/regulator.h +++ b/include/regulator.h @@ -85,6 +85,15 @@ struct regulator_desc { }; struct regulator_dev { + const char *name; + struct list_head list; + struct device_node *node; + int enable_count; + int enable_time_us; + int min_uv; + int max_uv; + const char *supply_name; + struct list_head consumer_list; const struct regulator_desc *desc; struct regmap *regmap; bool boot_on; |