From patchwork Tue Jun 11 08:56:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 13693294 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 A4897C25B76 for ; Tue, 11 Jun 2024 08:56:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=sSYjkEWigDvPKmuJv6TBjsYCIub4IlgZ1iMfxk0+QRA=; b=xePThR4YwPBLUe Obm476jXXBNKKMBVYEdBRH94TH05/wdftwXw55DkxlVkrcwaPCzHVr7dS1TIctwBJEaPxk3SuIwhq sxB+lHxFTRG1ur+1vhTcGC4/Lt7NEk0cstX4itJ4CojjxmL9bOseyGNyn2GFm4b450hx4yKUzDkFa If23O4Bm/YawyGWLv6vQ/pDYsZzy9xA1cBM9D+ctGdZNqga82pbGOi7a+e44uDsGasOqH1bttQRJq zPaLFMnZFpshhHMLhHTNNJFh0+6gVJxaomQzFTiWBdGpGku87n8jT6Dqnxy4IJbqU4J/85Z87PRXE NQzzsbwwJKSu6Rjf5t0Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGxIf-00000008DIG-2MXB; Tue, 11 Jun 2024 08:56:18 +0000 Received: from madrid.collaboradmins.com ([46.235.227.194]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGxIX-00000008DDj-1Hxe; Tue, 11 Jun 2024 08:56:10 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1718096168; bh=twG15UdjWXRB0IFFj6bI1+cRICgjEaOW//2cOBbp4BU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1T+zp0TU9AD5jSP+4g31G7oBmmeksfl1anVMrptEDBrSnE6WjYhcPR608yehrm0am eIDp5pk3KEFIpMdA+EU0TutknCpJoZMcVfSOC7B3Z2gFetgBWfwrdJN6T4w25Vy2F/ rHoa02qyVICck3L8FNZ3uOA63S/kphyNMTIUtbgJ/XAvDXQhxIEk/k5X1T7cx1s1Pi pqHc09m9QVx5InSgrKWzseJDUTkeh62MCpxdfg1p6O7i4jGCLonTA42Jnaf4HOOkfH UWptsFqKmMH0sNRQa0NHYlnb4rwUo/15f2hNeW0YEl/gjPZLxO9CfJ/t0ssmbTkTSK A4Pdxe/TxYEFA== Received: from IcarusMOD.eternityproject.eu (cola.collaboradmins.com [195.201.22.229]) (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 madrid.collaboradmins.com (Postfix) with ESMTPSA id C7DF237811D1; Tue, 11 Jun 2024 08:56:06 +0000 (UTC) From: AngeloGioacchino Del Regno To: boris.brezillon@collabora.com Cc: maarten.lankhorst@linux.intel.com, mripard@kernel.org, tzimmermann@suse.de, airlied@gmail.com, daniel@ffwll.ch, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, steven.price@arm.com, matthias.bgg@gmail.com, angelogioacchino.delregno@collabora.com, 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, Conor Dooley , Chen-Yu Tsai Subject: [PATCH v3 1/2] dt-bindings: gpu: mali-bifrost: Add compatible for MT8188 SoC Date: Tue, 11 Jun 2024 10:56:01 +0200 Message-ID: <20240611085602.491324-2-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240611085602.491324-1-angelogioacchino.delregno@collabora.com> References: <20240611085602.491324-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240611_015609_504852_56FF7468 X-CRM114-Status: UNSURE ( 9.59 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add a compatible for the MediaTek MT8188 SoC, with an integrated ARM Mali G57 MC3 (Valhall-JM) GPU. Acked-by: Conor Dooley Reviewed-by: Chen-Yu Tsai Signed-off-by: AngeloGioacchino Del Regno --- Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml index e796a1ff8c82..278399adc550 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml @@ -34,6 +34,7 @@ properties: - const: arm,mali-valhall-jm # Mali Valhall GPU model/revision is fully discoverable - items: - enum: + - mediatek,mt8188-mali - mediatek,mt8192-mali - const: arm,mali-valhall-jm # Mali Valhall GPU model/revision is fully discoverable @@ -195,7 +196,9 @@ allOf: properties: compatible: contains: - const: mediatek,mt8183b-mali + enum: + - mediatek,mt8183b-mali + - mediatek,mt8188-mali then: properties: power-domains: From patchwork Tue Jun 11 08:56:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AngeloGioacchino Del Regno X-Patchwork-Id: 13693295 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 F17B4C27C5E for ; Tue, 11 Jun 2024 08:56:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=sIC1uKmXvqHKOA/UPRGCjJj9LPEBXzFD2s0crBnUGHY=; b=B52UBWJxIz9Z8x r5oULwLPs230zSDD32lXS24gMMnyRFVQJVtmqplAd2SRcAlW9mwip9fm5oeJZWSgMune8dTRYVQst C21Jm/jUnKhw3VFU4VFftM1tNjBX3XWhyGfrovExQezZQfh4snvPpiKUu4Z5dAP325XIDOnt74svT /eSiWaOa1KLhp0e33FXaxEjssXV45HHmHNqa64XU6EUKYXNP1w4HN+LeJR0/uq3F3MbGXUv7HhqIF MwUCAA/vy9uAa9Ya6ywKsG3AL0JS122Qjm4B/ngvlS1pxcD4kIvJu/KAldMtBXSfnh8GVHXF6O6r1 hYeLw5X/Pi5+xBkdxSpw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGxIl-00000008DMO-2nbK; Tue, 11 Jun 2024 08:56:23 +0000 Received: from madrid.collaboradmins.com ([46.235.227.194]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGxIY-00000008DEb-1sLQ; Tue, 11 Jun 2024 08:56:11 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1718096169; bh=cnIJtrznV6h9d/xAr9/uNAXnPfcZk6/iS2ar3GbUMdc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=eCKfL5qsspepMmy/Te/D3skWgGUJG+6vBCJ6XXNGHpEistFsDWL+GF2sGzxQdKiGC ZM0NpluLDC84QkHRHoabJD093hEyTEVWJi/CX+sieg3YmlM7YRX5DC6E/YJTSvI3mH 3x5gSzXvl3o0r401WfIaQXW/8hfdb35TKjBoZRPjhKpEMNyW5fhHrM1yNCH0ZzlANz spafVEY0yBe8LwlobM3nPb43DS71ScsK5Q7tWv/rQ0aCXAIwQzMr04cjLz6Z9rXGsP odwBQTqX/87eg2fG8MdGi+UM+IAsfK04eX+ezsDamjnxJAW//Rw1h00vqStwa7joDH N8fyE5cGhz0zg== Received: from IcarusMOD.eternityproject.eu (cola.collaboradmins.com [195.201.22.229]) (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 madrid.collaboradmins.com (Postfix) with ESMTPSA id 34046378217A; Tue, 11 Jun 2024 08:56:08 +0000 (UTC) From: AngeloGioacchino Del Regno To: boris.brezillon@collabora.com Cc: maarten.lankhorst@linux.intel.com, mripard@kernel.org, tzimmermann@suse.de, airlied@gmail.com, daniel@ffwll.ch, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, steven.price@arm.com, matthias.bgg@gmail.com, angelogioacchino.delregno@collabora.com, 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, Chen-Yu Tsai Subject: [PATCH v3 2/2] drm/panfrost: Add support for Mali on the MT8188 SoC Date: Tue, 11 Jun 2024 10:56:02 +0200 Message-ID: <20240611085602.491324-3-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240611085602.491324-1-angelogioacchino.delregno@collabora.com> References: <20240611085602.491324-1-angelogioacchino.delregno@collabora.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240611_015610_642990_C365CEBE X-CRM114-Status: GOOD ( 10.96 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org MediaTek MT8188 has a Mali-G57 MC3 (Valhall-JM): add a new compatible and platform data using the same supplies and the same power domain lists as MT8183 (one regulator, three power domains). Reviewed-by: Chen-Yu Tsai Signed-off-by: AngeloGioacchino Del Regno Reviewed-by: Steven Price --- drivers/gpu/drm/panfrost/panfrost_drv.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c index ef9f6c0716d5..b43557b10ae3 100644 --- a/drivers/gpu/drm/panfrost/panfrost_drv.c +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c @@ -777,6 +777,15 @@ static const struct panfrost_compatible mediatek_mt8186_data = { .pm_features = BIT(GPU_PM_CLK_DIS) | BIT(GPU_PM_VREG_OFF), }; +/* MT8188 uses the same power domains and power supplies as MT8183 */ +static const struct panfrost_compatible mediatek_mt8188_data = { + .num_supplies = ARRAY_SIZE(mediatek_mt8183_b_supplies) - 1, + .supply_names = mediatek_mt8183_b_supplies, + .num_pm_domains = ARRAY_SIZE(mediatek_mt8183_pm_domains), + .pm_domain_names = mediatek_mt8183_pm_domains, + .pm_features = BIT(GPU_PM_CLK_DIS) | BIT(GPU_PM_VREG_OFF), +}; + static const char * const mediatek_mt8192_supplies[] = { "mali", NULL }; static const char * const mediatek_mt8192_pm_domains[] = { "core0", "core1", "core2", "core3", "core4" }; @@ -808,6 +817,7 @@ static const struct of_device_id dt_match[] = { { .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,mt8188-mali", .data = &mediatek_mt8188_data }, { .compatible = "mediatek,mt8192-mali", .data = &mediatek_mt8192_data }, {} };