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
54b019cb
Commit
54b019cb
authored
Apr 12, 2013
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'asoc/topic/compress' into asoc-next
parents
13419625
0cd5751a
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
1 deletion
+40
-1
sound/soc/mid-x86/sst_platform.c
sound/soc/mid-x86/sst_platform.c
+11
-1
sound/soc/mid-x86/sst_platform.h
sound/soc/mid-x86/sst_platform.h
+2
-0
sound/soc/soc-compress.c
sound/soc/soc-compress.c
+27
-0
No files found.
sound/soc/mid-x86/sst_platform.c
View file @
54b019cb
/*
* sst_platform.c - Intel MID Platform driver
*
* Copyright (C) 2010-201
2
Intel Corp
* Copyright (C) 2010-201
3
Intel Corp
* Author: Vinod Koul <vinod.koul@intel.com>
* Author: Harsha Priya <priya.harsha@intel.com>
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
...
...
@@ -656,11 +656,21 @@ static int sst_platform_compr_get_codec_caps(struct snd_compr_stream *cstream,
return
stream
->
compr_ops
->
get_codec_caps
(
codec
);
}
static
int
sst_platform_compr_set_metadata
(
struct
snd_compr_stream
*
cstream
,
struct
snd_compr_metadata
*
metadata
)
{
struct
sst_runtime_stream
*
stream
=
cstream
->
runtime
->
private_data
;
return
stream
->
compr_ops
->
set_metadata
(
stream
->
id
,
metadata
);
}
static
struct
snd_compr_ops
sst_platform_compr_ops
=
{
.
open
=
sst_platform_compr_open
,
.
free
=
sst_platform_compr_free
,
.
set_params
=
sst_platform_compr_set_params
,
.
set_metadata
=
sst_platform_compr_set_metadata
,
.
trigger
=
sst_platform_compr_trigger
,
.
pointer
=
sst_platform_compr_pointer
,
.
ack
=
sst_platform_compr_ack
,
...
...
sound/soc/mid-x86/sst_platform.h
View file @
54b019cb
...
...
@@ -124,6 +124,8 @@ struct compress_sst_ops {
int
(
*
close
)
(
unsigned
int
str_id
);
int
(
*
get_caps
)
(
struct
snd_compr_caps
*
caps
);
int
(
*
get_codec_caps
)
(
struct
snd_compr_codec_caps
*
codec
);
int
(
*
set_metadata
)
(
unsigned
int
str_id
,
struct
snd_compr_metadata
*
mdata
);
};
...
...
sound/soc/soc-compress.c
View file @
54b019cb
...
...
@@ -330,11 +330,38 @@ static int soc_compr_copy(struct snd_compr_stream *cstream,
return
ret
;
}
static
int
sst_compr_set_metadata
(
struct
snd_compr_stream
*
cstream
,
struct
snd_compr_metadata
*
metadata
)
{
struct
snd_soc_pcm_runtime
*
rtd
=
cstream
->
private_data
;
struct
snd_soc_platform
*
platform
=
rtd
->
platform
;
int
ret
=
0
;
if
(
platform
->
driver
->
compr_ops
&&
platform
->
driver
->
compr_ops
->
set_metadata
)
ret
=
platform
->
driver
->
compr_ops
->
set_metadata
(
cstream
,
metadata
);
return
ret
;
}
static
int
sst_compr_get_metadata
(
struct
snd_compr_stream
*
cstream
,
struct
snd_compr_metadata
*
metadata
)
{
struct
snd_soc_pcm_runtime
*
rtd
=
cstream
->
private_data
;
struct
snd_soc_platform
*
platform
=
rtd
->
platform
;
int
ret
=
0
;
if
(
platform
->
driver
->
compr_ops
&&
platform
->
driver
->
compr_ops
->
get_metadata
)
ret
=
platform
->
driver
->
compr_ops
->
get_metadata
(
cstream
,
metadata
);
return
ret
;
}
/* ASoC Compress operations */
static
struct
snd_compr_ops
soc_compr_ops
=
{
.
open
=
soc_compr_open
,
.
free
=
soc_compr_free
,
.
set_params
=
soc_compr_set_params
,
.
set_metadata
=
sst_compr_set_metadata
,
.
get_metadata
=
sst_compr_get_metadata
,
.
get_params
=
soc_compr_get_params
,
.
trigger
=
soc_compr_trigger
,
.
pointer
=
soc_compr_pointer
,
...
...
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