180689db1SShawn McCarney# Regulator Configuration 280689db1SShawn McCarney 380689db1SShawn McCarney## Overview 480689db1SShawn McCarney 580689db1SShawn McCarneyThe configuration of voltage regulators can be modified. Configuration changes 680689db1SShawn McCarneyusually override hardware default settings. 780689db1SShawn McCarney 880689db1SShawn McCarneyThe most common configuration change is setting the output voltage for a 980689db1SShawn McCarneyregulator rail. Other examples include modifying pgood thresholds and 1080689db1SShawn McCarneyovercurrent settings. 1180689db1SShawn McCarney 1280689db1SShawn McCarneyRegulator configuration occurs early in the system boot before regulators have 1380689db1SShawn McCarneybeen enabled (turned on). 1480689db1SShawn McCarney 1580689db1SShawn McCarney## How configuration is defined 1680689db1SShawn McCarney 1780689db1SShawn McCarneyConfiguration is defined for a voltage regulator using the 1880689db1SShawn McCarney[configuration](config_file/configuration.md) object in the 1980689db1SShawn McCarney[JSON config file](config_file/README.md). 2080689db1SShawn McCarney 2180689db1SShawn McCarneyThis object specifies actions to run, such as 2280689db1SShawn McCarney[pmbus_write_vout_command](config_file/pmbus_write_vout_command.md) and 2380689db1SShawn McCarney[i2c_write_byte](config_file/i2c_write_byte.md). 2480689db1SShawn McCarney 2580689db1SShawn McCarney## How configuration is initiated 2680689db1SShawn McCarney 2780689db1SShawn McCarneyDuring the system boot, the systemd service file 2880689db1SShawn McCarney[phosphor-regulators-config.service](../../services/phosphor-regulators-config.service) 2980689db1SShawn McCarneyis started. This runs the `regsctl` utility. This utility invokes the D-Bus 3080689db1SShawn McCarney`configure` method on the `phosphor-regulators` application. 3180689db1SShawn McCarney`phosphor-regulators` will perform the configuration defined in the JSON config 3280689db1SShawn McCarneyfile. 3380689db1SShawn McCarney 34*8b38b177SShawn McCarney## Multiple chassis 35*8b38b177SShawn McCarney 36*8b38b177SShawn McCarneyIn a [multiple chassis](multiple_chassis.md) system, `phosphor-regulators` will 37*8b38b177SShawn McCarneyonly configure regulators in chassis with the proper status: 38*8b38b177SShawn McCarney 39*8b38b177SShawn McCarney- `Present` property is true 40*8b38b177SShawn McCarney- `Enabled` property is true (if interface exists) 41*8b38b177SShawn McCarney- `Available` property is true (if interface exists) 42*8b38b177SShawn McCarney 43*8b38b177SShawn McCarneySee [Chassis Status](../phosphor-power-sequencer/docs/chassis_status.md) for 44*8b38b177SShawn McCarneymore information on these properties. 45*8b38b177SShawn McCarney 4680689db1SShawn McCarney## Error handling 4780689db1SShawn McCarney 4880689db1SShawn McCarneyIf an error occurs while executing actions to perform configuration: 4980689db1SShawn McCarney 5080689db1SShawn McCarney- The error will be logged. 5180689db1SShawn McCarney- Any remaining actions for the current voltage regulator/rail will be skipped. 5280689db1SShawn McCarney- Configuration changes will still be applied to all remaining voltage 5380689db1SShawn McCarney regulators in the system. 5480689db1SShawn McCarney- The system boot will continue. 55