Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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 <michal.wajdeczko@intel.com>
Reviewed-by: Michał Winiarski <michal.winiarski@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240524113714.932-2-michal.wajdeczko@intel.com

+11
+11
drivers/gpu/drm/xe/xe_device.c
··· 34 34 #include "xe_gt.h" 35 35 #include "xe_gt_mcr.h" 36 36 #include "xe_gt_printk.h" 37 + #include "xe_gt_sriov_vf.h" 38 + #include "xe_guc.h" 37 39 #include "xe_hwmon.h" 38 40 #include "xe_irq.h" 39 41 #include "xe_memirq.h" ··· 570 568 } 571 569 572 570 for_each_tile(tile, xe, id) { 571 + if (IS_SRIOV_VF(xe)) { 572 + xe_guc_comm_init_early(&tile->primary_gt->uc.guc); 573 + err = xe_gt_sriov_vf_bootstrap(tile->primary_gt); 574 + if (err) 575 + return err; 576 + err = xe_gt_sriov_vf_query_config(tile->primary_gt); 577 + if (err) 578 + return err; 579 + } 573 580 err = xe_ggtt_init_early(tile->mem.ggtt); 574 581 if (err) 575 582 return err;