regulator: pca9450: Add SD_VSEL GPIO for LDO5
authorFrieder Schrempf <frieder.schrempf@kontron.de>
Thu, 11 Feb 2021 10:55:28 +0000 (11:55 +0100)
committerMark Brown <broonie@kernel.org>
Thu, 11 Feb 2021 13:11:34 +0000 (13:11 +0000)
commit8c67a11bae889f51fe5054364c3c789dfae3ad73
tree70d31c34dbbc50889d7845bccf547e8b53506435
parent7aa382cfe714f61b0c29f02c31d389c506b4e2ae
regulator: pca9450: Add SD_VSEL GPIO for LDO5

LDO5 has two separate control registers. LDO5CTRL_L is used if the
input signal SD_VSEL is low and LDO5CTRL_H if it is high.
The current driver implementation only uses LDO5CTRL_H. To make this
work on boards that have SD_VSEL connected to a GPIO, we add support
for specifying an optional GPIO and setting it to high at probe time.

In the future we might also want to add support for boards that have
SD_VSEL set to a fixed low level. In this case we need to change the
driver to be able to use the LDO5CTRL_L register.

Signed-off-by: Frieder Schrempf <frieder.schrempf@kontron.de>
Link: https://lore.kernel.org/r/20210211105534.38972-1-frieder.schrempf@kontron.de
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/pca9450-regulator.c