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: 13693288 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 CA29EC25B76 for ; Tue, 11 Jun 2024 08:56:20 +0000 (UTC) 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: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=ybd08wFsrNPJ1lctEezos+bZKCqyzYEkQ4iHbJ2qYJc=; b=QrzpBSJB1Q8B2592lBq9ApC0qW gJAiFrOyP8rWZFniQ/nzSX8G7In7RglCrPyknXtXQ20jD0EMFIqwSpR94qTwDOAqoL0Sg9l73fJ5+ PiN9UoSmNxWvnV4UnXneXArVZGlLYyF9i1zheYsXpzpaRMlWexw5w9qbDdWb2gTTXcbTwx8mKdShI wQd3mvVsouJ7512Gdf7z34CRWQW8FTq9zX5vWDuNdqsbEBYZD59o+efISxENJeGbbxR3zYliKyGvJ mSMXUcoj2cMlFg9b3cT2MDWCtSHBYaYG4rm9mpDAxOQypquqXtbf0DhmPMOCxtAQ385ANWVJS9VpW mtdoHiQA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGxIi-00000008DJn-1piE; Tue, 11 Jun 2024 08:56:20 +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-mediatek@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-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=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: 13693289 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 BF6ADC25B76 for ; Tue, 11 Jun 2024 08:56:26 +0000 (UTC) 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: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=PWrzE93eozKELUV9AhMY2zwUiiZM2yIHTF8qO/gSqFc=; b=drpDC90RnITVu6U83TkgJ6nVQQ 9AlHibeuvqxfa7Evg32kb6ktvDXP150WLXEAvicQ5Y6sRX6+vV7oLl/rbiLVfAe2Zh3LRC22Vc2yi ABguN+bTvgF/qFH6J+qdHsdi9fOHmr1hWeP9qLViwXKCO0gP2RcBk/8AWkGy5s+ZJ4hK23J+SmqYy 1g9iHGs+ciqnEbBCoheBD+NeZWobYjgM1k2CqLZH7QSpQlai2bjXWcQcQx/hzt0QClfTF7q67f7wi xqfmTH/z/VuXeEf/bcIBvJSapTD3IYLZ+/qYlfxOAKQJpwWPqjtvwPDzUAbi4mWslTxBhfZeSINkV qjuYs/aw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGxIo-00000008DO7-1BbF; Tue, 11 Jun 2024 08:56:26 +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-mediatek@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-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=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 }, {} };