[PATCH v3 0/4] regulator: core: support shared enable GPIO

From: Kim, Milo
Date: Mon Feb 18 2013 - 01:51:04 EST


A Regulator can be enabled by external GPIO pin which is configurable in the
regulator_config.
At this moment, the GPIO can be owned by only one regulator device.
In some devices like LP8788 LDOs, multiple regulators are enabled by shared
one GPIO pin.
This patch-set enables shared enable GPIO concept and fix LP8788 LDO driver
as well.

Patches were generated based on 'for-next' of regulator.git
(git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git)

Patch v3.
a) Add a reference count, 'request_count' which makes sure only free the GPIO
when it has no users
b) Make return type of regulator_ena_gpio_ctrl()
c) Free the GPIO when kzalloc() gets failed in regulator_ena_gpio_request()
d) Add a pointer to the GPIO structure to the regulator_dev on setting the GPIO
: use a GPIO structure directly instead of scanning the GPIO list

Patch v2.
a) Add a list for enable GPIO
b) Add a reference count, 'enable_count' for actual pin control

Patch v1.
Initial patch

Milo(Woogyom) Kim (4):
regulator: core: support shared enable GPIO concept
regulator: core: manage enable GPIO list
regulator: core: use regulator_ena_pin member
regulator: lp8788-ldo: use ena_pin of regulator-core for external control

drivers/regulator/core.c | 142 +++++++++++++++++++++++++++++++++-----
drivers/regulator/lp8788-ldo.c | 98 +++++---------------------
include/linux/regulator/driver.h | 4 +-
3 files changed, 142 insertions(+), 102 deletions(-)

--
1.7.9.5


Best Regards,
Milo


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/