mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-29 20:30:35 +00:00
![Zev Weiss](/assets/img/avatar_default.png)
In addition to adding some fairly simple OF support code, we make some slight adjustments to the userspace-consumer driver to properly support use with regulator-output hardware: - We now do an exclusive get of the supply regulators so as to prevent regulator_init_complete_work from automatically disabling them. - Instead of assuming that the supply is initially disabled, we now query its state to determine the initial value of drvdata->enabled. Signed-off-by: Zev Weiss <zev@bewilderbeest.net> Link: https://lore.kernel.org/r/20221031233704.22575-4-zev@bewilderbeest.net Signed-off-by: Mark Brown <broonie@kernel.org>
27 lines
696 B
C
27 lines
696 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef __REGULATOR_PLATFORM_CONSUMER_H_
|
|
#define __REGULATOR_PLATFORM_CONSUMER_H_
|
|
|
|
struct regulator_consumer_supply;
|
|
|
|
/**
|
|
* struct regulator_userspace_consumer_data - line consumer
|
|
* initialisation data.
|
|
*
|
|
* @name: Name for the consumer line
|
|
* @num_supplies: Number of supplies feeding the line
|
|
* @supplies: Supplies configuration.
|
|
* @init_on: Set if the regulators supplying the line should be
|
|
* enabled during initialisation
|
|
*/
|
|
struct regulator_userspace_consumer_data {
|
|
const char *name;
|
|
|
|
int num_supplies;
|
|
struct regulator_bulk_data *supplies;
|
|
|
|
bool init_on;
|
|
bool no_autoswitch;
|
|
};
|
|
|
|
#endif /* __REGULATOR_PLATFORM_CONSUMER_H_ */
|