Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

drivers: regulator: npm1300: Add boot state detection #64843

Conversation

aasinclair
Copy link
Contributor

Added boot state detection, so that the reference count is set correctly and enable/disable work as expected.

With this fix it is no longer necessary to set
regulator-boot-on when the regulator is enabled in hardware.

gmarull
gmarull previously approved these changes Nov 6, 2023
drivers/regulator/regulator_npm1300.c Outdated Show resolved Hide resolved
int regulator_npm1300_init(const struct device *dev)
{
const struct regulator_npm1300_config *config = dev->config;
bool enabled = false;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no need to initialize this one

Added boot state detection, so that the reference count is
set correctly and enable/disable work as expected.

With this fix it is no longer necessary to set
regulator-boot-on when the regulator is enabled in hardware.

Signed-off-by: Andy Sinclair <andy.sinclair@nordicsemi.no>
@fabiobaltieri fabiobaltieri merged commit ec52722 into zephyrproject-rtos:main Nov 7, 2023
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants