Skip to content

Commit d3414ac

Browse files
committed
drm/xe/vf: Don't try Driver-FLR if VF
Driver-FLR can't be triggered from the VF driver, so treat it as disabled if VF. While around, fix also the message, as it shouldn't be printed just 'once' as we may have many devices. Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Reviewed-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com> Reviewed-by: Matt Roper <matthew.d.roper@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250311135726.1998-2-michal.wajdeczko@intel.com
1 parent de35cc2 commit d3414ac

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

drivers/gpu/drm/xe/xe_device.c

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -496,7 +496,15 @@ ALLOW_ERROR_INJECTION(xe_device_create, ERRNO); /* See xe_pci_probe() */
496496

497497
static bool xe_driver_flr_disabled(struct xe_device *xe)
498498
{
499-
return xe_mmio_read32(xe_root_tile_mmio(xe), GU_CNTL_PROTECTED) & DRIVERINT_FLR_DIS;
499+
if (IS_SRIOV_VF(xe))
500+
return true;
501+
502+
if (xe_mmio_read32(xe_root_tile_mmio(xe), GU_CNTL_PROTECTED) & DRIVERINT_FLR_DIS) {
503+
drm_info(&xe->drm, "Driver-FLR disabled by BIOS\n");
504+
return true;
505+
}
506+
507+
return false;
500508
}
501509

502510
/*
@@ -560,10 +568,8 @@ static void __xe_driver_flr(struct xe_device *xe)
560568

561569
static void xe_driver_flr(struct xe_device *xe)
562570
{
563-
if (xe_driver_flr_disabled(xe)) {
564-
drm_info_once(&xe->drm, "BIOS Disabled Driver-FLR\n");
571+
if (xe_driver_flr_disabled(xe))
565572
return;
566-
}
567573

568574
__xe_driver_flr(xe);
569575
}

0 commit comments

Comments
 (0)