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
0af1327b
Commit
0af1327b
authored
Mar 05, 2015
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'asoc/topic/dapm-dt' into asoc-next
parents
1dfcab55
3185878a
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
4 deletions
+23
-4
include/sound/soc.h
include/sound/soc.h
+5
-0
sound/soc/fsl/fsl-asoc-card.c
sound/soc/fsl/fsl-asoc-card.c
+6
-0
sound/soc/soc-core.c
sound/soc/soc-core.c
+12
-4
No files found.
include/sound/soc.h
View file @
0af1327b
...
...
@@ -1071,11 +1071,16 @@ struct snd_soc_card {
/*
* Card-specific routes and widgets.
* Note: of_dapm_xxx for Device Tree; Otherwise for driver build-in.
*/
const
struct
snd_soc_dapm_widget
*
dapm_widgets
;
int
num_dapm_widgets
;
const
struct
snd_soc_dapm_route
*
dapm_routes
;
int
num_dapm_routes
;
const
struct
snd_soc_dapm_widget
*
of_dapm_widgets
;
int
num_of_dapm_widgets
;
const
struct
snd_soc_dapm_route
*
of_dapm_routes
;
int
num_of_dapm_routes
;
bool
fully_routed
;
struct
work_struct
deferred_resume_work
;
...
...
sound/soc/fsl/fsl-asoc-card.c
View file @
0af1327b
...
...
@@ -512,6 +512,12 @@ static int fsl_asoc_card_probe(struct platform_device *pdev)
memcpy
(
priv
->
dai_link
,
fsl_asoc_card_dai
,
sizeof
(
struct
snd_soc_dai_link
)
*
ARRAY_SIZE
(
priv
->
dai_link
));
ret
=
snd_soc_of_parse_audio_routing
(
&
priv
->
card
,
"audio-routing"
);
if
(
ret
)
{
dev_err
(
&
pdev
->
dev
,
"failed to parse audio-routing: %d
\n
"
,
ret
);
goto
asrc_fail
;
}
/* Normal DAI Link */
priv
->
dai_link
[
0
].
cpu_of_node
=
cpu_np
;
priv
->
dai_link
[
0
].
codec_of_node
=
codec_np
;
...
...
sound/soc/soc-core.c
View file @
0af1327b
...
...
@@ -1561,6 +1561,10 @@ static int snd_soc_instantiate_card(struct snd_soc_card *card)
snd_soc_dapm_new_controls
(
&
card
->
dapm
,
card
->
dapm_widgets
,
card
->
num_dapm_widgets
);
if
(
card
->
of_dapm_widgets
)
snd_soc_dapm_new_controls
(
&
card
->
dapm
,
card
->
of_dapm_widgets
,
card
->
num_of_dapm_widgets
);
/* initialise the sound card only once */
if
(
card
->
probe
)
{
ret
=
card
->
probe
(
card
);
...
...
@@ -1616,6 +1620,10 @@ static int snd_soc_instantiate_card(struct snd_soc_card *card)
snd_soc_dapm_add_routes
(
&
card
->
dapm
,
card
->
dapm_routes
,
card
->
num_dapm_routes
);
if
(
card
->
of_dapm_routes
)
snd_soc_dapm_add_routes
(
&
card
->
dapm
,
card
->
of_dapm_routes
,
card
->
num_of_dapm_routes
);
for
(
i
=
0
;
i
<
card
->
num_links
;
i
++
)
{
if
(
card
->
dai_link
[
i
].
dai_fmt
)
snd_soc_runtime_set_dai_fmt
(
&
card
->
rtd
[
i
],
...
...
@@ -3223,8 +3231,8 @@ int snd_soc_of_parse_audio_simple_widgets(struct snd_soc_card *card,
widgets
[
i
].
name
=
wname
;
}
card
->
dapm_widgets
=
widgets
;
card
->
num_dapm_widgets
=
num_widgets
;
card
->
of_
dapm_widgets
=
widgets
;
card
->
num_
of_
dapm_widgets
=
num_widgets
;
return
0
;
}
...
...
@@ -3308,8 +3316,8 @@ int snd_soc_of_parse_audio_routing(struct snd_soc_card *card,
}
}
card
->
num_dapm_routes
=
num_routes
;
card
->
dapm_routes
=
routes
;
card
->
num_
of_
dapm_routes
=
num_routes
;
card
->
of_
dapm_routes
=
routes
;
return
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