From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751673AbbKJHv6 (ORCPT ); Tue, 10 Nov 2015 02:51:58 -0500 Received: from bear.ext.ti.com ([192.94.94.41]:49263 "EHLO bear.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750896AbbKJHv4 (ORCPT ); Tue, 10 Nov 2015 02:51:56 -0500 Subject: Re: [PATCH] ASoC: davinci-mcasp: Fix TDM slot rx/tx mask associations To: Andreas Dannenberg , Liam Girdwood , Mark Brown , Jyri Sarha References: <1447093159-32294-1-git-send-email-dannenberg@ti.com> CC: Misael Lopez Cruz , , , From: Peter Ujfalusi Message-ID: <5641A213.4030508@ti.com> Date: Tue, 10 Nov 2015 09:51:47 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <1447093159-32294-1-git-send-email-dannenberg@ti.com> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/09/2015 08:19 PM, Andreas Dannenberg wrote: > Fixes the associations between the tx_mask and rx_mask and the associated > playback / capture streams during setting of the TDM slot. With this > patch in place it is now possible for example to only populate tx_mask > (leaving rx_mask as 0) for output-only codecs to control the TDM slot(s) > the McASP serial port uses for transmit. Before that, this scenario > would incorrectly rely on the rx_mask for this. > > Signed-off-by: Andreas Dannenberg Acked-by: Peter Ujfalusi > --- > sound/soc/davinci/davinci-mcasp.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/sound/soc/davinci/davinci-mcasp.c b/sound/soc/davinci/davinci-mcasp.c > index 4495a40..caa0beb 100644 > --- a/sound/soc/davinci/davinci-mcasp.c > +++ b/sound/soc/davinci/davinci-mcasp.c > @@ -681,8 +681,8 @@ static int davinci_mcasp_set_tdm_slot(struct snd_soc_dai *dai, > } > > mcasp->tdm_slots = slots; > - mcasp->tdm_mask[SNDRV_PCM_STREAM_PLAYBACK] = rx_mask; > - mcasp->tdm_mask[SNDRV_PCM_STREAM_CAPTURE] = tx_mask; > + mcasp->tdm_mask[SNDRV_PCM_STREAM_PLAYBACK] = tx_mask; > + mcasp->tdm_mask[SNDRV_PCM_STREAM_CAPTURE] = rx_mask; > mcasp->slot_width = slot_width; > > return davinci_mcasp_set_ch_constraints(mcasp); > -- Péter From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Ujfalusi Subject: Re: [PATCH] ASoC: davinci-mcasp: Fix TDM slot rx/tx mask associations Date: Tue, 10 Nov 2015 09:51:47 +0200 Message-ID: <5641A213.4030508@ti.com> References: <1447093159-32294-1-git-send-email-dannenberg@ti.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: In-Reply-To: <1447093159-32294-1-git-send-email-dannenberg@ti.com> Sender: linux-kernel-owner@vger.kernel.org To: Andreas Dannenberg , Liam Girdwood , Mark Brown , Jyri Sarha Cc: Misael Lopez Cruz , alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, linux-omap@vger.kernel.org List-Id: linux-omap@vger.kernel.org On 11/09/2015 08:19 PM, Andreas Dannenberg wrote: > Fixes the associations between the tx_mask and rx_mask and the associ= ated > playback / capture streams during setting of the TDM slot. With this > patch in place it is now possible for example to only populate tx_mas= k > (leaving rx_mask as 0) for output-only codecs to control the TDM slot= (s) > the McASP serial port uses for transmit. Before that, this scenario > would incorrectly rely on the rx_mask for this. >=20 > Signed-off-by: Andreas Dannenberg Acked-by: Peter Ujfalusi > --- > sound/soc/davinci/davinci-mcasp.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) >=20 > diff --git a/sound/soc/davinci/davinci-mcasp.c b/sound/soc/davinci/da= vinci-mcasp.c > index 4495a40..caa0beb 100644 > --- a/sound/soc/davinci/davinci-mcasp.c > +++ b/sound/soc/davinci/davinci-mcasp.c > @@ -681,8 +681,8 @@ static int davinci_mcasp_set_tdm_slot(struct snd_= soc_dai *dai, > } > =20 > mcasp->tdm_slots =3D slots; > - mcasp->tdm_mask[SNDRV_PCM_STREAM_PLAYBACK] =3D rx_mask; > - mcasp->tdm_mask[SNDRV_PCM_STREAM_CAPTURE] =3D tx_mask; > + mcasp->tdm_mask[SNDRV_PCM_STREAM_PLAYBACK] =3D tx_mask; > + mcasp->tdm_mask[SNDRV_PCM_STREAM_CAPTURE] =3D rx_mask; > mcasp->slot_width =3D slot_width; > =20 > return davinci_mcasp_set_ch_constraints(mcasp); >=20 --=20 P=E9ter