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
5f7a0ea9
Commit
5f7a0ea9
authored
Jan 18, 2018
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'asoc/topic/qcom' into asoc-next
parents
b60a0063
96e1b9ee
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
sound/soc/qcom/apq8016_sbc.c
sound/soc/qcom/apq8016_sbc.c
+5
-5
No files found.
sound/soc/qcom/apq8016_sbc.c
View file @
5f7a0ea9
...
...
@@ -43,7 +43,7 @@ struct apq8016_sbc_data {
static
int
apq8016_sbc_dai_init
(
struct
snd_soc_pcm_runtime
*
rtd
)
{
struct
snd_soc_dai
*
cpu_dai
=
rtd
->
cpu_dai
;
struct
snd_soc_co
dec
*
codec
;
struct
snd_soc_co
mponent
*
component
;
struct
snd_soc_dai_link
*
dai_link
=
rtd
->
dai_link
;
struct
snd_soc_card
*
card
=
rtd
->
card
;
struct
apq8016_sbc_data
*
pdata
=
snd_soc_card_get_drvdata
(
card
);
...
...
@@ -92,7 +92,7 @@ static int apq8016_sbc_dai_init(struct snd_soc_pcm_runtime *rtd)
jack
=
pdata
->
jack
.
jack
;
snd_jack_set_key
(
jack
,
SND_JACK_BTN_0
,
KEY_
MEDIA
);
snd_jack_set_key
(
jack
,
SND_JACK_BTN_0
,
KEY_
PLAYPAUSE
);
snd_jack_set_key
(
jack
,
SND_JACK_BTN_1
,
KEY_VOICECOMMAND
);
snd_jack_set_key
(
jack
,
SND_JACK_BTN_2
,
KEY_VOLUMEUP
);
snd_jack_set_key
(
jack
,
SND_JACK_BTN_3
,
KEY_VOLUMEDOWN
);
...
...
@@ -102,15 +102,15 @@ static int apq8016_sbc_dai_init(struct snd_soc_pcm_runtime *rtd)
for
(
i
=
0
;
i
<
dai_link
->
num_codecs
;
i
++
)
{
struct
snd_soc_dai
*
dai
=
rtd
->
codec_dais
[
i
];
co
dec
=
dai
->
codec
;
co
mponent
=
dai
->
component
;
/* Set default mclk for internal codec */
rval
=
snd_soc_co
dec_set_sysclk
(
codec
,
0
,
0
,
DEFAULT_MCLK_RATE
,
rval
=
snd_soc_co
mponent_set_sysclk
(
component
,
0
,
0
,
DEFAULT_MCLK_RATE
,
SND_SOC_CLOCK_IN
);
if
(
rval
!=
0
&&
rval
!=
-
ENOTSUPP
)
{
dev_warn
(
card
->
dev
,
"Failed to set mclk: %d
\n
"
,
rval
);
return
rval
;
}
rval
=
snd_soc_co
dec_set_jack
(
codec
,
&
pdata
->
jack
,
NULL
);
rval
=
snd_soc_co
mponent_set_jack
(
component
,
&
pdata
->
jack
,
NULL
);
if
(
rval
!=
0
&&
rval
!=
-
ENOTSUPP
)
{
dev_warn
(
card
->
dev
,
"Failed to set jack: %d
\n
"
,
rval
);
return
rval
;
...
...
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