Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756189AbdIHImH (ORCPT ); Fri, 8 Sep 2017 04:42:07 -0400 Received: from mail-out.m-online.net ([212.18.0.10]:33138 "EHLO mail-out.m-online.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754171AbdIHImF (ORCPT ); Fri, 8 Sep 2017 04:42:05 -0400 X-Auth-Info: F3WPr3iLzVk9/h4Tuh8bH9P77Ix5yS64jQc1lHycfNY= Subject: Re: [PATCH] ASoC: fsl_ssi: Override bit clock rate based on slot number To: Nicolin Chen , broonie@kernel.org Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, alsa-devel@alsa-project.org, tiwai@suse.com, perex@perex.cz, lgirdwood@gmail.com, fabio.estevam@nxp.com, timur@tabi.org, caleb@crome.org, max.krummenacher@toradex.com, arnaud.mouiche@invoxia.com, mpa@pengutronix.de, mail@maciej.szmigiero.name References: <1504848223-3376-1-git-send-email-nicoleotsuka@gmail.com> <20170908054235.GA9603@Asurada-CZ80> From: =?UTF-8?Q?=c5=81ukasz_Majewski?= Organization: DENX Message-ID: <0844824e-ae66-2337-8d58-7bd835f564a2@denx.de> Date: Fri, 8 Sep 2017 10:41:56 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <20170908054235.GA9603@Asurada-CZ80> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1503 Lines: 45 Hi Nicolin, > On Thu, Sep 07, 2017 at 10:23:43PM -0700, Nicolin Chen wrote: >> The set_sysclk() now is used to override the output bit clock rate. >> But this is not a common way to implement a set_dai_sysclk(). And >> this creates a problem when a general machine driver (simple-card >> for example) tries to do set_dai_sysclk() by passing an input clock >> rate for the baud clock instead of setting the bit clock rate as >> fsl_ssi driver expected. >> >> So this patch solves this problem by firstly removing set_sysclk() >> since the hw_params() can calculate the bit clock rate. Secondly, >> in order not to break those TDM use cases which previously might >> have been using set_sysclk() to override the bit clock rate, this >> patch changes the driver to override it based on the slot number. >> >> The patch also removes an obsolete comment of the dir parameter. >> >> Signed-off-by: Nicolin Chen > > Forgot to mention, I think that it's better to wait for a couple of > Tested-by from those who use the TDM mode of SSI before applying it. Although, I'm not the PCM user, I've tested your patch and it works :-) Tested-by: Ɓukasz Majewski Test HW: imx6q + tfa9879 codec > > Thanks > Nicolin > -- Best regards, Lukasz Majewski -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de