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
241ed23c
Commit
241ed23c
authored
Jun 01, 2021
by
Thierry Reding
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'for-5.14/regulator' into for-5.14/soc
parents
6efb943b
380d2b2d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
0 deletions
+24
-0
drivers/regulator/core.c
drivers/regulator/core.c
+23
-0
include/linux/regulator/driver.h
include/linux/regulator/driver.h
+1
-0
No files found.
drivers/regulator/core.c
View file @
241ed23c
...
...
@@ -4105,6 +4105,29 @@ int regulator_set_voltage_time_sel(struct regulator_dev *rdev,
}
EXPORT_SYMBOL_GPL
(
regulator_set_voltage_time_sel
);
int
regulator_sync_voltage_rdev
(
struct
regulator_dev
*
rdev
)
{
int
ret
;
regulator_lock
(
rdev
);
if
(
!
rdev
->
desc
->
ops
->
set_voltage
&&
!
rdev
->
desc
->
ops
->
set_voltage_sel
)
{
ret
=
-
EINVAL
;
goto
out
;
}
/* balance only, if regulator is coupled */
if
(
rdev
->
coupling_desc
.
n_coupled
>
1
)
ret
=
regulator_balance_voltage
(
rdev
,
PM_SUSPEND_ON
);
else
ret
=
-
EOPNOTSUPP
;
out:
regulator_unlock
(
rdev
);
return
ret
;
}
/**
* regulator_sync_voltage - re-apply last regulator output voltage
* @regulator: regulator source
...
...
include/linux/regulator/driver.h
View file @
241ed23c
...
...
@@ -540,6 +540,7 @@ int regulator_set_current_limit_regmap(struct regulator_dev *rdev,
int
regulator_get_current_limit_regmap
(
struct
regulator_dev
*
rdev
);
void
*
regulator_get_init_drvdata
(
struct
regulator_init_data
*
reg_init_data
);
int
regulator_set_ramp_delay_regmap
(
struct
regulator_dev
*
rdev
,
int
ramp_delay
);
int
regulator_sync_voltage_rdev
(
struct
regulator_dev
*
rdev
);
/*
* Helper functions intended to be used by regulator drivers prior registering
...
...
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