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
nexedi
linux
Commits
24e0c57b
Commit
24e0c57b
authored
Jan 21, 2012
by
Mark Brown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ASoC: wm8996: Use devm_regulator_bulk_get()
Signed-off-by:
Mark Brown
<
broonie@opensource.wolfsonmicro.com
>
parent
4a086e4c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
6 deletions
+3
-6
sound/soc/codecs/wm8996.c
sound/soc/codecs/wm8996.c
+3
-6
No files found.
sound/soc/codecs/wm8996.c
View file @
24e0c57b
...
...
@@ -3153,8 +3153,8 @@ static __devinit int wm8996_i2c_probe(struct i2c_client *i2c,
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
wm8996
->
supplies
);
i
++
)
wm8996
->
supplies
[
i
].
supply
=
wm8996_supply_names
[
i
];
ret
=
regulator_bulk_get
(
&
i2c
->
dev
,
ARRAY_SIZE
(
wm8996
->
supplies
),
wm8996
->
supplies
);
ret
=
devm_
regulator_bulk_get
(
&
i2c
->
dev
,
ARRAY_SIZE
(
wm8996
->
supplies
),
wm8996
->
supplies
);
if
(
ret
!=
0
)
{
dev_err
(
&
i2c
->
dev
,
"Failed to request supplies: %d
\n
"
,
ret
);
goto
err_gpio
;
...
...
@@ -3164,7 +3164,7 @@ static __devinit int wm8996_i2c_probe(struct i2c_client *i2c,
wm8996
->
supplies
);
if
(
ret
!=
0
)
{
dev_err
(
&
i2c
->
dev
,
"Failed to enable supplies: %d
\n
"
,
ret
);
goto
err_g
et
;
goto
err_g
pio
;
}
if
(
wm8996
->
pdata
.
ldo_ena
>
0
)
{
...
...
@@ -3226,8 +3226,6 @@ static __devinit int wm8996_i2c_probe(struct i2c_client *i2c,
if
(
wm8996
->
pdata
.
ldo_ena
>
0
)
gpio_set_value_cansleep
(
wm8996
->
pdata
.
ldo_ena
,
0
);
regulator_bulk_disable
(
ARRAY_SIZE
(
wm8996
->
supplies
),
wm8996
->
supplies
);
err_get:
regulator_bulk_free
(
ARRAY_SIZE
(
wm8996
->
supplies
),
wm8996
->
supplies
);
err_gpio:
if
(
wm8996
->
pdata
.
ldo_ena
>
0
)
gpio_free
(
wm8996
->
pdata
.
ldo_ena
);
...
...
@@ -3242,7 +3240,6 @@ static __devexit int wm8996_i2c_remove(struct i2c_client *client)
snd_soc_unregister_codec
(
&
client
->
dev
);
wm8996_free_gpio
(
wm8996
);
regulator_bulk_free
(
ARRAY_SIZE
(
wm8996
->
supplies
),
wm8996
->
supplies
);
regmap_exit
(
wm8996
->
regmap
);
if
(
wm8996
->
pdata
.
ldo_ena
>
0
)
{
gpio_set_value_cansleep
(
wm8996
->
pdata
.
ldo_ena
,
0
);
...
...
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