提交 d7b54c30 编写于 作者: V Vinod Koul 提交者: Mark Brown

ASoC: Intel: remove codec memeber from codec structs

As we already have a memeber struct snd_sst_params.codec to fill this.
so removing duplicate instance
Signed-off-by: NVinod Koul <vinod.koul@intel.com>
Acked-by: NLiam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: NMark Brown <broonie@linaro.org>
上级 bd17aa45
...@@ -36,7 +36,6 @@ enum stream_type { ...@@ -36,7 +36,6 @@ enum stream_type {
}; };
struct snd_pcm_params { struct snd_pcm_params {
u16 codec; /* codec type */
u8 num_chan; /* 1=Mono, 2=Stereo */ u8 num_chan; /* 1=Mono, 2=Stereo */
u8 pcm_wd_sz; /* 16/24 - bit*/ u8 pcm_wd_sz; /* 16/24 - bit*/
u32 reserved; /* Bitrate in bits per second */ u32 reserved; /* Bitrate in bits per second */
...@@ -49,7 +48,6 @@ struct snd_pcm_params { ...@@ -49,7 +48,6 @@ struct snd_pcm_params {
/* MP3 Music Parameters Message */ /* MP3 Music Parameters Message */
struct snd_mp3_params { struct snd_mp3_params {
u16 codec;
u8 num_chan; /* 1=Mono, 2=Stereo */ u8 num_chan; /* 1=Mono, 2=Stereo */
u8 pcm_wd_sz; /* 16/24 - bit*/ u8 pcm_wd_sz; /* 16/24 - bit*/
u8 crc_check; /* crc_check - disable (0) or enable (1) */ u8 crc_check; /* crc_check - disable (0) or enable (1) */
...@@ -63,7 +61,6 @@ struct snd_mp3_params { ...@@ -63,7 +61,6 @@ struct snd_mp3_params {
/* AAC Music Parameters Message */ /* AAC Music Parameters Message */
struct snd_aac_params { struct snd_aac_params {
u16 codec;
u8 num_chan; /* 1=Mono, 2=Stereo*/ u8 num_chan; /* 1=Mono, 2=Stereo*/
u8 pcm_wd_sz; /* 16/24 - bit*/ u8 pcm_wd_sz; /* 16/24 - bit*/
u8 bdownsample; /*SBR downsampling 0 - disable 1 -enabled AAC+ only */ u8 bdownsample; /*SBR downsampling 0 - disable 1 -enabled AAC+ only */
...@@ -77,7 +74,6 @@ struct snd_aac_params { ...@@ -77,7 +74,6 @@ struct snd_aac_params {
/* WMA Music Parameters Message */ /* WMA Music Parameters Message */
struct snd_wma_params { struct snd_wma_params {
u16 codec;
u8 num_chan; /* 1=Mono, 2=Stereo */ u8 num_chan; /* 1=Mono, 2=Stereo */
u8 pcm_wd_sz; /* 16/24 - bit*/ u8 pcm_wd_sz; /* 16/24 - bit*/
u32 brate; /* Use the hard coded value. */ u32 brate; /* Use the hard coded value. */
......
...@@ -112,7 +112,6 @@ static int sst_platform_compr_set_params(struct snd_compr_stream *cstream, ...@@ -112,7 +112,6 @@ static int sst_platform_compr_set_params(struct snd_compr_stream *cstream,
switch (params->codec.id) { switch (params->codec.id) {
case SND_AUDIOCODEC_MP3: { case SND_AUDIOCODEC_MP3: {
str_params.codec = SST_CODEC_TYPE_MP3; str_params.codec = SST_CODEC_TYPE_MP3;
str_params.sparams.uc.mp3_params.codec = SST_CODEC_TYPE_MP3;
str_params.sparams.uc.mp3_params.num_chan = params->codec.ch_in; str_params.sparams.uc.mp3_params.num_chan = params->codec.ch_in;
str_params.sparams.uc.mp3_params.pcm_wd_sz = 16; str_params.sparams.uc.mp3_params.pcm_wd_sz = 16;
break; break;
...@@ -120,7 +119,6 @@ static int sst_platform_compr_set_params(struct snd_compr_stream *cstream, ...@@ -120,7 +119,6 @@ static int sst_platform_compr_set_params(struct snd_compr_stream *cstream,
case SND_AUDIOCODEC_AAC: { case SND_AUDIOCODEC_AAC: {
str_params.codec = SST_CODEC_TYPE_AAC; str_params.codec = SST_CODEC_TYPE_AAC;
str_params.sparams.uc.aac_params.codec = SST_CODEC_TYPE_AAC;
str_params.sparams.uc.aac_params.num_chan = params->codec.ch_in; str_params.sparams.uc.aac_params.num_chan = params->codec.ch_in;
str_params.sparams.uc.aac_params.pcm_wd_sz = 16; str_params.sparams.uc.aac_params.pcm_wd_sz = 16;
if (params->codec.format == SND_AUDIOSTREAMFORMAT_MP4ADTS) if (params->codec.format == SND_AUDIOSTREAMFORMAT_MP4ADTS)
......
...@@ -147,7 +147,6 @@ static void sst_fill_pcm_params(struct snd_pcm_substream *substream, ...@@ -147,7 +147,6 @@ static void sst_fill_pcm_params(struct snd_pcm_substream *substream,
struct sst_pcm_params *param) struct sst_pcm_params *param)
{ {
param->codec = SST_CODEC_TYPE_PCM;
param->num_chan = (u8) substream->runtime->channels; param->num_chan = (u8) substream->runtime->channels;
param->pcm_wd_sz = substream->runtime->sample_bits; param->pcm_wd_sz = substream->runtime->sample_bits;
param->reserved = 0; param->reserved = 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册