Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
d440c4ef
Commit
d440c4ef
authored
Sep 11, 2019
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'regulator-5.3' into regulator-linus
parents
f74c2bb9
3829100a
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
9 deletions
+26
-9
drivers/regulator/act8945a-regulator.c
drivers/regulator/act8945a-regulator.c
+4
-4
drivers/regulator/slg51000-regulator.c
drivers/regulator/slg51000-regulator.c
+2
-2
drivers/regulator/twl-regulator.c
drivers/regulator/twl-regulator.c
+20
-3
No files found.
drivers/regulator/act8945a-regulator.c
View file @
d440c4ef
...
...
@@ -169,16 +169,16 @@ static int act8945a_set_mode(struct regulator_dev *rdev, unsigned int mode)
reg
=
ACT8945A_DCDC3_CTRL
;
break
;
case
ACT8945A_ID_LDO1
:
reg
=
ACT8945A_LDO1_
SUS
;
reg
=
ACT8945A_LDO1_
CTRL
;
break
;
case
ACT8945A_ID_LDO2
:
reg
=
ACT8945A_LDO2_
SUS
;
reg
=
ACT8945A_LDO2_
CTRL
;
break
;
case
ACT8945A_ID_LDO3
:
reg
=
ACT8945A_LDO3_
SUS
;
reg
=
ACT8945A_LDO3_
CTRL
;
break
;
case
ACT8945A_ID_LDO4
:
reg
=
ACT8945A_LDO4_
SUS
;
reg
=
ACT8945A_LDO4_
CTRL
;
break
;
default:
return
-
EINVAL
;
...
...
drivers/regulator/slg51000-regulator.c
View file @
d440c4ef
...
...
@@ -205,7 +205,7 @@ static int slg51000_of_parse_cb(struct device_node *np,
ena_gpiod
=
devm_gpiod_get_from_of_node
(
chip
->
dev
,
np
,
"enable-gpios"
,
0
,
gflags
,
"gpio-en-ldo"
);
if
(
ena_gpiod
)
{
if
(
!
IS_ERR
(
ena_gpiod
)
)
{
config
->
ena_gpiod
=
ena_gpiod
;
devm_gpiod_unhinge
(
chip
->
dev
,
config
->
ena_gpiod
);
}
...
...
@@ -459,7 +459,7 @@ static int slg51000_i2c_probe(struct i2c_client *client,
GPIOD_OUT_HIGH
|
GPIOD_FLAGS_BIT_NONEXCLUSIVE
,
"slg51000-cs"
);
if
(
cs_gpiod
)
{
if
(
!
IS_ERR
(
cs_gpiod
)
)
{
dev_info
(
dev
,
"Found chip selector property
\n
"
);
chip
->
cs_gpiod
=
cs_gpiod
;
}
...
...
drivers/regulator/twl-regulator.c
View file @
d440c4ef
...
...
@@ -359,6 +359,17 @@ static const u16 VINTANA2_VSEL_table[] = {
2500
,
2750
,
};
/* 600mV to 1450mV in 12.5 mV steps */
static
const
struct
regulator_linear_range
VDD1_ranges
[]
=
{
REGULATOR_LINEAR_RANGE
(
600000
,
0
,
68
,
12500
)
};
/* 600mV to 1450mV in 12.5 mV steps, everything above = 1500mV */
static
const
struct
regulator_linear_range
VDD2_ranges
[]
=
{
REGULATOR_LINEAR_RANGE
(
600000
,
0
,
68
,
12500
),
REGULATOR_LINEAR_RANGE
(
1500000
,
69
,
69
,
12500
)
};
static
int
twl4030ldo_list_voltage
(
struct
regulator_dev
*
rdev
,
unsigned
index
)
{
struct
twlreg_info
*
info
=
rdev_get_drvdata
(
rdev
);
...
...
@@ -427,6 +438,8 @@ static int twl4030smps_get_voltage(struct regulator_dev *rdev)
}
static
const
struct
regulator_ops
twl4030smps_ops
=
{
.
list_voltage
=
regulator_list_voltage_linear_range
,
.
set_voltage
=
twl4030smps_set_voltage
,
.
get_voltage
=
twl4030smps_get_voltage
,
};
...
...
@@ -466,7 +479,8 @@ static const struct twlreg_info TWL4030_INFO_##label = { \
}, \
}
#define TWL4030_ADJUSTABLE_SMPS(label, offset, num, turnon_delay, remap_conf) \
#define TWL4030_ADJUSTABLE_SMPS(label, offset, num, turnon_delay, remap_conf, \
n_volt) \
static const struct twlreg_info TWL4030_INFO_##label = { \
.base = offset, \
.id = num, \
...
...
@@ -479,6 +493,9 @@ static const struct twlreg_info TWL4030_INFO_##label = { \
.owner = THIS_MODULE, \
.enable_time = turnon_delay, \
.of_map_mode = twl4030reg_map_mode, \
.n_voltages = n_volt, \
.n_linear_ranges = ARRAY_SIZE(label ## _ranges), \
.linear_ranges = label ## _ranges, \
}, \
}
...
...
@@ -518,8 +535,8 @@ TWL4030_ADJUSTABLE_LDO(VSIM, 0x37, 9, 100, 0x00);
TWL4030_ADJUSTABLE_LDO
(
VDAC
,
0x3b
,
10
,
100
,
0x08
);
TWL4030_ADJUSTABLE_LDO
(
VINTANA2
,
0x43
,
12
,
100
,
0x08
);
TWL4030_ADJUSTABLE_LDO
(
VIO
,
0x4b
,
14
,
1000
,
0x08
);
TWL4030_ADJUSTABLE_SMPS
(
VDD1
,
0x55
,
15
,
1000
,
0x08
);
TWL4030_ADJUSTABLE_SMPS
(
VDD2
,
0x63
,
16
,
1000
,
0x08
);
TWL4030_ADJUSTABLE_SMPS
(
VDD1
,
0x55
,
15
,
1000
,
0x08
,
68
);
TWL4030_ADJUSTABLE_SMPS
(
VDD2
,
0x63
,
16
,
1000
,
0x08
,
69
);
/* VUSBCP is managed *only* by the USB subchip */
TWL4030_FIXED_LDO
(
VINTANA1
,
0x3f
,
1500
,
11
,
100
,
0x08
);
TWL4030_FIXED_LDO
(
VINTDIG
,
0x47
,
1500
,
13
,
100
,
0x08
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment