Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp2131437iob; Fri, 20 May 2022 02:45:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxHgLa899xaE3K7iEL51jLWXCdFczEP99DO2DEuYqUCTtGa0K2Myy2E6hA9zt428dfaYaiX X-Received: by 2002:a17:907:7815:b0:6ce:5242:1280 with SMTP id la21-20020a170907781500b006ce52421280mr7938335ejc.217.1653039918733; Fri, 20 May 2022 02:45:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653039918; cv=none; d=google.com; s=arc-20160816; b=Z6rxblEsQSZgxxk8Z047UJQIfHOSTUYHUFvLmRQLa4qJPwc85j5qWXZmTkjV7eeIe8 hzOjtx1Z6TO6x7tFUakttOL5tTGme3E/F5rgKP/glLlyFh4AjQee1gZL/aZHBYBuoOR8 O/IfbnzmJF6nbRKyaQuBOL6gs5WsgV8RIQy7jNBNsS6R6eZLrJeJM6tdeg5+DdZPdRoR ItgpjE+fbMRHUo2t8+NycnwQB83I6St/bjg1yv+TxOLaAj72L+7hC5s/f+nhsn7e8X16 1rq2CWFT8rw+yqcqev2mTOLnlfu7vbL6MNcafowzWIVDCbEKZh/q/eoUPKrrIMYGkhyP PdOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=u0w8abIetG2abMfdqOSd7Y82vyjnsYTVbT2dM/SJUnQ=; b=Ie/C3lYIAZcXawUsU9b7ppbHO2jj99AlkUnKL9atWny+6dxT4KQQskKTE77q9S85BK hJBoAUyOeS5XF4y6mRVkjSq1kvEWvRL1+iocwMho2s3v7VtMDMsKjS/ds36aiUQgV65X yn12hsD31wM+c2Ft9ftmlUfUxF62LviNKy4zgmJ63H+JvNY0mKwjlacYxZH9KDXnPEPe 3wunwZmRnOg6ATL3Lq+HH3th18h+O0WimF5cvACJWSlPWFXTsAolrSQISCc3WTl0aCHU 5Xqtjej128rhLZPfCnuNpdcCGZL6SJyLGUFYWZCaD2AKieJjFc+Amj6nqCaFE+onAzHQ 8pUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=kqyqe4kq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qf20-20020a1709077f1400b006f3a0afcfd8si9454844ejc.133.2022.05.20.02.44.51; Fri, 20 May 2022 02:45:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=kqyqe4kq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238670AbiESNXT (ORCPT + 99 others); Thu, 19 May 2022 09:23:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35030 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235367AbiESNXQ (ORCPT ); Thu, 19 May 2022 09:23:16 -0400 Received: from mail-ej1-x62f.google.com (mail-ej1-x62f.google.com [IPv6:2a00:1450:4864:20::62f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C9CFC7A835 for ; Thu, 19 May 2022 06:23:15 -0700 (PDT) Received: by mail-ej1-x62f.google.com with SMTP id ch13so9870247ejb.12 for ; Thu, 19 May 2022 06:23:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=u0w8abIetG2abMfdqOSd7Y82vyjnsYTVbT2dM/SJUnQ=; b=kqyqe4kqxe8fIM4wT/Lk+TKu3gZPfVVJL7C4awAbF1WarDBgMnhX/jTNZMl/vxTt85 O+Z6wBabc4+ZNCx8n0IHE9REoVXdCMvPJlFCnZZYhFj1hzZxP+8mcqFOUhlVZbDAzPre Kc/q7pYmg1xfxtbb3BFBaHJS52S/wJHPIZsXAseZ8vOuQdzGf7Q8TolTfts249OnHSX2 Zvvj5lEJ4vqVz5G0WslC0SbW4MlQrCVSSX7e6+KrAampo/iIcwlgZWo1YulA6XmleJ2q lrwd2wIj2hyi5kx1AWJ3qxAkGhNfEyLpl2qlX5PGPoPvv92sBJrzSyZNuz9JxC/w48oG d3fg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=u0w8abIetG2abMfdqOSd7Y82vyjnsYTVbT2dM/SJUnQ=; b=G1c5LmAYiF3DmPFr4IPPlsEwucUrwb6WX4iCrIvjrN1kBdl6oZZiogjvhcffwnl6jR 8cHrLo0v5CJxjZ3Vm9phn0nVZ+ql36awu5/ebnwPS2DdjS5SA8k1U5QgL9Ry+rCgM0kY /WpJwhSXPAbV+lRVEVMBOMgqUa5Gh58vSabM/wzvSvNcHq1ebk1zfsZj2N93v2scMgsk 5zr5y3BpaQu+M3GxR9LcmAlhBsN/gfFJ/cuBgIKkUvMn7sVBKfzWB6qcNMaK/mUZi2I4 G4AOFwpKUdnLdEaGpwffTzjFOEZI9j1oAxceSeXDLPtzUcw4fzTNYxO9/0nkn0ceJAtU +gjA== X-Gm-Message-State: AOAM533xAd1hukFErm0gv/B3wMf1qAaySDkJfa0bpxCrjNgAzw6kGAOu Rn6Y8y8tqt/h+ONfUYoQJMZQf3ahS17w8HIjIw4= X-Received: by 2002:a17:907:7b9f:b0:6f4:d8c5:392c with SMTP id ne31-20020a1709077b9f00b006f4d8c5392cmr4265502ejc.652.1652966594102; Thu, 19 May 2022 06:23:14 -0700 (PDT) MIME-Version: 1.0 References: <1652963808-14515-1-git-send-email-shengjiu.wang@nxp.com> In-Reply-To: <1652963808-14515-1-git-send-email-shengjiu.wang@nxp.com> From: Fabio Estevam Date: Thu, 19 May 2022 10:23:06 -0300 Message-ID: Subject: Re: [PATCH] ASoC: fsl_sai: Enable MCTL_MCLK_EN bit for master mode To: Shengjiu Wang Cc: Nicolin Chen , Xiubo Li , Shengjiu Wang , Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Linux-ALSA , linuxppc-dev , linux-kernel Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Shengjiu, On Thu, May 19, 2022 at 9:49 AM Shengjiu Wang wrote: > diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c > index fa950dde5310..dae16a14f177 100644 > --- a/sound/soc/fsl/fsl_sai.c > +++ b/sound/soc/fsl/fsl_sai.c > @@ -437,6 +437,12 @@ static int fsl_sai_set_bclk(struct snd_soc_dai *dai, bool tx, u32 freq) > FSL_SAI_CR2_DIV_MASK | FSL_SAI_CR2_BYP, > savediv / 2 - 1); > > + if (sai->soc_data->max_register >= FSL_SAI_MCTL) { Isn't it a bit fragile to take this decision based on the number of SAI registers in the SoC? What about adding a specific field in soc_data for such a purpose?