xref: /openbmc/phosphor-power/phosphor-regulators/docs/configuration.md (revision 8b38b177315d40f1f9bc1e4d0784d45ea17cbd5c)
1# Regulator Configuration
2
3## Overview
4
5The configuration of voltage regulators can be modified. Configuration changes
6usually override hardware default settings.
7
8The most common configuration change is setting the output voltage for a
9regulator rail. Other examples include modifying pgood thresholds and
10overcurrent settings.
11
12Regulator configuration occurs early in the system boot before regulators have
13been enabled (turned on).
14
15## How configuration is defined
16
17Configuration is defined for a voltage regulator using the
18[configuration](config_file/configuration.md) object in the
19[JSON config file](config_file/README.md).
20
21This object specifies actions to run, such as
22[pmbus_write_vout_command](config_file/pmbus_write_vout_command.md) and
23[i2c_write_byte](config_file/i2c_write_byte.md).
24
25## How configuration is initiated
26
27During the system boot, the systemd service file
28[phosphor-regulators-config.service](../../services/phosphor-regulators-config.service)
29is started. This runs the `regsctl` utility. This utility invokes the D-Bus
30`configure` method on the `phosphor-regulators` application.
31`phosphor-regulators` will perform the configuration defined in the JSON config
32file.
33
34## Multiple chassis
35
36In a [multiple chassis](multiple_chassis.md) system, `phosphor-regulators` will
37only configure regulators in chassis with the proper status:
38
39- `Present` property is true
40- `Enabled` property is true (if interface exists)
41- `Available` property is true (if interface exists)
42
43See [Chassis Status](../phosphor-power-sequencer/docs/chassis_status.md) for
44more information on these properties.
45
46## Error handling
47
48If an error occurs while executing actions to perform configuration:
49
50- The error will be logged.
51- Any remaining actions for the current voltage regulator/rail will be skipped.
52- Configuration changes will still be applied to all remaining voltage
53  regulators in the system.
54- The system boot will continue.
55