Message ID | 871qj5gq8c.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 227BAC77B7A for <alsa-devel@archiver.kernel.org>; Thu, 25 May 2023 05:02:17 +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 B96141FE; Thu, 25 May 2023 07:01:24 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz B96141FE DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1684990934; bh=6xB7EQYzattNpDgPEkkaA5Rf27rpG9qFS5ykOi1y318=; h=From:To:Cc:Subject:In-Reply-To:References:Date:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=lMrPoBu1E9TdPv9aYQINfI0ZkYStLJ6vu7fabW1J5WpX1lukhWNscR6rOJzqUY3eH DB/w7qUrE/G/TrnrZH2Ze6lt0GuYzinyIkpNR/GGbxphLsV9y937Tsw3aIVsB3txrj CbPA8AHAn3VMaj0p4WvCBLrVhV4IRXtfD0TK1qyQ= Received: by alsa1.perex.cz (Postfix, from userid 50401) id C6140F806D3; Thu, 25 May 2023 03:22:09 +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 E8199F806CB; Thu, 25 May 2023 03:22:08 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 4FFE6F806D4; Thu, 25 May 2023 03:22:05 +0200 (CEST) Received: from JPN01-TYC-obe.outbound.protection.outlook.com (mail-tycjpn01on2071b.outbound.protection.outlook.com [IPv6:2a01:111:f403:7010::71b]) (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 24D77F806CE for <alsa-devel@alsa-project.org>; Thu, 25 May 2023 03:22:00 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 24D77F806CE 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=HOBBI0FV ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NSxTeE2DszA9R2AwoQXiQtZ+OsB+meO3jiEVOVCGUlhAgqIPn7NJq4pjupmxkESCvw5L/R20XeiOI0h79PG8NGlWE+lvfXttygxUV0ldBb2oUTIB1utSJ1l9TqHrpvjuAc/MnIqyAx1qelB+ceraJ9mypS8jgDmiNPhf+3rfJ1/v/LFOZ1CrVf/B+3v1Q7sSZPBk7Xj2+VJUgBErwfK33breun3/967TE23pWHAxX/6Ivaao8ZBNi5EcPQdrAI8qDNlTyzuyd3VaTpO+eAUjX04uEDDf0PwvPnNRQ3netMAwLcyhddF/y/jXHg6F9cR6Z2tnXBWMAva06WmKeHV4+g== 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=UEa9MSp/pEhMaa4tNifWlD+mJo+k1OHTpkFn9Br8cNM=; b=a/VULgEK/v9RK4Z0JyFqWKdz7EKQKvaa2CCqQYjE8z+AYtCvo1lv7mrQMTl+ekBOiOOPSuK2UwyFe8zMvPGnytabhf0S0lRLmZbcP6+v0zwotx0p7twij8RPLKJTLSIgY43OJidCRiPUngk8wWJlVwiO4wwQGGoI6O57qKD3x215FFj2y+iN3D9pbKNYl0aq/CvB3xDQ6T4tF15WN8gwb2EeoLGVeCPxh+KWXtS8KuuPiTP9UjtNrM1FsZbTp8iA4+Ai0UDemX2gANwfrPLj6bJMGFG4kspTP/G+jLlwOjUAlBPexGf1msFj/lZsY//hNIdMXCHKBGq2Thv+2cRHRA== 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=UEa9MSp/pEhMaa4tNifWlD+mJo+k1OHTpkFn9Br8cNM=; b=HOBBI0FVXk/LkJIUIdx4J8NFHkV6t4zd3ieEdyVFnlWARo6SSxNT3mVhEifNtEvFi3xJSDhHob1mpwh6T15PspEcd9x3rncrTH/wtzVe8gGfgPb2Cj0r4gpalKBreCh+gFQHm1xwvXG1/1Po7MxF7AQIOz2/+JS1uMigh6EpyT4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=renesas.com; Received: from TYCPR01MB8440.jpnprd01.prod.outlook.com (2603:1096:400:15d::5) by TYWPR01MB9477.jpnprd01.prod.outlook.com (2603:1096:400:19a::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6433.14; Thu, 25 May 2023 01:21:56 +0000 Received: from TYCPR01MB8440.jpnprd01.prod.outlook.com ([fe80::6c36:5ff9:24c9:e4f7]) by TYCPR01MB8440.jpnprd01.prod.outlook.com ([fe80::6c36:5ff9:24c9:e4f7%6]) with mapi id 15.20.6433.016; Thu, 25 May 2023 01:21:56 +0000 Message-ID: <871qj5gq8c.wl-kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> To: Jaroslav Kysela <perex@perex.cz>, Liam Girdwood <lgirdwood@gmail.com>, Mark Brown <broonie@kernel.org>, Takashi Iwai <tiwai@suse.com>, Vinod Koul <vkoul@kernel.org> Cc: alsa-devel@alsa-project.org Subject: [PATCH v2 20/21] ASoC: soc-compress.c: replace dpcm_playback/capture to playback/capture_only User-Agent: Wanderlust/2.15.9 Emacs/27.1 Mule/6.0 In-Reply-To: <87ttw1gqgn.wl-kuninori.morimoto.gx@renesas.com> References: <87ttw1gqgn.wl-kuninori.morimoto.gx@renesas.com> Content-Type: text/plain; charset=ISO-8859-2 Content-Transfer-Encoding: quoted-printable Date: Thu, 25 May 2023 01:21:55 +0000 X-ClientProxiedBy: TYWP286CA0023.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:262::10) To TYCPR01MB8440.jpnprd01.prod.outlook.com (2603:1096:400:15d::5) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYCPR01MB8440:EE_|TYWPR01MB9477:EE_ X-MS-Office365-Filtering-Correlation-Id: f8bdce48-0bfa-47a1-7498-08db5cbe6dd3 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: vL5Fm9CzMITDKTqV/wHdbq0ZTrjqw/PHb8MTJABpUGB3MfYGktd9R9g46pAumcfdgxnIUt6YrCQXTM7ijkF/h/hpEoDgCqh1yUp84/uNSZriWOD8SIwyTyu7VANJscpD93xd0nvrE4xOAozSS8vUs6OAMihN/j80UU42tIIFc1+46+Zw1iuLQkb5eRJBa9+xGTe3rxG1twIzwHs3Vb9nRtSihKxKYvBOhVbmJ1+m4XC/Z9Q669WfpZhbtGNIisgppA4u8tECDzIvmxum5GyvFI5vSDSfLVPg0XYPtfY30XIeqXny9vRs4DscNPjjEIqjOa/laKCO4QYqiMJGXT5v8tS+rmf2UdQYPAyrYRQFicdxaaX8lEqyizoYQySwX4dh6c/JMr3HZSpGsQG3ikhyPrAFgmlJORSusyIzLaBcrOzvglqeuO7M0bEPDvSPeNk6PWVLj1Re6YXxZQfOMal3B0LVE7YhtweYsqcmvX7cbGzViHzn/GqsSiCrjJwyjKnLLsHNR42MmdMZAuJp562bUxDF6IrIu/6tbkD8VLNuUD66p2Lw0R3kscFYUWAlom3hJ3nDUWKWU0lG4VCTxA0XtAToKzLgtj21x2uWu/TRoI+NNIH3cF5F5ISkYyEQpvil X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:TYCPR01MB8440.jpnprd01.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(376002)(396003)(366004)(346002)(39860400002)(136003)(451199021)(38100700002)(38350700002)(6486002)(2906002)(66946007)(66476007)(4326008)(8936002)(8676002)(41300700001)(66556008)(316002)(36756003)(5660300002)(478600001)(2616005)(52116002)(110136005)(186003)(6512007)(83380400001)(86362001)(26005)(6506007);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?iso-8859-2?q?uP5oI4IpvRzD5UAm1P4HqOG?= =?iso-8859-2?q?WsCIWq0TWj5xrAKX4MJko+erAVC1Gyj5tIYRlp05euLG9mgMyMf3hBJN6KcC?= =?iso-8859-2?q?2XBrhPdBCWvzPYWfJOU09j/qL6jHLqIRep2pl4NuwBHJj7/xt1clD06CWtv8?= =?iso-8859-2?q?Doctruva+TXt3BgwVbPbWPezOf9/6QmqZmQ/AYoS3GcN9l6otLcaaEj8faBP?= =?iso-8859-2?q?rCJB3qSLBvb6lvreStlLS9i+AE6Iz4a8ZxIpESdzD4Zn26ADjlBm8L4swjsq?= =?iso-8859-2?q?IxCwTN7ZE3vZh1w6Li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3PgcxBkqj+eNrT+?= =?iso-8859-2?q?8p36glwUhPBBUhMG1q6xKT1fyN/s/lYYjABUjDOsVNJoQlv2WJRjGjn87Vqx?= =?iso-8859-2?q?L0WVnoQ6kinnUIiWw+8GU9N4yalQugdA3EX8CP74e7vGdAKLeqmYKJpQ88nO?= =?iso-8859-2?q?Z2NGiifdmTpkipX2F1IQglTN3s7+AeEh6iT2emnAjwNzA6fRfBdbU0wArC6f?= =?iso-8859-2?q?ZdE5iqdpd2kJZb9nsxGq+ybL6Pf7sAf5uP/dqMtkNZx/e4/ljAVldgge0Hk5?= =?iso-8859-2?q?OL/oU/AstZ24GZxJB5HkblvQUw5ouulI4JNrs5jGobkBULXctxZQbdqN3F01?= =?iso-8859-2?q?fjawBXnNkkjhhghOfkZ1mtZnTi3WhxYtzVV7h/fTYhN0lGG9S/6zvfbOSrcz?= =?iso-8859-2?q?llooBb9nAP+5e5dJsbE0Y7k11q4jtbqvrWexr3PVGBhm74lvhWXGui2AxLjW?= =?iso-8859-2?q?wJIU0CEU47Ak7ICUmxAaRI48mMdBqKqN3611+uqw0HbbL4xWakLTsx3rDDSs?= =?iso-8859-2?q?=3D?= X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-Network-Message-Id: f8bdce48-0bfa-47a1-7498-08db5cbe6dd3 X-MS-Exchange-CrossTenant-AuthSource: TYCPR01MB8440.jpnprd01.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 May 2023 01:21:56.3017 (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: XQJRV0BJIuHZ6Cf/79hHbIKDveKk7Sy9FHJPPnxm+rPXApAoPny0S/oxdh/diE52Yqr8cQN8whXf/2WolBhop/jE+1jW/4nb7CSM6GpZdi6iFGTz2BZoAMM4CyxrdxVu X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYWPR01MB9477 Message-ID-Hash: B6TRXKDD2WYK4M7HH4JANM3PNZTGCCTA X-Message-ID-Hash: B6TRXKDD2WYK4M7HH4JANM3PNZTGCCTA 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.8 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/B6TRXKDD2WYK4M7HH4JANM3PNZTGCCTA/> 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: replace dpcm_playback/capture to playback/capture_only
|
expand
|
diff --git a/sound/soc/soc-compress.c b/sound/soc/soc-compress.c index d8715db5e415..cf3cab7a648f 100644 --- a/sound/soc/soc-compress.c +++ b/sound/soc/soc-compress.c @@ -602,12 +602,15 @@ int snd_soc_new_compress(struct snd_soc_pcm_runtime *rtd, int num) return -ENOMEM; if (rtd->dai_link->dynamic) { + int playback = !rtd->dai_link->capture_only; + int capture = !rtd->dai_link->playback_only; + 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", @@ -620,9 +623,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 {