2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-26 06:04:14 +08:00
linux-next/include/linux/regulator
Markus Pargmann 76f439df50 regulator: Add ena_gpio_initialized to regulator_config
Most drivers do not set the ena_gpio field of struct regulator_config
before passing it to the regulator core. This is fine as long as the
gpio identifier that is passed is a positive integer. But the gpio
identifier 0 is also valid. So we are not able to decide wether we got a
real gpio identifier or not based on a 0 in ena_gpio.

To be able to decide if it is a valid gpio that got passed, this patch
adds a ena_gpio_initialized field that should be set if was initialized
with a correct value, either a gpio >= 0 or a negative error number. The
core then checks if ena_gpio or ena_gpio_initialized before handling it
as a gpio. This way we maintain backwards compatibility and fix the
behaviour for gpio number 0.

Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
2014-10-20 12:23:45 +01:00
..
ab8500.h regulator: ab8500: Remove ab8500_regulator_debug_init/exit() 2014-06-22 11:51:47 +01:00
act8865.h regulator: act8865: add support for act8846 2014-08-05 18:02:53 +01:00
consumer.h regulator: core: Add REGULATOR_EVENT_PRE_VOLTAGE_CHANGE (and ABORT) 2014-08-29 11:58:31 +01:00
da9211.h regulator: da9211: support device tree 2014-08-27 10:27:56 +01:00
db8500-prcmu.h
driver.h regulator: Add ena_gpio_initialized to regulator_config 2014-10-20 12:23:45 +01:00
fan53555.h regulator: fan53555: Prevent multiple include of fan53555.h 2013-08-07 10:38:16 +01:00
fixed.h
gpio-regulator.h
lp872x.h
lp3971.h
lp3972.h
machine.h regulator: fix kernel-doc warnings in header files 2014-08-28 09:59:42 +01:00
max1586.h regulator: max1586: add device-tree support 2014-09-01 11:35:45 +01:00
max8649.h
max8660.h regulators: max8660: add DT bindings 2013-08-02 17:29:54 +01:00
max8952.h regulator: max8952: Add Device Tree support 2013-04-05 11:20:52 +01:00
max8973-regulator.h
of_regulator.h
pfuze100.h regulator: pfuze100: add pfuze200 support 2014-03-04 17:40:31 +08:00
tps6507x.h
tps51632-regulator.h
tps62360.h
userspace-consumer.h