From patchwork Mon Apr 24 02:36:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 13221511 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 C07BCC77B60 for ; Mon, 24 Apr 2023 02:38:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Date:Subject:References: In-Reply-To:Cc:To:From:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Xop6hXqLxQE4mss3XELz0jjWSF8vbH0B9Vwe/iPkpow=; b=z96bc/bRLhepnR d97psBOUL5oNUOlOsIwfPS5x092uh4NT+mRWjOh/65RUWDzyLF1yblyGgKL6bsEZPEZqs/UItidiL S8RpEADVgVsZqWb/0dCQqzU5ql63mKfQPY3ZSrYiXbTBvCm7oi0GL2bpySoS5sVco2j4+/CWU+c60 r8pX1ftCx1A6Jx1kZcN7B9KNzJdPvHj/+leXqbC+M1FGCjM6Stpv4GEytNRoUpwNzxbJ2aNSULZOk jHZBZjshLxDZb8JoGxdPtqq8MLy+iS++ta6TvpcJQqBMzXryZlA8dvlvmdrUL50Tj0S3Ft/PHCRQw u0eyBqZk2O5FVIr48svQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pqm4f-00F7yi-2C; Mon, 24 Apr 2023 02:37:05 +0000 Received: from mail-os0jpn01on2071a.outbound.protection.outlook.com ([2a01:111:f403:700c::71a] helo=JPN01-OS0-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pqm4d-00F7wa-0X for linux-arm-kernel@lists.infradead.org; Mon, 24 Apr 2023 02:37:04 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hFqMdEewN9UQ/6BN7tFPKH3pbTxiL/uDG+sv9Nj8XoXCb+EyHhowTQNSw8gP0Jk4tKyc1PetOtzURCMZ6xe3stVwipRrtEUR8CcigIypFRpI9U8yKG7wsCM7l+9DWxRIdIFGzVs2Mc7rGG60wPoKEhS3+2UmESwfDFBe+0H5AXcQ1oHrHvRY2QB7Ls5wYI/g16WCDnixDl9wcRakg2J37Kaq92w7QNsr7sjqmY9HIREwuP/wVxxESNg/QvCAtpM9FguOg67sd2ukqbrmCJzX662KETXXacy0EpNFdq4k+h8Zhb+fG42WyyN2149/L/WuyBHnJZDiKO7Gj2bDtk9XSw== 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=brsO5m2NcuD7PSPK7lBj8uHBboetIwSFbmapRzxiUcg=; b=O1dh3UZ5ZNnAI5Uu+fkH8trXRris6s8gCOc5Huhh3hzl4Yg/FC3M+Su9NZQctt32YgClNx4Zo//v1tg6jVoZTnMV2pQPf8aR4T4KpaJ6Ir+tHakBE+EveGQMQnTEyx8iZldrEsKLGusovFGQt+p+IvSH9IsnYRNJnKUxz+wmDTMOgve6UnAJtW0rGfw3qbwe667ELociVJw2iiWVy2q/QisKLyV/bxo2FFKm07cIJPJBPfxVuKDXRo7L6f6tfZBwNmSCCo46jM8twwOHnP6k4TN+Y1oCSIqG26P5edXDWIcA0Zqr3AmWS7SsOqQX9zmSgMexxAGVKEfL9cznKrGaog== 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=brsO5m2NcuD7PSPK7lBj8uHBboetIwSFbmapRzxiUcg=; b=UKYflfAW5Su1weGZpCq7pquUE8QHXkukKiiTla93rFzRpEhSw1RYoWr+RzGiJ2XAYPbNAqdhvYIbEO/AOi26Fo6cFH5xg2Sx14FWxViir4OQ4hL3U45MwvbMnn2v1BQDGBwnc7O8xUhQ67hOA/PPUQ8oC/w2cJ2A65bYNz5yfDM= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=renesas.com; Received: from OS3PR01MB8426.jpnprd01.prod.outlook.com (2603:1096:604:194::10) by TYCPR01MB11070.jpnprd01.prod.outlook.com (2603:1096:400:3a7::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6319.33; Mon, 24 Apr 2023 02:36:52 +0000 Received: from OS3PR01MB8426.jpnprd01.prod.outlook.com ([fe80::91e7:a94f:9f75:d840]) by OS3PR01MB8426.jpnprd01.prod.outlook.com ([fe80::91e7:a94f:9f75:d840%5]) with mapi id 15.20.6319.022; Mon, 24 Apr 2023 02:36:52 +0000 Message-ID: <871qka0zwb.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto To: Alexandre Belloni , Claudiu Beznea , Jaroslav Kysela , Liam Girdwood , Mark Brown , Nicolas Ferre , Takashi Iwai Cc: alsa-devel@alsa-project.org, linux-arm-kernel@lists.infradead.org In-Reply-To: <87bkje0zzf.wl-kuninori.morimoto.gx@renesas.com> References: <87bkje0zzf.wl-kuninori.morimoto.gx@renesas.com> Subject: [PATCH v2 07/13] ASoC: atmel: use asoc_dummy_dlc User-Agent: Wanderlust/2.15.9 Emacs/27.1 Mule/6.0 Date: Mon, 24 Apr 2023 02:36:52 +0000 X-ClientProxiedBy: TYCP286CA0180.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:3c6::13) To OS3PR01MB8426.jpnprd01.prod.outlook.com (2603:1096:604:194::10) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: OS3PR01MB8426:EE_|TYCPR01MB11070:EE_ X-MS-Office365-Filtering-Correlation-Id: 18b924fb-1d23-4fd0-b5e0-08db446cc354 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: IJaLZdDGdAPZymKxHiz6fiDmyFttmhiVopcA4zRIhJlPoarTMP399/8K5ZIb1v2EV16fLEeB1j5t5H06dtliSHiaPcF8Pne/dSIqF5inItr+F4VcbWokm6Sh3j4yIDZhYlTiZNx1h2EIHToL9I3Ux4uzN4/LkXhmIoGTYDIf4qF/RM+nE+UBbDLKG9bRcU3w9mDAJU2IoTEpefbXwnSDuzCTrT+VTrhzJYCmsCcSd5hBDxkYEFsN4I65//s9tCUbJnEy1ZuJlKc4KA3YJyZkJiLCZpvTPYvb9pMHEMDc9NGDIxJ6vLVW4PoUd/L8voJtttJ1uSz9mmLZ2ktx1/VDAoNyuGuYXezw/X+VsLSFUYRcqb8H+gbfQh8nNBnzlDs0cWYbzzosTAUTeaXN7KLmCwzfTTNoN7F/NeHe43cxq08fQ/cUktXGRovXpw4WhyvwLYoMvc6iQOPIiacvYTl59kFFu2+hDU4OpnObGHy7viQpHyr4H+UPu/lSS7VEdJ8KqWVYOApwTZ052j1K0MaoG3a/qqHYrSajRR/G3ANb5bwvPEdi6WD1tCvG9KxoIwRphAoe2u/DGjyFv+C3pkN4YTQSiPSPqsxDJNEuO8Tm28+0DKZy2lTpkA3xmDkKXSi7 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:OS3PR01MB8426.jpnprd01.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(136003)(39860400002)(366004)(376002)(346002)(396003)(451199021)(2906002)(66476007)(66556008)(66946007)(316002)(4326008)(8676002)(8936002)(5660300002)(41300700001)(36756003)(86362001)(6512007)(26005)(186003)(38100700002)(38350700002)(478600001)(52116002)(6486002)(83380400001)(2616005)(6506007)(110136005);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 4SQLTalXFZFQJagPcFIE4gEVVnc+7Tj16oCSSF24MXq+nGzbp7ecEvsjDjD60a25yiJ2vysTgOjf0tQPgtvqmu0JwVYhVYtuGrkeiiHfeae4SAIpMM8YlJoSknAqb/abbxSIF31nMY7jkezeskVWIAMuoppBP0vGz/J5r7UmVKSR3wvG/pWPqhCdY9vffzIqxaNyiMxsam5ck6QIc/cbTspF6wbmtZDJqoDfJNbe85yPLP4okzMqNHfaP0dPID6fP6HM//w558gnp7a/v06bC0sL+EXjKL0yP5YB8tLpBgo5Q3T5F3895GdUpNGGW+hXG2vZ/FoVgM/rGjrXtjLUXOy1wTqnvvTF3P/RBnvH7c9cBvbala5lgx14AHPjKiuZMkBgr+EqIdZdFeAbmKAaZnZfFYUL8XxCXpfAScbXylASsyKdW5aDcC4kt76aOhb5XJbNqNLupsWMigNR4wzvLqXc6s8H5Z2jdLy7M+rHG6U6Xrjx+HwqUZNYci9Ss3y7sFZRAnU5zZR92PGTnRMwfiJW/zVaHD+0lbbz2R5T1lFjxDoGxD/eMcDXG5a6XTcKal0oDmO+PpisLN6SovC2bOGt0DReKwj8FTAYgX9C3EExSjyCbMbVcYuFk8Iz2WiTqViUMbIjHWDbrubB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enant-AuthSource: OS3PR01MB8426.jpnprd01.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Apr 2023 02:36:52.8345 (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: xyPbJ2yhrBFkcBTSLKibBZo9Ra6dM8QhixuDE+1BwAmrojYpZURzqI3aWfmLItGP9J/x9p3tAAgj7kAeVJ2pu+pnoKGFZf9elPT5V25ZF2yEy0fyObZ8xh2j12dF7dR8 X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYCPR01MB11070 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230423_193703_211359_A79296D1 X-CRM114-Status: GOOD ( 10.11 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Now we can share asoc_dummy_dlc. This patch use it. Signed-off-by: Kuninori Morimoto --- sound/soc/atmel/atmel-classd.c | 8 +++----- sound/soc/atmel/atmel-pdmic.c | 8 +++----- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/sound/soc/atmel/atmel-classd.c b/sound/soc/atmel/atmel-classd.c index 007ab746973d..4c1985711218 100644 --- a/sound/soc/atmel/atmel-classd.c +++ b/sound/soc/atmel/atmel-classd.c @@ -473,21 +473,19 @@ static int atmel_classd_asoc_card_init(struct device *dev, if (!dai_link) return -ENOMEM; - comp = devm_kzalloc(dev, 2 * sizeof(*comp), GFP_KERNEL); + comp = devm_kzalloc(dev, sizeof(*comp), GFP_KERNEL); if (!comp) return -ENOMEM; - dai_link->cpus = &comp[0]; - dai_link->codecs = &comp[1]; + dai_link->cpus = comp; + dai_link->codecs = &asoc_dummy_dlc; dai_link->num_cpus = 1; dai_link->num_codecs = 1; dai_link->name = "CLASSD"; dai_link->stream_name = "CLASSD PCM"; - dai_link->codecs->dai_name = "snd-soc-dummy-dai"; dai_link->cpus->dai_name = dev_name(dev); - dai_link->codecs->name = "snd-soc-dummy"; card->dai_link = dai_link; card->num_links = 1; diff --git a/sound/soc/atmel/atmel-pdmic.c b/sound/soc/atmel/atmel-pdmic.c index 00c7b3a34ef5..efcbdd1a629f 100644 --- a/sound/soc/atmel/atmel-pdmic.c +++ b/sound/soc/atmel/atmel-pdmic.c @@ -496,21 +496,19 @@ static int atmel_pdmic_asoc_card_init(struct device *dev, if (!dai_link) return -ENOMEM; - comp = devm_kzalloc(dev, 2 * sizeof(*comp), GFP_KERNEL); + comp = devm_kzalloc(dev, sizeof(*comp), GFP_KERNEL); if (!comp) return -ENOMEM; - dai_link->cpus = &comp[0]; - dai_link->codecs = &comp[1]; + dai_link->cpus = comp; + dai_link->codecs = &asoc_dummy_dlc; dai_link->num_cpus = 1; dai_link->num_codecs = 1; dai_link->name = "PDMIC"; dai_link->stream_name = "PDMIC PCM"; - dai_link->codecs->dai_name = "snd-soc-dummy-dai"; dai_link->cpus->dai_name = dev_name(dev); - dai_link->codecs->name = "snd-soc-dummy"; card->dai_link = dai_link; card->num_links = 1;