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 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 F3BECC433EF for ; Thu, 26 May 2022 09:58:40 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 7E9121675; Thu, 26 May 2022 11:57:48 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 7E9121675 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1653559118; bh=jyA/7RWAV9Y0Oq627zy9yw/ca5pcu7WYJ2a7t9DaETU=; h=Date:Subject:To:References:From:In-Reply-To:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=qxpslhCNhgoeIui5Rzfq5ZMti3uVPTDyb7Zkr4/Vrg6fvs3jMxeEnbh9X+DAVnraW 85oAARthiKW5V/SnUVbaRB4EO07UqqIxEjrwJNsMK0F4+WdMWcaMzKlYLJtLqkobQQ b2dj0fMpajbAboXyRAxjKl48RM8yVB8fC1gqxUNs= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 18199F80137; Thu, 26 May 2022 11:57:48 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 16943F8007E; Thu, 26 May 2022 11:57:47 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) (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 B3A6DF8007E for ; Thu, 26 May 2022 11:57:43 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz B3A6DF8007E Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="VVCfNfTp" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1653559064; x=1685095064; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=jyA/7RWAV9Y0Oq627zy9yw/ca5pcu7WYJ2a7t9DaETU=; b=VVCfNfTpO7+09ExSVC9fQXbH1Hbrl+99TEbhtH9IdGl8tG27c65wggRJ 2AzpxCfGMW0jsrsRopa43pueu/UaJjsbxgmvOfDlqMO2ZDAw5FCMwf2DE 6tSAfLbXBREEvPP4pWZPOmWhyEpPXncAjC2HvNvBEbxStwdEnrQayUKBd cliw7hhDANT3TgYaet6iij249cfRdpCCMh3FQNA9tQ20VbZOR5S6tJkRm yfdB6/2M5BYM3nw0n1cs1SDzA7Z6FfQKnbOhEp9VaC44TnV6Bb+tC0re0 6ubvCpNIJsn2d/k93c0733HijJ0VLRMRW9YJdPXg5pbcRjD6R20RYOnIw Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10358"; a="360493853" X-IronPort-AV: E=Sophos;i="5.91,252,1647327600"; d="scan'208";a="360493853" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 May 2022 02:57:40 -0700 X-IronPort-AV: E=Sophos;i="5.91,252,1647327600"; d="scan'208";a="602963984" Received: from aslawinx-mobl.ger.corp.intel.com (HELO [10.99.249.251]) ([10.99.249.251]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 May 2022 02:57:39 -0700 Message-ID: <021e4cc3-f67e-865f-0d8b-5b07fce97623@linux.intel.com> Date: Thu, 26 May 2022 11:57:26 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: About Cleanup ASoC Content-Language: en-US To: Kuninori Morimoto , Pierre-Louis Bossart References: <87fskz5yrr.wl-kuninori.morimoto.gx@renesas.com> <87a6b6cofh.wl-kuninori.morimoto.gx@renesas.com> <349ddb89-6f1e-f087-2399-795cf82b92b3@linux.intel.com> <87ilptqbvx.wl-kuninori.morimoto.gx@renesas.com> From: =?UTF-8?Q?Amadeusz_S=c5=82awi=c5=84ski?= In-Reply-To: <87ilptqbvx.wl-kuninori.morimoto.gx@renesas.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Cezary Rojewski , Mark Brown , Linux-ALSA X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" On 5/26/2022 4:13 AM, Kuninori Morimoto wrote: > > Hi Pierre-Louis > > Thank you for your feedback > >>> +-- basic board --------+ >>> |+--------+ | >>> || CPU ch0| <--> CodecA | >>> || ch1| <-+ | >>> |+--------+ | | >>> +-------------|---------+ >>> >>> +-- expansion board ----+ >>> | | | >>> | +-> CodecB| >>> +-----------------------+ > (snip) >>> I'm not sure how to count the Card, but >>> "basic board sound" is 1st card, >>> "expansion board sound" is 2nd card for us in intuitively. > (snip) >> did you mean 'channels' or 'streams'? > (snip) >> If however the 'ch0' and 'ch1' can be independent content then this >> configuration would make sense indeed, and it would be quite similar to >> the ideas on the Intel side. > > These are independent sounds. > It is working for us if we merge these into one Cards, but... > I'm OK and will do nothing if no one want to have multi Card connection. > but I'm happy to work for it if someone needs it. Well, this sounds like what we did in avs, namely we split cards separately based on endpoint. Main driver decides what endpoints to expose, based on ACPI detection and ACPI match rules, see [1]. For example in our model it is possible to have 2 separate i2s codecs connected and each having its own card. From avs driver we expose snd_soc_dai_driver with 2 streams (playback and capture), see [2] and then tell machine driver to just connect them to codec [3] - look for "SSP%d Pin", "ssp%d Tx" and "ssp%d Rx". Connections between "ssp%d Tx"/"ssp%d Rx" and userspace FE are handled by topology in our case, but should be easy to expose without it, if you don't use topologies. [1] https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git/tree/sound/soc/intel/avs/board_selection.c [2] https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git/tree/sound/soc/intel/avs/pcm.c#n946 [3] https://lore.kernel.org/alsa-devel/20220511162403.3987658-8-cezary.rojewski@intel.com/T/#u