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
699f8584
Commit
699f8584
authored
Oct 08, 2014
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'asoc/fix/dapm' into asoc-linus
parents
b9fb7299
e5092c96
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
11 deletions
+14
-11
sound/soc/soc-dapm.c
sound/soc/soc-dapm.c
+14
-11
No files found.
sound/soc/soc-dapm.c
View file @
699f8584
...
...
@@ -592,9 +592,9 @@ static int dapm_create_or_share_mixmux_kcontrol(struct snd_soc_dapm_widget *w,
int
shared
;
struct
snd_kcontrol
*
kcontrol
;
bool
wname_in_long_name
,
kcname_in_long_name
;
char
*
long_name
;
char
*
long_name
=
NULL
;
const
char
*
name
;
int
ret
;
int
ret
=
0
;
prefix
=
soc_dapm_prefix
(
dapm
);
if
(
prefix
)
...
...
@@ -653,15 +653,17 @@ static int dapm_create_or_share_mixmux_kcontrol(struct snd_soc_dapm_widget *w,
kcontrol
=
snd_soc_cnew
(
&
w
->
kcontrol_news
[
kci
],
NULL
,
name
,
prefix
);
kfree
(
long_name
);
if
(
!
kcontrol
)
return
-
ENOMEM
;
if
(
!
kcontrol
)
{
ret
=
-
ENOMEM
;
goto
exit_free
;
}
kcontrol
->
private_free
=
dapm_kcontrol_free
;
ret
=
dapm_kcontrol_data_alloc
(
w
,
kcontrol
);
if
(
ret
)
{
snd_ctl_free_one
(
kcontrol
);
return
ret
;
goto
exit_free
;
}
ret
=
snd_ctl_add
(
card
,
kcontrol
);
...
...
@@ -669,17 +671,18 @@ static int dapm_create_or_share_mixmux_kcontrol(struct snd_soc_dapm_widget *w,
dev_err
(
dapm
->
dev
,
"ASoC: failed to add widget %s dapm kcontrol %s: %d
\n
"
,
w
->
name
,
name
,
ret
);
return
ret
;
goto
exit_free
;
}
}
ret
=
dapm_kcontrol_add_widget
(
kcontrol
,
w
);
if
(
ret
)
return
ret
;
if
(
ret
==
0
)
w
->
kcontrols
[
kci
]
=
kcontrol
;
w
->
kcontrols
[
kci
]
=
kcontrol
;
exit_free:
kfree
(
long_name
);
return
0
;
return
ret
;
}
/* create new dapm mixer control */
...
...
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