From patchwork Thu Mar 16 10:20:30 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 664189 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 700C8C7618E for ; Thu, 16 Mar 2023 10:21:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230346AbjCPKVI (ORCPT ); Thu, 16 Mar 2023 06:21:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49052 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230480AbjCPKUz (ORCPT ); Thu, 16 Mar 2023 06:20:55 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BBD6DB1A4A; Thu, 16 Mar 2023 03:20:48 -0700 (PDT) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id 28F90660309E; Thu, 16 Mar 2023 10:20:46 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1678962046; bh=t6e55TKXpWDXs7rKf1rewUoc056XoaKTiofz8DN9RjM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RynW8u0Dr4ZczODzCd2SqpQk6l0qle1QQQKYJReaYbbgC/NiBVgsx8YY/z1d86idK f4IQC1dpbvJM61+JNY8IKP3oQ3PpwHoBs7UUqYHCj6Hf+mpHt16S/pCwrxDVGXPCQb 2CpXPfrQWFani4dmmdV1QUymIn8bWPeUP6lXbkml5nQ+M2RQaejKmWT8827i8yhght mM5Rc3MYdRtOp7i5UkB5BO7y3t40z1vH9I7tV5N3MeYSICkOyFEoBOcu1ZgiYofuTo 0K53H3tkpCB5WHdMIl6yQ8txBdOSaapyxAbhB24sRX3Q9svQ2dhqp7TneaTHHTbDLC oCABAxTCASlUQ== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v5 01/12] dt-bindings: gpu: mali-bifrost: Split out MediaTek power-domains variation Date: Thu, 16 Mar 2023 11:20:30 +0100 Message-Id: <20230316102041.210269-2-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> References: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org In preparation for adding new bindings for new MediaTek SoCs, split out the power-domains variation from the `else` in the current mediatek,mt8183-mali conditional. The sram-supply part is left in place to be disallowed for anything that is not compatible with "mediatek,mt8183-mali" as this regulator is MediaTek-specific and it is, and will ever be, used only for this specific string due to the addition of the mediatek-regulator-coupler driver. Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai Reviewed-by: Rob Herring --- .../devicetree/bindings/gpu/arm,mali-bifrost.yaml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml index 78964c140b46..7e110751353e 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml @@ -109,6 +109,9 @@ allOf: contains: const: amlogic,meson-g12a-mali then: + properties: + power-domains: + maxItems: 1 required: - resets - if: @@ -131,6 +134,8 @@ allOf: - const: gpu - const: bus - const: bus_ace + power-domains: + maxItems: 1 resets: minItems: 3 reset-names: @@ -164,8 +169,6 @@ allOf: - power-domain-names else: properties: - power-domains: - maxItems: 1 sram-supply: false - if: properties: @@ -180,6 +183,8 @@ allOf: items: - const: gpu - const: bus + power-domains: + maxItems: 1 required: - clock-names From patchwork Thu Mar 16 10:20:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 664188 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A9BF3C7618A for ; Thu, 16 Mar 2023 10:21:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230520AbjCPKVJ (ORCPT ); Thu, 16 Mar 2023 06:21:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48702 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230365AbjCPKU5 (ORCPT ); Thu, 16 Mar 2023 06:20:57 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 65CA3BD4E0; Thu, 16 Mar 2023 03:20:49 -0700 (PDT) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id 110C8660309F; Thu, 16 Mar 2023 10:20:47 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1678962047; bh=0AQ+gCHdVFTNhiJx165qPUL/6q3xPgjQ71jCDBHRJbM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=XZDAjq3y2FnChbx/QaN5W8qWibNZXqFSx+bE4yxNo3mFhqkC7puUiGzFrqJ5720we v276dVUUfq1cEPXmL24DQ4EhnCiJsU25pvEEIvRp3r/vhHJbgczulchcoecA+QwABQ B1HOy+tPc/AkhUEuqiFocFMS+vZeq5umSPFkuuheU3xiOtZYibBpfGg/ajB8vdAruC 4R7RsK/EAaaGdSde/s04W54Jf6mYSi8f0QMZIPtMAI5KdYR2Pc6Yb27G3iEgE81+XC CySRPOBKTfHPlH+BVgy45OGeCYPm+Yxj95Ynox8lSxDadnVcD/twx2DodOuI9ckKhQ 2H7AMk+HJ9iqg== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v5 02/12] dt-bindings: gpu: mali-bifrost: Set power-domains maxItems to 5 Date: Thu, 16 Mar 2023 11:20:31 +0100 Message-Id: <20230316102041.210269-3-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> References: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org In preparation for adding (and fixing) power-domain-names and MediaTek MT8192 bindings, allow up to five items for power-domains. Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml index 7e110751353e..5b7f1c9d2b30 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml @@ -63,7 +63,7 @@ properties: power-domains: minItems: 1 - maxItems: 3 + maxItems: 5 resets: minItems: 1 @@ -157,6 +157,7 @@ allOf: properties: power-domains: minItems: 3 + maxItems: 3 power-domain-names: items: - const: core0 From patchwork Thu Mar 16 10:20:33 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 664187 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 62E60C6FD19 for ; Thu, 16 Mar 2023 10:21:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230419AbjCPKVN (ORCPT ); Thu, 16 Mar 2023 06:21:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48850 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230434AbjCPKVC (ORCPT ); Thu, 16 Mar 2023 06:21:02 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F3206BDD00; Thu, 16 Mar 2023 03:20:52 -0700 (PDT) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id CD3D966030A1; Thu, 16 Mar 2023 10:20:48 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1678962049; bh=cvXpJ8LbxubJEtHvxk8Psw3/s85Oor+YdZdxHV1BvnA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kaRZ4u7T2R2eNSV5sEw9n2rokz8EIIh9g3ilN7C700K2R+bZ50POfJlz9WcqMNubk 7Km6JlWLgGcL7zZ13CMx4wVWRvFC+3vpXiXrW8e1Jo4i6nGcMsq0bsvUwBIeFlgOP9 pkMZSKHhW7xd0q7M1kJg8kJEqyVmhJ3ZZqlK+hdJnIbcx7gUT8RQisOeaCpBUTLzqt V0pFeyDva4lz2iqPUO9UDjOGZLZ0MHS85N+mnaDDtYh91CYuM5saXaaKynjHhZ3hSm ODxHBVVJIX76MhqWsS0pU+QVQS5q+Y1hysd2KmHVfcGfK+Ql+GB+kHCYOGOLzJ/ffp 9rLDEFBU0wAsQ== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v5 04/12] dt-bindings: gpu: mali-bifrost: Add sub-schema for MT8192's power domains Date: Thu, 16 Mar 2023 11:20:33 +0100 Message-Id: <20230316102041.210269-5-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> References: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org MediaTek MT8192 (and similar) needs five power domains for the Mali GPU and no sram-supply: change the binding to allow so by also introducing power-domain-names in the generic binding; while at it, also disallow the newly introduced power-domain-names for all non-MediaTek bindings. Fixes: 5d82e74a97c2 ("dt-bindings: Add compatible for Mali Valhall (JM)") Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Rob Herring Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai --- .../bindings/gpu/arm,mali-bifrost.yaml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml index 7c61524aae26..9ede51427012 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml @@ -177,6 +177,25 @@ allOf: else: properties: sram-supply: false + - if: + properties: + compatible: + contains: + const: mediatek,mt8192-mali + then: + properties: + power-domains: + minItems: 5 + power-domain-names: + items: + - const: core0 + - const: core1 + - const: core2 + - const: core3 + - const: core4 + required: + - power-domains + - power-domain-names - if: properties: compatible: From patchwork Thu Mar 16 10:20:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 664186 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D1927C7618E for ; Thu, 16 Mar 2023 10:21:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231258AbjCPKVh (ORCPT ); Thu, 16 Mar 2023 06:21:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48700 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230510AbjCPKVK (ORCPT ); Thu, 16 Mar 2023 06:21:10 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 06596BCB9C; Thu, 16 Mar 2023 03:20:56 -0700 (PDT) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id B3C1566030A4; Thu, 16 Mar 2023 10:20:49 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1678962050; bh=Ve/6iRm3WMPE1EojlHjL3TKtdXfDs4Ou+mT+OBRzwJc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RPzEZRk1nUidBfPOaouPRtWxnwWtq6OclMoT7GIZ8LRg4a/f0sCDMsBximrNRluAL vvLyYi39Q9YBaVPMZUqHsRVhdq42Fc0aUhKRWXvlx6oMOXxhTGRfOc86pF7Dlt/exl 0jyXG5HBHArpaz/fJh3eBF9mqI3T+GKWoH4Ekab2org7gjC9vePDLgG6iNDkEZmByM MK3m7x60UCGUAk7mrgr0PdyTnGww1wIOkVlthr5BoOEjiEO/EwvJuBqQsFZrwp2b56 Y51NImWYIBF1AYX2E1CSmNygH8rZkaghZC09ZlO3xB9djIMl4sVjs5Pnz0yBJEt9nV yt0wZqcNPlwgg== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v5 05/12] dt-bindings: gpu: mali-bifrost: Add new MT8183 compatible Date: Thu, 16 Mar 2023 11:20:34 +0100 Message-Id: <20230316102041.210269-6-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> References: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Since new platform data was required in Panfrost for getting GPU DVFS finally working on MediaTek SoCs, add a new "mediatek,mt8183b-mali" compatible. Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Rob Herring Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai --- .../bindings/gpu/arm,mali-bifrost.yaml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml index 9ede51427012..63b993d5fd87 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml @@ -19,6 +19,7 @@ properties: - enum: - amlogic,meson-g12a-mali - mediatek,mt8183-mali + - mediatek,mt8183b-mali - realtek,rtd1619-mali - renesas,r9a07g044-mali - renesas,r9a07g054-mali @@ -177,6 +178,24 @@ allOf: else: properties: sram-supply: false + - if: + properties: + compatible: + contains: + const: mediatek,mt8183b-mali + then: + properties: + power-domains: + minItems: 3 + maxItems: 3 + power-domain-names: + items: + - const: core0 + - const: core1 + - const: core2 + required: + - power-domains + - power-domain-names - if: properties: compatible: From patchwork Thu Mar 16 10:20:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 664185 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 26E1EC7618D for ; Thu, 16 Mar 2023 10:21:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231286AbjCPKVj (ORCPT ); Thu, 16 Mar 2023 06:21:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49148 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230499AbjCPKVJ (ORCPT ); Thu, 16 Mar 2023 06:21:09 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D67941B322; Thu, 16 Mar 2023 03:20:56 -0700 (PDT) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id 96F2966030A2; Thu, 16 Mar 2023 10:20:50 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1678962051; bh=uglCXCkWdTA8UQ8UzHMlW0QAy31JjzQ29lenVUc0QMI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=JJNsD8RRoKeOsn+xdsXLRjM30aGTJrGpguskbdxgNVnCsVGyyi7RANKku2nXARYdJ bRb//ChxE+qethj+tRWNauzSzq6hM0ayC1iy5Obr94nrbR7x+ObttT948WqSRhgjZ6 +1BBu5QHYgbhZRMcnuBFnNHUc6KsQd45bQXajV23WPDqfvo1kGSCp1D7/BbQrKYYnd OzSLLzOYKozdGPaobdmDXcj0kBtLLoD6e7WoTiQjKZ+zDV6FQ4IzS2GynIBECnR8Yd RdkqzzN9s7uXq2JDe12OkX3aDfTMeYr8+dM61MLUuHz8Sn5PTC2iY3iqXmlp05qf03 MkQmD4/4vD4PA== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v5 06/12] dt-bindings: gpu: mali-bifrost: Add support for MediaTek MT8186 Date: Thu, 16 Mar 2023 11:20:35 +0100 Message-Id: <20230316102041.210269-7-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> References: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org MT8186 has a Mali-G52 MC2 2EE GPU (two cores): add a binding with two power domains (one per core) for it. Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai Reviewed-by: Rob Herring --- .../bindings/gpu/arm,mali-bifrost.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml index 63b993d5fd87..3d0d96913b1b 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml @@ -20,6 +20,7 @@ properties: - amlogic,meson-g12a-mali - mediatek,mt8183-mali - mediatek,mt8183b-mali + - mediatek,mt8186-mali - realtek,rtd1619-mali - renesas,r9a07g044-mali - renesas,r9a07g054-mali @@ -196,6 +197,23 @@ allOf: required: - power-domains - power-domain-names + - if: + properties: + compatible: + contains: + const: mediatek,mt8186-mali + then: + properties: + power-domains: + minItems: 2 + maxItems: 2 + power-domain-names: + items: + - const: core0 + - const: core1 + required: + - power-domains + - power-domain-names - if: properties: compatible: From patchwork Thu Mar 16 10:20:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 664184 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BE81BC6FD1F for ; Thu, 16 Mar 2023 10:21:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231290AbjCPKVl (ORCPT ); Thu, 16 Mar 2023 06:21:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48762 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231133AbjCPKVM (ORCPT ); Thu, 16 Mar 2023 06:21:12 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CF843BD4E1; Thu, 16 Mar 2023 03:20:58 -0700 (PDT) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id 3278466030A5; Thu, 16 Mar 2023 10:20:54 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1678962054; bh=zaVPC8a/zjPKkMkKy2u0SknVPayDnrlxaZ88LGSOuPI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=V+ebgBXr59zxnfFqZTRha1fbz/sXBfiDuR3wz4sIfqE/TQ4J9AbE3/XQpH2LGrDjk I7OA2HII3H2o9DkwjN98y5HpFsScHJli/w165lcNfVJdfo6E0caSfhbfdSCmCaW7x4 ZsN9by9bR+7sqhKL8hZKStk2J/tnqF0cm9hbBelMEYFTFNzgmfikxiHvhXW3SRx/1H McZoEAyZvv7bwEzcScDFwZHRQsZzz8/t7KbdnhYncpQPPwJfelsXm0zJRfPn4nb4TY zWcejFyTAo0xah/I2OXNetcw+Io8wvB2VWxW+ONsCOKbhOantTDqr5ZidQI5raWz9k fkxEFQntyhYVA== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v5 10/12] drm/panfrost: Add mediatek,mt8192-mali compatible Date: Thu, 16 Mar 2023 11:20:39 +0100 Message-Id: <20230316102041.210269-11-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> References: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Alyssa Rosenzweig Required for Mali-G57 on the Mediatek MT8192 and MT8195, which uses even more power domains than the MT8183 before it. Signed-off-by: Alyssa Rosenzweig [Angelo: Removed unneeded "sram" supply, added mt8195 to commit description] Co-developed-by: AngeloGioacchino Del Regno Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Steven Price Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai --- drivers/gpu/drm/panfrost/panfrost_drv.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c index f49096f53141..45c4accb6a1e 100644 --- a/drivers/gpu/drm/panfrost/panfrost_drv.c +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c @@ -656,6 +656,16 @@ static const struct panfrost_compatible mediatek_mt8183_data = { .pm_domain_names = mediatek_mt8183_pm_domains, }; +static const char * const mediatek_mt8192_supplies[] = { "mali", NULL }; +static const char * const mediatek_mt8192_pm_domains[] = { "core0", "core1", "core2", + "core3", "core4" }; +static const struct panfrost_compatible mediatek_mt8192_data = { + .num_supplies = ARRAY_SIZE(mediatek_mt8192_supplies) - 1, + .supply_names = mediatek_mt8192_supplies, + .num_pm_domains = ARRAY_SIZE(mediatek_mt8192_pm_domains), + .pm_domain_names = mediatek_mt8192_pm_domains, +}; + static const struct of_device_id dt_match[] = { /* Set first to probe before the generic compatibles */ { .compatible = "amlogic,meson-gxm-mali", @@ -674,6 +684,7 @@ static const struct of_device_id dt_match[] = { { .compatible = "arm,mali-bifrost", .data = &default_data, }, { .compatible = "arm,mali-valhall-jm", .data = &default_data, }, { .compatible = "mediatek,mt8183-mali", .data = &mediatek_mt8183_data }, + { .compatible = "mediatek,mt8192-mali", .data = &mediatek_mt8192_data }, {} }; MODULE_DEVICE_TABLE(of, dt_match); From patchwork Thu Mar 16 10:20:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 664183 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5F6CDC6FD1F for ; Thu, 16 Mar 2023 10:21:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231314AbjCPKVr (ORCPT ); Thu, 16 Mar 2023 06:21:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49674 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230447AbjCPKVQ (ORCPT ); Thu, 16 Mar 2023 06:21:16 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0953CBD4E6; Thu, 16 Mar 2023 03:21:01 -0700 (PDT) Received: from IcarusMOD.eternityproject.eu (2-237-20-237.ip236.fastwebnet.it [2.237.20.237]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madras.collabora.co.uk (Postfix) with ESMTPSA id F1A0F660309D; Thu, 16 Mar 2023 10:20:55 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1678962056; bh=6DBVKIIHG8WZZ3ntbG1VNgOpsrN60zwSXj2PzGrIUrQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=MbXRKWlmiz0cDiInj2vV5mKScoT/lZkY25h1C8iu8wTWzLudoPjB68uvEUYSKXkjD HHP+smP827Gc38cqEDXPjAAaPU5jBbNNqcwkuUXn4/v7lgtXUjARhXTePEPi7JFfyl kfhIOYrGcMrLKaz/TN2mf1XJHRu8kaEKB3Ncn3kJd6o/asHXUrbnIt1x6yIVWUepG8 ckMf9jds4JjYEQNWDZepYz63jS2tg0UyF5gcDtrK0KYOR+77EWKqsY1PIEJMzBW+8X nMpYv7dvDbHG6av2kGdWh+DAlqs8gTyIEiB59yGF5+4GzsjvR/Ucq539rfqGztng6b nNOUIvNpnRYUg== From: AngeloGioacchino Del Regno To: airlied@gmail.com Cc: daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, steven.price@arm.com, alyssa.rosenzweig@collabora.com, matthias.bgg@gmail.com, robh@kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wenst@chromium.org, AngeloGioacchino Del Regno Subject: [PATCH v5 12/12] drm/panfrost: Add support for Mali on the MT8186 SoC Date: Thu, 16 Mar 2023 11:20:41 +0100 Message-Id: <20230316102041.210269-13-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> References: <20230316102041.210269-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org MediaTek MT8186 has a Mali-G52 MC2 2EE (Bifrost): add a new compatible and platform data using the same supplies list as "mt8183_b" (only one regulator), and a new pm_domains list with only two power domains. Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Steven Price Reviewed-by: Chen-Yu Tsai Tested-by: Chen-Yu Tsai --- drivers/gpu/drm/panfrost/panfrost_drv.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c index 4f39b410302c..bbada731bbbd 100644 --- a/drivers/gpu/drm/panfrost/panfrost_drv.c +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c @@ -672,6 +672,14 @@ static const struct panfrost_compatible mediatek_mt8183_b_data = { .pm_domain_names = mediatek_mt8183_pm_domains, }; +static const char * const mediatek_mt8186_pm_domains[] = { "core0", "core1" }; +static const struct panfrost_compatible mediatek_mt8186_data = { + .num_supplies = ARRAY_SIZE(mediatek_mt8183_b_supplies) - 1, + .supply_names = mediatek_mt8183_b_supplies, + .num_pm_domains = ARRAY_SIZE(mediatek_mt8186_pm_domains), + .pm_domain_names = mediatek_mt8186_pm_domains, +}; + static const char * const mediatek_mt8192_supplies[] = { "mali", NULL }; static const char * const mediatek_mt8192_pm_domains[] = { "core0", "core1", "core2", "core3", "core4" }; @@ -701,6 +709,7 @@ static const struct of_device_id dt_match[] = { { .compatible = "arm,mali-valhall-jm", .data = &default_data, }, { .compatible = "mediatek,mt8183-mali", .data = &mediatek_mt8183_data }, { .compatible = "mediatek,mt8183b-mali", .data = &mediatek_mt8183_b_data }, + { .compatible = "mediatek,mt8186-mali", .data = &mediatek_mt8186_data }, { .compatible = "mediatek,mt8192-mali", .data = &mediatek_mt8192_data }, {} };