Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1842289iob; Thu, 5 May 2022 09:10:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwcI9d6VPrdPZxAGR4hlKIvmmjlAg/80eSnCDjWTxadqT3SzGmkgT4XRYlG1BXqtKQWrr1p X-Received: by 2002:a17:907:8a24:b0:6f4:82c9:9adc with SMTP id sc36-20020a1709078a2400b006f482c99adcmr15255200ejc.223.1651767056934; Thu, 05 May 2022 09:10:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651767056; cv=none; d=google.com; s=arc-20160816; b=cWwSrpc0BOhvt1Y+rBAk2qaH5t2QTkfQ9fwJ4CjEsZgXos71ZTgqPCXOYLT4htxuep +sJ/D4sPyz1fhvG3TBrnlE4PRH4mAXB1eFbFar6PTlaMq+qlWH5zEZ43mUJbllyQKrUX iDxyXsUA7kdOBghDoBVyf6qgMCZMaicjiW61j9xoIkt4STmUJqrSsNN2UMcGcVSu7Ydh ed8dbAI9GlGsCsdd5Y6vGUb06Oxy+s5uk9vAZ9uao/bVqq79ZbMJdRQED/3JpasXAMz4 h8iFOEu3R72pyTF6H/Ft96SsCciWf204wzSSG3r+efHbqYr7CoqAfCh+rGOWDg+/xiao txQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=jI/r2vVU6FXyNqwdJVTO1u3BvOi4SbozoeCbOEdcZnI=; b=Zh637tronSLLVWehQSNuuUk95OgOGP9jun/gp4zhNWUQ3qQnAKJUUyqYpLN87B0VY3 tHlL/JZwwce7ptTAxtOt2fnehuOHBk85BUxHEnmaYHAmpmX6uKutTfxdHjmM8PPOCUNE fsWjEPm1BmsqjFdICSUi3SJDQJj9JfYBPxks6wBi8CxCbrfRMD6PicTlqGNxjkD7RH/o hIEQtkqcWVF+WhymaDoKgUyXQLB87t0qnI65rbjBF+daS77oFPhyj40Uabwj4qJ7MSGp jsaTwLjoZx2KzwA/b9MYNU+tn09cLBpqXF647YsyZy4NYIfwvj48VT4voynxccxsPnXk mwLw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=LQP40dxF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e14-20020a1709062c0e00b006e8625949efsi2613044ejh.923.2022.05.05.09.10.31; Thu, 05 May 2022 09:10:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=LQP40dxF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244360AbiEEIMF (ORCPT + 99 others); Thu, 5 May 2022 04:12:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44304 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236869AbiEEIME (ORCPT ); Thu, 5 May 2022 04:12:04 -0400 Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [46.235.227.227]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9F3273337C; Thu, 5 May 2022 01:08:25 -0700 (PDT) Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: kholk11) with ESMTPSA id E73021F44D6A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1651738103; bh=Sx0JTutas4/a5URHaHdUEVftBTpjpG3kAugSQyvFlOk=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=LQP40dxFDRXce8lfztccxf30KUdLwEI7Biw7WJFTVQgsdDbNckjKld2YhLoBNGUFK 6oiSh0nR9Xfnfbzk/jr6ze4TO3H0+DqXEUSKRQPakdjJeaG4ckhTKy9NBwbOVYL7Rz 75B5Sarx4ocMBfhtUMYwULroMzHxA1GU5xiW71rPLvmdS8+Nb3IVHiMdvyuR1N54lA 8CKd8fB/xfvNwcgZqG6z1VjuSIdQFmHsVfj3TRNZlUY4/F4ra07cYNlwfAXCukg8J5 X4Obi7f66sRUcI/xgAb4Y3SaJM2Yu8CnQ9wkG3c5C6d0oOM60j5N3/znbWeNql2KFQ K5ftZZVV6WFrw== Message-ID: <4826c824-40ce-5726-ed95-5be069233ca7@collabora.com> Date: Thu, 5 May 2022 10:08:20 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: [PATCH 1/3] ASoC: dt-bindings: mediatek: mt8192: Add i2s-share properties Content-Language: en-US To: =?UTF-8?B?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= , Mark Brown Cc: kernel@collabora.com, Jiaxin Yu , Krzysztof Kozlowski , Liam Girdwood , Matthias Brugger , Rob Herring , Shane Chien , alsa-devel@alsa-project.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org References: <20220429203039.2207848-1-nfraprado@collabora.com> <20220429203039.2207848-2-nfraprado@collabora.com> From: AngeloGioacchino Del Regno In-Reply-To: <20220429203039.2207848-2-nfraprado@collabora.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Il 29/04/22 22:30, NĂ­colas F. R. A. Prado ha scritto: > The Mediatek AFE PCM controller for MT8192 allows sharing of an I2S bus > between two busses. Add a pattern for these properties in the > dt-binding. > > Signed-off-by: NĂ­colas F. R. A. Prado > --- > > Documentation/devicetree/bindings/sound/mt8192-afe-pcm.yaml | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/Documentation/devicetree/bindings/sound/mt8192-afe-pcm.yaml b/Documentation/devicetree/bindings/sound/mt8192-afe-pcm.yaml > index 7a25bc9b8060..5b03c8dbf318 100644 > --- a/Documentation/devicetree/bindings/sound/mt8192-afe-pcm.yaml > +++ b/Documentation/devicetree/bindings/sound/mt8192-afe-pcm.yaml > @@ -54,6 +54,11 @@ properties: > - const: aud_infra_clk > - const: aud_infra_26m_clk > > +patternProperties: > + "^i2s[0-35-9]-share$": > + description: Name of the I2S bus that is shared with this bus > + pattern: "^I2S[0-35-9]$" > + > required: > - compatible > - interrupts > The only other way of doing this would be to complicate this in the driver so that we can do something like "i2s-share = <0 2>"; instead of i2s0-share = "I2S2"; ...and I don't think that this would be any more straightforward than the provided way. There's an improvement that we can do to that pattern description though, which would be explaining that declaring 'i2s0-share = "I2S2"' means that I2S2's data pin will be used as DATA-OUT, while i2s0 is DATA-IN. Another thing that comes to mind here is that this is a MediaTek specific property and *not* a generic one, which means that both the driver and this binding should be fixed to get a "mediatek," prefix, so, this property should - in reality - be "mediatek,i2s[0-35-9]-share" instead. I think that everyone agrees about that, but let's see what the others say. Cheers, Angelo