From patchwork Mon Apr 1 00:31:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 13612364 Received: from JPN01-TYC-obe.outbound.protection.outlook.com (mail-tycjpn01on2099.outbound.protection.outlook.com [40.107.114.99]) (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 5B89D10F1 for ; Mon, 1 Apr 2024 00:31:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.114.99 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711931479; cv=fail; b=bMcyDP2L543FtanzRXNLeSMwCD6cIVJjukpDSKPBGiV4nrePkrK3xCKfc2Jn1Of1/BENR746tTfdVqKHEbDE+HWszKbN5EKjo6nx02wHZYmNJCOwHIDxpgt/sUzy7YZSadPMWAhvKVBlyE93CzPbY9iK68GhlKoxBdAqxKlG5jw= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711931479; c=relaxed/simple; bh=DRJo5Zh7uoUsqlhBa9LN8X9mkwIp5Hf2eepH8DBYf3s=; h=Message-ID:To:In-Reply-To:References:From:Subject:Content-Type: Date:MIME-Version; b=DEkR2ZeBWEignouNV5NV+hKlN6pn2/pwwaT2b5HwYLEi4sSK5exodT/gIQZal4aALsbLfLn1LuQbFSuoGV0j9ZB1x3BGgrKzXvSva9og8L206HPhWqZMvoX/ekilqHlMko1ZgRcmcDvIoDWZ19sAMOqIhqgevw4LJLCW5P3mOsQ= 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=LeunItvv; arc=fail smtp.client-ip=40.107.114.99 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="LeunItvv" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jQNaKdXJfIuA2Fa0mSb8AhX0ImVyre6hXkbcrjgEbyVLiwREDo/20udigJ70l4E6SN2B1zdwkWwwsO2HjEpGQvXGj93xHbqCFnUf9PykVDmLQNsyJfAk5Iad9PUFdIOZzCmo8ZEB2Krnzxbu7hoylXfv0iok651MyM8lmMRqEgZkmkeHDCYCSgbDoI9Oad6rM074O7zXj1G11KZNHu+RFukYuMDwu1P4aJLaLXp4a4lWzBbK0cz+dSQhAXIx4CkH4NATE9hU6GGhz/alrhK1tIKWkOg5y2N7exMxEuYZjvvtolGo0Gdc8w0Vz/TLN4vduhMN4Fwiqyp4NHBbAfgKmg== 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=Uz6U1imtp4A5ePlvKD0/SLhzN1hah03F7tGbrV3yCBI=; b=k3eztONAVCKMjsOi2VXmwEal2lx/ceX+krYpZv+DeMw1Uw/G5WFRqIHxQSVpsBgbER9o0tAj8W9C91atWvp2EbjIfF8P6SfXDhxdFbbfVRIfsiTRdgNIfqPj8ychQYpEgVl85YXy3bPc9+HsuYA693+SIXMAMS0CZYSog5E3goOKD1lpY9nwO3WJyXss0AvY8Oll1lRRm25muRVKgLQPxCzPH0EkgXXF91nc/POde1qt7Ze0+fhBkwHczKIZA5YP0CUmV+akYYppxLP+cP1zdLNOC8Bg9ToXkXGzK9oeMcpc17/V8gKGf6ZHC0eQwq1Y0CzTeJlO8tekMJI7/I/hJA== 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=Uz6U1imtp4A5ePlvKD0/SLhzN1hah03F7tGbrV3yCBI=; b=LeunItvvjczu00ZNraQLUvj8+FhSReUlpLwRPDOuD7VNc6xM0Vy9eetSmqCgTpBTULDaeNUBct984DzGJw3yuxKr9mNaGxHsSnoNfmwd0Y9jKpCJlapr2+yIESTBEC0xwNp5yBNYEmSzjUM5OEMCXVZVQ1JIq45qYDfmtSR3Ec4= Received: from TYCPR01MB10914.jpnprd01.prod.outlook.com (2603:1096:400:3a9::11) by OS3PR01MB8258.jpnprd01.prod.outlook.com (2603:1096:604:175::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.46; Mon, 1 Apr 2024 00:31:14 +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.7386.025; Mon, 1 Apr 2024 00:31:14 +0000 Message-ID: <87sf05udnx.wl-kuninori.morimoto.gx@renesas.com> To: =?iso-8859-2?q?=22Amadeusz_S=B3awi=F1ski=22?= , Alper Nebi Yasak , AngeloGioacchino Del Regno , Banajit Goswami , Bard Liao , Brent Lu , Cezary Rojewski , Cristian Ciocaltea , Daniel Baluta , Hans de Goede , Jaroslav Kysela , Jerome Brunet , Kai Vehmanen , Kevin Hilman , Liam Girdwood , Linus Walleij , Mark Brown , Maso Huang , Matthias Brugger , Neil Armstrong , Peter Ujfalusi , Pierre-Louis Bossart , Ranjani Sridharan , Sascha Hauer , Shawn Guo , Shengjiu Wang , Srinivas Kandagatla , Sylwester Nawrocki , Takashi Iwai , Trevor Wu , Vinod Koul , Xiubo Li , alsa-devel@alsa-project.org, imx@lists.linux.dev, linux-sound@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com In-Reply-To: <87zfuesz8y.wl-kuninori.morimoto.gx@renesas.com> References: <87zfuesz8y.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto Subject: [PATCH v2 05/16] ASoC: meson: Replace dpcm_playback/capture to playback/capture_only Date: Mon, 1 Apr 2024 00:31:14 +0000 X-ClientProxiedBy: TYCP301CA0006.JPNP301.PROD.OUTLOOK.COM (2603:1096:400:386::15) To TYCPR01MB10914.jpnprd01.prod.outlook.com (2603:1096:400:3a9::11) Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYCPR01MB10914:EE_|OS3PR01MB8258:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xvuMVwvizZ5GFMDpYuL6rotZdckUU1ayHIVcBYQkESAesk0ocLWkDHLMkdCBm90mRKE2kBivWBCtkZIyh25ZUQGWzGD5E7sVrJtoCZ/arocyf01GBe+TM1l/7rqd6Q+oT2AToWG2Jko0tgwJTksNCTS5tQWAku5mHygsdeUJ2Cw1JTCL/U2jA5l0apYDe7e8eIfXugNxSzlaU6hlZPvsLmWTMDZ/Gi6sCl/kJChrYeK5NRROzT5YVBnLXDpoPayvRuS0xuT8a1wUBVnJwpFCtPwOoNkFiIR0qI3tjvcgt1GJeutRY/OFOlIGXxAD+8xBXPsSqf071PLQHqja6f33Gr1CAHkK4izlbD5ilnV4nCgcfMLK47Eq4RtpqLoNAu2Otf4gSZkyUGbwpDAthw9JBlI53f6KPUkhwRABhlY50NFU/i711FcxfjeeLrTRoqVacMteWnldtm8RrL0yO+lB1AmNt1cCq+ZIYpSYrGpYiIGDeAomEfWr28mqantEezkrKbR0LSXUYnD3a4tHpt8Po1ZcrmL9lZpAqEYY7tnk7dOQvNWD5IDI1Bj3i+PKIlPRL/KFbzsM38cSSn+TjI1+OAzwJsVX0k/xVxmRZD7RA31hC7siuzSeX4vFPbk0rrb12KANNwv10WGKNbqZKA0/oSlcbfb1sMObwYSwMfevwzHSb2rtRzT3G2S9b/wbo81WvnibafgzZz64rPqeS+sHpTGoFrYRIDX0VBznA+pPX6I= 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)(7416005)(376005)(52116005)(1800799015)(366007)(921011)(38350700005);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: eR+37oA1jvJRcBi5iKi/+H4GYnCPa3eJOGljkrk5F0MpOuxMqmDoLG8vQOBx2NVjQQjhO9t8BkvXGv3uqaVstEjMjxV647k7TR3aSHFV1oifutnPeacMVTxWMVZHWAPRifv/pph2E6F0ufwr++OmQcTFdu26QCcof1ZTtgB1/wjRAAZLYBJd5SirwIRBllW6OGnEYn3mT75ByTwC95p1alpLuNyHSGH8fEK+VTupSKDvFnti1Jx2mpZi6ZW9FW0Yk7k0FH3D57CD2vZrM9NJvcxBjwu6YKbIsiHB7mOHTrFidq0EuKHly8Ccj5M1Q5xvOVhfhDjxpgmP10qomlSwIcQu1rD1dHrfA5U8W1pGYhrzbHHO3ow8GKGPek8ZaAnbHH2IBxicd4ou65UPadt7ayap09sYCuB0DDOTROZoqdzTO+M9KXtHlOSeXkMJSFQj5NP7NJ9KeD0P4LkfILtNgBPuzUPh5Janb9I564X4R8qRarSkCwrB/hrGRSQPlNNzS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tNSr6MzzkjT7bdrJY8AD6sE3qcPBsm/L5xx7Wjgr2CVvNwzRDxo190yaD0Q4= X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-Network-Message-Id: a577cef1-793d-476b-81b3-08dc51e309fa X-MS-Exchange-CrossTenant-AuthSource: TYCPR01MB10914.jpnprd01.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Apr 2024 00:31:14.8259 (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: +A1HF3NTosMCRRBf2HbclBRSce673A0dGrrEAWwysvc7/wmtvu6xjpN1Bi66z3H2jB8WRUIUmryWfsZgC9oCEfoLBoNZJGDn+IHtEQa3Urc/TtRwNIlLX57pntz7O6Pv X-MS-Exchange-Transport-CrossTenantHeadersStamped: OS3PR01MB8258 soc_get_playback_capture() is now handling DPCM and normal comprehensively for playback/capture stream. We can use playback/capture_only flag instead of using dpcm_playback/capture. This patch replace these. Signed-off-by: Kuninori Morimoto Reviewed-by: Jerome Brunet --- sound/soc/meson/axg-card.c | 8 ++++---- sound/soc/meson/meson-card-utils.c | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sound/soc/meson/axg-card.c b/sound/soc/meson/axg-card.c index 3180aa4d3a15..21bf1453af43 100644 --- a/sound/soc/meson/axg-card.c +++ b/sound/soc/meson/axg-card.c @@ -132,7 +132,7 @@ static int axg_card_add_tdm_loopback(struct snd_soc_card *card, lb->stream_name = lb->name; lb->cpus->of_node = pad->cpus->of_node; lb->cpus->dai_name = "TDM Loopback"; - lb->dpcm_capture = 1; + lb->capture_only = 1; lb->no_pcm = 1; lb->ops = &axg_card_tdm_be_ops; lb->init = axg_card_tdm_dai_lb_init; @@ -176,7 +176,7 @@ static int axg_card_parse_cpu_tdm_slots(struct snd_soc_card *card, /* Disable playback is the interface has no tx slots */ if (!tx) - link->dpcm_playback = 0; + link->capture_only = 1; for (i = 0, rx = 0; i < AXG_TDM_NUM_LANES; i++) { snprintf(propname, 32, "dai-tdm-slot-rx-mask-%d", i); @@ -186,7 +186,7 @@ static int axg_card_parse_cpu_tdm_slots(struct snd_soc_card *card, /* Disable capture is the interface has no rx slots */ if (!rx) - link->dpcm_capture = 0; + link->playback_only = 1; /* ... but the interface should at least have one of them */ if (!tx && !rx) { @@ -275,7 +275,7 @@ static int axg_card_parse_tdm(struct snd_soc_card *card, return ret; /* Add loopback if the pad dai has playback */ - if (link->dpcm_playback) { + if (!link->capture_only) { ret = axg_card_add_tdm_loopback(card, index); if (ret) return ret; diff --git a/sound/soc/meson/meson-card-utils.c b/sound/soc/meson/meson-card-utils.c index ed6c7e2f609c..1a4ef124e4e2 100644 --- a/sound/soc/meson/meson-card-utils.c +++ b/sound/soc/meson/meson-card-utils.c @@ -186,9 +186,9 @@ int meson_card_set_fe_link(struct snd_soc_card *card, link->dpcm_merged_rate = 1; if (is_playback) - link->dpcm_playback = 1; + link->playback_only = 1; else - link->dpcm_capture = 1; + link->capture_only = 1; return meson_card_set_link_name(card, link, node, "fe"); }