From nobody Sun Feb 8 04:34:43 2026 Received: from bali.collaboradmins.com (bali.collaboradmins.com [148.251.105.195]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9A7371EB19E; Fri, 7 Feb 2025 15:18:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.251.105.195 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738941524; cv=none; b=exkeCHs6zcVW5e+o5pC5XXk/JQzzB8a9AU/uiyRHwPStc6hINyLStf7cecBDH/kQrcmaxAuIWkNN92VntqwzKVkku0lI26BVQGBUeznD0bePm3rHDnS9Psf2OO7+2AY6bPIx5UDwEWOuhCevPJIa7ILfobBoJxdK8hhwmnMU85A= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738941524; c=relaxed/simple; bh=Npp4DvyGGF//B2p9+Cu9AlWi5SsZHn4kTOYRctSBgsw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Zefm/yrbqsItohN1a1qQCxKIm5CgvJODjlC0nP+HGaNcP1qwb1YhWVT11R1kwj8NGUUeS3wZGO3CcZ9Uu2QURBmyFwgscptfNbRpCFKZX8Ze8RAFa6NPhjbxp4Gk9FlaD3lirxmYWn4IfiDsN4Yo0QWrsI67S79MUJ0E0r3NfYM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=e4l8WpXj; arc=none smtp.client-ip=148.251.105.195 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="e4l8WpXj" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1738941520; bh=Npp4DvyGGF//B2p9+Cu9AlWi5SsZHn4kTOYRctSBgsw=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=e4l8WpXja1SD8o2Ch0eoTl1eugTuqA3PGYxfJ6eKTy/jPXfExLbEgxGKG4gmli9vX vOOavsEHYihlVTQQkXqW/GKydfB5+4b1QsCFOXSpnQ789kKH57+Silj+7TIP5NcOrG PPKWqhs9dm0aLEbwQmtefmM89GYLn5q2OtgxV3WZYmSWmBmCOqsH1kfu7aElfytzxP K8A7MFYrw164pWK6C4QhEsDaO6rihPC7RCxxb38UUpG/Lf6YJzVgGzhIJCmsOMNrA3 zFVlP86lxRKZh9AfZQKrq7u4SjXYAqfDwGlT3gaWEXa2x3bp8PMK4trcci1p90xfBg XdzqOfbJUQyDQ== Received: from yukiji.home (lfbn-tou-1-1147-231.w90-76.abo.wanadoo.fr [90.76.208.231]) (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: laeyraud) by bali.collaboradmins.com (Postfix) with ESMTPSA id C8E7A17E1090; Fri, 7 Feb 2025 16:18:39 +0100 (CET) From: Louis-Alexis Eyraud Date: Fri, 07 Feb 2025 16:18:30 +0100 Subject: [PATCH v3 1/3] dt-bindings: gpu: mali-bifrost: Add compatible for MT8370 SoC Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250207-mt8370-enable-gpu-v3-1-75e9b902f9c1@collabora.com> References: <20250207-mt8370-enable-gpu-v3-0-75e9b902f9c1@collabora.com> In-Reply-To: <20250207-mt8370-enable-gpu-v3-0-75e9b902f9c1@collabora.com> To: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno , Boris Brezillon , Steven Price Cc: kernel@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, Louis-Alexis Eyraud X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1738941518; l=1546; i=louisalexis.eyraud@collabora.com; s=20250113; h=from:subject:message-id; bh=Npp4DvyGGF//B2p9+Cu9AlWi5SsZHn4kTOYRctSBgsw=; b=zHLbCLp0ZmDfhHObegEcvvfdQT2F/55gU1FUtfDLD4auzXJ5QfDWlJrgTWq0ucd5UGgDzj/mx 8Mombz9W7qgDSotzNj5B3Bpw62O+BuCbD2bGqu3yJCfzKF4fAa8pozr X-Developer-Key: i=louisalexis.eyraud@collabora.com; a=ed25519; pk=CHFBDB2Kqh4EHc6JIqFn69GhxJJAzc0Zr4e8QxtumuM= Add a compatible for the MediaTek MT8370 SoC, with an integrated ARM Mali G57 MC2 GPU (Valhall-JM, dual core). This new compatible is needed for this SoC support, as the other existing compatibles for the same GPU architecture (MT8188, MT8192) do not match the required power domain number. The other compatibles (especially MT8186) cannot be reused because of GPU architecture difference. Signed-off-by: Louis-Alexis Eyraud Reviewed-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 735c7f06c24e632ab738d062f15378f754c8adaf..6f6211950bb495fa6bfcdfe8d1e= 27e5ce7aeeae0 100644 --- a/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml +++ b/Documentation/devicetree/bindings/gpu/arm,mali-bifrost.yaml @@ -37,6 +37,7 @@ properties: - enum: - mediatek,mt8188-mali - mediatek,mt8192-mali + - mediatek,mt8370-mali - const: arm,mali-valhall-jm # Mali Valhall GPU model/revision i= s fully discoverable =20 reg: @@ -217,7 +218,9 @@ allOf: properties: compatible: contains: - const: mediatek,mt8186-mali + enum: + - mediatek,mt8186-mali + - mediatek,mt8370-mali then: properties: power-domains: --=20 2.48.1 From nobody Sun Feb 8 04:34:43 2026 Received: from bali.collaboradmins.com (bali.collaboradmins.com [148.251.105.195]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id ABACD1EB1A6; Fri, 7 Feb 2025 15:18:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.251.105.195 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738941525; cv=none; b=UOFkzJNlKlXfY0vWlmKJ0MugDZ4tm6WomfahIgoSvj+AxDn23grLAZicKwsxYM4HtMOZXDuI599Mg9R7PqVX8Vd83pvq9HVJmaHriD/UMse3Fx61zWm9jOMZcdD6qqJM48q2zcv72BzT0gv6It0jTtK1AixEiElm+IUq/hvCfp4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738941525; c=relaxed/simple; bh=I4naQ4du97R0ib9F27jLpy7nIKZ3D3FTwYtREBA8SF0=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=kGabEG5a0aoU2F9hd8QUoVekk4XI0M3DK1UApSStpOsVDVeX3oAgVp2eVRJM9l2I8oqz+NhSiEyercl+7yJt+8ESykYe0hGhGqBM+wmyszGTnm4xsENbLL99h2qgX6kqs29w2cFjkXQ/2PcrflDBFdF9zZ1hHDdfA8s+CzTgqwI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=mianmZKb; arc=none smtp.client-ip=148.251.105.195 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="mianmZKb" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1738941521; bh=I4naQ4du97R0ib9F27jLpy7nIKZ3D3FTwYtREBA8SF0=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=mianmZKbEEIXaY0pyE8qmNml7S5tH7mMg6iQyxOf/jTsADYmnSpA8d1Bbb2JGPRjX CP9pWVAHBZUVauj+aPe8cB9j0KfaBVuXxK6RL82O9K4aZkhAzawn4/Cyn19LmQ7xBZ VVYswt7nr0agGAkX08/I+hTLnj62H3ppKMgjmFFhcepyBWqxpC3FS8mVrwXLlRcHPy uP4WBHbf+KchpaB6D6kROgJ6Sai75NFlYwD5FK1eWi9q4bFmMfwS5jKFw/QBrr+pT/ aJYNbcKNcSVr4HjjiET4/wtIMEZgxS5s0TuKHv24J38ZDpW0reuk5UXlPmNuQyDcBC JauUwICBOLZhQ== Received: from yukiji.home (lfbn-tou-1-1147-231.w90-76.abo.wanadoo.fr [90.76.208.231]) (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: laeyraud) by bali.collaboradmins.com (Postfix) with ESMTPSA id F21EA17E10B5; Fri, 7 Feb 2025 16:18:40 +0100 (CET) From: Louis-Alexis Eyraud Date: Fri, 07 Feb 2025 16:18:31 +0100 Subject: [PATCH v3 2/3] drm/panfrost: Add support for Mali on the MT8370 SoC Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250207-mt8370-enable-gpu-v3-2-75e9b902f9c1@collabora.com> References: <20250207-mt8370-enable-gpu-v3-0-75e9b902f9c1@collabora.com> In-Reply-To: <20250207-mt8370-enable-gpu-v3-0-75e9b902f9c1@collabora.com> To: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno , Boris Brezillon , Steven Price Cc: kernel@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, Louis-Alexis Eyraud X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1738941518; l=1373; i=louisalexis.eyraud@collabora.com; s=20250113; h=from:subject:message-id; bh=I4naQ4du97R0ib9F27jLpy7nIKZ3D3FTwYtREBA8SF0=; b=6EopXfZjmiAqGuV53X9US0qgB2osoMvaZrSYUiqqyZXINeVtqzc40DXaXLGUNgknMbzJFPeqX K68iZTd1j4PBWW8A9wOwzN9IEdQsGMRhmUMZ2n4f1fAJbZ8Qhwm2wTg X-Developer-Key: i=louisalexis.eyraud@collabora.com; a=ed25519; pk=CHFBDB2Kqh4EHc6JIqFn69GhxJJAzc0Zr4e8QxtumuM= Add a compatible for the MediaTek MT8370 SoC, with an integrated ARM Mali G57 MC2 GPU (Valhall-JM, dual core), with the same platform data as MT8186 (one regulator, two power domains). Despite their different GPU architecture (making them not being compatible), the MT8186 platform data can still be used for MT8370 because it only describes supplies, pm_domains and enablement of power management features in the panfrost driver. Reviewed-by: Steven Price Signed-off-by: Louis-Alexis Eyraud Acked-by: Krzysztof Kozlowski Reviewed-by: AngeloGioacchino Del Regno --- drivers/gpu/drm/panfrost/panfrost_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panf= rost/panfrost_drv.c index 0f3935556ac761adcd80197d87e8e478df436fd5..7b7e9f6f620659a7fdcb5d907eb= c4f01eca876e0 100644 --- a/drivers/gpu/drm/panfrost/panfrost_drv.c +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c @@ -859,6 +859,7 @@ static const struct of_device_id dt_match[] =3D { { .compatible =3D "mediatek,mt8186-mali", .data =3D &mediatek_mt8186_data= }, { .compatible =3D "mediatek,mt8188-mali", .data =3D &mediatek_mt8188_data= }, { .compatible =3D "mediatek,mt8192-mali", .data =3D &mediatek_mt8192_data= }, + { .compatible =3D "mediatek,mt8370-mali", .data =3D &mediatek_mt8186_data= }, {} }; MODULE_DEVICE_TABLE(of, dt_match); --=20 2.48.1 From nobody Sun Feb 8 04:34:43 2026 Received: from bali.collaboradmins.com (bali.collaboradmins.com [148.251.105.195]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CE46B1EB1B3; Fri, 7 Feb 2025 15:18:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.251.105.195 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738941526; cv=none; b=hp8TJZmU1LBKfd4TlOD323jhb9ePjorDr3EMZiicmDaYcxkoLIcRAiAD64TmUoJIt4FficA88xmBB8jpZYmgEyGJImaFRZUNS14eDkJAA+I2TeyPyFG43nM5h/0eo+xB+79nK2lmqQpEBNF+I9EXTU+FVNPaktymniwHO/oW2Qo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738941526; c=relaxed/simple; bh=CN3+JuK+9gG4rZwQyx1SxziYFUpyVC/10T8zzKMX1ns=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=UR7KU3N6A+SeIH728ltS5nzNdW8PTibazI1DB/3mYLty4NpZIMgZcwmdHEFQhLHhCZX84/ZhuTsal6NfXijhO3tnsEtJiL4BmgZMftchswuiLTmGDQxpn9rfGOPKEqjUHcPxs6oZV0L1EJSgV63qKXgLTJs32wd+1Kas6rI/hmg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=oinCfeuK; arc=none smtp.client-ip=148.251.105.195 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="oinCfeuK" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1738941523; bh=CN3+JuK+9gG4rZwQyx1SxziYFUpyVC/10T8zzKMX1ns=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=oinCfeuKKWe++o0wr6s0PbX99P299S/FiMlvo9RIzdEKmsW1YCB1USm2kYyOokBfI iisu58WnSb0MyZ5oEiFVvXuyky2MDmu7SVx7Cr/OgjWfSO+LYPRQN1yOqt0R7Sl4Uz H+Mlv+4Xf2TsppmDpg6nbQDyaYuhhHiR9j5A9CkXiJXpDA12T2bVH2OlsejirOpGnn hvnexFSrfpkP9NEjpsHiCgPkXoKj5Vea9izHwvmpTwczbdgkaG6l+6YwrMvOHp8dGB g+VtRDzARGIkYHwZmDsXSpaVYRGX5zx/7UqXwECnb2b0sCnYvNwpT+bfNk3s0BT2Mf ckVCMhqBOebiA== Received: from yukiji.home (lfbn-tou-1-1147-231.w90-76.abo.wanadoo.fr [90.76.208.231]) (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: laeyraud) by bali.collaboradmins.com (Postfix) with ESMTPSA id 2547B17E1164; Fri, 7 Feb 2025 16:18:42 +0100 (CET) From: Louis-Alexis Eyraud Date: Fri, 07 Feb 2025 16:18:32 +0100 Subject: [PATCH v3 3/3] arm64: dts: mediatek: mt8370: Enable gpu support Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250207-mt8370-enable-gpu-v3-3-75e9b902f9c1@collabora.com> References: <20250207-mt8370-enable-gpu-v3-0-75e9b902f9c1@collabora.com> In-Reply-To: <20250207-mt8370-enable-gpu-v3-0-75e9b902f9c1@collabora.com> To: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno , Boris Brezillon , Steven Price Cc: kernel@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, Louis-Alexis Eyraud X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1738941518; l=1567; i=louisalexis.eyraud@collabora.com; s=20250113; h=from:subject:message-id; bh=CN3+JuK+9gG4rZwQyx1SxziYFUpyVC/10T8zzKMX1ns=; b=8y9YPPVMz5TCKK1Bvd8KcC0qBES8eUGrCm1D8d4DYAYmYyEpr50J81o9H3sz0X+cRwdhkQgPX EGze/5F8wAFCU877jbxUEhwceg+H4wSpZSm4dIebnoM9xrVE/Zp/2ou X-Developer-Key: i=louisalexis.eyraud@collabora.com; a=ed25519; pk=CHFBDB2Kqh4EHc6JIqFn69GhxJJAzc0Zr4e8QxtumuM= Add a new gpu node in mt8370.dtsi to enable support for the ARM Mali G57 MC2 GPU (Valhall-JM) found on the MT8370 SoC, using the Panfrost driver. On a Mediatek Genio 510 EVK board, the panfrost driver probed with the following message: ``` panfrost 13000000.gpu: clock rate =3D 390000000 panfrost 13000000.gpu: mali-g57 id 0x9093 major 0x0 minor 0x0 status 0x0 panfrost 13000000.gpu: features: 00000000,000019f7, issues: 00000003, 80000400 panfrost 13000000.gpu: Features: L2:0x08130206 Shader:0x00000000 Tiler:0x00000809 Mem:0x1 MMU:0x00002830 AS:0xff JS:0x7 panfrost 13000000.gpu: shader_present=3D0x5 l2_present=3D0x1 [drm] Initialized panfrost 1.3.0 for 13000000.gpu on minor 0 ``` Signed-off-by: Louis-Alexis Eyraud Reviewed-by: AngeloGioacchino Del Regno --- arch/arm64/boot/dts/mediatek/mt8370.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8370.dtsi b/arch/arm64/boot/dts= /mediatek/mt8370.dtsi index cf1a3759451ff899ce9e63e5a00f192fb483f6e5..2f27f7e7ab813b97f869297ae36= 0f69854e966e1 100644 --- a/arch/arm64/boot/dts/mediatek/mt8370.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8370.dtsi @@ -59,6 +59,15 @@ &cpu_little3_cooling_map0 { <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; =20 +&gpu { + compatible =3D "mediatek,mt8370-mali", "arm,mali-valhall-jm"; + + power-domains =3D <&spm MT8188_POWER_DOMAIN_MFG2>, + <&spm MT8188_POWER_DOMAIN_MFG3>; + + power-domain-names =3D "core0", "core1"; +}; + &ppi_cluster0 { affinity =3D <&cpu0 &cpu1 &cpu2 &cpu3>; }; --=20 2.48.1