Skip to content

Commit 280807d

Browse files
quic-kdybciorobclark
authored andcommitted
drm/msm/a6xx: Print GMU core firmware version at boot
Log the version for informational purposes, such as for keeping track of possible GMU fw-related failures in crash / CI logs. Intentionally not implemented on the if (gmu->legacy) codepath, as these registers seem not to be used on there. Downstream additionally warns if the firmware version is too old for a given GPU, but we already pair the binary to a given GPU, so let's not go there at the moment. Signed-off-by: Konrad Dybcio <[email protected]> Reviewed-by: Akhil P Oommen <[email protected]> Patchwork: https://patchwork.freedesktop.org/patch/629934/ Signed-off-by: Rob Clark <[email protected]>
1 parent bb5acde commit 280807d

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

drivers/gpu/drm/msm/adreno/a6xx_gmu.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -729,6 +729,7 @@ static int a6xx_gmu_fw_load(struct a6xx_gmu *gmu)
729729
const struct firmware *fw_image = adreno_gpu->fw[ADRENO_FW_GMU];
730730
const struct block_header *blk;
731731
u32 reg_offset;
732+
u32 ver;
732733

733734
u32 itcm_base = 0x00000000;
734735
u32 dtcm_base = 0x00040000;
@@ -775,6 +776,12 @@ static int a6xx_gmu_fw_load(struct a6xx_gmu *gmu)
775776
}
776777
}
777778

779+
ver = gmu_read(gmu, REG_A6XX_GMU_CORE_FW_VERSION);
780+
DRM_INFO("Loaded GMU firmware v%u.%u.%u\n",
781+
FIELD_GET(A6XX_GMU_CORE_FW_VERSION_MAJOR__MASK, ver),
782+
FIELD_GET(A6XX_GMU_CORE_FW_VERSION_MINOR__MASK, ver),
783+
FIELD_GET(A6XX_GMU_CORE_FW_VERSION_STEP__MASK, ver));
784+
778785
return 0;
779786
}
780787

0 commit comments

Comments
 (0)