From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 17024606A880 for ; Tue, 17 Nov 2026 16:00:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=gip+lS8j; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=EWjSB+JD DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date: Message-ID:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Unsubscribe-Post: List-Owner; bh=/x+1/YRqE8Zusxp33H94lPbXoArQ2s0dgh4gGGEjxCA=; b=gip+lS8jAwrfS/ ngW6GwcF4zBhpxzCoTH+k9rJQnxooujeSssLIMT519Yq1fj0ILhJLm9rWOiWbp1kqnCrmFtPapC4Z 5hQjVuahG6OSdbONIkEOExuV5xlEr6545IH7xh/DDnxxotFX4eZ01+aApfJQ/jDeb95XwTLPcmD1a xqVbk9qqUXvAWpM3CemefvqKOLCSXd5kvc0uibOoB0w6r88I5jywAvcljTTTjhxqfVsPx02I3zKV7 XFnknMnM2ku9mTgp2Z8Eq5g8mziQwPXo01UkZROEOWjxVMdp+zgj8OnAqaH/2u4syW+8cMgElUrN9 TskmrUajygHgUlcIKEwg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xTLbn-00000006NfD-3QbC; Tue, 17 Nov 2026 16:00:35 +0000 Received: from sea.source.kernel.org ([172.234.252.31]) by bombadil.infradead.org with esmtps (Exim 4.100.1 #2 (Red Hat Linux)) id 1xTLbm-00000006Nee-1zvn; Tue, 17 Nov 2026 16:00:34 +0000 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) by sea.source.kernel.org (Postfix) with ESMTP id D500743AC7; Tue, 17 Nov 2026 16:00:33 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4F6DA1F000C5; Tue, 17 Nov 2026 16:00:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1794931233; bh=/x+1/YRqE8Zusxp33H94lPbXoArQ2s0dgh4gGGEjxCA=; h=Date:Subject:To:Cc:References:From:In-Reply-To; b=EWjSB+JDp+qP5V7KsT50JdtiayD/niRQQs4Kfv0MNgY+vFhOcYiYIVdyaaTsJgoUR cYT+mElpY+qy0gO8aKDAp/Dp7zX7qZTMJ4V8BI/p96hZkwlo+vHCC7A2hNuGlP4oA8 CzF2kZyuv1Ybf27EKEYCompQacfC1Xo7BxWE/4tvHB1EVt7an6EYFnivRGwkYNSfDy eEj2TEUxIPbTY06bgW1f3obd4XMnL5bQDp+vN025kIg5Ry/ZG5FtpTkuIfFP9I1FFo ILwbMJYG/AawWOZbN3Vwo8FUnnIj1c8XOUdY1ivHdkpO+GAdp8G+08R//14sOMt3Vn Mz9JMddBrVfSA== Message-ID: <94ed1340-94bd-49ee-ba31-9bb63164c89a@kernel.org> Date: Tue, 17 Nov 2026 17:00:26 +0100 X-Archived-By: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2 4/4] arm64: dts: mediatek: mt8167: Add DRM nodes To: AngeloGioacchino Del Regno , Luca Leonardo Scorcia , linux-mediatek@lists.infradead.org Cc: Chun-Kuang Hu , Philipp Zabel , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , CK Hu , Jitao shi , dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org References: <20260921113914.779393-1-l.scorcia@gmail.com> <20260921113914.779393-5-l.scorcia@gmail.com> <200ef6c1-eced-4c36-832d-3fb409aac866@collabora.com> <5715e9e5-857d-4104-aedd-9662da0fc0ab@kernel.org> <911e4163-8a2c-4ca2-8903-8d3ddb7266e8@collabora.com> <600165c4-eaa7-4b1e-806c-63d3b97d5064@kernel.org> <63da5790-984b-4760-8e92-85b5d2269b30@collabora.com> From: Krzysztof Kozlowski Content-Language: en-US Autocrypt: addr=krzk@kernel.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xeYJtjUH0ZX6ndJ33FJYf5V3yXqqjcZ30FgHzJCFUu JMp7PSyMPzpUXfU12yfcRYVEMQrmplNZssmYhiTeVicuOOypWugZKVLGNm0IweVCaZ/DJDIH gNbpvVwjcKYrx85m9cBVEBUGaQP6AT7qlVCkrf50v8bofSIyVa2xmubbAwwFA1oxoOusjPIE J3iadrwpFvsZjF5uHAKS+7wHLoW9hVzOnLbX6ajk5Hf8Pb1m+VH/E8bPBNNYKkfTtypTDUCj NYcd27tjnXfG+SDs/EXNUAIRefCyvaRG7oRYF3Ec+2RgQDRnmmjCjoQNbFrJvJkFHlPeHaeS BosGY+XWKydnmsfY7SSnjAzLUGAFhLd/XDVpb1Een2XucPpKvt9ORF+48gy12FA5GduRLhQU vK4tU7ojoem/G23PcowM1CwPurC8sAVsQb9KmwTGh7rVz3ks3w/zfGBy3+WmLg++C2Wct6nM Pd8/6CBVjEWqD06/RjI2AnjIq5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AzjUUovO8rgI c+5yN5heq5loYHgK6OQ9OlHzsPHO9e9MOQcKlFycs1pyijFGzDwdNUm/SchK8iWT2QApTx4A K9bCVaboTA2T77QYkRcRJYSsO1alGX0ome/hMLD1daXlkrNUp1HWa3K4iytLRXjCSIorWiGs n+q3krnpXu3TFkA8qtOFZMdnIiFuiq1yLT8hptsV5xh1TA2nsVvSYiaCr3q4s4BKjS/KrLDb qoxzw8ISjdUp4pA85vb6YLCmb39NgidD+7PmAr65lBNveIFynTgsja1rRQ4= In-Reply-To: <63da5790-984b-4760-8e92-85b5d2269b30@collabora.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" X-Spam-Status: No, score=-7.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 On 17/11/2026 15:21, AngeloGioacchino Del Regno wrote: > >>> >>> Any advice on how to possibly resolve this without rewriting the entire thing? >>> >>> Mapping that by mmio address in the driver seems too stupid/dirty/bad/etc. >> >> Driver needs that, so why exactly stupid? > > Really feels like going back to the days when devicetree was not a thing and all of > the MMIOs (on ARM at least) were added into a mach file. Well, adding an alias just to tell that device node with MMIO address 0xdeadbeef is ID 0 is very similar, just placed differently. The "aliases" are the mapping between MMIO and ID. Driver code also can do the mapping between MMIO and ID. > > > >> You do not represent any >> actual hardware information in DT with these aliases. > > That depends on how you see it (as in, on the point of view), really, because well > technically the second ReadDMA IP is ... not the ... primary, as it's the secondary > one - as much as the third DPI is not the primary one (even though DRM can make it > so that it can be used as a primary output, but that's a software thing, not HW). > > So... well, with that point of view... those aliases *are* representing information > about the hardware. > > But I know that you're not complaining just about this, and this reply is not a way > to argue all that much, just a bit of thinking out loud. Being simply "second" is not alone useful information. It's pointless, it does not matter neither to hardware nor to drivers. If it matters, then probably that "second" has some other meaning and it maps to an actual hardware topology difference, then often it deserves its own compatible or property, depending on the difference. > > > >> You want to tell >> drivers how drivers should behave - that's not a job for DT, > > I want to tell drivers what is the first or the second or the third hardware > instance of the same IP, I don't want to tell drivers how drivers should behave > from devicetree. > The drivers are behaving differently with different hardware (read as: hardware > that is *physically* located in front of something else, or somewhere else anyway) > as in with different hardware instances. Then alias is not the way to represent these differences. > >> that's job >> for driver data. Of course if there is smarter way than MMIO->ID, I am >> all in. > > You can't imagine how much I was hoping for you to say something about an > alternative solution to that. > > As I said, it feels a bit like pre-DT times, but what I get from you is that this > is cleaner than just adding information about the real hardware instance number in > devicetree (no that's not just MediaTek, qcom also had similar issues as you said). Sure, I understand. This is an workaround and might be less applicable here. It might be possible that your hardware needs a dedicated property. Unfortunately, this cannot be a custom per-device alias. Best regards, Krzysztof