mirror of
https://github.com/t2linux/kernel.git
synced 2026-04-30 13:48:59 -07:00
Merge tag 'regulator-v5.8' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
Pull regulator updates from Mark Brown:
"The big change in this release is that Matti Vaittinen has factored
out the linear ranges support into a separate library in lib/ since it
is also useful for at least the power subsystem (and most likely
others too), it helps subsystems which need to map register values
into more useful real world values do so with minimal per-driver code.
- Factoring out of the linear ranges support into a library in lib/
from Matti Vaittinen.
- Trace points for bypass mode.
- Use the consumer name in debugfs to make it easier to understand.
- New drivers for Maxim MAX77826 and MAX8998"
* tag 'regulator-v5.8' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: (23 commits)
regulator: max8998: max8998_set_current_limit() can be static
dt-bindings: regulator: Convert anatop regulator to json-schema
regulator: core: Add regulator bypass trace points
regulator: extract voltage balancing code to the separate function
regulator/mfd: max8998: Document charger regulator
regulator: max8998: Add charger regulator
MAINTAINERS: Add maintainer entry for linear ranges helper
regulator: bd718x7: remove voltage change restriction from BD71847 LDOs
lib: linear_ranges: Add missing MODULE_LICENSE()
regulator: use linear_ranges helper
power: supply: bd70528: rename linear_range to avoid collision
lib/test_linear_ranges: add a test for the 'linear_ranges'
lib: add linear ranges helpers
regulator: db8500-prcmu: Use true,false for bool variable
regulator: bd718x7: remove voltage change restriction from BD71847
regulator: max77826: Remove erroneous additionalProperties
regulator: qcom-rpmh: Fix typos in pm8150 and pm8150l
regulator: Document bindings for max77826
regulator: max77826: Add max77826 regulator driver
regulator: tps80031: remove redundant assignment to variables ret and val
...
This commit is contained in:
@@ -73,6 +73,8 @@ number as described in MAX8998 datasheet.
|
||||
- ESAFEOUT1: (ldo19)
|
||||
- ESAFEOUT2: (ld020)
|
||||
|
||||
- CHARGER: main battery charger current control
|
||||
|
||||
Standard regulator bindings are used inside regulator subnodes. Check
|
||||
Documentation/devicetree/bindings/regulator/regulator.txt
|
||||
for more details.
|
||||
@@ -113,5 +115,11 @@ Example:
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
charger_reg: CHARGER {
|
||||
regulator-name = "CHARGER";
|
||||
regulator-min-microamp = <90000>;
|
||||
regulator-max-microamp = <800000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,40 +0,0 @@
|
||||
Anatop Voltage regulators
|
||||
|
||||
Required properties:
|
||||
- compatible: Must be "fsl,anatop-regulator"
|
||||
- regulator-name: A string used as a descriptive name for regulator outputs
|
||||
- anatop-reg-offset: Anatop MFD register offset
|
||||
- anatop-vol-bit-shift: Bit shift for the register
|
||||
- anatop-vol-bit-width: Number of bits used in the register
|
||||
- anatop-min-bit-val: Minimum value of this register
|
||||
- anatop-min-voltage: Minimum voltage of this regulator
|
||||
- anatop-max-voltage: Maximum voltage of this regulator
|
||||
|
||||
Optional properties:
|
||||
- anatop-delay-reg-offset: Anatop MFD step time register offset
|
||||
- anatop-delay-bit-shift: Bit shift for the step time register
|
||||
- anatop-delay-bit-width: Number of bits used in the step time register
|
||||
- vin-supply: The supply for this regulator
|
||||
- anatop-enable-bit: Regulator enable bit offset
|
||||
|
||||
Any property defined as part of the core regulator
|
||||
binding, defined in regulator.txt, can also be used.
|
||||
|
||||
Example:
|
||||
|
||||
regulator-vddpu {
|
||||
compatible = "fsl,anatop-regulator";
|
||||
regulator-name = "vddpu";
|
||||
regulator-min-microvolt = <725000>;
|
||||
regulator-max-microvolt = <1300000>;
|
||||
regulator-always-on;
|
||||
anatop-reg-offset = <0x140>;
|
||||
anatop-vol-bit-shift = <9>;
|
||||
anatop-vol-bit-width = <5>;
|
||||
anatop-delay-reg-offset = <0x170>;
|
||||
anatop-delay-bit-shift = <24>;
|
||||
anatop-delay-bit-width = <2>;
|
||||
anatop-min-bit-val = <1>;
|
||||
anatop-min-voltage = <725000>;
|
||||
anatop-max-voltage = <1300000>;
|
||||
};
|
||||
@@ -0,0 +1,94 @@
|
||||
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
|
||||
%YAML 1.2
|
||||
---
|
||||
$id: http://devicetree.org/schemas/regulator/anatop-regulator.yaml#
|
||||
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
||||
|
||||
title: Freescale Anatop Voltage Regulators
|
||||
|
||||
maintainers:
|
||||
- Ying-Chun Liu (PaulLiu) <paul.liu@linaro.org>
|
||||
|
||||
allOf:
|
||||
- $ref: "regulator.yaml#"
|
||||
|
||||
properties:
|
||||
compatible:
|
||||
const: fsl,anatop-regulator
|
||||
|
||||
regulator-name: true
|
||||
|
||||
anatop-reg-offset:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the anatop MFD register offset.
|
||||
|
||||
anatop-vol-bit-shift:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the bit shift for the register.
|
||||
|
||||
anatop-vol-bit-width:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the number of bits used in the register.
|
||||
|
||||
anatop-min-bit-val:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the minimum value of this register.
|
||||
|
||||
anatop-min-voltage:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the minimum voltage of this regulator.
|
||||
|
||||
anatop-max-voltage:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the maximum voltage of this regulator.
|
||||
|
||||
anatop-delay-reg-offset:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the anatop MFD step time register offset.
|
||||
|
||||
anatop-delay-bit-shift:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the bit shift for the step time register.
|
||||
|
||||
anatop-delay-bit-width:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing the number of bits used in the step time register.
|
||||
|
||||
anatop-enable-bit:
|
||||
$ref: '/schemas/types.yaml#/definitions/uint32'
|
||||
description: u32 value representing regulator enable bit offset.
|
||||
|
||||
vin-supply:
|
||||
$ref: '/schemas/types.yaml#/definitions/phandle'
|
||||
description: input supply phandle.
|
||||
|
||||
required:
|
||||
- compatible
|
||||
- regulator-name
|
||||
- anatop-reg-offset
|
||||
- anatop-vol-bit-shift
|
||||
- anatop-vol-bit-width
|
||||
- anatop-min-bit-val
|
||||
- anatop-min-voltage
|
||||
- anatop-max-voltage
|
||||
|
||||
unevaluatedProperties: false
|
||||
|
||||
examples:
|
||||
- |
|
||||
regulator-vddpu {
|
||||
compatible = "fsl,anatop-regulator";
|
||||
regulator-name = "vddpu";
|
||||
regulator-min-microvolt = <725000>;
|
||||
regulator-max-microvolt = <1300000>;
|
||||
regulator-always-on;
|
||||
anatop-reg-offset = <0x140>;
|
||||
anatop-vol-bit-shift = <9>;
|
||||
anatop-vol-bit-width = <5>;
|
||||
anatop-delay-reg-offset = <0x170>;
|
||||
anatop-delay-bit-shift = <24>;
|
||||
anatop-delay-bit-width = <2>;
|
||||
anatop-min-bit-val = <1>;
|
||||
anatop-min-voltage = <725000>;
|
||||
anatop-max-voltage = <1300000>;
|
||||
};
|
||||
@@ -0,0 +1,68 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
|
||||
%YAML 1.2
|
||||
---
|
||||
$id: http://devicetree.org/schemas/regulator/maxim,max77826.yaml#
|
||||
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
||||
|
||||
title: Maxim Integrated MAX77826 PMIC
|
||||
|
||||
maintainers:
|
||||
- Iskren Chernev <iskren.chernev@gmail.com>
|
||||
|
||||
properties:
|
||||
$nodename:
|
||||
pattern: "pmic@[0-9a-f]{1,2}"
|
||||
compatible:
|
||||
enum:
|
||||
- maxim,max77826
|
||||
|
||||
reg:
|
||||
maxItems: 1
|
||||
|
||||
regulators:
|
||||
type: object
|
||||
allOf:
|
||||
- $ref: regulator.yaml#
|
||||
description: |
|
||||
list of regulators provided by this controller, must be named
|
||||
after their hardware counterparts LDO[1-15], BUCK and BUCKBOOST
|
||||
|
||||
patternProperties:
|
||||
"^LDO([1-9]|1[0-5])$":
|
||||
type: object
|
||||
allOf:
|
||||
- $ref: regulator.yaml#
|
||||
|
||||
"^BUCK|BUCKBOOST$":
|
||||
type: object
|
||||
allOf:
|
||||
- $ref: regulator.yaml#
|
||||
|
||||
additionalProperties: false
|
||||
|
||||
required:
|
||||
- compatible
|
||||
- reg
|
||||
- regulators
|
||||
|
||||
additionalProperties: false
|
||||
|
||||
examples:
|
||||
- |
|
||||
i2c {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
pmic@69 {
|
||||
compatible = "maxim,max77826";
|
||||
reg = <0x69>;
|
||||
|
||||
regulators {
|
||||
LDO2 {
|
||||
regulator-min-microvolt = <650000>;
|
||||
regulator-max-microvolt = <3587500>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
...
|
||||
@@ -9748,6 +9748,13 @@ F: drivers/lightnvm/
|
||||
F: include/linux/lightnvm.h
|
||||
F: include/uapi/linux/lightnvm.h
|
||||
|
||||
LINEAR RANGES HELPERS
|
||||
M: Mark Brown <broonie@kernel.org>
|
||||
R: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>
|
||||
F: lib/linear_ranges.c
|
||||
F: lib/test_linear_ranges.c
|
||||
F: include/linux/linear_range.h
|
||||
|
||||
LINUX FOR POWER MACINTOSH
|
||||
M: Benjamin Herrenschmidt <benh@kernel.crashing.org>
|
||||
L: linuxppc-dev@lists.ozlabs.org
|
||||
|
||||
@@ -335,14 +335,14 @@ static int bd70528_get_present(struct bd70528_psy *bdpsy, int *val)
|
||||
return 0;
|
||||
}
|
||||
|
||||
struct linear_range {
|
||||
struct bd70528_linear_range {
|
||||
int min;
|
||||
int step;
|
||||
int vals;
|
||||
int low_sel;
|
||||
};
|
||||
|
||||
static const struct linear_range current_limit_ranges[] = {
|
||||
static const struct bd70528_linear_range current_limit_ranges[] = {
|
||||
{
|
||||
.min = 5,
|
||||
.step = 1,
|
||||
@@ -374,7 +374,7 @@ static const struct linear_range current_limit_ranges[] = {
|
||||
* voltage for low temperatures. The driver currently only reads
|
||||
* the charge current at room temperature. We do set both though.
|
||||
*/
|
||||
static const struct linear_range warm_charge_curr[] = {
|
||||
static const struct bd70528_linear_range warm_charge_curr[] = {
|
||||
{
|
||||
.min = 10,
|
||||
.step = 10,
|
||||
@@ -398,7 +398,7 @@ static const struct linear_range warm_charge_curr[] = {
|
||||
#define MAX_WARM_CHG_CURR_SEL 0x1f
|
||||
#define MIN_CHG_CURR_SEL 0x0
|
||||
|
||||
static int find_value_for_selector_low(const struct linear_range *r,
|
||||
static int find_value_for_selector_low(const struct bd70528_linear_range *r,
|
||||
int selectors, unsigned int sel,
|
||||
unsigned int *val)
|
||||
{
|
||||
@@ -420,7 +420,7 @@ static int find_value_for_selector_low(const struct linear_range *r,
|
||||
* I guess it is enough if we use voltage/current which is closest (below)
|
||||
* the requested?
|
||||
*/
|
||||
static int find_selector_for_value_low(const struct linear_range *r,
|
||||
static int find_selector_for_value_low(const struct bd70528_linear_range *r,
|
||||
int selectors, unsigned int val,
|
||||
unsigned int *sel, bool *found)
|
||||
{
|
||||
|
||||
@@ -11,13 +11,13 @@ static const struct regulator_ops pg86x_ops = {
|
||||
.list_voltage = regulator_list_voltage_linear_range,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range pg86x_buck1_ranges[] = {
|
||||
static const struct linear_range pg86x_buck1_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE( 0, 0, 10, 0),
|
||||
REGULATOR_LINEAR_RANGE(1000000, 11, 34, 25000),
|
||||
REGULATOR_LINEAR_RANGE(1600000, 35, 47, 50000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range pg86x_buck2_ranges[] = {
|
||||
static const struct linear_range pg86x_buck2_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE( 0, 0, 15, 0),
|
||||
REGULATOR_LINEAR_RANGE(1000000, 16, 39, 25000),
|
||||
REGULATOR_LINEAR_RANGE(1600000, 40, 52, 50000),
|
||||
|
||||
@@ -134,13 +134,13 @@ struct pm800_regulator_info {
|
||||
}
|
||||
|
||||
/* Ranges are sorted in ascending order. */
|
||||
static const struct regulator_linear_range buck1_volt_range[] = {
|
||||
static const struct linear_range buck1_volt_range[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000, 0, 0x4f, 12500),
|
||||
REGULATOR_LINEAR_RANGE(1600000, 0x50, 0x54, 50000),
|
||||
};
|
||||
|
||||
/* BUCK 2~5 have same ranges. */
|
||||
static const struct regulator_linear_range buck2_5_volt_range[] = {
|
||||
static const struct linear_range buck2_5_volt_range[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000, 0, 0x4f, 12500),
|
||||
REGULATOR_LINEAR_RANGE(1600000, 0x50, 0x72, 50000),
|
||||
};
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
menuconfig REGULATOR
|
||||
bool "Voltage and Current Regulator Support"
|
||||
select LINEAR_RANGES
|
||||
help
|
||||
Generic Voltage and Current Regulator support.
|
||||
|
||||
@@ -585,6 +586,16 @@ config REGULATOR_MAX77802
|
||||
Exynos5420/Exynos5800 SoCs to control various voltages.
|
||||
It includes support for control of voltage and ramp speed.
|
||||
|
||||
config REGULATOR_MAX77826
|
||||
tristate "Maxim 77826 regulator"
|
||||
depends on I2C
|
||||
select REGMAP_I2C
|
||||
help
|
||||
This driver controls a Maxim 77826 regulator via I2C bus.
|
||||
The regulator include 15 LDOs, BUCK and BUCK BOOST regulator.
|
||||
It includes support for control of output voltage. This
|
||||
regulator is found on the Samsung Galaxy S5 (klte) smartphone.
|
||||
|
||||
config REGULATOR_MC13XXX_CORE
|
||||
tristate
|
||||
|
||||
|
||||
@@ -74,6 +74,7 @@ obj-$(CONFIG_REGULATOR_MAX8998) += max8998.o
|
||||
obj-$(CONFIG_REGULATOR_MAX77686) += max77686-regulator.o
|
||||
obj-$(CONFIG_REGULATOR_MAX77693) += max77693-regulator.o
|
||||
obj-$(CONFIG_REGULATOR_MAX77802) += max77802-regulator.o
|
||||
obj-$(CONFIG_REGULATOR_MAX77826) += max77826-regulator.o
|
||||
obj-$(CONFIG_REGULATOR_MC13783) += mc13783-regulator.o
|
||||
obj-$(CONFIG_REGULATOR_MC13892) += mc13892-regulator.o
|
||||
obj-$(CONFIG_REGULATOR_MC13XXX_CORE) += mc13xxx-regulator-core.o
|
||||
|
||||
@@ -139,17 +139,6 @@ static const unsigned int ldo_vintcore_voltages[] = {
|
||||
1350000,
|
||||
};
|
||||
|
||||
static const unsigned int ldo_sdio_voltages[] = {
|
||||
1160000,
|
||||
1050000,
|
||||
1100000,
|
||||
1500000,
|
||||
1800000,
|
||||
2200000,
|
||||
2910000,
|
||||
3050000,
|
||||
};
|
||||
|
||||
static const unsigned int fixed_1200000_voltage[] = {
|
||||
1200000,
|
||||
};
|
||||
@@ -166,10 +155,6 @@ static const unsigned int fixed_2050000_voltage[] = {
|
||||
2050000,
|
||||
};
|
||||
|
||||
static const unsigned int fixed_3300000_voltage[] = {
|
||||
3300000,
|
||||
};
|
||||
|
||||
static const unsigned int ldo_vana_voltages[] = {
|
||||
1050000,
|
||||
1075000,
|
||||
@@ -192,13 +177,6 @@ static const unsigned int ldo_vaudio_voltages[] = {
|
||||
2600000, /* Duplicated in Vaudio and IsoUicc Control register. */
|
||||
};
|
||||
|
||||
static const unsigned int ldo_vdmic_voltages[] = {
|
||||
1800000,
|
||||
1900000,
|
||||
2000000,
|
||||
2850000,
|
||||
};
|
||||
|
||||
static DEFINE_MUTEX(shared_mode_mutex);
|
||||
static struct ab8500_shared_mode ldo_anamic1_shared;
|
||||
static struct ab8500_shared_mode ldo_anamic2_shared;
|
||||
|
||||
@@ -220,13 +220,13 @@ static const struct regmap_config act8865_regmap_config = {
|
||||
.val_bits = 8,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range act8865_voltage_ranges[] = {
|
||||
static const struct linear_range act8865_voltage_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000, 0, 23, 25000),
|
||||
REGULATOR_LINEAR_RANGE(1200000, 24, 47, 50000),
|
||||
REGULATOR_LINEAR_RANGE(2400000, 48, 63, 100000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range act8600_sudcdc_voltage_ranges[] = {
|
||||
static const struct linear_range act8600_sudcdc_voltage_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(3000000, 0, 63, 0),
|
||||
REGULATOR_LINEAR_RANGE(3000000, 64, 159, 100000),
|
||||
REGULATOR_LINEAR_RANGE(12600000, 160, 191, 200000),
|
||||
|
||||
@@ -73,7 +73,7 @@ struct act8945a_pmic {
|
||||
u32 op_mode[ACT8945A_ID_MAX];
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range act8945a_voltage_ranges[] = {
|
||||
static const struct linear_range act8945a_voltage_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000, 0, 23, 25000),
|
||||
REGULATOR_LINEAR_RANGE(1200000, 24, 47, 50000),
|
||||
REGULATOR_LINEAR_RANGE(2400000, 48, 63, 100000),
|
||||
|
||||
@@ -87,7 +87,7 @@ static const struct regulator_ops arizona_ldo1_hc_ops = {
|
||||
.set_bypass = regulator_set_bypass_regmap,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range arizona_ldo1_hc_ranges[] = {
|
||||
static const struct linear_range arizona_ldo1_hc_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(900000, 0, 0x6, 50000),
|
||||
REGULATOR_LINEAR_RANGE(1800000, 0x7, 0x7, 0),
|
||||
};
|
||||
|
||||
@@ -125,7 +125,7 @@ static const struct regulator_ops arizona_micsupp_ops = {
|
||||
.set_bypass = arizona_micsupp_set_bypass,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range arizona_micsupp_ranges[] = {
|
||||
static const struct linear_range arizona_micsupp_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(1700000, 0, 0x1e, 50000),
|
||||
REGULATOR_LINEAR_RANGE(3300000, 0x1f, 0x1f, 0),
|
||||
};
|
||||
@@ -152,7 +152,7 @@ static const struct regulator_desc arizona_micsupp = {
|
||||
.owner = THIS_MODULE,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range arizona_micsupp_ext_ranges[] = {
|
||||
static const struct linear_range arizona_micsupp_ext_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(900000, 0, 0x14, 25000),
|
||||
REGULATOR_LINEAR_RANGE(1500000, 0x15, 0x27, 100000),
|
||||
};
|
||||
|
||||
@@ -103,18 +103,18 @@ static const struct regulator_ops as3711_dldo_ops = {
|
||||
.map_voltage = regulator_map_voltage_linear_range,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range as3711_sd_ranges[] = {
|
||||
static const struct linear_range as3711_sd_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(612500, 0x1, 0x40, 12500),
|
||||
REGULATOR_LINEAR_RANGE(1425000, 0x41, 0x70, 25000),
|
||||
REGULATOR_LINEAR_RANGE(2650000, 0x71, 0x7f, 50000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range as3711_aldo_ranges[] = {
|
||||
static const struct linear_range as3711_aldo_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(1200000, 0, 0xf, 50000),
|
||||
REGULATOR_LINEAR_RANGE(1800000, 0x10, 0x1f, 100000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range as3711_dldo_ranges[] = {
|
||||
static const struct linear_range as3711_dldo_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(900000, 0, 0x10, 50000),
|
||||
REGULATOR_LINEAR_RANGE(1750000, 0x20, 0x3f, 50000),
|
||||
};
|
||||
|
||||
@@ -389,7 +389,7 @@ static const struct regulator_ops as3722_ldo6_extcntrl_ops = {
|
||||
.set_bypass = regulator_set_bypass_regmap,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range as3722_ldo_ranges[] = {
|
||||
static const struct linear_range as3722_ldo_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(0, 0x00, 0x00, 0),
|
||||
REGULATOR_LINEAR_RANGE(825000, 0x01, 0x24, 25000),
|
||||
REGULATOR_LINEAR_RANGE(1725000, 0x40, 0x7F, 25000),
|
||||
@@ -487,7 +487,7 @@ static bool as3722_sd0_is_low_voltage(struct as3722_regulators *as3722_regs)
|
||||
return false;
|
||||
}
|
||||
|
||||
static const struct regulator_linear_range as3722_sd2345_ranges[] = {
|
||||
static const struct linear_range as3722_sd2345_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(0, 0x00, 0x00, 0),
|
||||
REGULATOR_LINEAR_RANGE(612500, 0x01, 0x40, 12500),
|
||||
REGULATOR_LINEAR_RANGE(1425000, 0x41, 0x70, 25000),
|
||||
|
||||
@@ -510,7 +510,7 @@ static const struct regulator_ops axp20x_ops_sw = {
|
||||
.is_enabled = regulator_is_enabled_regmap,
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range axp20x_ldo4_ranges[] = {
|
||||
static const struct linear_range axp20x_ldo4_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(1250000,
|
||||
AXP20X_LDO4_V_OUT_1250mV_START,
|
||||
AXP20X_LDO4_V_OUT_1250mV_END,
|
||||
@@ -638,7 +638,7 @@ static const struct regulator_desc axp22x_drivevbus_regulator = {
|
||||
};
|
||||
|
||||
/* DCDC ranges shared with AXP813 */
|
||||
static const struct regulator_linear_range axp803_dcdc234_ranges[] = {
|
||||
static const struct linear_range axp803_dcdc234_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(500000,
|
||||
AXP803_DCDC234_500mV_START,
|
||||
AXP803_DCDC234_500mV_END,
|
||||
@@ -649,7 +649,7 @@ static const struct regulator_linear_range axp803_dcdc234_ranges[] = {
|
||||
20000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range axp803_dcdc5_ranges[] = {
|
||||
static const struct linear_range axp803_dcdc5_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(800000,
|
||||
AXP803_DCDC5_800mV_START,
|
||||
AXP803_DCDC5_800mV_END,
|
||||
@@ -660,7 +660,7 @@ static const struct regulator_linear_range axp803_dcdc5_ranges[] = {
|
||||
20000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range axp803_dcdc6_ranges[] = {
|
||||
static const struct linear_range axp803_dcdc6_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000,
|
||||
AXP803_DCDC6_600mV_START,
|
||||
AXP803_DCDC6_600mV_END,
|
||||
@@ -672,7 +672,7 @@ static const struct regulator_linear_range axp803_dcdc6_ranges[] = {
|
||||
};
|
||||
|
||||
/* AXP806's CLDO2 and AXP809's DLDO1 share the same range */
|
||||
static const struct regulator_linear_range axp803_dldo2_ranges[] = {
|
||||
static const struct linear_range axp803_dldo2_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(700000,
|
||||
AXP803_DLDO2_700mV_START,
|
||||
AXP803_DLDO2_700mV_END,
|
||||
@@ -758,7 +758,7 @@ static const struct regulator_desc axp803_regulators[] = {
|
||||
AXP_DESC_FIXED(AXP803, RTC_LDO, "rtc-ldo", "ips", 3000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range axp806_dcdca_ranges[] = {
|
||||
static const struct linear_range axp806_dcdca_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000,
|
||||
AXP806_DCDCA_600mV_START,
|
||||
AXP806_DCDCA_600mV_END,
|
||||
@@ -769,7 +769,7 @@ static const struct regulator_linear_range axp806_dcdca_ranges[] = {
|
||||
20000),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range axp806_dcdcd_ranges[] = {
|
||||
static const struct linear_range axp806_dcdcd_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000,
|
||||
AXP806_DCDCD_600mV_START,
|
||||
AXP806_DCDCD_600mV_END,
|
||||
@@ -834,7 +834,7 @@ static const struct regulator_desc axp806_regulators[] = {
|
||||
AXP806_PWR_OUT_CTRL2, AXP806_PWR_OUT_SW_MASK),
|
||||
};
|
||||
|
||||
static const struct regulator_linear_range axp809_dcdc4_ranges[] = {
|
||||
static const struct linear_range axp809_dcdc4_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(600000,
|
||||
AXP809_DCDC4_600mV_START,
|
||||
AXP809_DCDC4_600mV_END,
|
||||
|
||||
@@ -116,14 +116,14 @@ static const unsigned int ldo_vbus[] = {
|
||||
};
|
||||
|
||||
/* DCDC group CSR: supported voltages in microvolts */
|
||||
static const struct regulator_linear_range dcdc_csr_ranges[] = {
|
||||
static const struct linear_range dcdc_csr_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(860000, 2, 50, 10000),
|
||||
REGULATOR_LINEAR_RANGE(1360000, 51, 55, 20000),
|
||||
REGULATOR_LINEAR_RANGE(900000, 56, 63, 0),
|
||||
};
|
||||
|
||||
/* DCDC group IOSR1: supported voltages in microvolts */
|
||||
static const struct regulator_linear_range dcdc_iosr1_ranges[] = {
|
||||
static const struct linear_range dcdc_iosr1_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(860000, 2, 51, 10000),
|
||||
REGULATOR_LINEAR_RANGE(1500000, 52, 52, 0),
|
||||
REGULATOR_LINEAR_RANGE(1800000, 53, 53, 0),
|
||||
@@ -131,7 +131,7 @@ static const struct regulator_linear_range dcdc_iosr1_ranges[] = {
|
||||
};
|
||||
|
||||
/* DCDC group SDSR1: supported voltages in microvolts */
|
||||
static const struct regulator_linear_range dcdc_sdsr1_ranges[] = {
|
||||
static const struct linear_range dcdc_sdsr1_ranges[] = {
|
||||
REGULATOR_LINEAR_RANGE(860000, 2, 50, 10000),
|
||||
REGULATOR_LINEAR_RANGE(1340000, 51, 51, 0),
|
||||
REGULATOR_LINEAR_RANGE(900000, 52, 63, 0),
|
||||
@@ -143,7 +143,7 @@ struct bcm590xx_info {
|
||||
u8 n_voltages;
|
||||
const unsigned int *volt_table;
|
||||
u8 n_linear_ranges;
|
||||
const struct regulator_linear_range *linear_ranges;
|
||||
const struct linear_range *linear_ranges;
|
||||
};
|
||||
|
||||
#define BCM590XX_REG_TABLE(_name, _table) \
|
||||
|
||||
@@ -20,22 +20,22 @@
|
||||
#define BUCK_RAMPRATE_125MV 1
|
||||
#define BUCK_RAMP_MAX 250
|
||||
|
||||
static const struct regulator_linear_range bd70528_buck1_volts[] = {
|
||||
static const struct linear_range bd70528_buck1_volts[] = {
|
||||
REGULATOR_LINEAR_RANGE(1200000, 0x00, 0x1, 600000),
|
||||
REGULATOR_LINEAR_RANGE(2750000, 0x2, 0xf, 50000),
|
||||
};
|
||||
static const struct regulator_linear_range bd70528_buck2_volts[] = {
|
||||
static const struct linear_range bd70528_buck2_volts[] = {
|
||||
REGULATOR_LINEAR_RANGE(1200000, 0x00, 0x1, 300000),
|
||||
REGULATOR_LINEAR_RANGE(1550000, 0x2, 0xd, 50000),
|
||||
REGULATOR_LINEAR_RANGE(3000000, 0xe, 0xf, 300000),
|
||||
};
|
||||
static const struct regulator_linear_range bd70528_buck3_volts[] = {
|
||||
static const struct linear_range bd70528_buck3_volts[] = {
|
||||
REGULATOR_LINEAR_RANGE(800000, 0x00, 0xd, 50000),
|
||||
REGULATOR_LINEAR_RANGE(1800000, 0xe, 0xf, 0),
|
||||
};
|
||||
|
||||
/* All LDOs have same voltage ranges */
|
||||
static const struct regulator_linear_range bd70528_ldo_volts[] = {
|
||||
static const struct linear_range bd70528_ldo_volts[] = {
|
||||
REGULATOR_LINEAR_RANGE(1650000, 0x0, 0x07, 50000),
|
||||
REGULATOR_LINEAR_RANGE(2100000, 0x8, 0x0f, 100000),
|
||||
REGULATOR_LINEAR_RANGE(2850000, 0x10, 0x19, 50000),
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user