Skip to contentSkip to conversation

drm/msm/a2xx: enable Adreno A225 support

PATCH In review Dmitry Baryshkov 2 participants 8 messages Nov 21, 2025 – Nov 22, 2025

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

cover drm/msm/a2xx: enable Adreno A225 support

Add two remaining bits necessary to enable Adreno A225 support. Note, this wasn't tested on the actual hardware and is purely based on the old KGSL driver from msm-3.0. For example, running on MSM8960 might require adjusting PM_OVERRIDE[12] registers.

---
Dmitry Baryshkov (2):
drm/msm/a2xx: fix pixel shader start on A225 drm/msm/a2xx: add A225 entry to catalog

 drivers/gpu/drm/msm/adreno/a2xx_catalog.c | 12 ++++++++++++
 drivers/gpu/drm/msm/adreno/a2xx_gpu.c     |  5 ++++-
 2 files changed, 16 insertions(+), 1 deletion(-)

---
base-commit: b179ce312bafcb8c68dc718e015aee79b7939ff0
change-id: 20251121-a225-196020e562c2

Best regards,

Signature · 2 lines
With best wishes
Dmitry
#1 lore raw

PATCH 1/2 drm/msm/a2xx: fix pixel shader start on A225

A225 has a different PixelShader start address, write correct address while initializing GPU.

Fixes 21af872cd8c6 ("drm/msm/adreno: add a2xx")
---
 drivers/gpu/drm/msm/adreno/a2xx_gpu.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/gpu/drm/msm/adreno/a2xx_gpu.c +4 -1
index ec38db45d8a366e75acddbacd4810d7b7a80926f..cdc24b3b7b81cce6b01aa14a74bd8e512cd8be90 100644
@@ -77,7 +77,10 @@ static bool a2xx_me_init(struct msm_gpu *gpu)
 
 	/* Vertex and Pixel Shader Start Addresses in instructions
 	 * (3 DWORDS per instruction) */
-	OUT_RING(ring, 0x80000180);
+	if (adreno_is_a225(adreno_gpu))
+		OUT_RING(ring, 0x80000300);
+	else
+		OUT_RING(ring, 0x80000180);
 	/* Maximum Contexts */
 	OUT_RING(ring, 0x00000001);
 	/* Write Confirm Interval and The CP will wait the
Signature · 1 line
2.47.3
#3 lore raw

PATCH 2/2 drm/msm/a2xx: add A225 entry to catalog

In reply to Dmitry Baryshkov

Add catalog entry for Adreno A225.6 as present on MSM8960v3. Most of the pieces were already contributed by Jonathan Marek in commit 21af872cd8c6 ("drm/msm/adreno: add a2xx"), but weren't enabled because there was no GPU entry.

---
 drivers/gpu/drm/msm/adreno/a2xx_catalog.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)
drivers/gpu/drm/msm/adreno/a2xx_catalog.c +12 -0
index 5ddd015f930d9a7dd04e2d2035daa0b2f5ff3f27..9ee4c9c4dcf7575a4fdfe24a14cd6acc99f5de1c 100644
@@ -42,6 +42,18 @@ static const struct adreno_info a2xx_gpus[] = {
 		.gmem  = SZ_512K,
 		.inactive_period = DRM_MSM_INACTIVE_PERIOD,
 		.init  = a2xx_gpu_init,
+	}, {
+		/* Only for msm8960v3, v2 required a special firmware */
+		.chip_ids = ADRENO_CHIP_IDS(0x02020506),
+		.family = ADRENO_2XX_GEN2,
+		.revn  = 225,
+		.fw = {
+			[ADRENO_FW_PM4] = "a225_pm4.fw",
+			[ADRENO_FW_PFP] = "a225_pfp.fw",
+		},
+		.gmem  = SZ_512K,
+		.inactive_period = DRM_MSM_INACTIVE_PERIOD,
+		.init  = a2xx_gpu_init,
 	}
 };
 DECLARE_ADRENO_GPULIST(a2xx);
Signature · 1 line
2.47.3
Reviewed-by on v1 2/2
#4 lore raw

Re: [PATCH 2/2] drm/msm/a2xx: add A225 entry to catalog

Quoted 7 lines · Dmitry Baryshkov

Add catalog entry for Adreno A225.6 as present on MSM8960v3. Most of the pieces were already contributed by Jonathan Marek in commit 21af872cd8c6 ("drm/msm/adreno: add a2xx"), but weren't enabled because there was no GPU entry.

---

Konrad

#5 lore raw
In reply to Dmitry Baryshkov
Quoted 10 lines · Dmitry Baryshkov

Add two remaining bits necessary to enable Adreno A225 support. Note, this wasn't tested on the actual hardware and is purely based on the old KGSL driver from msm-3.0. For example, running on MSM8960 might require adjusting PM_OVERRIDE[12] registers.

---
Dmitry Baryshkov (2):
drm/msm/a2xx: fix pixel shader start on A225 drm/msm/a2xx: add A225 entry to catalog

Not sure that's enough, a2xx_drawctxt_draw_workaround looks scary

https://github.com/AdrianDC/android_kernel_sony_msm8960t/blob/lineage-18.1/drivers/gpu/msm/adreno_a2xx.c

Konrad

#6 lore raw
Quoted 12 lines · Konrad Dybcio
Quoted 10 lines · Dmitry Baryshkov

Add two remaining bits necessary to enable Adreno A225 support. Note, this wasn't tested on the actual hardware and is purely based on the old KGSL driver from msm-3.0. For example, running on MSM8960 might require adjusting PM_OVERRIDE[12] registers.

---
Dmitry Baryshkov (2):
drm/msm/a2xx: fix pixel shader start on A225 drm/msm/a2xx: add A225 entry to catalog

Quoted 3 lines

Not sure that's enough, a2xx_drawctxt_draw_workaround looks scary

https://github.com/AdrianDC/android_kernel_sony_msm8960t/blob/lineage-18.1/drivers/gpu/msm/adreno_a2xx.c

Yep. msm-3.0 does some other things for a200 / a220, which we don't perform. I don't know which parts actually apply to our stack and which don't.

Signature · 2 lines
With best wishes
Dmitry
#7 lore raw
Quoted 13 lines · Dmitry Baryshkov
Quoted 12 lines · Konrad Dybcio
Quoted 10 lines · Dmitry Baryshkov

Add two remaining bits necessary to enable Adreno A225 support. Note, this wasn't tested on the actual hardware and is purely based on the old KGSL driver from msm-3.0. For example, running on MSM8960 might require adjusting PM_OVERRIDE[12] registers.

---
Dmitry Baryshkov (2):
drm/msm/a2xx: fix pixel shader start on A225 drm/msm/a2xx: add A225 entry to catalog

Quoted 7 lines
Quoted 3 lines

Not sure that's enough, a2xx_drawctxt_draw_workaround looks scary

https://github.com/AdrianDC/android_kernel_sony_msm8960t/blob/lineage-18.1/drivers/gpu/msm/adreno_a2xx.c

Yep. msm-3.0 does some other things for a200 / a220, which we don't perform. I don't know which parts actually apply to our stack and which don't.

Right, this patchset at least fixes up the obvious errors and those interested can poke at it more

Konrad