diff options
| -rw-r--r-- | drivers/regulator/fixed-helper.c | 5 | ||||
| -rw-r--r-- | include/linux/regulator/fixed.h | 6 |
2 files changed, 6 insertions, 5 deletions
diff --git a/drivers/regulator/fixed-helper.c b/drivers/regulator/fixed-helper.c index 3aa268dfdb1d..f9d027992aae 100644 --- a/drivers/regulator/fixed-helper.c +++ b/drivers/regulator/fixed-helper.c | |||
| @@ -24,9 +24,10 @@ static void regulator_fixed_release(struct device *dev) | |||
| 24 | * @name: name to be used for the regulator | 24 | * @name: name to be used for the regulator |
| 25 | * @supplies: consumers for this regulator | 25 | * @supplies: consumers for this regulator |
| 26 | * @num_supplies: number of consumers | 26 | * @num_supplies: number of consumers |
| 27 | * @uv: voltage in microvolts | ||
| 27 | */ | 28 | */ |
| 28 | struct platform_device *regulator_register_always_on(int id, const char *name, | 29 | struct platform_device *regulator_register_always_on(int id, const char *name, |
| 29 | struct regulator_consumer_supply *supplies, int num_supplies) | 30 | struct regulator_consumer_supply *supplies, int num_supplies, int uv) |
| 30 | { | 31 | { |
| 31 | struct fixed_regulator_data *data; | 32 | struct fixed_regulator_data *data; |
| 32 | 33 | ||
| @@ -40,7 +41,7 @@ struct platform_device *regulator_register_always_on(int id, const char *name, | |||
| 40 | return NULL; | 41 | return NULL; |
| 41 | } | 42 | } |
| 42 | 43 | ||
| 43 | data->cfg.microvolts = 0; | 44 | data->cfg.microvolts = uv; |
| 44 | data->cfg.gpio = -EINVAL; | 45 | data->cfg.gpio = -EINVAL; |
| 45 | data->cfg.enabled_at_boot = 1; | 46 | data->cfg.enabled_at_boot = 1; |
| 46 | data->cfg.init_data = &data->init_data; | 47 | data->cfg.init_data = &data->init_data; |
diff --git a/include/linux/regulator/fixed.h b/include/linux/regulator/fixed.h index 6b9325b5e371..680f24e08af2 100644 --- a/include/linux/regulator/fixed.h +++ b/include/linux/regulator/fixed.h | |||
| @@ -59,16 +59,16 @@ struct regulator_consumer_supply; | |||
| 59 | 59 | ||
| 60 | #if IS_ENABLED(CONFIG_REGULATOR) | 60 | #if IS_ENABLED(CONFIG_REGULATOR) |
| 61 | struct platform_device *regulator_register_always_on(int id, const char *name, | 61 | struct platform_device *regulator_register_always_on(int id, const char *name, |
| 62 | struct regulator_consumer_supply *supplies, int num_supplies); | 62 | struct regulator_consumer_supply *supplies, int num_supplies, int uv); |
| 63 | #else | 63 | #else |
| 64 | static inline struct platform_device *regulator_register_always_on(int id, const char *name, | 64 | static inline struct platform_device *regulator_register_always_on(int id, const char *name, |
| 65 | struct regulator_consumer_supply *supplies, int num_supplies) | 65 | struct regulator_consumer_supply *supplies, int num_supplies, int uv) |
| 66 | { | 66 | { |
| 67 | return NULL; | 67 | return NULL; |
| 68 | } | 68 | } |
| 69 | #endif | 69 | #endif |
| 70 | 70 | ||
| 71 | #define regulator_register_fixed(id, s, ns) regulator_register_always_on(id, \ | 71 | #define regulator_register_fixed(id, s, ns) regulator_register_always_on(id, \ |
| 72 | "fixed-dummy", s, ns) | 72 | "fixed-dummy", s, ns, 0) |
| 73 | 73 | ||
| 74 | #endif | 74 | #endif |
