Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp3717102rdb; Wed, 13 Sep 2023 23:43:59 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGHcmOrfmAKGBrluO0wNJX1e7EeMHJ9RnSRCXS+Din+RJgc75EsV6f24x2hlnHDFFr6luUy X-Received: by 2002:a17:902:c40d:b0:1bc:3944:9391 with SMTP id k13-20020a170902c40d00b001bc39449391mr5765721plk.25.1694673839593; Wed, 13 Sep 2023 23:43:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694673839; cv=none; d=google.com; s=arc-20160816; b=ytDmdYbYBahwTe24QVX7r2YkLfOv7J0+up7/b/mMvXgttLjfjBr/c804HrqtbTSqfb ebyXKA53emAY+A9tZih9QswpsFi5zu+pOh+TMkwzbMdm1biyJ+T3EXTcukEou9gAZAf4 KD6ddZmQKtcqv0jNyxXouJK/p6u37JAEVxHPr8hQdt9bOn/iwbhvRSCGM16Wxo+Gokyr qXfnDBf71SLCJtKcxg2LNhtrUy/ueHTjmbLBGVNsHnKAx6dJpJZn5KjnOa40om+tWz+o GHueK/pP9xUYXAtBb1w1R2AU6xYw/YfPyBn3HTKvS3EiFR4tOkUVR71eMipOcqMVN8KW wjVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=8puwwYQ2UBHFNT37XGmqgv1DiqsgZEnUlgOGxcY1CkI=; fh=bcQ8oojKPJWqAka2FdWlWUrHln7uUDvZtGR5ExssAvc=; b=ONUeHWofTmGm3hdzttgxfenzJ/lEavtmwSVEySdaDsBA61ecZNVj3S6cW91Dk8fNI/ BPOjw43NM6+z2Ob9ax/ueo9PYyv7H4SMHbBa3Th5aAD1BZbyyU97dXSlXVN7HiJglPNR ptFxJO2tNYSjdmTv/UTaq1I72bEH4NWAohH15RLJhHETH828cNU9pPROvQU6ratyW0gq cQGKoPW+M53OrbZ3CMwxktOdB34TgAa4IbDafjZq/t4pHonpJv/WgGVg38xNB0iV4RKG MOTb70ymdX/a1Lm5BMbEnjhqLsWTzgmuC1qLWYcRL6Gm9eB7QLB0drgiDwe2z59SRT+h TQ9Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=bCQo4MqY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 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 fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id e15-20020a17090301cf00b001b9c61c221bsi1028680plh.565.2023.09.13.23.43.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 23:43:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=bCQo4MqY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 260C982DAFF1; Wed, 13 Sep 2023 21:16:32 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234645AbjINEQ1 (ORCPT + 99 others); Thu, 14 Sep 2023 00:16:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45978 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234628AbjINEQY (ORCPT ); Thu, 14 Sep 2023 00:16:24 -0400 Received: from mail-pg1-x533.google.com (mail-pg1-x533.google.com [IPv6:2607:f8b0:4864:20::533]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 89A23E69 for ; Wed, 13 Sep 2023 21:16:20 -0700 (PDT) Received: by mail-pg1-x533.google.com with SMTP id 41be03b00d2f7-577fb90bbebso129172a12.1 for ; Wed, 13 Sep 2023 21:16:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1694664980; x=1695269780; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=8puwwYQ2UBHFNT37XGmqgv1DiqsgZEnUlgOGxcY1CkI=; b=bCQo4MqY3N6wirLvwaV3zBRX34IxCP2kdzfZAscz/IeqgqdHtWpnix5LYUzK7QNde6 5YZRp6TTWLnZnZIE5CMHO8r7uqjtcdKi25t7FaEsM53s0xCPkEtieqa1XaOMWR9N/QVC 98EW/sYGzJx1Foh7eOWqSYMPDMNWL1pBgnWA3xf9W6c9hu34yLcjX3+Z7dihG8P7x4xc MuFuFN9UXyaXHNwovK6gBEnV1QgaiujFShaWH7ADzBH0IW/3OItXaEcyzIC61BCF6Wpt LiAk8z+XeXov9+NVWEYJCe2CXhAoNCvU1yIcRYQm/Idv5tgn7gCFyNSqDpthZ25bxWB8 2iQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694664980; x=1695269780; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8puwwYQ2UBHFNT37XGmqgv1DiqsgZEnUlgOGxcY1CkI=; b=bYVmYP4E+/rdVJFScJYJfrr9FHaP0v3Bue1LJ06WYGeXuO2mJmK5IYy7w0bFom8m5G 1JsHFCE2BE8gRem+J0WejCLwk2p25cy1GKBUBeHDEt/GBHU72ORxc/Us/H4YmlcNg0aJ FbgQKdAV40Yrrf6VU4O3JfLwa8Ng0TEB4yzUSxH1dPbj6qLuhmv/vzqiIDt3lOT+96hR +m4WK9DJpFJPIA/bIakGd8UHNUduJqsO7+jm/QoSsDwRC12S6ZQ2SzMog+vGV6vod9vG gF8NX8N+2LrSWH7XBjmLd4OIMkl7hiwrzop8KDXQVtHq6AGQSZQp3dFLeTK/badEbhni jHlw== X-Gm-Message-State: AOJu0YxatVja/47G7yF+KlcRBcN9a5vungSCe7+F2teaEL5cx/Fklzij RM4Sdk5AcZ/Z99gYbNgmeMdF4mg71fT0gwXcv0U= X-Received: by 2002:a05:6a21:4886:b0:13a:e955:d958 with SMTP id av6-20020a056a21488600b0013ae955d958mr4295356pzc.7.1694664979937; Wed, 13 Sep 2023 21:16:19 -0700 (PDT) MIME-Version: 1.0 References: <20230913102656.2966757-1-chancel.liu@nxp.com> In-Reply-To: <20230913102656.2966757-1-chancel.liu@nxp.com> From: Shengjiu Wang Date: Thu, 14 Sep 2023 12:16:08 +0800 Message-ID: Subject: Re: [PATCH v2] ASoC: imx-rpmsg: Set ignore_pmdown_time for dai_link To: Chancel Liu Cc: Xiubo.Lee@gmail.com, festevam@gmail.com, nicoleotsuka@gmail.com, lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, shawnguo@kernel.org, s.hauer@pengutronix.de, kernel@pengutronix.de, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 13 Sep 2023 21:16:32 -0700 (PDT) X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email On Wed, Sep 13, 2023 at 6:27=E2=80=AFPM Chancel Liu w= rote: > > i.MX rpmsg sound cards work on codec slave mode. MCLK will be disabled > by CPU DAI driver in hw_free(). Some codec requires MCLK present at > power up/down sequence. So need to set ignore_pmdown_time to power down > codec immediately before MCLK is turned off. > > Take WM8962 as an example, if MCLK is disabled before DAPM power down > playback stream, FIFO error will arise in WM8962 which will have bad > impact on playback next. > > Signed-off-by: Chancel Liu Acked-by: Shengjiu Wang Best regards Wang Shengjiu > --- > sound/soc/fsl/imx-rpmsg.c | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/sound/soc/fsl/imx-rpmsg.c b/sound/soc/fsl/imx-rpmsg.c > index 3c7b95db2eac..b578f9a32d7f 100644 > --- a/sound/soc/fsl/imx-rpmsg.c > +++ b/sound/soc/fsl/imx-rpmsg.c > @@ -89,6 +89,14 @@ static int imx_rpmsg_probe(struct platform_device *pde= v) > SND_SOC_DAIFMT_NB_NF | > SND_SOC_DAIFMT_CBC_CFC; > > + /* > + * i.MX rpmsg sound cards work on codec slave mode. MCLK will be > + * disabled by CPU DAI driver in hw_free(). Some codec requires M= CLK > + * present at power up/down sequence. So need to set ignore_pmdow= n_time > + * to power down codec immediately before MCLK is turned off. > + */ > + data->dai.ignore_pmdown_time =3D 1; > + > /* Optional codec node */ > ret =3D of_parse_phandle_with_fixed_args(np, "audio-codec", 0, 0,= &args); > if (ret) { > -- > 2.25.1 >