alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ASoC: Intel: Skylake: Set sample_type in base config
@ 2019-02-27  6:49 Jenny TC
  2019-02-27 14:45 ` Pierre-Louis Bossart
  0 siblings, 1 reply; 4+ messages in thread
From: Jenny TC @ 2019-02-27  6:49 UTC (permalink / raw)
  To: alsa-devel, Pierre-Louis Bossart, Liam Girdwood, Jie Yang,
	Mark Brown, Jaroslav Kysela, Takashi Iwai, Rakesh Ughreja,
	Sriram Periyasamy, Abhijeet Kumar, Sanyog Kale
  Cc: N Harshapriya, M Naveen, M R Sathya Prakash, jenny.tc,
	Nujella Sathyanarayana

From: Jenny TC <jenny.tc@intel.com>

sample_type defined in topology configuration is not getting reflected
in the dsp param. This patch sets sample_type in base config so that
the sample type defined in the topology is reflected int eh dsp params.
This issues was uncovered while debugging the S24_LE format which
require the MSB byte in 32 bit word to be skipped. Setting sample_type
to 1 helps to fix this.

Signed-off-by: Jenny TC <jenny.tc@intel.com>
---
 sound/soc/intel/skylake/skl-messages.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/intel/skylake/skl-messages.c b/sound/soc/intel/skylake/skl-messages.c
index b0e6fb9..9260e9a 100644
--- a/sound/soc/intel/skylake/skl-messages.c
+++ b/sound/soc/intel/skylake/skl-messages.c
@@ -483,6 +483,7 @@ static void skl_set_base_module_format(struct skl_sst *ctx,
 	base_cfg->audio_fmt.bit_depth = format->bit_depth;
 	base_cfg->audio_fmt.valid_bit_depth = format->valid_bit_depth;
 	base_cfg->audio_fmt.ch_cfg = format->ch_cfg;
+	base_cfg->audio_fmt.sample_type = format->sample_type;
 
 	dev_dbg(ctx->dev, "bit_depth=%x valid_bd=%x ch_config=%x\n",
 			format->bit_depth, format->valid_bit_depth,
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] ASoC: Intel: Skylake: Set sample_type in base config
@ 2019-02-27  7:04 Jenny TC
  0 siblings, 0 replies; 4+ messages in thread
From: Jenny TC @ 2019-02-27  7:04 UTC (permalink / raw)
  To: alsa-devel, Pierre-Louis Bossart, Liam Girdwood, Jie Yang,
	Mark Brown, Jaroslav Kysela, Takashi Iwai, Rakesh Ughreja,
	Sriram Periyasamy, Abhijeet Kumar, Sanyog Kale
  Cc: N Harshapriya, M Naveen, M R Sathya Prakash, jenny.tc,
	Nujella Sathyanarayana

sample_type defined in topology configuration is not getting reflected
in the dsp param. This patch sets sample_type in base config so that
the sample type defined in the topology is reflected int eh dsp params.
This issues was uncovered while debugging the S24_LE format which
require the MSB byte in 32 bit word to be skipped. Setting sample_type
to 1 helps to fix this.

Signed-off-by: Jenny TC <jenny.tc@intel.com>
---
 sound/soc/intel/skylake/skl-messages.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/intel/skylake/skl-messages.c b/sound/soc/intel/skylake/skl-messages.c
index b0e6fb9..9260e9a 100644
--- a/sound/soc/intel/skylake/skl-messages.c
+++ b/sound/soc/intel/skylake/skl-messages.c
@@ -483,6 +483,7 @@ static void skl_set_base_module_format(struct skl_sst *ctx,
 	base_cfg->audio_fmt.bit_depth = format->bit_depth;
 	base_cfg->audio_fmt.valid_bit_depth = format->valid_bit_depth;
 	base_cfg->audio_fmt.ch_cfg = format->ch_cfg;
+	base_cfg->audio_fmt.sample_type = format->sample_type;
 
 	dev_dbg(ctx->dev, "bit_depth=%x valid_bd=%x ch_config=%x\n",
 			format->bit_depth, format->valid_bit_depth,
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] ASoC: Intel: Skylake: Set sample_type in base config
  2019-02-27  6:49 Jenny TC
@ 2019-02-27 14:45 ` Pierre-Louis Bossart
  2019-02-28  4:19   ` Tc, Jenny
  0 siblings, 1 reply; 4+ messages in thread
From: Pierre-Louis Bossart @ 2019-02-27 14:45 UTC (permalink / raw)
  To: Jenny TC, alsa-devel, Liam Girdwood, Jie Yang, Mark Brown,
	Jaroslav Kysela, Takashi Iwai, Rakesh Ughreja, Sriram Periyasamy,
	Abhijeet Kumar, Sanyog Kale
  Cc: N Harshapriya, M Naveen, M R Sathya Prakash, jenny.tc,
	Nujella Sathyanarayana


On 2/27/19 12:49 AM, Jenny TC wrote:
> From: Jenny TC <jenny.tc@intel.com>
>
> sample_type defined in topology configuration is not getting reflected
> in the dsp param. This patch sets sample_type in base config so that
> the sample type defined in the topology is reflected int eh dsp params.
> This issues was uncovered while debugging the S24_LE format which
> require the MSB byte in 32 bit word to be skipped. Setting sample_type
> to 1 helps to fix this.

skl_set_base_module_format() is called from a variety of places, so am I correct in stating that S24_LE never worked with this driver? If so, the patch should really be titled "ASoC: Intel: Skylake: enable S24_LE format support"

Also your commit message is confusing in the last sentence. What do you mean by "Setting sample_type to " when you only use what's provided by the topology?

>
> Signed-off-by: Jenny TC <jenny.tc@intel.com>
> ---
>   sound/soc/intel/skylake/skl-messages.c | 1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/sound/soc/intel/skylake/skl-messages.c b/sound/soc/intel/skylake/skl-messages.c
> index b0e6fb9..9260e9a 100644
> --- a/sound/soc/intel/skylake/skl-messages.c
> +++ b/sound/soc/intel/skylake/skl-messages.c
> @@ -483,6 +483,7 @@ static void skl_set_base_module_format(struct skl_sst *ctx,
>   	base_cfg->audio_fmt.bit_depth = format->bit_depth;
>   	base_cfg->audio_fmt.valid_bit_depth = format->valid_bit_depth;
>   	base_cfg->audio_fmt.ch_cfg = format->ch_cfg;
> +	base_cfg->audio_fmt.sample_type = format->sample_type;
>   
>   	dev_dbg(ctx->dev, "bit_depth=%x valid_bd=%x ch_config=%x\n",
>   			format->bit_depth, format->valid_bit_depth,

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] ASoC: Intel: Skylake: Set sample_type in base config
  2019-02-27 14:45 ` Pierre-Louis Bossart
