From patchwork Thu Apr 18 04:13:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 13634131 Received: from JPN01-OS0-obe.outbound.protection.outlook.com (mail-os0jpn01on2086.outbound.protection.outlook.com [40.107.113.86]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2F50653E32 for ; Thu, 18 Apr 2024 04:13:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.113.86 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713413592; cv=fail; b=kri6gVTvTjWpL7Uuo/ZkbsXY60Ahc29X0Cy9thoY1CE26TbFDY/lF4JgAYoxUEP8BGjVpcmowpjLy8ADYi3K92newf2lGJG4tsbbpDnw/CJsgO5AIk38Z9v42k+km5YLiWPpaMEv52vgH1pkH3sLsjBRpn5CbDTMZoA4AfLJWZc= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713413592; c=relaxed/simple; bh=Kxnd0H32+e6C7IlRBgHhSR7C2uOPz+1yIkoySGVqFOE=; h=Message-ID:To:In-Reply-To:References:From:Subject:Content-Type: Date:MIME-Version; b=MNFQkM1H/aVlkJA359f3N3G16OU5QYDq8hr7lGl8WNg7/3TkjQkNzyqwQptvKEjO/6kiwYGcAPit+QT3876bPEw+qy31asWDZSOr2oqFGP6pJYZzf5FLKzzcUEF8AZvXh27lAvn/XWXR0LhMyNB6Lg5BQHDTIg53QhCl9/ue1ac= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=renesas.com; spf=pass smtp.mailfrom=renesas.com; dkim=pass (1024-bit key) header.d=renesas.com header.i=@renesas.com header.b=ezLExBLU; arc=fail smtp.client-ip=40.107.113.86 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=renesas.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=renesas.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=renesas.com header.i=@renesas.com header.b="ezLExBLU" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dNUcba1jkJ10WF4D7hwNQJHOanL9ZZMWY2+VAnWfJbaO+J+I3IdgsFDO+ohsuUjXx8p+y0PPwBihrOX/Fp9nJgaBcyXF+VT+H5+/3SKhdJwpiDJk9kAYNOrPYfPSS2luxW5We+3NgBCicO6YFiWIH2Cr/Ed1sPd6KeQ3IvscXOcGY17Y88j8m88v9lmNcJ6HB7k8iGydfwTQa6zxbxYujQABBTMVlgyvJB2TUQMfzBkDD+rnMY6AK3veu6LUcLHw2lAu/t8lvV3JFOG6eDrGUuWU9oarBbG6Mrcfz8Aev+NtNllJVRAe/P8Al/Fb2mscUFnqUy5k4q8msaTAt+/A6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=fsy4flBypaWLZ/M2nrPYJYJ/3wDyjmftOvHiS1GzmgM=; b=UCbNYyITfZht+FJsQFE7MheYv5JPdFXcYpdf7vdMX5y4jDiT8T2ikWK/fDbsiqao0cINtoOBed2z8971ynSmo8USfFWPXq6lYHEnI8xZ4AhV0opB97B0fqawWumNlD5lWqkPAFpG5lheU7T/3pR0RcorqHUAafF0NeNZPcDA/vL6x3yHRl/D6I/ckBLdPEu8b21uFRmN1mG9v2D9Pd9Gbs1ilC2yTeBDoceSQDZB/o0aJVQs4I80s+tjX8zVUDEaYcwZzCLyD81Jr5ivSVFphrTgbmaX1ltljnkhetVpMXAOwwlNza4jGkJqZPYkzwz2rQ2oVcRq5xGGw1og3EweZA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=renesas.com; dmarc=pass action=none header.from=renesas.com; dkim=pass header.d=renesas.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=renesas.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fsy4flBypaWLZ/M2nrPYJYJ/3wDyjmftOvHiS1GzmgM=; b=ezLExBLU9sSYXp8i3QecoaVYNwRq6D+h+zCv/Z0evlTjhxgxOfWgOmBo+NfffaFdMEUGaXZ2XfidM0dc9PrTxYQ9A9nNhiPayWlDiL/unJ53isdPV52mYmmm+K9vjHMOSCdpPS8UhnyIS78yGZIM+2Aq1/tByoQBClbrXVR4Ih8= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=renesas.com; Received: from TYCPR01MB10914.jpnprd01.prod.outlook.com (2603:1096:400:3a9::11) by OSAPR01MB7397.jpnprd01.prod.outlook.com (2603:1096:604:142::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7472.39; Thu, 18 Apr 2024 04:13:07 +0000 Received: from TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::131e:55c0:a4a0:713b]) by TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::131e:55c0:a4a0:713b%7]) with mapi id 15.20.7472.037; Thu, 18 Apr 2024 04:13:07 +0000 Message-ID: <87a5lr8g19.wl-kuninori.morimoto.gx@renesas.com> To: =?iso-8859-2?q?=22Amadeusz_S=B3awi=F1ski=22?= , Alexandre Belloni , Alper Nebi Yasak , AngeloGioacchino Del Regno , Banajit Goswami , Bard Liao , Brent Lu , Cezary Rojewski , Charles Keepax , Claudiu Beznea , Cristian Ciocaltea , Daniel Baluta , Hans de Goede , Jaroslav Kysela , Jerome Brunet , Jiawei Wang , Jonathan Corbet , Kai Vehmanen , Kevin Hilman , Liam Girdwood , Mark Brown , Maso Huang , Matthias Brugger , Neil Armstrong , Nicolas Ferre , Peter Ujfalusi , Pierre-Louis Bossart , Ranjani Sridharan , Sascha Hauer , Shawn Guo , Shengjiu Wang , Srinivas Kandagatla , Sylwester Nawrocki , Takashi Iwai , Vinod Koul , Xiubo Li , alsa-devel@alsa-project.org, imx@lists.linux.dev, linux-doc@vger.kernel.org, linux-sound@vger.kernel.org In-Reply-To: <87h6fz8g3u.wl-kuninori.morimoto.gx@renesas.com> References: <87h6fz8g3u.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto Subject: [PATCH v3 05/23] ASoC: fsl: Replace dpcm_playback/capture to playback/capture_assertion Date: Thu, 18 Apr 2024 04:13:06 +0000 X-ClientProxiedBy: TYCP286CA0348.JPNP286.PROD.OUTLOOK.COM (2603:1096:405:7c::11) To TYCPR01MB10914.jpnprd01.prod.outlook.com (2603:1096:400:3a9::11) Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYCPR01MB10914:EE_|OSAPR01MB7397:EE_ X-MS-Office365-Filtering-Correlation-Id: 2af238a9-8d4c-4c8e-aea1-08dc5f5dda20 X-LD-Processed: 53d82571-da19-47e4-9cb4-625a166a4a2a,ExtAddr X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: KGex6StHamwj2njPRfJRX/Dyi5MOA19GF21+18bsakn2vLULxE0ER7iKlx2nJMZe09/822GWZkS2WBgDAO+3IZwqrqVZtRJeJ3Pmo0IyzWIVagDlyOHkVIeioKxTrgzGtdOTERtlHcAfe8kymWvuUZltoMJr9KxGfBZ6Zyzu5sKC48400hr8kKQ6t/xIPZxav6Y9Z1FIS4z0inB1cqgHidnj+xaGbr0cUvz+r7vgKyZXwHiD0qBw7F76A4FLJVCYUDrA/e/r2eCQDl+AQpcpxWRGp8FEmwUiwsMRUjvts0ba+yRjhz84krxvjE3mPC2dy8r3hzCFxMP9thPh0g3lbr/cVQaGEEylH1+sLNoU173Rl6cBN3qHKS9RTsxZVoV/B2bGpd3b3Xb4xiMN/R04QlmvUVITuTxwyUNSpWKghl6LpDxXQAaN9ihqdVBCjHuOK/hKSHt90XlmAVTIdP3GOKF1Dn0s9m/Me0Yxn63UA/bbXm/kWeR9hH0P1eOSY4l/KAbik48mFntlB8W25vmyWSxqMpI/f8T2R1rpGNAtgGXVAMh167hKd8t2wUmnA/6/7QpX+6e5jZ17yNnRnw3Ve3ngk/HAnKP3kxny5jIbiiZeENsMy74JO1ZnZ/dfUuwiuXk6vq+rUFHxadTYLlT4ndJb4BaUhp6DlBObfaii42RL6fg8X/xOUqDr5HtHSKC8IcbuDYFSte9SZ5XeVuLD3obW114jKT8ECR2vgc3znW0= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:TYCPR01MB10914.jpnprd01.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(52116005)(7416005)(1800799015)(376005)(366007)(38350700005)(921011);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: jaJg+teJeA4AHzODyg+/bUhpva2t4Lf/b/nwu6LoN+Hh+8I/C6GUOcGwPZBHGEIU7HVge0t6qwxwYhG72dDRBfgsznW4u5otMqWuAVEX6pv7PeMkYFv+affQRnl4UASIQRjEAUzlCqoS4VufAAk49Zi1T19vcYECfXYUeHjBNjxFzASCYGMrqaoN/6qPr87/LBCkcczWC2Vkr7VKvox/BzKPBMFGb+RL0GaaRyXIDG57YttHhBoagGH6T3hKZa//8s8pBZfdSMa77uZYeKZYP3sqEfEiXeKhcxpYq6zz+QbVgq7nPO0VnNMo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16NxSfimv4O+GDHwZYsDd2OfR51ARmVnoPboHkrYhpOo4s/AnAhmXH9kKChYQxTtQWiUKDloRNuh+nYOQulfwKrbrLJ5BcbIRhvttN0qaaav+EjNLTuhliJ2CY+I25HfnsMBmZk4xH1QFq+qn9ySGISTsUwjjTgXLl0afEeO5OJPWtjCqHPJ/sYvRFHGqzsrQ1jKGDBQcGaOOL/yvlg2r3qWPVLnUZL2pTaPdUKr/zSeCyGI8yZgCQFKU8= X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2af238a9-8d4c-4c8e-aea1-08dc5f5dda20 X-MS-Exchange-CrossTenant-AuthSource: TYCPR01MB10914.jpnprd01.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Apr 2024 04:13:07.6763 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 53d82571-da19-47e4-9cb4-625a166a4a2a X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: gbHtBae41QmCvDMgmc4qBXRWSsy1KuXY05fzaN1rTBupzvWRiJPZ6qcyR0PpXv0WHFF1rN5M23Y4tUOCCTEMHUnzKEmBK54HzEMsODhXi8EVEaZKX2fRf7CEEYylWmaZ X-MS-Exchange-Transport-CrossTenantHeadersStamped: OSAPR01MB7397 soc_get_playback_capture() is now handling DPCM and normal comprehensively for playback/capture stream in same code. This patch converts dpcm_xxx flag to xxx_assertion. Signed-off-by: Kuninori Morimoto --- sound/soc/fsl/fsl-asoc-card.c | 20 ++++++++++---------- sound/soc/fsl/imx-audmix.c | 8 ++++---- sound/soc/fsl/imx-card.c | 4 ++-- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc-card.c index f6d2564864c6..50ca3e72eb21 100644 --- a/sound/soc/fsl/fsl-asoc-card.c +++ b/sound/soc/fsl/fsl-asoc-card.c @@ -320,8 +320,8 @@ static const struct snd_soc_dai_link fsl_asoc_card_dai[] = { { .name = "HiFi-ASRC-FE", .stream_name = "HiFi-ASRC-FE", - .dpcm_playback = 1, - .dpcm_capture = 1, + .playback_assertion = 1, + .capture_assertion = 1, .dynamic = 1, SND_SOC_DAILINK_REG(hifi_fe), }, @@ -330,8 +330,8 @@ static const struct snd_soc_dai_link fsl_asoc_card_dai[] = { .stream_name = "HiFi-ASRC-BE", .be_hw_params_fixup = be_hw_params_fixup, .ops = &fsl_asoc_card_ops, - .dpcm_playback = 1, - .dpcm_capture = 1, + .playback_assertion = 1, + .capture_assertion = 1, .no_pcm = 1, SND_SOC_DAILINK_REG(hifi_be), }, @@ -649,8 +649,8 @@ static int fsl_asoc_card_probe(struct platform_device *pdev) } else if (of_device_is_compatible(np, "fsl,imx-audio-tlv320aic31xx")) { codec_dai_name = "tlv320dac31xx-hifi"; priv->dai_fmt |= SND_SOC_DAIFMT_CBS_CFS; - priv->dai_link[1].dpcm_capture = 0; - priv->dai_link[2].dpcm_capture = 0; + priv->dai_link[1].capture_assertion = 0; + priv->dai_link[2].capture_assertion = 0; priv->cpu_priv.sysclk_dir[TX] = SND_SOC_CLOCK_OUT; priv->cpu_priv.sysclk_dir[RX] = SND_SOC_CLOCK_OUT; priv->card.dapm_routes = audio_map_tx; @@ -676,15 +676,15 @@ static int fsl_asoc_card_probe(struct platform_device *pdev) priv->dai_fmt = SND_SOC_DAIFMT_LEFT_J | SND_SOC_DAIFMT_CBC_CFC | SND_SOC_DAIFMT_NB_NF; - priv->dai_link[1].dpcm_capture = 0; - priv->dai_link[2].dpcm_capture = 0; + priv->dai_link[1].capture_assertion = 0; + priv->dai_link[2].capture_assertion = 0; priv->card.dapm_routes = audio_map_tx; priv->card.num_dapm_routes = ARRAY_SIZE(audio_map_tx); } else if (of_device_is_compatible(np, "fsl,imx-audio-wm8524")) { codec_dai_name = "wm8524-hifi"; priv->dai_fmt |= SND_SOC_DAIFMT_CBC_CFC; - priv->dai_link[1].dpcm_capture = 0; - priv->dai_link[2].dpcm_capture = 0; + priv->dai_link[1].capture_assertion = 0; + priv->dai_link[2].capture_assertion = 0; priv->cpu_priv.slot_width = 32; priv->card.dapm_routes = audio_map_tx; priv->card.num_dapm_routes = ARRAY_SIZE(audio_map_tx); diff --git a/sound/soc/fsl/imx-audmix.c b/sound/soc/fsl/imx-audmix.c index 2aeb18397bcb..ca768375e7c7 100644 --- a/sound/soc/fsl/imx-audmix.c +++ b/sound/soc/fsl/imx-audmix.c @@ -258,8 +258,8 @@ static int imx_audmix_probe(struct platform_device *pdev) priv->dai[i].cpus->of_node = args.np; priv->dai[i].cpus->dai_name = dev_name(&cpu_pdev->dev); priv->dai[i].dynamic = 1; - priv->dai[i].dpcm_playback = 1; - priv->dai[i].dpcm_capture = (i == 0 ? 1 : 0); + priv->dai[i].playback_assertion = 1; + priv->dai[i].capture_assertion = (i == 0 ? 1 : 0); priv->dai[i].ignore_pmdown_time = 1; priv->dai[i].ops = &imx_audmix_fe_ops; @@ -283,8 +283,8 @@ static int imx_audmix_probe(struct platform_device *pdev) priv->dai[num_dai + i].cpus->of_node = audmix_np; priv->dai[num_dai + i].cpus->dai_name = be_name; priv->dai[num_dai + i].no_pcm = 1; - priv->dai[num_dai + i].dpcm_playback = 1; - priv->dai[num_dai + i].dpcm_capture = 1; + priv->dai[num_dai + i].playback_assertion = 1; + priv->dai[num_dai + i].capture_assertion = 1; priv->dai[num_dai + i].ignore_pmdown_time = 1; priv->dai[num_dai + i].ops = &imx_audmix_be_ops; diff --git a/sound/soc/fsl/imx-card.c b/sound/soc/fsl/imx-card.c index 9c7e24cebd7b..873f6f89dcf5 100644 --- a/sound/soc/fsl/imx-card.c +++ b/sound/soc/fsl/imx-card.c @@ -814,8 +814,8 @@ static int imx_card_probe(struct platform_device *pdev) } for_each_card_prelinks(&data->card, i, link) { if (link->dynamic == 1 && link_be) { - link->dpcm_playback = link_be->dpcm_playback; - link->dpcm_capture = link_be->dpcm_capture; + link->playback_assertion = link_be->playback_assertion; + link->capture_assertion = link_be->capture_assertion; } } }