regulator: Add regulator_bulk_set_voltage
Add a convenience API to set the voltage on multiple consumers stored in a struct regulator_bulk_data[] in one API call. Change-Id: Iaeb5ba8c357a66f1401fb1e142bb03904e8e9c7c Signed-off-by: Justin Paupore <jpaupore@codeaurora.org>
This commit is contained in:
committed by
Stephen Boyd
parent
2a76454f05
commit
2c76b8832b
@@ -117,6 +117,10 @@ struct regulator;
|
||||
* using the bulk regulator APIs.
|
||||
* @consumer: The regulator consumer for the supply. This will be managed
|
||||
* by the bulk API.
|
||||
* @min_uV: The minimum requested voltage for the regulator (in microvolts),
|
||||
* or 0 to not set a voltage.
|
||||
* @max_uV: The maximum requested voltage for the regulator (in microvolts),
|
||||
* or 0 to use @min_uV.
|
||||
*
|
||||
* The regulator APIs provide a series of regulator_bulk_() API calls as
|
||||
* a convenience to consumers which require multiple supplies. This
|
||||
@@ -125,6 +129,8 @@ struct regulator;
|
||||
struct regulator_bulk_data {
|
||||
const char *supply;
|
||||
struct regulator *consumer;
|
||||
int min_uV;
|
||||
int max_uV;
|
||||
|
||||
/* private: Internal use */
|
||||
int ret;
|
||||
@@ -155,6 +161,8 @@ int devm_regulator_bulk_get(struct device *dev, int num_consumers,
|
||||
struct regulator_bulk_data *consumers);
|
||||
int regulator_bulk_enable(int num_consumers,
|
||||
struct regulator_bulk_data *consumers);
|
||||
int regulator_bulk_set_voltage(int num_consumers,
|
||||
struct regulator_bulk_data *consumers);
|
||||
int regulator_bulk_disable(int num_consumers,
|
||||
struct regulator_bulk_data *consumers);
|
||||
int regulator_bulk_force_disable(int num_consumers,
|
||||
|
||||
Reference in New Issue
Block a user