Lines Matching refs:voltage

488 /* Platform voltage constraint check */
495 rdev_err(rdev, "voltage operation not allowed\n");
505 rdev_err(rdev, "unsupportable voltage range: %d-%duV\n",
519 /* Make sure we select a voltage that suits the needs of all
527 struct regulator_voltage *voltage;
530 voltage = &regulator->voltage[state];
535 if (!voltage->min_uV && !voltage->max_uV)
538 if (*max_uV > voltage->max_uV)
539 *max_uV = voltage->max_uV;
540 if (*min_uV < voltage->min_uV)
541 *min_uV = voltage->min_uV;
545 rdev_err(rdev, "Restricting voltage, %u-%uuV\n",
867 return sprintf(buf, "voltage\n");
1060 /* get output voltage */
1068 rdev_dbg(rdev, "invalid output voltage found\n");
1070 /* get input voltage */
1082 rdev_dbg(rdev, "invalid input voltage found\n");
1127 rdev_err(rdev, "failed to set voltage: %pe\n", ERR_PTR(ret));
1247 /* do we need to apply the constraint voltage */
1267 "failed to get the current voltage: %pe\n",
1273 * If we're below the minimum voltage move up to the
1274 * minimum voltage, if we're above the maximum voltage
1304 /* constrain machine-level voltage specs to fit
1315 /* it's safe to autoconfigure fixed-voltage supplies
1325 /* voltage constraints are optional */
1331 rdev_err(rdev, "invalid voltage constraints\n");
1357 "unsupportable voltage constraints %u-%uuV\n",
1461 * regulator circuits e.g. valid voltage/current ranges, etc. NOTE:
1589 rdev_err(rdev, "failed to set over voltage limits %pe\n",
1594 "IC does not support requested over voltage limits\n");
1603 rdev_err(rdev, "failed to set under voltage limits %pe\n",
1608 "IC does not support requested under voltage limits\n");
1926 &regulator->voltage[PM_SUSPEND_ON].min_uV);
1928 &regulator->voltage[PM_SUSPEND_ON].max_uV);
2959 * the predefined voltage or current value. Calls to regulator_enable()
3067 * Disable the regulator output voltage or current. Calls to
3119 * Forcibly disable the regulator output voltage or current.
3324 * @selector: identify voltage to list
3327 * Returns a voltage that can be passed to @regulator_set_voltage(),
3352 * regulator_get_hardware_vsel_register - get the HW voltage selector register
3354 * @vsel_reg: voltage selector register, output parameter
3355 * @vsel_mask: mask for voltage selector bitfield, output parameter
3358 * regulator voltage. This might be useful when configuring voltage-scaling
3385 * @selector: identify voltage to list
3387 * Converts the selector to a hardware-specific voltage selector that can be
3388 * directly written to the regulator registers. The address of the voltage
3411 * regulator_get_linear_step - return the voltage step size between VSEL values
3414 * Returns the voltage step size between VSEL values for linear
3426 * regulator_is_supported_voltage - check if a voltage range can be supported
3429 * @min_uV: Minimum required voltage in uV.
3430 * @max_uV: Maximum required voltage in uV.
3440 /* If we can't change voltage check the current voltage */
3449 /* Any voltage within constrains range is fine? */
3594 * At least try to return to the previous voltage if setting a new
3761 struct regulator_voltage *voltage = &regulator->voltage[state];
3768 * voltage for multiple frequencies, for example).
3770 if (voltage->min_uV == min_uV && voltage->max_uV == max_uV)
3773 /* If we're trying to set a range that overlaps the current voltage,
3775 * changing the voltage.
3780 voltage->min_uV = min_uV;
3781 voltage->max_uV = max_uV;
3799 old_min_uV = voltage->min_uV;
3800 old_max_uV = voltage->max_uV;
3801 voltage->min_uV = min_uV;
3802 voltage->max_uV = max_uV;
3804 /* for not coupled regulators this will just set the voltage */
3807 voltage->min_uV = old_min_uV;
3808 voltage->max_uV = old_max_uV;
3857 dev_err(&rdev->dev, "Failed to increase supply voltage: %pe\n",
3875 dev_warn(&rdev->dev, "Failed to decrease supply voltage: %pe\n",
3891 /* Limit voltage change only if necessary */
3905 /* Clamp target voltage within the given step */
3934 * If there are no coupled regulators, simply set the voltage
3939 * If consumers don't provide any demands, set voltage
3956 /* Find highest min desired voltage */
3985 * If not, set it to minimum voltage, allowed by other coupled
4013 * Correct target voltage, so as it currently isn't
4073 * Find the best possible voltage change on each loop. Leave the loop
4085 * Find highest difference between optimal voltage
4086 * and current voltage.
4090 * optimal_uV is the best voltage that can be set for
4168 * regulator_set_voltage - set regulator output voltage
4170 * @min_uV: Minimum required voltage in uV
4171 * @max_uV: Maximum acceptable voltage in uV
4173 * Sets a voltage regulator to the desired output voltage. This can be set
4176 * If the regulator is enabled then the voltage will change to the new value
4178 * output at the new voltage when enabled.
4181 * request voltage that meets the system constraints will be used.
4229 struct regulator_voltage *voltage;
4236 voltage = &regulator->voltage[state];
4237 if (voltage->min_uV || voltage->max_uV)
4257 rdev_err(rdev, "The suspend voltage can't be changed!\n");
4288 * @old_uV: starting voltage in microvolts
4289 * @new_uV: target voltage in microvolts
4291 * Provided with the starting and ending voltage, this function attempts to
4293 * voltage.
4302 int voltage;
4315 /* We only look for exact voltage matches here */
4322 voltage = regulator_list_voltage(regulator, i);
4323 if (voltage < 0)
4325 if (voltage == 0)
4327 if (voltage == old_uV)
4329 if (voltage == new_uV)
4343 * @old_selector: selector for starting voltage
4344 * @new_selector: selector for target voltage
4346 * Provided with the starting and target voltage selectors, this function
4347 * returns time in microseconds required to rise or fall to this new voltage
4397 * regulator_sync_voltage - re-apply last regulator output voltage
4400 * Re-apply the last configured voltage. This is intended to be used
4402 * has caused the configured voltage to change.
4407 struct regulator_voltage *voltage = &regulator->voltage[PM_SUSPEND_ON];
4421 /* This is only going to work if we've had a voltage configured. */
4422 if (!voltage->min_uV && !voltage->max_uV) {
4427 min_uV = voltage->min_uV;
4428 max_uV = voltage->max_uV;
4498 * regulator_get_voltage - get regulator output voltage
4501 * This returns the current regulator voltage in uV.
4503 * NOTE: If the regulator is disabled it will return the voltage value. This
5106 * This function handles critical events such as under-voltage, over-current,
5120 reason = "System critical regulator: voltage drop detected";
6092 consumer->voltage[PM_SUSPEND_ON].min_uV / 1000,
6093 consumer->voltage[PM_SUSPEND_ON].max_uV / 1000);
6225 seq_puts(s, " regulator use open bypass opmode voltage current min max\n");