Message ID | 87sey0oznl.wl-kuninori.morimoto.gx@renesas.com |
---|---|
State | Superseded |
Headers | show
Return-Path: <alsa-devel-bounces@alsa-project.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5698FC25B75 for <alsa-devel@archiver.kernel.org>; Thu, 30 May 2024 01:31:16 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id B4665845; Thu, 30 May 2024 03:31:04 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz B4665845 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1717032674; bh=dWJ9aiL0KPdEdwUWlUtMQzWpBBRw5tjhFlKXxKwqj90=; h=From:Subject:To:In-Reply-To:References:Date:List-Id:List-Archive: List-Help:List-Owner:List-Post:List-Subscribe:List-Unsubscribe: From; b=csV/B4Hlwwy4Ob2WQYgOZb7tc1o3JsiQw+KFNW4Cbjufddlu/1LuVyJx+1FB12hlM NGxt9SKbWQaKLDFWhYQZmrwcUUfd4Ojj7AVaJmL9gpjIUvVKz2l4BuIcZNOXW7Ww79 1cSp56eHg3hnLWjxaUGwddPp2SlIY9/prJJLUW0Q= Received: by alsa1.perex.cz (Postfix, from userid 50401) id 3CF26F8061A; Thu, 30 May 2024 03:29:55 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id DB57EF805BF; Thu, 30 May 2024 03:29:54 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 04D22F804FF; Thu, 30 May 2024 03:29:50 +0200 (CEST) Received: from OS0P286CU010.outbound.protection.outlook.com (mail-japanwestazlp170100000.outbound.protection.outlook.com [IPv6:2a01:111:f403:c406::]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id CF86DF80149 for <alsa-devel@alsa-project.org>; Thu, 30 May 2024 03:29:39 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz CF86DF80149 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key, unprotected) header.d=renesas.com header.i=@renesas.com header.a=rsa-sha256 header.s=selector1 header.b=NO3IfGGJ ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=nHMXs9beX3cuhMm7wI9Pc6oQBStx5EZJw2LfCI+lyVGYwNfkLiWDFwhhmhN/ixlpsM7VZHjNls8PRbGISnA6OzzAhfUSFDJxil37pblFvTWMXEgQTP2eCn5LA98mXofbpmJT9C3LDGOe7UIaHOExQT9wfwklE7VlxSNekw9ISh1fpTl8cnJeSJ+LXo0R2XhowTle1D0yhSCYb5MCq6uKgPqbkdPVMXIKT/gYlAUlSd7nSgkfvkX/YaPMp3bGSB5mxss+rW7Iuk5OHZWA/PtXjK2RAfTSet3lIyBow3aAiLTBxfnDy91YN0iyWbliF7nKl5Y1IqcjP6RVTP4t4VpKGg== 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=ipWWxJjMu/EVkBUzGA8d5t1ousLvweYqHA9t/geTqS8=; b=oTG31RkD5k6/0Qn8BR4Y6OHwCBv61H8w6nFf+0xBpuVMOaGFFy2WBncG6U2NVi3Hk1XBpCcbTgiqbQPEAfB+lKc7Fe+k6JLoWOGNysK1Eh6cfEAMQmWnlV9IrKslgfaCkXgK0SipVZR9/Zc3CeDww6r8yJ+66Suq0ACHQfUENrrumtln1cpXUuQqZEJ/ImydSxHWoc/3idbTsUKDVD4wCyXWDQnuNN/Q4c20sM0ksbBbMnTWviNlT3bD9S4bE+KbZIGbGmoxzL1SkXJXGuMK+dHtWzLM7hf6mzpjCRoRR09Gdm7FXRvMpTLi+FELfR1FTzC1KFfoBDOoJ0el4BZXMw== 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=ipWWxJjMu/EVkBUzGA8d5t1ousLvweYqHA9t/geTqS8=; b=NO3IfGGJHsJJ+AIV1NCalZff/oY502MnxRIkMt2Fp+oal8xr0dvxUXPniIjCtyyJMEFXzQFMVHPk9F5ifeyYRIETIjgAtZ9UxS/Qt8xw7CNAT02fj9TisrOxcd628m9gWyn1q2sVCFWViE5D0y9su/If863Dq6N9UjOTGE3BYbM= 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 OS0PR01MB5524.jpnprd01.prod.outlook.com (2603:1096:604:a6::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7633.21; Thu, 30 May 2024 01:29:36 +0000 Received: from TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::c568:1028:2fd1:6e11]) by TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::c568:1028:2fd1:6e11%4]) with mapi id 15.20.7633.018; Thu, 30 May 2024 01:29:36 +0000 Message-ID: <87sey0oznl.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Subject: [RFC 08/12] ASoC: soc-compress: remove dpcm_xxx flags User-Agent: Wanderlust/2.15.9 Emacs/29.3 Mule/6.0 To: =?iso-8859-2?q?=22Amadeusz_S=B3awi=F1ski=22?= <amadeuszx.slawinski@linux.intel.com>, Alexandre Belloni <alexandre.belloni@bootlin.com>, Alper Nebi Yasak <alpernebiyasak@gmail.com>, AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>, Banajit Goswami <bgoswami@quicinc.com>, Bard Liao <yung-chuan.liao@linux.intel.com>, Brent Lu <brent.lu@intel.com>, Cezary Rojewski <cezary.rojewski@intel.com>, Charles Keepax <ckeepax@opensource.cirrus.com>, Claudiu Beznea <claudiu.beznea@tuxon.dev>, Cristian Ciocaltea <cristian.ciocaltea@collabora.com>, Daniel Baluta <daniel.baluta@nxp.com>, Hans de Goede <hdegoede@redhat.com>, Jaroslav Kysela <perex@perex.cz>, Jerome Brunet <jbrunet@baylibre.com>, Jiawei Wang <me@jwang.link>, Jonathan Corbet <corbet@lwn.net>, Kai Vehmanen <kai.vehmanen@linux.intel.com>, Kevin Hilman <khilman@baylibre.com>, Liam Girdwood <lgirdwood@gmail.com>, Mark Brown <broonie@kernel.org>, Maso Huang <maso.huang@mediatek.com>, Matthias Brugger <matthias.bgg@gmail.com>, Neil Armstrong <neil.armstrong@linaro.org>, Nicolas Ferre <nicolas.ferre@microchip.com>, Peter Ujfalusi <peter.ujfalusi@linux.intel.com>, Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>, Ranjani Sridharan <ranjani.sridharan@linux.intel.com>, Sascha Hauer <s.hauer@pengutronix.de>, Shawn Guo <shawnguo@kernel.org>, Shengjiu Wang <shengjiu.wang@gmail.com>, Srinivas Kandagatla <srinivas.kandagatla@linaro.org>, Sylwester Nawrocki <s.nawrocki@samsung.com>, Takashi Iwai <tiwai@suse.com>, Vinod Koul <vkoul@kernel.org>, Xiubo Li <Xiubo.Lee@gmail.com>, alsa-devel@alsa-project.org, imx@lists.linux.dev, linux-doc@vger.kernel.org, linux-sound@vger.kernel.org In-Reply-To: <874jagqe9w.wl-kuninori.morimoto.gx@renesas.com> References: <874jagqe9w.wl-kuninori.morimoto.gx@renesas.com> Content-Type: text/plain; charset=US-ASCII Date: Thu, 30 May 2024 01:29:34 +0000 X-ClientProxiedBy: TYCP286CA0158.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:383::9) To TYCPR01MB10914.jpnprd01.prod.outlook.com (2603:1096:400:3a9::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYCPR01MB10914:EE_|OS0PR01MB5524:EE_ X-MS-Office365-Filtering-Correlation-Id: c6ab454f-e4d2-476e-2088-08dc8047f76d 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;ARA:13230031|376005|7416005|366007|1800799015|52116005|921011|38350700005; X-Microsoft-Antispam-Message-Info: N5zbw9d+SbU7ZTFyLhUJIJbkugumL2i6XkLd1h8VmqIm0ly5bL4gCzzkJ9UGFxmmNVgYZ+r6cTkPa/nyuXOJdObQYmUhrLgAvXwurmgm/E5VLzczGTUYYSNjm6U+Q2oA2KvB9r/kV2Fbst9g+keV0INTYWS2eEWNwISMXp0UH9V42+uiq49aeOqxaxb9z8e+1Ovs0zKMrou9FiOnsr2vdrlkhKz0giqOifs2E1qPlvQABoObp7hFNOIwb9iVqZs+lVPX8krTybzex3LfLvKKB/DIhWI3PV9Ox5mR1L56iy0TZGKtcGKH+OLmF/nNxWGTXRhr6tYTPSjapcaHxcJM58ciaxv4H+cJUSfkfhbGRRrEaApmY1/5Bm5WrPqvoBYtQYwouB+vBB0WTxMF2Cv6f22EOogBYWya7DUztoZjeuvhT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NONE;SFS:(13230031)(376005)(7416005)(366007)(1800799015)(52116005)(921011)(38350700005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: F4VLcJp3xab1LyK8ETLDislXCKs1exTwE7oMdku+cY6LHw7wsxIvRl3+dkvx7AI+D/qaU36v5Zts1DoJgUtWN80OXSr2Iat5s4Kk19oxJwzHbH8s81H23n3VCO97ecjLSgb8TDZ7LwSp45QAguEKdigcFVoWLOmubRTkkZlnsSc5eyFnLwJ5SUGNAOiqqhWJceB0vXHsqWS2K2kjQztKlBsIwmEva5fP2RzNlD4B4GigaWf5p/mIIruiTDxQ4k3BUsR6HwSFeMdN0JINFUKHoxS1hLZlw0p6rSdFrdz5RXIuLbpOzUEVIRzjxbCxhMrTSf31OtF1hNIwoIHffkp5ik9FEI6gnJE8d7pgzhmxmUXmCmDlDqm+8dkVXAQIn0obbQtzB12USptJU+prYtMgMVcsm83/81egBgndOm4i4TRQUTDYQUcJlo2E4SYTI10VfdgZq/c6vLzP5Nn1SYq+3PNKWq2O0nMQiFIxFrcqXFGHdoAzGXEmjaUxrMU6q9Eb+TVcN4fNDzue170pdaQ+Gu52JgKkDW/puKub1N1nTDgoIDKD8eqy9JkLTWbrJBHCXfH4bUGGQ9K5YSrbCGlp3bSXbNT4wnVh+PEteiki7zV2VIzcdEQgsRTqeJVBWI+mU1Nn5yxgIlmDSQLDeo2Fne9Xa+OYLLFzh1bLXtKeOa52EaV7RpK3LanMPcDHlUT0gqbPBCN3WBPFJvS+/OuXTE2i5N8kPwED5MDAfs69JU9vvh0fkV1yjfS72k3rdoAoYY7b2Ib1DElGyemrjUDpLia+ITRuikp0v3BFMtn+6MRnicLvCpnF0hsociA+pGBd7VYr2dVFhQHlB2wzlmbWao/Bs0PIMnEv40OWZXKc+pCN5njvvcSphpfYIr85s6+AuJ/euvHWoONP2tYe9WZbj7+IXDyAVLSuwmbQpUoZ8pJcEOpnltkM0WI5AxmLYyWbZExETsWVYTBBNn4GT3t7KtYajH0XQqHTbDq63NxKVoGS8P18ow3MoiaaEp9eqzNEeR7U6Q1sXKG3nil/pGUj9ke6i+wTvxEBvEf0RkOuQyzDBPWme/g6s1gEEdUsOvWt0hjgPUyOCIC7TUEth8SQevV9VWhWG4W5oVI7DndvClVz5LMqEE3QsvGQ/QIuvt/Et1ljxPgEq6JC5fY3EW4Fyg8WfUuWUEQvgEfKRFL9JHfL+n46MKLNcORaWPhhsHkxL2Ln9x0ogAiz5m//S++Rm9TxLfhrOcNSfBJfZjZIPK8H8BQ+cbLXc1B0iEUNggjqidyNbj48u1w9NiAznEIL88syhY1oysqwzxbO7b0tgUZbufrpDORhv4FFHMVsw8rg9gdp9qFQ0gtvVvKFx0nFHiWXmBU80VncTVdfYZamb5fVaKlVpC08dqTllA/YSCyYpGDOv04sIWbrirBO+i8G1GecOeuVH7/lEMjrVJByXUFPWCGMbnqxBmsam1nKnHIXQcYebaKQ3xM/kz8HJjcU6h9EN0/kTcP+1h3HUkeF9O3W/Bv2inuJy3Gkhx+uTb0MyPzlFqjXLZMCiyQ8jmVoMmPAkuwTeEJ7xg/0KgEf6wiJ5QQxWwOm/kPMHMvnVE46cggTo+1P0tIfYkKPuzKJgTDCMXduCELvwRsGkFGXgcU= X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-Network-Message-Id: c6ab454f-e4d2-476e-2088-08dc8047f76d X-MS-Exchange-CrossTenant-AuthSource: TYCPR01MB10914.jpnprd01.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 May 2024 01:29:36.3700 (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: TRelUNAME/QPwgHLD+gXRUBdnH6LIFCOEFtU3JYPKevJYUQbNQEoP7G1+wsfKvabq8dLS2eNr5IvFBrj9oQdnkmEjp6PRSIeVTlM6o25MYkIvp+JOJMRqarI3f58BNE/ X-MS-Exchange-Transport-CrossTenantHeadersStamped: OS0PR01MB5524 Message-ID-Hash: H7DGNZNIC2JSVANI5WCSY6NEHHJRDCHR X-Message-ID-Hash: H7DGNZNIC2JSVANI5WCSY6NEHHJRDCHR X-MailFrom: kuninori.morimoto.gx@renesas.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" <alsa-devel.alsa-project.org> Archived-At: <https://mailman.alsa-project.org/hyperkitty/list/alsa-devel@alsa-project.org/message/H7DGNZNIC2JSVANI5WCSY6NEHHJRDCHR/> List-Archive: <https://mailman.alsa-project.org/hyperkitty/list/alsa-devel@alsa-project.org/> List-Help: <mailto:alsa-devel-request@alsa-project.org?subject=help> List-Owner: <mailto:alsa-devel-owner@alsa-project.org> List-Post: <mailto:alsa-devel@alsa-project.org> List-Subscribe: <mailto:alsa-devel-join@alsa-project.org> List-Unsubscribe: <mailto:alsa-devel-leave@alsa-project.org> |
Series |
ASoC: remove/replace dpcm_xxx flag
|
expand
|
diff --git a/sound/soc/soc-compress.c b/sound/soc/soc-compress.c index e692aa3b8b22f..a0c55246f424b 100644 --- a/sound/soc/soc-compress.c +++ b/sound/soc/soc-compress.c @@ -606,12 +606,19 @@ int snd_soc_new_compress(struct snd_soc_pcm_runtime *rtd, int num) return -ENOMEM; if (rtd->dai_link->dynamic) { + int playback = 1; + int capture = 1; + + if (rtd->dai_link->capture_only) + playback = 0; + if (rtd->dai_link->playback_only) + capture = 0; + snprintf(new_name, sizeof(new_name), "(%s)", rtd->dai_link->stream_name); ret = snd_pcm_new_internal(rtd->card->snd_card, new_name, num, - rtd->dai_link->dpcm_playback, - rtd->dai_link->dpcm_capture, &be_pcm); + playback, capture, &be_pcm); if (ret < 0) { dev_err(rtd->card->dev, "Compress ASoC: can't create compressed for %s: %d\n", @@ -624,9 +631,9 @@ int snd_soc_new_compress(struct snd_soc_pcm_runtime *rtd, int num) rtd->pcm = be_pcm; rtd->fe_compr = 1; - if (rtd->dai_link->dpcm_playback) + if (playback) be_pcm->streams[SNDRV_PCM_STREAM_PLAYBACK].substream->private_data = rtd; - if (rtd->dai_link->dpcm_capture) + if (capture) be_pcm->streams[SNDRV_PCM_STREAM_CAPTURE].substream->private_data = rtd; memcpy(compr->ops, &soc_compr_dyn_ops, sizeof(soc_compr_dyn_ops)); } else {
dpcm_xxx flags are no longer needed. It converts dpcm_xxx flag to xxx_only if needed. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> --- sound/soc/soc-compress.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-)