History log of /optee_os/core/drivers/regulator/regulator_fixed.c (Results 1 – 3 of 3)
Revision Date Author Comments
# 39d1e320 06-May-2025 Patrick Delaunay <patrick.delaunay@foss.st.com>

drivers: gpio: add configure functions

Align the OP-TEE GPIO driver with GPIO lib (devm_gpiod_get_index with
enum gpiod_flags) and add a way to select the GPIO configuration directly
during request

drivers: gpio: add configure functions

Align the OP-TEE GPIO driver with GPIO lib (devm_gpiod_get_index with
enum gpiod_flags) and add a way to select the GPIO configuration directly
during request with the new function, gpio_dt_cfg_by_index().

This patch remove assumption on GPIO direction (gpio input was assumed in
GPIO driver) or output level when the GPIO is requested by consumer.
with this patch it must be requested explicitly with:
- GPIO_IN: configure the input GPIO
- GPIO_ASIS: direction is managed by caller later with gpio_set_value()
call.
- GPIO_OUT_LOW / GPIO_OUT_HIGH: output GPIO at expected level,
the sequence for GPIO have the correct order to avoid glitch by using
the gpio function at the correct order.

This patch is a preliminary step for the introduction of ops configure.
The API gpio_dt_get_by_index() is keep for backward compatibility but
should be used with gpio_configure() or replaced by gpio_dt_cfg_by_index().

Now gpio_configure() is only used in the 2 drivers, regulator_fixed and
regulator_gpio, because in these drivers the flags gpio->dt_flags are
modified after call of gpio_dt_get_by_index().

For get_voltage_level_gpio(), GPIO_OUT_HIGH is used by default as it is
done in Linux function of_get_gpio_regulator_config().

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Signed-off-by: Thomas Bourgoin <thomas.bourgoin@foss.st.com>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...


# dc374be0 06-May-2025 Patrick Delaunay <patrick.delaunay@foss.st.com>

drivers: regulator: simplify device tree parsing

Use gpio_dt_get_by_index() to get the properties in device tree with
all the possible variant name: "gpio" and "gpios".

Signed-off-by: Patrick Delau

drivers: regulator: simplify device tree parsing

Use gpio_dt_get_by_index() to get the properties in device tree with
all the possible variant name: "gpio" and "gpios".

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Signed-off-by: Thomas Bourgoin <thomas.bourgoin@foss.st.com>
Reviewed-by: Etienne Carriere <etienne.carriere@foss.st.com>

show more ...


# 652d2ce7 12-Sep-2023 Etienne Carriere <etienne.carriere@linaro.org>

drivers: regulator: fixed regulator

Implements fixed voltage level regulator driver to register DT
compatible "regulator-fixed" devices into the regulator framework.
These regulators may be enabled/

drivers: regulator: fixed regulator

Implements fixed voltage level regulator driver to register DT
compatible "regulator-fixed" devices into the regulator framework.
These regulators may be enabled/disabled using a GPIO pin in which
cases CFG_DRIVERS_GPIO shall be enabled.

Acked-by: Gatien Chevallier <gatien.chevallier@foss.st.com>
Acked-by: Thomas Bourgoin <thomas.bourgoin@foss.st.com>
Co-developed-by: Pascal Paillet <p.paillet@foss.st.com>
Signed-off-by: Pascal Paillet <p.paillet@foss.st.com>
Signed-off-by: Etienne Carriere <etienne.carriere@linaro.org>

show more ...