From patchwork Thu Jan 11 00:50:44 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 13516703 Received: from JPN01-OS0-obe.outbound.protection.outlook.com (mail-os0jpn01on2105.outbound.protection.outlook.com [40.107.113.105]) (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 98AA038F for ; Thu, 11 Jan 2024 00:50:47 +0000 (UTC) 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="LrSpKMpn" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kXFZd0ygJ7rPr0sjMHCkSYNgtFkLpahztl5ap17CUXMD41l64P/3PGPZq/6O/y9zGsbl96xCnXJI3/dfPQYFMl8Iqvt88VK5gd49p7CoP0twxbk7yGoliOQbu3eQXA7yyYgf2WquGTb0HZ2hu+AW8issQbSKc0iLFoRRUUpObdQQbezZwnMath9WUxQ8abEJCsNOqCjR4wfsY3ha61LN19xwLZv/tQbqlXvuvO5jh6b+fNtBi7NM+Q2I5DlK9+pD6P69eQTv6p7YVRdFGsx+FaSbbSKwc/51SvY6e2BFsmNsKSTb4A1XYs1A0xQhzhTuhSsWmtox7oJdd6466ul8Jg== 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=nA5ulsqctQGkmlkhXE46nl+yvAM2t7d4kqamtwDaAhk=; b=k3q70nLa6pnNRuH6khF3nIkR7O8P9uQKBDsOJjt7OYzygZ9qptaMOnSlmhJnz0oz9TIxaO3ho8eH9ovlEWD9FdK/LZwLeImQHdRR3zH74xWRvSHpGgvowOI62IZg8Xe/Rimq39AEvtOib5/2g3J0sAGgyt+c14o8AJV3q2AD+cDADSixloy6YIv1u7OlzW0UN0iKSmChZw7EjwQP+zXctYt6hKUYq5V1t0gJ+Hzz5zZ/Sou0GY0orsovYbbBx8+85oj9zGNZNcEbCIyGCXTJdadFdCZYs8JJV6mwnYz//sRvxW4swwjKqrs+16yC0/iZjgteSB1MuvapxZmpbhFQQQ== 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=nA5ulsqctQGkmlkhXE46nl+yvAM2t7d4kqamtwDaAhk=; b=LrSpKMpnoIgZ/boBSmGzBjhN/qyNvGTXjhKfUBEmdh/Ox2vspXjXiy+iYalI7zllxC/3lPqM9QvTKLz2+GahpIF7YOH4WkMqOG6BlGV1t+W5xfgiOjSXQYXkYE+Jo/0rDOpb7qy3QByAjNKccohqSFMnI6n7qVlWXjmVyW0uxfk= 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 TYWPR01MB10908.jpnprd01.prod.outlook.com (2603:1096:400:393::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7181.19; Thu, 11 Jan 2024 00:50:44 +0000 Received: from TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::91d:1bfa:edc4:1c5b]) by TYCPR01MB10914.jpnprd01.prod.outlook.com ([fe80::91d:1bfa:edc4:1c5b%7]) with mapi id 15.20.7181.015; Thu, 11 Jan 2024 00:50:44 +0000 Message-ID: <87wmsgwv4r.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto To: =?iso-8859-1?q?=22Uwe_Kleine-K=C3=B6nig=22?= , Alexandre Belloni , Claudiu Beznea , Jaroslav Kysela , Liam Girdwood , Mark Brown , Nicolas Ferre , Takashi Iwai Cc: alsa-devel@alsa-project.org, linux-sound@vger.kernel.org Subject: [PATCH v2 3/3] ASoC: atmel: use devm_snd_soc_register_card() User-Agent: Wanderlust/2.15.9 Emacs/27.1 Mule/6.0 In-Reply-To: <871qaoy9q7.wl-kuninori.morimoto.gx@renesas.com> References: <871qaoy9q7.wl-kuninori.morimoto.gx@renesas.com> Date: Thu, 11 Jan 2024 00:50:44 +0000 X-ClientProxiedBy: TYAPR01CA0165.jpnprd01.prod.outlook.com (2603:1096:404:7e::33) 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_|TYWPR01MB10908:EE_ X-MS-Office365-Filtering-Correlation-Id: c29cf8e5-d1d2-4fc0-d078-08dc123f57d6 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: iWUgzuM/RTD8sOnF/2yQgj1go5+jqXRFeaiXnpUxAC75hpT8JcOXj4uhh0ayTKjk8ndZ9b9NzDCLgfgLMP5W72Eozau7CY/Z2l61gEzNhm1f3sKXKMgtK3bWy60IyVQO5J8StrGpyAOq1ukw8tlGrat1PuLy/OrSq8oSon1Y/wPd/1OY0GSXnvmYmh/Lig/xkoREDqkFOfN7Bw0H0mvAiHbVt00C4XliGnb8kV8LHNMLVBoWK+OlaGuLFalZu9ctoybuLaRzcNGfHZgmjHXhcvC7GFmV2Ehb02Xsxnrq+oMo9Ys+2bjSFldp0UAT+Xk2v7yOnjnVq61b3hgG90KCixxKKcgBaHJwzkZGL9NJCgemBswaRLGcOmsGcKU5mRHP9m2m7mAw4Yrv4otxst1w1iTe/RNAQ+flHROBBYIFJkmopSAwAjerM4fEzR+ilf48Jr0tUzVfeG2P+02h9BvJCErv3re5z49OV+8bAzSd70SbGSzGGjOZ2NyjY0ukg+WKiiEWyDTHIW3rdaWAN0gVqBePve/rAkc3gnynYbqGZAK2iA7cGdQ4G1IoDcty77yptUQ8fTU9DK+GgOMGogloDMe8FGudPlJEX+jtXNgHhbzxgHhWtxJBh3Si22He1oon 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)(136003)(376002)(366004)(396003)(346002)(39860400002)(230922051799003)(64100799003)(1800799012)(186009)(451199024)(2616005)(83380400001)(26005)(6512007)(6506007)(52116002)(478600001)(38100700002)(4326008)(2906002)(86362001)(316002)(5660300002)(110136005)(41300700001)(8936002)(6486002)(8676002)(7416002)(66946007)(66556008)(66476007)(36756003)(38350700005);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: C3Mq3tjcAiOZns9PPeOs/He3BNC0na7oHVsSpGH645DLr3mv6RgfwzkNNHCAN/jOeihYrqpYfGlGAaX56DSfXaHSrTbEsYyMplpscCoTUV+F/z9nugK2iZ6rYcy7kYAmde0iHEYZXR0O3LXakuhghaTOEDXHWqBrsQ6iUVxJu+wlEd6eouSZuvlaaQ8SJu27Kyr6NUniX+oLhNp8J0sT8pLgKUsodykQ3siCNqrZya+qjSq+BMgq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8dmu/frow5lGqmfQQjm/i6CWLpTITcL8JWTUEAWHRpPBmtDheTl/e3qhPPvS6chusf1f1YWw2uCE+fl9FmnX+VTGmGE/gL7rMph52be3Tgfp6G1iWWu1sV9gObm/qgiUJAX2NfeyoI7+8+a2SI8y7e4v3ZiFcQcIBe7K3en12vjTew7UdDSXHKU1px6rAKJYoZr7c4iTv3Sx9EpVdXdaZtzvSLvfVyRttZPKb3jpp6xvKkR8cCJn24cjh3Zjot5yliaB65INb7GdQVGbMb5z6SUY41MN5mvMqqMJyvePnLlfLFDrcc0dRYVP8= X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-Network-Message-Id: c29cf8e5-d1d2-4fc0-d078-08dc123f57d6 X-MS-Exchange-CrossTenant-AuthSource: TYCPR01MB10914.jpnprd01.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Jan 2024 00:50:44.6886 (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: iQTesFAte9Kus1LA5lw18AuYQrDU3R4r52i07f4Dny9XSuRfdvkLT0tI67rDXRgdffdYe/pjEwg8LDjgpC7ngocbaomSaWb9WOCkLQ/MZOBS8+bFFJsVvG5bQjmr5Kgp X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYWPR01MB10908 Let's use devm_snd_soc_register_card() instead of snd_soc_register_card() and ignore snd_soc_unregister_card() Signed-off-by: Kuninori Morimoto --- sound/soc/atmel/mikroe-proto.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/sound/soc/atmel/mikroe-proto.c b/sound/soc/atmel/mikroe-proto.c index 18a8760443ae..8341a6e06493 100644 --- a/sound/soc/atmel/mikroe-proto.c +++ b/sound/soc/atmel/mikroe-proto.c @@ -140,7 +140,7 @@ static int snd_proto_probe(struct platform_device *pdev) dai->dai_fmt = dai_fmt; - ret = snd_soc_register_card(&snd_proto); + ret = devm_snd_soc_register_card(&pdev->dev, &snd_proto); if (ret) dev_err_probe(&pdev->dev, ret, "snd_soc_register_card() failed\n"); @@ -155,11 +155,6 @@ static int snd_proto_probe(struct platform_device *pdev) return ret; } -static void snd_proto_remove(struct platform_device *pdev) -{ - snd_soc_unregister_card(&snd_proto); -} - static const struct of_device_id snd_proto_of_match[] = { { .compatible = "mikroe,mikroe-proto", }, {}, @@ -172,7 +167,6 @@ static struct platform_driver snd_proto_driver = { .of_match_table = snd_proto_of_match, }, .probe = snd_proto_probe, - .remove_new = snd_proto_remove, }; module_platform_driver(snd_proto_driver);