@ 2019-02-28  4:19   ` Tc, Jenny
  0 siblings, 0 replies; 4+ messages in thread
From: Tc, Jenny @ 2019-02-28  4:19 UTC (permalink / raw)
  To: Pierre-Louis Bossart, Jenny TC, alsa-devel@alsa-project.org,
	Liam Girdwood, Jie Yang, Mark Brown, Jaroslav Kysela,
	Takashi Iwai, Ughreja, Rakesh A, Periyasamy, SriramX,
	Kumar, Abhijeet, Kale, Sanyog R
  Cc: N, Harshapriya, M, Naveen, M R, Sathya Prakash,
	Nujella, Sathyanarayana



>>sample_type defined in topology configuration is not getting reflected
>>in the dsp param. This patch sets sample_type in base config so that
>>the sample type defined in the topology is reflected int eh dsp params.
>>This issues was uncovered while debugging the S24_LE format which
>>require the MSB byte in 32 bit word to be skipped. Setting sample_type
>>to 1 helps to fix this.
>skl_set_base_module_format() is called from a variety of places, so am I correct in stating that S24_LE never worked with this driver? If so, the patch should really be titled "ASoC: Intel: Skylake: enable S24_LE format >support"

Yes, S24_LE is being enabled for first time, I'll update the title

>Also your commit message is confusing in the last sentence. What do you mean by "Setting sample_type to " when you only use what's provided by the topology?

Yes, setting sample type to 1 in topology firmware helps to fix this. I'll update the commit message to make it clear.

Signed-off-by: Jenny TC <jenny.tc@intel.com>
---
 sound/soc/intel/skylake/skl-messages.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/intel/skylake/skl-messages.c b/sound/soc/intel/skylake/skl-messages.c
index b0e6fb9..9260e9a 100644
--- a/sound/soc/intel/skylake/skl-messages.c
+++ b/sound/soc/intel/skylake/skl-messages.c
@@ -483,6 +483,7 @@ static void skl_set_base_module_format(struct skl_sst *ctx,
 	base_cfg->audio_fmt.bit_depth = format->bit_depth;
 	base_cfg->audio_fmt.valid_bit_depth = format->valid_bit_depth;
 	base_cfg->audio_fmt.ch_cfg = format->ch_cfg;
+	base_cfg->audio_fmt.sample_type = format->sample_type;
 
 	dev_dbg(ctx->dev, "bit_depth=%x valid_bd=%x ch_config=%x\n",
 			format->bit_depth, format->valid_bit_depth,

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-02-28  4:19 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-27  7:04 [PATCH] ASoC: Intel: Skylake: Set sample_type in base config Jenny TC
  -- strict thread matches above, loose matches on Subject: below --
2019-02-27  6:49 Jenny TC
2019-02-27 14:45 ` Pierre-Louis Bossart
2019-02-28  4:19   ` Tc, Jenny

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).