drm/xe: Don't raise error on fused-off media

It's legitimate for the media GMD_ID register to read back as 0x0 if
media functionality is fused off or otherwise not present on the
platform.  Avoid printing an "unknown media version" error message for
this case.

Reviewed-by: Gustavo Sousa <gustavo.sousa@intel.com>
Link: https://lore.kernel.org/r/20230614205202.3376752-3-matthew.d.roper@intel.com
Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
This commit is contained in:
Matt Roper 2023-06-14 13:52:00 -07:00 committed by Rodrigo Vivi
parent 4133435847
commit 54c5b74a06

View File

@ -447,6 +447,10 @@ static void handle_gmdid(struct xe_device *xe,
peek_gmdid(xe, GMD_ID.addr + 0x380000, &ver, media_revid);
/* Media may legitimately be fused off / not present */
if (ver == 0)
return;
for (int i = 0; i < ARRAY_SIZE(media_ip_map); i++) {
if (ver == media_ip_map[i].ver) {
xe->info.media_verx100 = ver;