From: Michal Wajdeczko Date: Fri, 24 May 2024 11:37:13 +0000 (+0200) Subject: drm/xe/vf: Read VF configuration prior to GGTT initialization X-Git-Tag: microblaze-v6.13~18^2~29^2~264 X-Git-Url: http://git.monstr.eu/?a=commitdiff_plain;h=ea797cf4b7f8470f1b23cd084096cb93fb93e6c3;p=linux-2.6-microblaze.git drm/xe/vf: Read VF configuration prior to GGTT initialization Each VF will be assigned with only a limited range of the GGTT address space. Make sure that VF driver will read its own GGTT configuration before starting any GGTT initialization. Signed-off-by: Michal Wajdeczko Reviewed-by: MichaƂ Winiarski Link: https://patchwork.freedesktop.org/patch/msgid/20240524113714.932-2-michal.wajdeczko@intel.com --- diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c index 2eba1e32c633..b2d5c7341238 100644 --- a/drivers/gpu/drm/xe/xe_device.c +++ b/drivers/gpu/drm/xe/xe_device.c @@ -34,6 +34,8 @@ #include "xe_gt.h" #include "xe_gt_mcr.h" #include "xe_gt_printk.h" +#include "xe_gt_sriov_vf.h" +#include "xe_guc.h" #include "xe_hwmon.h" #include "xe_irq.h" #include "xe_memirq.h" @@ -568,6 +570,15 @@ int xe_device_probe(struct xe_device *xe) } for_each_tile(tile, xe, id) { + if (IS_SRIOV_VF(xe)) { + xe_guc_comm_init_early(&tile->primary_gt->uc.guc); + err = xe_gt_sriov_vf_bootstrap(tile->primary_gt); + if (err) + return err; + err = xe_gt_sriov_vf_query_config(tile->primary_gt); + if (err) + return err; + } err = xe_ggtt_init_early(tile->mem.ggtt); if (err) return err;