diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/regulator/consumer.h | 4 | ||||
| -rw-r--r-- | include/linux/regulator/driver.h | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/regulator/consumer.h b/include/linux/regulator/consumer.h index f540b1496e2f..4cfaaf222304 100644 --- a/include/linux/regulator/consumer.h +++ b/include/linux/regulator/consumer.h | |||
| @@ -101,6 +101,8 @@ struct regmap; | |||
| 101 | * Data passed is "struct pre_voltage_change_data" | 101 | * Data passed is "struct pre_voltage_change_data" |
| 102 | * ABORT_VOLTAGE_CHANGE Regulator voltage change failed for some reason. | 102 | * ABORT_VOLTAGE_CHANGE Regulator voltage change failed for some reason. |
| 103 | * Data passed is old voltage cast to (void *). | 103 | * Data passed is old voltage cast to (void *). |
| 104 | * PRE_DISABLE Regulator is about to be disabled | ||
| 105 | * ABORT_DISABLE Regulator disable failed for some reason | ||
| 104 | * | 106 | * |
| 105 | * NOTE: These events can be OR'ed together when passed into handler. | 107 | * NOTE: These events can be OR'ed together when passed into handler. |
| 106 | */ | 108 | */ |
| @@ -115,6 +117,8 @@ struct regmap; | |||
| 115 | #define REGULATOR_EVENT_DISABLE 0x80 | 117 | #define REGULATOR_EVENT_DISABLE 0x80 |
| 116 | #define REGULATOR_EVENT_PRE_VOLTAGE_CHANGE 0x100 | 118 | #define REGULATOR_EVENT_PRE_VOLTAGE_CHANGE 0x100 |
| 117 | #define REGULATOR_EVENT_ABORT_VOLTAGE_CHANGE 0x200 | 119 | #define REGULATOR_EVENT_ABORT_VOLTAGE_CHANGE 0x200 |
| 120 | #define REGULATOR_EVENT_PRE_DISABLE 0x400 | ||
| 121 | #define REGULATOR_EVENT_ABORT_DISABLE 0x800 | ||
| 118 | 122 | ||
| 119 | /** | 123 | /** |
| 120 | * struct pre_voltage_change_data - Data sent with PRE_VOLTAGE_CHANGE event | 124 | * struct pre_voltage_change_data - Data sent with PRE_VOLTAGE_CHANGE event |
diff --git a/include/linux/regulator/driver.h b/include/linux/regulator/driver.h index fc0ee0ce8325..28da08e4671f 100644 --- a/include/linux/regulator/driver.h +++ b/include/linux/regulator/driver.h | |||
| @@ -301,6 +301,9 @@ struct regulator_desc { | |||
| 301 | * NULL). | 301 | * NULL). |
| 302 | * @regmap: regmap to use for core regmap helpers if dev_get_regulator() is | 302 | * @regmap: regmap to use for core regmap helpers if dev_get_regulator() is |
| 303 | * insufficient. | 303 | * insufficient. |
| 304 | * @ena_gpio_initialized: GPIO controlling regulator enable was properly | ||
| 305 | * initialized, meaning that >= 0 is a valid gpio | ||
| 306 | * identifier and < 0 is a non existent gpio. | ||
| 304 | * @ena_gpio: GPIO controlling regulator enable. | 307 | * @ena_gpio: GPIO controlling regulator enable. |
| 305 | * @ena_gpio_invert: Sense for GPIO enable control. | 308 | * @ena_gpio_invert: Sense for GPIO enable control. |
| 306 | * @ena_gpio_flags: Flags to use when calling gpio_request_one() | 309 | * @ena_gpio_flags: Flags to use when calling gpio_request_one() |
| @@ -312,6 +315,7 @@ struct regulator_config { | |||
| 312 | struct device_node *of_node; | 315 | struct device_node *of_node; |
| 313 | struct regmap *regmap; | 316 | struct regmap *regmap; |
| 314 | 317 | ||
| 318 | bool ena_gpio_initialized; | ||
| 315 | int ena_gpio; | 319 | int ena_gpio; |
| 316 | unsigned int ena_gpio_invert:1; | 320 | unsigned int ena_gpio_invert:1; |
| 317 | unsigned int ena_gpio_flags; | 321 | unsigned int ena_gpio_flags; |
