Page MenuHomeFreeBSD

regulator: Disable unused regulator
ClosedPublic

Authored by manu on Mar 21 2018, 9:16 AM.
Tags
None
Referenced Files
F137011739: D14781.id40531.diff
Thu, Nov 20, 11:46 PM
F137011357: D14781.id41072.diff
Thu, Nov 20, 11:45 PM
F137008796: D14781.id40529.diff
Thu, Nov 20, 11:39 PM
F137008170: D14781.id.diff
Thu, Nov 20, 11:37 PM
F137007295: D14781.diff
Thu, Nov 20, 11:35 PM
Unknown Object (File)
Sat, Nov 15, 8:55 PM
Unknown Object (File)
Fri, Nov 14, 11:30 PM
Unknown Object (File)
Fri, Nov 14, 8:13 PM
Subscribers

Details

Summary

bootloaders such as u-boot might enable regulators, or simply regulators could be enabled by default by the PMIC, even if we don't have a driver for the device or subsystem.
Disable unused regulators just before going to userland.
A tunable hw.regulator.disable_unused is added to not disable them in case this causes problems on some board but the default behavior is to disable everything unused. I prefer to break thinks now and fix them rather than never switch to the case were we disable regulators.

Test Plan

Tested on : Pine64-LTS (an idle board goes from ~0.33A to ~0.27A)

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 15680
Build 15709: arc lint + arc unit

Event Timeline

It would pay to add a comment to explain what the function is for.

Add comment explaining what the function does.

This revision was not accepted when it landed; it landed in state Needs Review.Apr 4 2018, 6:44 AM
This revision was automatically updated to reflect the committed changes.