Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Maxime Ripard <mripard@kernel.org>
To: codekipper@gmail.com
Cc: alsa-devel@alsa-project.org, linux-sunxi@googlegroups.com,
	linux-kernel@vger.kernel.org, lgirdwood@gmail.com,
	be17068@iperbole.bo.it, wens@csie.org, broonie@kernel.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v6 3/3] ASoC: sun4i-i2s: Adjust LRCLK width
Date: Tue, 27 Aug 2019 09:01:01 +0200	[thread overview]
Message-ID: <20190827070101.tastgcqvzrgv3kc5@flea> (raw)
In-Reply-To: <20190826180734.15801-4-codekipper@gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 1176 bytes --]

On Mon, Aug 26, 2019 at 08:07:34PM +0200, codekipper@gmail.com wrote:
> From: Marcus Cooper <codekipper@gmail.com>
>
> Some codecs such as i2s based HDMI audio and the Pine64 DAC require
> a different amount of bit clocks per frame than what is calculated
> by the sample width. Use the values obtained by the tdm slot bindings
> to adjust the LRCLK width accordingly.
>
> Signed-off-by: Marcus Cooper <codekipper@gmail.com>
> ---
>  sound/soc/sunxi/sun4i-i2s.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/sound/soc/sunxi/sun4i-i2s.c b/sound/soc/sunxi/sun4i-i2s.c
> index 056a299c03fb..0965a97c96e5 100644
> --- a/sound/soc/sunxi/sun4i-i2s.c
> +++ b/sound/soc/sunxi/sun4i-i2s.c
> @@ -455,7 +455,10 @@ static int sun8i_i2s_set_chan_cfg(const struct sun4i_i2s *i2s,
>  		break;
>
>  	case SND_SOC_DAIFMT_I2S:
> -		lrck_period = params_physical_width(params);
> +		if (i2s->slot_width)
> +			lrck_period = i2s->slot_width;
> +		else
> +			lrck_period = params_physical_width(params);
>  		break;

That would be the case with the DSP formats too, right?

Maxime

--
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

[-- Attachment #2: Type: text/plain, Size: 176 bytes --]

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2019-08-27  7:01 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-26 18:07 [PATCH v6 0/3] ASoC: sun4i-i2s: Updates to the driver codekipper
2019-08-26 18:07 ` [PATCH v6 1/3] ASoC: sun4i-i2s: incorrect regmap for A83T codekipper
2019-08-27  4:13   ` [linux-sunxi] " Chen-Yu Tsai
2019-08-27  5:54     ` Code Kipper
2019-08-27  8:01       ` Chen-Yu Tsai
2019-08-27  8:35         ` Code Kipper
2019-08-27 10:28           ` Chen-Yu Tsai
2019-08-26 18:07 ` [PATCH v6 2/3] ASoC: sun4i-i2s: Add regmap field to sign extend sample codekipper
2019-08-27  9:34   ` Maxime Ripard
2019-08-27 10:55     ` Code Kipper
2019-08-26 18:07 ` [PATCH v6 3/3] ASoC: sun4i-i2s: Adjust LRCLK width codekipper
2019-08-27  7:01   ` Maxime Ripard [this message]
2019-08-27  8:36     ` Code Kipper

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190827070101.tastgcqvzrgv3kc5@flea \
    --to=mripard@kernel.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=be17068@iperbole.bo.it \
    --cc=broonie@kernel.org \
    --cc=codekipper@gmail.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sunxi@googlegroups.com \
    --cc=wens@csie.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox