mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-17 01:54:22 +00:00
feat(st-regulator): add enable ramp-delay
Permit to override enable ramp-delay value from the device tree in BL2. Change-Id: Id8e803b368055a50fbd14d4527917c449b958ad9 Signed-off-by: Pascal Paillet <p.paillet@st.com> Signed-off-by: Maxime Méré <maxime.mere@foss.st.com>
This commit is contained in:
parent
19bcffad58
commit
6897ae8d0f
1 changed files with 8 additions and 0 deletions
|
@ -420,6 +420,7 @@ int regulator_set_flag(struct rdev *rdev, uint16_t flag)
|
|||
|
||||
static int parse_properties(const void *fdt, struct rdev *rdev, int node)
|
||||
{
|
||||
const fdt32_t *cuint;
|
||||
int ret;
|
||||
|
||||
if (fdt_getprop(fdt, node, "regulator-always-on", NULL) != NULL) {
|
||||
|
@ -430,6 +431,13 @@ static int parse_properties(const void *fdt, struct rdev *rdev, int node)
|
|||
}
|
||||
}
|
||||
|
||||
cuint = fdt_getprop(fdt, node, "regulator-enable-ramp-delay", NULL);
|
||||
if (cuint != NULL) {
|
||||
rdev->enable_ramp_delay = fdt32_to_cpu(*cuint);
|
||||
VERBOSE("%s: enable_ramp_delay=%u\n", rdev->desc->node_name,
|
||||
rdev->enable_ramp_delay);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue