From patchwork Wed Mar 6 07:55:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chancel Liu X-Patchwork-Id: 13583455 Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2049.outbound.protection.outlook.com [40.107.21.49]) (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 113785D72A; Wed, 6 Mar 2024 07:56:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.21.49 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711783; cv=fail; b=cAY5GBNQSHwEQIjWBfu39nvSASu/0WmPa9vY1faTF11upeoioe5TXNkrH4uVOfoAZ0g4QzXlnzSvTicpKBoiim3qgdfTMiz5ilPVvxwMofAd04sM0pXTaSh1gbw0kx3kz58BvHemw+QbAAeXnX78NVWhupU/FKGIyLZ8OM33EJQ= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711783; c=relaxed/simple; bh=UdzpLy7t/M4jL8zY0CvNf54Yx25bprqtjbhvuOVzB7A=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: Content-Type:MIME-Version; b=AmMMnMf7E47aCo43B/ITblR5sjgkZAQAxrBwIkrlDflG1G3to82ZC0Dg0Zc55Nw1OoP15DLeivnVdPVwFdc/a42v4OskB5wUHN86FAO5Gd/RkbhbL5ykwxs6ghlNsjzUtnzjvIVvZWsMmIWTf2rHul8dy0ecydOAxPNJV+7tDg8= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=BoOULznL; arc=fail smtp.client-ip=40.107.21.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="BoOULznL" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=goXPG34nSduQRfkAYCd9NUTspWHrb7giIeF6hQPZhGgQGx81wt/fAwDhquLsLSR+pGXsUGglf+3/hI26npAS7D798GYVIko5ETx+Uei7O+ON9wiYMLb9FCeIiXBTLlAxpbYTiYXP39b+Q8/AY0+t4zBzQi54QN8/ty51fNY3piHBEmVrjNUa9pN0AhyB5tx338fcFlfK6gKF0/RgehQVQsD551XdBYIxOxHlECbsMSlMdgNeAKIlsGP4QxkOe2gtKmoELftBfM8JJsCwPepuXz5IRsLzCKQbRoibiVFsyN2tsFmEqChcPiZzqbVNgMqKQsacU2B6UQEFRhMGMO+Dkw== 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=vbsh0ootkphFdcrrwWuCS7B7NeWjjhCbN1sssmNZ460=; b=OXnLpbL5vQBiFOBC8VNbJ7JqWcwLQ6tOekXs6MEm9HbtzkElL4xKO32kUxH8drW23uU4KBsR3V+rIlvyTo2szaCXgPBg1Oud5uffn8DtEa0fC7dAii8Wr57HgAPR9/c6+z1PXn8s2iD9co5X3f/IXlSiABIM/lCa0GI0dUpJO9vEOB5EflmLB5oPUpvw8QeNZrngfkmk5pk/b30CAS/6Mx3s6UgLzxuciON8fN/3FUh1chBaA0MLXgGbidiYfEIrpO3a5w9sMBi+V8/CWiTCMZGFmdFpw7PZqO5BtjT6HtOrHCFdwoshNuZWYGvo8CEv6kBzYv8Tjqq5zjmUHIFFpg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vbsh0ootkphFdcrrwWuCS7B7NeWjjhCbN1sssmNZ460=; b=BoOULznLMRvSud73/1jIOlFdAZDURdlyUy/ZAuzaLGLTHkgQzOPM3+I/Gc5gHe+EDZrfqauVd2HcyB69o6JwbpmPKmu8zh0AWO6PEZnN1smidXvOKH2U1HcZ7sKcjrOKdTVbH0SagIT6sUVCIWujNyhHaktzGl/wtM0aVBDfXN8= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) by VE1PR04MB7376.eurprd04.prod.outlook.com (2603:10a6:800:1a0::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7339.39; Wed, 6 Mar 2024 07:56:16 +0000 Received: from DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01]) by DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01%7]) with mapi id 15.20.7339.035; Wed, 6 Mar 2024 07:56:16 +0000 From: Chancel Liu To: shengjiu.wang@gmail.com, 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, linux-imx@nxp.com, alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org, linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Chancel Liu Subject: [PATCH 1/4] ASoC: fsl: imx_pcm_rpmsg: Register component with rpmsg channel name Date: Wed, 6 Mar 2024 16:55:07 +0900 Message-ID: <20240306075510.535963-2-chancel.liu@nxp.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240306075510.535963-1-chancel.liu@nxp.com> References: <20240306075510.535963-1-chancel.liu@nxp.com> X-ClientProxiedBy: SI2PR04CA0017.apcprd04.prod.outlook.com (2603:1096:4:197::15) To DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) 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: DB9PR04MB9498:EE_|VE1PR04MB7376:EE_ X-MS-Office365-Filtering-Correlation-Id: 0dbc6de1-481c-4bd1-8273-08dc3db2e6a3 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: VgAO4cgjbn+eASX0QrHLaagJML+x/WGogIEVoui8D6cV3Y7ftXp7VDc1GhJ8oKAhptPLxBg2lZJooRRaTbv/QlRSr7375rjVWiJPGx4VCuhEtD2cpSrk+KMb7DDw9XbpWVd4+i7O9xYMq1Q578Tb49Wpc1+fo656sYBeOqKEIowmp8n1fZrgzXurT+jWolC9HU9XLGxuyZF9TabbEFrC6t2TTJEaW/rIoq2hUmyWe591bO/Ie/+3qMJ9zoCrNCuPa27fwTVylbvmU8AefCPOfkX63cAOoRiIVNcj9YmbylPxkc0n+7sYEXINMdM7eLLekSZv8Ui7wbxUCpMuUpY5BMFKbd4UZQ+waJbqqdijFSbMuPftQkx0Qd3RJa5xzcJNX1ypdzHD35RMnsNtOKpK37jv5WaFPSEfxVHiyM215gNLug4WA8gMl3ZC7966MKTiUurbu1qqHF/MeaXm1LUq8+25QIiUk5fckdDHoagkCeA0l6L4RX5sH/iq27HJQyjDnM3DiJjhr7hPqR+6CQ/L69877nmJeDTPdE1gUY0tQcSg1oi5ULu4SBZ2UUKsbb35vwGLMSZRdxbkbDkSfstQThTBJl6ORQTUk83kilo+awLQQDGO8Yccxlxop/5mEQuSq+ED18/C1AHtpmXka3bSa07hMW8ZxAC1jCAueQ3k6TQr5vAIqexqPPKTcFy2CmgGmWydXTgHjh90SyUupXNYo+e5Eup9fm7zQtLtOTRGBYw= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DB9PR04MB9498.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376005)(921011)(38350700005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: lDwwzhr9FKhKY38ezFsYmHH4fsM120PeKZnh/Rf1/+n4saR3pCNpgVDGaG0obRico1NivmgmhENX4VXWQwoBeUlgc3K2tYib/3saTnu/+9Hl94IVjfnLSVNHgr7z3DyaANYPean/eFmdCUwHW7kvY/g0ylB1GgslN5TCZXNTS591oboSLdX0mNO8WhG8ywjvUmBHLPRi35ZtEJygjHXkZnLXk/CoAnXuI98vXQkB4mfbvGx2TWKvJwMm732wqlHIdzZzOSd6Hp3aBqjA0VbuxmepOraqQQcYkLAr//NlF3knSWxuVk6nbUmC4JFysiwf5oI7ZBPlkENP/a+NagelcNLXadAOEXdKThROpVxUwposZa4554UzPCqmGnvkjofahn0aPakAC7aM5HStyXsxr33sfgT8u8KPOmB7rqXrHY+6rFyKHrJS0jyXD9ujYTuFBwBCjWOusnXUG0uCQ9YrIXEwYf5gjDGAo/uvhG9bl1XbW23woA9fUc6IAuqmxthtodoo0I5CBvGmihClLDo6i1FhEXtCMusHp64j6sygFmI/868XdK5JPRTg694j20eai508FbwwiVJKtxzfDMkAVyTWFhQOn80NYnRdhUj2FzH5n+bwAuUCKD+h6SH9hq9TBCzMKwGf8lQkjcpHBnfJV3FOLLxjrXmctk7iT07Cz8zujR9QZENZTJgA68hL1GZtlrSK/JWi5s77UU1n/lwigu9a/3POzVRba+naf7VbttFIQrezc5ZB1OTH2M35xDcpGnND9UrNx4F44SiQCbc2r7WzsXAY9R2FhNfsGPeQXNn9cl9/OzmWEU3S+NBfWkOWEa8D5qNTMMHeNR6vP1IRuz+8F5jRhl2AE/+oOzGDoDbbeMJkfcXFjaDSM6H9xznuZ0mlqDP9vqEpW2ffvD3NgYn2soC8qAAUypnqypL2LUaaMMOiAxJ68NIZktY7vL/SBQC2m+S36u/XBPEDdH/xUvXCs/+5WOOPvHcp2be6drHqLq1BystZrUpsbtT4HdITDdWyrugRT4sFwlWWRhqxfZ+KZd/4qEr02Y4Sie85oinYRzehne3m/Bk4JQKQuQZLo4ax6PKk1zkG3tzp90OT+EO7gjPhRTYOSVd2AL3alPiDDEOFTIonV357HKcxOVuIEIvwWqbQPpjArVqOHqhtBzfFfG+ytjh46hv7MfZRJcVasw5zPtr0bmYq52YhXZ+ViYjPHREQkcLVdrZnXnU8uJ6U8Tqp0vH+IIadF6i5cRi/1J8GKAifmZqNPBDEdK3ZXO5K4cq10Fbt8Kr72ol5YJVlgzbJenvEtXHSSQ/qsnRJfdJcrFyzNm8L+kBGkXhvumKXSrCRy7cApJ/IUxAz+2NpDd8JnC2QvxN3xcercilASM0N5WRg2dKHRgEyQY16KUqyp7YQDVhl3+y8Z0aIZ4QmfasMJf1yytW7+QR1uu6leV4eCCpyNndqvRXl8nqxbULu3mFBGm2IluFJgIxTwqwbUWJXnhAL9tcTJ1ctl5s21pP5tkta71Ie8aeimc6FLNLXbO/m65HK2gosXq5XW0nHOzo0qtrhVLky5L/LHl+owUdCY2ZJs8e9I+PuNq75 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0dbc6de1-481c-4bd1-8273-08dc3db2e6a3 X-MS-Exchange-CrossTenant-AuthSource: DB9PR04MB9498.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Mar 2024 07:56:16.4178 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: DuyBNhfc/CBCrZKKIPp6/M4Dqo5s1QJTM/Qqw9S0Hh/oKPfscDUDv8fpLttu0vpg3Wc1qTbPF5MOy5OOUU43iA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB7376 Machine driver uses rpmsg channel name to link this platform component. However if the component is re-registerd card will not find this new created component in snd_soc_try_rebind_card(). Explicitly register this component with rpmsg channel name so that card can always find this component. Signed-off-by: Chancel Liu --- sound/soc/fsl/imx-pcm-rpmsg.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/sound/soc/fsl/imx-pcm-rpmsg.c b/sound/soc/fsl/imx-pcm-rpmsg.c index fb9244c1e9c5..2b9e4bb5e0f7 100644 --- a/sound/soc/fsl/imx-pcm-rpmsg.c +++ b/sound/soc/fsl/imx-pcm-rpmsg.c @@ -732,9 +732,6 @@ static int imx_rpmsg_pcm_probe(struct platform_device *pdev) goto fail; } - /* platform component name is used by machine driver to link with */ - component->name = info->rpdev->id.name; - #ifdef CONFIG_DEBUG_FS component->debugfs_prefix = "rpmsg"; #endif @@ -822,9 +819,17 @@ static const struct dev_pm_ops imx_rpmsg_pcm_pm_ops = { imx_rpmsg_pcm_resume) }; +static const struct platform_device_id imx_rpmsg_pcm_id_table[] = { + { .name = "rpmsg-audio-channel" }, + { .name = "rpmsg-micfil-channel" }, + { } +}; +MODULE_DEVICE_TABLE(platform, imx_rpmsg_pcm_id_table); + static struct platform_driver imx_pcm_rpmsg_driver = { .probe = imx_rpmsg_pcm_probe, .remove_new = imx_rpmsg_pcm_remove, + .id_table = imx_rpmsg_pcm_id_table, .driver = { .name = IMX_PCM_DRV_NAME, .pm = &imx_rpmsg_pcm_pm_ops, From patchwork Wed Mar 6 07:55:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chancel Liu X-Patchwork-Id: 13583456 Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2049.outbound.protection.outlook.com [40.107.21.49]) (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 428C25CDE8; Wed, 6 Mar 2024 07:56:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.21.49 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711785; cv=fail; b=cJF42+zd5GKieD0dtZOGgmd7cZBU4jLf8hrWD52sT040BjmVBv0UvabmyEnYatHNzlkvq0R6FZb50q6AHuuPr6VXn/QFoEbBkbTUzMVgBkn3xcvPE3RsEnnH4B2Pd9FlazOVa58/N7VJwhetapAKWA/1x0+1a935080/87hLGA0= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711785; c=relaxed/simple; bh=HBmrhhEuWxy3hoO5iNeDkh8W1qQNc1bOWF6AbhCMw/M=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: Content-Type:MIME-Version; b=bgN1X4EQXyxC8ruis33NlO9HNVHTkDQBBiRltlrieIIawX5MAwAUfMeN0LLq/dcE+ikevroL+TiefrWmbF66VIRzpmgX4K2nHDKaf90lW3bA19LGusLPXW2dMk0FunZiC0EtGX0G9Kq81eh7GNCBpJqn220wNjJrcBxU0fyAxaw= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=hAWNN0IY; arc=fail smtp.client-ip=40.107.21.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="hAWNN0IY" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=SkuC9q7aC539gb/8YqlAxGvzvAmHpHqGpjirwOcXMXTs5vF+XIL64bjv/wi3i2ocqLwv2x1nQy4hK4AN5FJ7dwpkntxqQ2FJv+3IV8XKkTgcU2uz1fyQvDO/ZOKlcXCfbCiTGhxwLwSyMdbuBEPj/g8LqlfSg7OHCjEeVsOhWhp4KJEqCB8n5puOT9nZxyI9ad4FbcxnyrfGEwoFdthIch1E608VXl18F2u2b8sJnkFHvNp14cYYSQu0LEJCbJNFOGj0iNRFkY0fNQtfhg9YT8OCq9KNq82r1FFSwRPjvryx4ZRSpjKbBMWrBf47oQMIZAg9JXgOsQqUY7NVDI+cDA== 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=usFJflqaAIQAVMktPObw+rK+eyJhCtZONibE7XKKYLg=; b=mwh7puEfHl1Qxm6aWLjkibevS5o6RlE+m644/RvAf9F1NCHI6BiZ5dJpAq/ga/4DunYjei/qLOZv0rtnrfWpZ6zc1HvVS0jit76r1OLwOVEZVUvgnvZmpjnxmTDGxF+FhtENAqozxGhWhFobi69POVXvP0ChjMgHnI2KSChRJzLZvKVC8g3lhrsPXejAkpprDvxns+aSChJamytziF15QVLVtBMF2IchQdlKjWrjkzro0xwgB5iRQxmFGqNU1WKzZt8F/I+cHIAq3bstjU0u6Cy66iPfREyb5zDBNMQ1gMuFBZ2qJ7rGPAs24BaLRHco69LVvVmbt2Z6ZkXiZmU5Sw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=usFJflqaAIQAVMktPObw+rK+eyJhCtZONibE7XKKYLg=; b=hAWNN0IY/6mGha08sAIu+pUza98hBFT/Sqsnyes3rEBEs8+ktcJpoRa1pUndYQ5x73xnPiF4+R+frpWVTDwysXsl7tiboVdK8i0RdvffvaDffkEJJEfbvMM2YR5KBj/pr+kTFb/DSkM44uk49CeTWLzBPyW6BeHDONv9Jod7Vr4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) by VE1PR04MB7376.eurprd04.prod.outlook.com (2603:10a6:800:1a0::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7339.39; Wed, 6 Mar 2024 07:56:21 +0000 Received: from DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01]) by DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01%7]) with mapi id 15.20.7339.035; Wed, 6 Mar 2024 07:56:21 +0000 From: Chancel Liu To: shengjiu.wang@gmail.com, 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, linux-imx@nxp.com, alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org, linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Chancel Liu Subject: [PATCH 2/4] ASoC: fsl: imx-audio-rpmsg: Register device with rpmsg channel name Date: Wed, 6 Mar 2024 16:55:08 +0900 Message-ID: <20240306075510.535963-3-chancel.liu@nxp.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240306075510.535963-1-chancel.liu@nxp.com> References: <20240306075510.535963-1-chancel.liu@nxp.com> X-ClientProxiedBy: SI2PR04CA0017.apcprd04.prod.outlook.com (2603:1096:4:197::15) To DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) 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: DB9PR04MB9498:EE_|VE1PR04MB7376:EE_ X-MS-Office365-Filtering-Correlation-Id: 30ce7820-dab1-4c86-7c4c-08dc3db2e9a7 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ohzJlRAKso0PYrQe6XDF4im2e+yUWnfxfcR0Rn8VeOkexLyj9GlAU+KRQ3G0si+nlY2A2MDUXlfb/2b7gjbpLJPZ0PKFMxdyDxwKHK3LzjhP6fpPN8RggW+Ex9P7awDZaSIlszdlrND2dBcEnfUzzhTvPicScZiR+eyD18z7HAy77mPYVugE681+NDhqLx1F0XyecqfIc29QtgFERhA1s1XMmhsWGDSTABk0N4ijsY9u7hQ7dEktVUYl+l1eBSOaVeMXe5VrlAMtwcoGeO70Q1XxXfpm1LFRiotUAmlATWJL9PvDMf7M0W6Sp0vwlIdgoJy1AWtm/dMAdFTL9/1/OrSH8NmJ2EVYI2G08GDWtHtyvGaUUvBuLQDECZfB1EjmAx2xApEaO2+8Y8Z0G8p/BFH1D4/zjUFfGYcoUv7XfPNMS8VxOseBHq4d7jwNt3fi8LBEk+5+8eML/1B5Ia9wfej+lymbkjk9Tjq01Hpbhye0N+EIRzru9iEujmvcAF5B7qix4HX1Mb5qHjU7ELrnz6WyfAwnsCwWgTkXePHxZjTATrPS1LCJGgjamd5wCAMTxQ3wq9D3be80KESt6MVuaGSpK7zOmMMjiCEVjhmLYnniJuaVd5ybQO8WMIJMptZxSNm6893VF0ZWAbxk8U/ih7VnEczghq645Oc7qCswFIbDSHW0XZlyxbB2ge4Y8N2jL5snmd4QSJ7Ye8V8TIdwG4ELlEPb/eC0JNXbuvdb3oM= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DB9PR04MB9498.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376005)(921011)(38350700005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 2v2o5RvmBg20l4LPfAcE6+RV65KW/8dvneESR+NR+PQwjtwB7iNHgaibYD2dn30bq71eF4Kd/3+8gIkc4E41BqM0x8AjjmD7gq1RzZvBWgAjx6SZs5juJ909ODOBNB5EXEHkUdsONmO9eF6Lwp0bVMojDUt+FaYaH+0J3biWlpg0Y1qGIU69blF3c00SE0SPHJF/baanInM8N5S4qrFmPknA1iCWVIjbOAICb1pOKbaGrcxOsYyEdjIGnPDzvy6HeAaR9gsJu97JqW1RrNwHvP7y6+OtGQhjNmaccgb5XJYPW1+8tFc2tpTSTAMZS2tJafZH8sUvOEULGQzCqh0iNG5Cqna8TPzKx0AGi/thc/+hjpPU94RNPB5S2uaukpBL25mdZvVLBvmqrG0VnXoUf7iMj4rxAgrAnkBErEbsbEgdgKtJKA20uDsBCECO5ZymDq50C0NuTBN073s4EshJStisWcTGRDzyeeo6y6Ft0FglXSt0aSyLiSRJaVYVWjuJJi8EHt1Vc06DCEqb3PBiIn/S2cIOMYMUrguqfjc8JMgGjm5en55TNCl55JrUczxk8jzH9IRoh8PzjlkbDBEjhsPnrT+etYwHIGx8vOf3hXBhYvWhPB+w7eSe6LvrE+P5soQQRd+lJa9WPwXwFw6p20/2sU6T4R6CyPbmTRHf/1riOcrf+lgmArrzByVYfZkr4wLVxoqhTe6gwaj8dijfg1lqEX7B8ESedalI0c7hMao3lr3viGK0d212c9QpC36jsWTzEtXFzdxnWK1enVK0uZqrk7Cd648VZ4LbC4eozuS+/HlJzjr/vocKKr/R5qalBrB5Dt4iw6xLE5ARHiNg9R8GmYiE2I62s2rS0ZCgiBXsjLn9NiS1ffjTpgDbPt4blR1yHHmVtoDnXU03DTGtgfOvUnXS1o1to10E0wJRom0b0UhSOWTkdBVGamNVj8xv0tsOXdQ4owKK22eHaDQ9JHim+X6Dcas9rPHtycVuXEGBznbJ5ipCcJwQbcGi5yDbas1cQOLXoG1FX3o3UlUFTdOWT64Y8IirsIST/TPL3Xj1ute60TssbZYkPqk/ty58Yh1K1a5ldKB8BF//YBGgD2Xcw+Za8uAIvvAgpiuk7kWh0qLdegme+5/eXWFoCAlUkX2iSNJX0AdTygoW2d4BBX1YzNq0aKiiKiCyCHiFmPwAosfj3fVK/o1SETTSEiESmDa3Ezt6AM1/Z8JXXLyC/J/6ba9u1g2STArjAr3XY21RJVEtbI3mR7Ze2JfPTvDD74YsSK+vdJqpusNOjzRujnigpmPTf7I9aUxeZ3Z8my8QiuBDSVcu2AA/B3VhdWa3S1HLYVRqqPfegOb+rJigb4PdlJainvvf0zvnLkoIreu2Cm7C3GRoJM4Br3inz4ZLIL8cbb7WmmYE+4GwuP6J0mWJGMaqKeQdTees957iM/6QYy9u11cl6isawlzf0c4TFfHFCEIELs4UzjRJrsKVTHXLchxGOlRcd10uPAuDlnWEXNQXs74Nx2ByOOMML7GdE8LDMcS/A0SdD47PsW6aB3nqqnoBpyyXByAB339l4H1b7uJIrmdmLGpRaP+ylEYe X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 30ce7820-dab1-4c86-7c4c-08dc3db2e9a7 X-MS-Exchange-CrossTenant-AuthSource: DB9PR04MB9498.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Mar 2024 07:56:21.6593 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: HoF4gP6BIR22KsKg5v1ATRk+wrkB+Jj5ZOzAfR6z0zFRMJPC7W2hYtaklE2/HUfDGoUkG5+LMm043l5XsJ7iNA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB7376 This rpmsg driver registers device for ASoC platform driver. To align with platform driver use rpmsg channel name to create device. Signed-off-by: Chancel Liu --- sound/soc/fsl/imx-audio-rpmsg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/imx-audio-rpmsg.c b/sound/soc/fsl/imx-audio-rpmsg.c index 289e47c03d40..40820d5ad92d 100644 --- a/sound/soc/fsl/imx-audio-rpmsg.c +++ b/sound/soc/fsl/imx-audio-rpmsg.c @@ -87,8 +87,8 @@ static int imx_audio_rpmsg_probe(struct rpmsg_device *rpdev) /* Register platform driver for rpmsg routine */ data->rpmsg_pdev = platform_device_register_data(&rpdev->dev, - IMX_PCM_DRV_NAME, - PLATFORM_DEVID_AUTO, + rpdev->id.name, + PLATFORM_DEVID_NONE, NULL, 0); if (IS_ERR(data->rpmsg_pdev)) { dev_err(&rpdev->dev, "failed to register rpmsg platform.\n"); From patchwork Wed Mar 6 07:55:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chancel Liu X-Patchwork-Id: 13583457 Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2074.outbound.protection.outlook.com [40.107.21.74]) (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 DE8265D8FB; Wed, 6 Mar 2024 07:56:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.21.74 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711791; cv=fail; b=GXKLD2fz/quQz+pWSSRB6y20n3Ryf+TLBe6YM7FxO1afCHproS9Ztzb1V1p+jarBVcENrBMGN8G3cc6CdRdzYIfixNxH5KaJbkNHvCSZVarEcTB/npePS8Pe3M8QVVvrfEMvG23CEDjej4fmakXE0MZhI4ahmxZeblP5KT4NjVU= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711791; c=relaxed/simple; bh=xX5NUeP9+fwEJxl+VNwTwWVDv1TtsGNieqfcR6+rZTo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: Content-Type:MIME-Version; b=umGsD+PfpyzJ35ItKza9glH5kt8FDxgFyakRpaRxi0QRkGHPq79LRDX8hA5OElXQKTuTHJegZbm54ISfNsWe8EVCt2Jh9qZ7Ycq6yDlNnBk4rU3Pt6WqNj8YxlheT/khV1ElOsAeRkVOY7bEwsx2m55dmEbtIOh+q1D8N17nkk0= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=aQpmH65o; arc=fail smtp.client-ip=40.107.21.74 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="aQpmH65o" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Js8Sjw3OaVSFBKKV3szzHgfVsNFYThpw82oB4yM73kou8Q+4SddTMFto2DBSOIWwJQuWj7oNh+4kmTBHE45mTDDqyIV2Th68AHoej1S3qcuokmO1o1VqyVS5NN7/EEu9tzPUvAVs+bNNex1aAPU8rZhTfchKlqAmHiOjF/PVa0WfuSwRpUu8AtA7NARlB+S1GS0zoCirgjJS4LD922eYFZT39xF7dumLcMhfxTzuqmh4UR3YZnszr75f/BMhgqz8UZdw2RONSBENUVKVSfa0J1SFFNreWi0fhX4ULwWzKiFVX7XqnjdcJv4TvXBsi/Fcx9jM+GD3hUzrwnb9p0sx3w== 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=wgGzeG+iwTNJd/AAbQ6AjkhznAUN+suHLFNatmwyngw=; b=VZIDc3juLEC2pF2HfAInhKYr++FNSFJToelSGk6m2onkphh41ensG6kWDIQCeEdTJO4aL3qOlTqsd/IWXHPwTUJBFEKl9sMNykbrwJiiTwGcILOWaun3INz1fza0eYaRE59rt34UwQh198D3yXrgQ5sQXw0DvOFKyjTBNUVk+fNjUmDSogD8mInQ0AuF0JKds1nK86FyQ2iNs7Rkc3kOhPqS3zkI4jzqo1ZH6KroIbWeo8WPgdlwF5oKLTT+t3JQBoQdQi0s6rsKZg7rpRMIWCU5SUEMfg5z4G/10dI1Ma6YtYvbGPrb8EbSdTL2tutFDhVJ+GUo9VIaTZwp+7VY7g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=wgGzeG+iwTNJd/AAbQ6AjkhznAUN+suHLFNatmwyngw=; b=aQpmH65o36JP3fh873lbMSYCMv72jbk+JS1wnhA4cXybzJ+G2zI9pdxv25akCM13DAulvYmZ1W7BKb1PJAlhSv9FxSxYTwc70w3KpC0DpmZSSkKB3bnXBhZ78hu1ruZuhOCpT9YtutLun+BRIiHHYy4sz88Bu4wPKFRmUh/v/rc= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) by VE1PR04MB7376.eurprd04.prod.outlook.com (2603:10a6:800:1a0::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7339.39; Wed, 6 Mar 2024 07:56:26 +0000 Received: from DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01]) by DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01%7]) with mapi id 15.20.7339.035; Wed, 6 Mar 2024 07:56:26 +0000 From: Chancel Liu To: shengjiu.wang@gmail.com, 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, linux-imx@nxp.com, alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org, linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Chancel Liu Subject: [PATCH 3/4] ASoC: fsl: Let imx-audio-rpmsg register platform device for card Date: Wed, 6 Mar 2024 16:55:09 +0900 Message-ID: <20240306075510.535963-4-chancel.liu@nxp.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240306075510.535963-1-chancel.liu@nxp.com> References: <20240306075510.535963-1-chancel.liu@nxp.com> X-ClientProxiedBy: SI2PR04CA0017.apcprd04.prod.outlook.com (2603:1096:4:197::15) To DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) 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: DB9PR04MB9498:EE_|VE1PR04MB7376:EE_ X-MS-Office365-Filtering-Correlation-Id: 9ef007f8-46ea-484f-ab02-08dc3db2ecca X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ZDXBDj4Z33vSjF+trkNOfZXoAKa2YCnmiGVBJPf+ZCWWIAvR629HLH6VDAn6iIdaNTg7EN51ELeXW50738fAfqBp3xSgR+PQ53xQEgQi4c0KCKVCYxyeId9LdFx7mWRSxFIxYVIPMm2mLstgcQcb9UvAIo3rIDe60ctkFXrGKtzswCOSKsDuXQa0w9zU5oM+UH4cLf+hgm3ybvA5bRrj8uhKGGvYRz10Oo6nSP/NgREEIVHrTFBRPhTkqHpQLhW3FZp7op/shKmCuSJHJc3vrO3QG1g/YcJOgrJxKIgZvSkDgoY7Fr7EZnuthqVM1b+PfuhtZV2Nv+jpwBBLpPRJ26NdmxcMgGPWKIcmSmcmBUSmOQlp+M2Xu/AkzDXHP2x0INkOIH+wm3AtszFxk9sTYEITYHbsfGBDpAv8+8cQf6tDqIelf+KQOw+H1HR8iT9+bJxyKMdTThdPu+qj4m0vrD5WPej76+D7u35u+Esm4roWvu5uouH0P47QnfW/S/b2xbMIDM1naqkniWit5WoFV1+hGRXly7T29HlM7KSMi2BTCbOJuid22dgtD/3PiiwIF3gQ8TCaLbhPB9MywJmHAGyUe3ThnUvDddK9+HGKrINfSR7j0FIE8cegarjbbp/Rr5TL9zp9CWIs8XDDgYPhYZ0dfYbpgXMcORJH/z/oOTx8QqepHPoLGPrNuIPL65EUXstuY8RGmCqTT1/ifnM8Jk+pVaql7Vk63o1569L8eA8= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DB9PR04MB9498.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376005)(921011)(38350700005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: oHaffo0X1sfIB/xo0qytN0TW2Msuu/eDOBt2jE5uYwF9mTvLEZ8DNTez5l9rNrZDe3YCosRMtatWYqWGXLVEuWh6rXIJWBKxHYHbNGx5J6Bpg899EJDfcvMlagm3rOEFqe2M2obpET4i5oS3pr+BOESEkpfdlW2dVSBVToGxv/BgdDQ2H0axOetfVJVAKc62Qb79uAfj20zKpY4f/mBjhuy89SFryn55s9Hgq84acG/g+gLUIJY17ZpAvYeVxNgx27mHuAazthG5e+PmnhBXKBJeTLbIARyL7rFXuGI70nlNgqTO4yOmYPG5PX+2uwDVjrUEOZzW4FiLOkKArKavtBcC9P2gjf7bmqYhzg3X9ZezAO/iE0z4qr5H4WBCIugAptvKKjXdmx9ytiSX2Ghf49uiPQdmWtGkjNbrYHR9Go2lucCcd3u+SEyv9TwK6Hfp6c0tl98Jf9NqD7dFLNxTgj6rVnc9HkwwyEVrxF9ylShz+agWLup2B8I4TjDvcNaOdhOGagw8/zFy4fy7/lXLQZ1X8CGdtlN/2+M3qMzPwbLp+suL8qWPtkrqTTcm9M04DIoBr0hIQ6QD4m3o02QqZbmsIncmLYsVfIMdG8fncOu08n5ngC8+Zzet3Jf7p9xBfScFAtND4NKzhYmNHQ4B14AnjGkk08pzX7ZpNdY4pAJWVItCJtdWknZNu95kBParbN0baIrNRlPi5HiWwEdTXVJw04bM99JF5zkGdisNyUVz+ngi5wVrh3QI4g95ldMax4s5dnEglbFsOuQkcD8I9iVN2/PC8E2L9u4NIgHe0XSu+aLJLIGKCq1rnunOWmfv1sOBZl6APOURE3pntwPQKgXO8Zj8LcReVjjDJrpnic1mJ+N5lOmvgZ97Sa8j6/Tee3SyqIrmqWhY6XfwVYkx71gNdpK+EOhMlskk+CPpDacFAfWGsibNHQIyUof/UgNqpSdJxJhV27QD+6oEp8sD+mCSNu6zoL/cL4VMzLthaICZcFpSPylsZytPS16q5A9GW5XlNaS5kvBsmT1jDWlwNNq9FmXgaU0vJrwuRT1P9itHMsA/OMSs9qTrcYMV87oENaLwT2hcn4sA5kjIxPd0jl6ZTEkZE0aIct9bUHW8n0n/S8tnxKFSlhsL/iXMmSZucwIYg+d7dTg/oz1KuCRAPfr48MCWARamq09ecswG76iTXNqmCtWyuSCfmLBhePznAO37j/xXdmKGjrLQ2D998rZAgdDIcun3AN0SvSbjR7+phvT3NuuxEzP92C8aGMzMiDybHohhewe0w8gkRPUdpFOAIeWJgz2MiSgsbRkSLtGGluCNzUIjZIAJeLLIwsRAXTAgKR/Qlxk8wdlQ+KoROgp+XPjaGbnoI5EjyGUjlSGFDTBUTpHiDwocEy/1UgI+L9NTmymBUFcUjUQ6GjDryCwTRBs18Yv/MmLLj2pp8riLbaNp7y8Wv+pVdM0ntfvj5/gE8BGlpuvn1SObY2ucZFugMxMeqMaT/QQAtAK0/GEHA5V9VUP5NyZd8XHahifI2/pE/Szg6IIUZYG1jg2IK99wah644GE2lpXPtTJdX79tnhrsKOuDuFrQgkdr85yd X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9ef007f8-46ea-484f-ab02-08dc3db2ecca X-MS-Exchange-CrossTenant-AuthSource: DB9PR04MB9498.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Mar 2024 07:56:26.7987 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 5pMs1NzbT0apiJeB/iRWX44t4OFoWKxuoYvHGQADOBL0SLvlyYgPRLyeoylrNW5dmQX63Qiz6YkOeXPn/HTtUQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB7376 Let imx-audio-rpmsg register platform device for card. So that card register and unregister can be controlled by rpmsg driver's register and unregister. Signed-off-by: Chancel Liu --- sound/soc/fsl/fsl_rpmsg.c | 11 ----------- sound/soc/fsl/imx-audio-rpmsg.c | 18 +++++++++++++++++- 2 files changed, 17 insertions(+), 12 deletions(-) diff --git a/sound/soc/fsl/fsl_rpmsg.c b/sound/soc/fsl/fsl_rpmsg.c index 00852f174a69..53bd517e59d6 100644 --- a/sound/soc/fsl/fsl_rpmsg.c +++ b/sound/soc/fsl/fsl_rpmsg.c @@ -240,17 +240,6 @@ static int fsl_rpmsg_probe(struct platform_device *pdev) if (ret) goto err_pm_disable; - rpmsg->card_pdev = platform_device_register_data(&pdev->dev, - "imx-audio-rpmsg", - PLATFORM_DEVID_AUTO, - NULL, - 0); - if (IS_ERR(rpmsg->card_pdev)) { - dev_err(&pdev->dev, "failed to register rpmsg card\n"); - ret = PTR_ERR(rpmsg->card_pdev); - goto err_pm_disable; - } - return 0; err_pm_disable: diff --git a/sound/soc/fsl/imx-audio-rpmsg.c b/sound/soc/fsl/imx-audio-rpmsg.c index 40820d5ad92d..a6817ce1e92a 100644 --- a/sound/soc/fsl/imx-audio-rpmsg.c +++ b/sound/soc/fsl/imx-audio-rpmsg.c @@ -12,6 +12,7 @@ */ struct imx_audio_rpmsg { struct platform_device *rpmsg_pdev; + struct platform_device *card_pdev; }; static int imx_audio_rpmsg_cb(struct rpmsg_device *rpdev, void *data, int len, @@ -95,6 +96,17 @@ static int imx_audio_rpmsg_probe(struct rpmsg_device *rpdev) ret = PTR_ERR(data->rpmsg_pdev); } + data->card_pdev = platform_device_register_data(&rpdev->dev, + "imx-audio-rpmsg", + PLATFORM_DEVID_AUTO, + rpdev->id.name, + strlen(rpdev->id.name)); + if (IS_ERR(data->card_pdev)) { + dev_err(&rpdev->dev, "failed to register rpmsg card.\n"); + ret = PTR_ERR(data->card_pdev); + goto fail; + } + return ret; } @@ -105,6 +117,9 @@ static void imx_audio_rpmsg_remove(struct rpmsg_device *rpdev) if (data->rpmsg_pdev) platform_device_unregister(data->rpmsg_pdev); + if (data->card_pdev) + platform_device_unregister(data->card_pdev); + dev_info(&rpdev->dev, "audio rpmsg driver is removed\n"); } @@ -113,6 +128,7 @@ static struct rpmsg_device_id imx_audio_rpmsg_id_table[] = { { .name = "rpmsg-micfil-channel" }, { }, }; +MODULE_DEVICE_TABLE(rpmsg, imx_audio_rpmsg_id_table); static struct rpmsg_driver imx_audio_rpmsg_driver = { .drv.name = "imx_audio_rpmsg", @@ -126,5 +142,5 @@ module_rpmsg_driver(imx_audio_rpmsg_driver); MODULE_DESCRIPTION("Freescale SoC Audio RPMSG interface"); MODULE_AUTHOR("Shengjiu Wang "); -MODULE_ALIAS("platform:imx_audio_rpmsg"); +MODULE_ALIAS("rpmsg:imx_audio_rpmsg"); MODULE_LICENSE("GPL v2"); From patchwork Wed Mar 6 07:55:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chancel Liu X-Patchwork-Id: 13583458 Received: from EUR02-DB5-obe.outbound.protection.outlook.com (mail-db5eur02on2081.outbound.protection.outlook.com [40.107.249.81]) (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 2C9DC5D47A; Wed, 6 Mar 2024 07:56:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.249.81 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711797; cv=fail; b=ZEZYi5g3NnVQNymywjoTXjJjW+SDDYbAWZzR+puja3F7XUeomRDYl8A79p851ofpUTROPfL+oOUY3mATK0K8a1NVILty+YcyknaPPiDHeSaLT8ZXuND8LpJ4Rzqvcrkb7vG3jKQuLrERSTozuT2rHJtZNdRUgiIBZAGOCmXfGL4= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709711797; c=relaxed/simple; bh=ABObIBVV0pm33eBjssCezbbuagIOtvDFTS+Is3Z2YtU=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: Content-Type:MIME-Version; b=ldNmzCDu0Pu+mJzUSfr+mE1g8cumC+D/uLi73jsHkyBqpQY9bDFBwBAcB6WT2YcJa7hTabr/f1uR8vx9u7mb/ShT0FaGlM969Ecpa4XivElfwZZCAO0Yp9fTh6Wbza9wB08S4n5/9tfQo41ucv3LLQncbSdeyoRYc36XuvveJMI= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=jrlqsufg; arc=fail smtp.client-ip=40.107.249.81 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="jrlqsufg" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oFsB3PFDdsmdL9t0ycUI6Bye5dGEQqS6uE5J1qvqZ6dkC5otnhvjq6RyJsNFgqpLEFNqpkaCB1eItIGVoUnyAOyexJApFnFlm2VUDgYR+UocxY93u2wx+cuBgoZB/U3Nnxh+vy7aJ6znANcxuPhU9JwZ0hb5JOh+PVT0UklJVBvr7M3v8danLV4EdqTW+RfIPP83XdEMs3pPGlX9JJPWg2g574RjtObxM5eVEZOsXTrrCnysh8y8CRcWEccVTaiGTsSFP+/KC/sOlQUMS38R8OK68DuWv16U5IZh6OR9+49hw4kJOytAXVyP/kF9AZQcmJkcEUEayeZe37c7wExEnA== 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=C0HxxwqbTUQyhMeXXnXFbjpyx5CV83NN+sqlk2mdOZE=; b=aFXZkr+jWyb2pUQ3vJlExtSCWpw+KdkcsX+YKjGo9uiGV25By8j656pqsQR4klRiozrxg8phhVoIxBOI3v3keyXpDJ1P+9gyKcGBODgKGwL75SQ8x4lTHVdMO/rie86uq09PlJ5za/g3xpgogxMRg5cX8joZaPiBuT5Ltm83XcYmHI2I1BGkhiJWDQcSrCxUrUsCzZ61awgFxlSKnRtiZdv6topEPrN4XxK2fy0d2B6P5N2VM5zj5Wtt2JqDgPsDA3MoAYlgjMqmEPoygXsPbp3IVhWAdflWXw7lI6Ayr3ot1s0KVJQiBpotkb+KS+Jos0V1hU3FJcF3i18xsncqvg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=C0HxxwqbTUQyhMeXXnXFbjpyx5CV83NN+sqlk2mdOZE=; b=jrlqsufgwvu/8fdl8vaf4zS8Gvnkj8Qq7/oUAUSSw6hZusgoWGyc8FfhBejuZxhkQ1wj1GvfpypU8J57lfWZ+XHn/mKQqeCf5mgCZxnm5YsGM0rA0uRkynDxpKZiohIpFH1GvFmSB1StPYIELsNb98mLGi565b4OjKW+smQXAeY= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) by DU2PR04MB9147.eurprd04.prod.outlook.com (2603:10a6:10:2f6::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7339.39; Wed, 6 Mar 2024 07:56:32 +0000 Received: from DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01]) by DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::4bee:acb0:401a:3a01%7]) with mapi id 15.20.7339.035; Wed, 6 Mar 2024 07:56:32 +0000 From: Chancel Liu To: shengjiu.wang@gmail.com, 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, linux-imx@nxp.com, alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org, linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Chancel Liu Subject: [PATCH 4/4] ASoC: fsl: imx-rpmsg: Update to correct DT node Date: Wed, 6 Mar 2024 16:55:10 +0900 Message-ID: <20240306075510.535963-5-chancel.liu@nxp.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240306075510.535963-1-chancel.liu@nxp.com> References: <20240306075510.535963-1-chancel.liu@nxp.com> X-ClientProxiedBy: SI2PR04CA0017.apcprd04.prod.outlook.com (2603:1096:4:197::15) To DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) 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: DB9PR04MB9498:EE_|DU2PR04MB9147:EE_ X-MS-Office365-Filtering-Correlation-Id: e9083713-b647-4051-b35a-08dc3db2f00a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: mR/vwwmLdF94JRO6Y25cSjgqB+z/A+HSbLizGtzA7nieaDtfkQihwS7fjNJe2WvKzTgVE0b9jZNQrvPLXnpwepe+88rvs7gZFkwx6uDv4PcnAzxXdcI+93iP/wk22WbSoIqsj7IuhcUgbup8L18X7Z5S41R0nZMRHFS9AvMaenOjk3aX/MyobPMuZJtnGxG0aRFTbAXjPLlQnozeBLIgFrjJ0QB3EE5if2/X1zQhzwt9c7wxfaodkgPflAqdaan8KwjCgQfB3RRm7gjzv92eG+bdicu49x+IghhAa6+5qfkvrnez9G+MWhhIQsTh4naxMvwgZipMutJEopfyysD0mqzbQ24Jb48l6yZDOQqXMGCSXLFTPFXEeX45M042iAfrlBBnIscJIDlY2ZbrbQxNamHk3oTU/COb+6p+aGk2CDKtw/5LAIVAqUvSoRu2S/HK2tDMDCtmsY0JhKZiickjPRgu6twRWFa+QDLy/7L34eelGHMwQfkGaSUD1zY1rAKie9xksF2ELgeTsGg9CCJ91RHEbj9Hsh2jtD19GqDsF4hwTF8wb8f4wJa8OH/xFzqwv8w+4mNtfANvHKp39fdz8wM91uCHTZVOnThNMjriyO6kOmdyhhWrFWu8uqdvRgHqBJd7bDhMXCPvkkNjcJQIe+2VVmkZtZF/1mHK/lSgCqhh6JnWrjMY8RcI328/4j3CgnI34Rkg2b0SXShwjxOJz++A0SAPJxuIX58sghU/m/8= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DB9PR04MB9498.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376005)(921011)(38350700005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: MzZMjqGo7y/wrOG7nx1SHROhWjPx2Gjcx0EHzRvoss/AToOAzoX9JDQWZZK6RpZBbW9rEaJLnpC05ZlvQ/2Zo+K++uwqK8LEyt3Ya5UdLnDQATBATn2knkiDawZlp4Q/1jjr6xAldDHStTVLcyjEEHw9Whksnf9lMKp0mdrSXr5h5AtQvk46uFXj4Qd7SbmoyRLm30ifoLH7tQzBHRKPwaLI+ihjf2PF/HKuOopbsyT3FimEbwQJApGY/uM/sGL3fcPWuVxbcqFokxcuhYxl0+L9uhTQm1hYUgrZjW7kJmuFPqixWkX9KdRpk7pBv9U1Nljr+M5KCKdDxAPWVZw52qrmAlxddJ2elMP6PXWHolB3iVNXoBTIJnjIBIw7CHP40McYe0bSY5BS1BHcoT+5H+1XXy9MgH+w1DB19APumKBBmq4YpAjSwyl8s1sJ2RB19k60f5ZIBTASfsc4vOxlTgVhyFdXJJ/3k8px/FXwjtPL9dZF8uQXK1/zwzmzuYtCLg0/wKmmJoo5JB3AZ4pxnVKjyE7YoPhRgHvlZ51SrLiGx/ni/udjMN2mDRYuG9lY+niePHkK50mCwGhbgOyVnf/Cobv2KcImIQE8us9PYuHCjL2FpxdID0RiQW2Jd8cN4R4AECOig0IV/7gqd47LQEMgYXdFcAkXD27tTCHCvDUvo5y9DFHLzoaWI3AbC00HqOamuLc5mDCxh0VeLBL2WYYpGGFI+XHUlBMgLZYqRjxAeFyXNZCbSKw1YFIGfJ5yiNfxEQbHImfI6HMLmnf3pYWNRsj+v+dTrzWTqowPu/QQcsiXSoLPGPUePIparZP3QAD2U0ju3ivesqWlEE7HFsmTpJwhH91VbboTPPltxzTOPEFnrZUKOFQCpUaPj2BLzEyZPSYO+CrWRjx1l0aRDww/6WuCwc3MlmbV1wEOsFy3D4wNb8eWzmPUqa4iCwmrjkaW1qZkL2aAOhHq1mFKofR0lXyih9xVsqc510a0GhQpSgIPRRtyCGUADey11ZedAW7MCT5Vu+aEUVLSo2+t323kMclLnAQve+ImUBXPUb6hAO4bjSF0rpHFDlwsZiB7ebmrbsc5PeOyAV4V2+l3xyhHlT4yhZtay+/+BmfQv0rLTQj+xPlqID4t5Zu2eBIHQAq5hKtSz/maufE498Qy59VsTMOCpt0LuLTSS6fDi2U0RseTECFBTDT8FeLX7TtQjI+1FRjc2i0EMB0BREO8S28bUbcd9It2/bhjnSZv6HJ/PXEp7jXVZx3pzIsY3HgoeZ+4MD1dpKvaEDGiEeVjBYZyVPYxRiHYHHEeJ4nZ8LQYS9Grr6x5WxzxnDYseHWtoSvCj67QUOyIcvC7nB1Yl6K63BVUVkRxZU8/QItZcpLct81T69fjt3xLMChAAqcKNHZsMVKmgwaYIyUXWFrJTaksx7p0VjSis4qZMKIdq+M7c0R2D8r4KI4enBCbkPCu4Ya6YyaQuS2B+sQRMb9dr5JXlwyC/88ptwHythwSbbA2F1My1Bw/FnqRc86MWRCrhkXpEYQB7jThQnQWKHnueb80s3tli/C892Inaddg5ej3yWlvv5Vrsx8V90a7QSwD X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: e9083713-b647-4051-b35a-08dc3db2f00a X-MS-Exchange-CrossTenant-AuthSource: DB9PR04MB9498.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Mar 2024 07:56:32.2170 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: uqYAVVvBbScxeiDNv3L7qd/sOT0zFSiGgy9g66x3u2HreaY/0nkrzY8fNJJRx0QKRFaFeMM7blWBaySLEdDkCQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR04MB9147 Platform device for card to probe is registered in imx-audio-rpmsg. According to this change DT node of ASoC CPU DAI device is updated. Signed-off-by: Chancel Liu --- sound/soc/fsl/imx-rpmsg.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/sound/soc/fsl/imx-rpmsg.c b/sound/soc/fsl/imx-rpmsg.c index e5bd63dab10c..2686125b3043 100644 --- a/sound/soc/fsl/imx-rpmsg.c +++ b/sound/soc/fsl/imx-rpmsg.c @@ -108,10 +108,9 @@ static int imx_rpmsg_late_probe(struct snd_soc_card *card) static int imx_rpmsg_probe(struct platform_device *pdev) { struct snd_soc_dai_link_component *dlc; - struct device *dev = pdev->dev.parent; /* rpmsg_pdev is the platform device for the rpmsg node that probed us */ - struct platform_device *rpmsg_pdev = to_platform_device(dev); - struct device_node *np = rpmsg_pdev->dev.of_node; + struct platform_device *rpmsg_pdev = NULL; + struct device_node *np = NULL; struct of_phandle_args args; const char *platform_name; struct imx_rpmsg *data; @@ -127,6 +126,22 @@ static int imx_rpmsg_probe(struct platform_device *pdev) goto fail; } + if (!strcmp(pdev->dev.platform_data, "rpmsg-micfil-channel")) + np = of_find_node_by_name(NULL, "rpmsg_micfil"); + else + np = of_find_node_by_name(NULL, "rpmsg_audio"); + if (!np) { + dev_err(&pdev->dev, "failed to parse node\n"); + ret = -EINVAL; + goto fail; + } + rpmsg_pdev = of_find_device_by_node(np); + if (!rpmsg_pdev) { + dev_err(&pdev->dev, "failed to parse platform device\n"); + ret = -EINVAL; + goto fail; + } + ret = of_reserved_mem_device_init_by_idx(&pdev->dev, np, 0); if (ret) dev_warn(&pdev->dev, "no reserved DMA memory\n");