drm/xe: Prevent VFs from exposing the CCS mode sysfs file
authorNareshkumar Gollakoti <naresh.kumar.g@intel.com>
Mon, 2 Feb 2026 17:08:12 +0000 (22:38 +0530)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Wed, 18 Feb 2026 00:42:00 +0000 (19:42 -0500)
Skip creating CCS sysfs files in VF mode to ensure VFs do not
try to change CCS mode, as it is predefined and immutable in
the SR-IOV mode.

Reviewed-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Signed-off-by: Nareshkumar Gollakoti <naresh.kumar.g@intel.com>
Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Link: https://patch.msgid.link/20260202170810.1393147-5-naresh.kumar.g@intel.com
(cherry picked from commit 4e8f602ac3574cf1ebc7acfb6624d06e04b30c91)
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/xe/xe_gt_ccs_mode.c

index 91ac22e..fe94468 100644 (file)
@@ -191,7 +191,7 @@ int xe_gt_ccs_mode_sysfs_init(struct xe_gt *gt)
        struct xe_device *xe = gt_to_xe(gt);
        int err;
 
-       if (!xe_gt_ccs_mode_enabled(gt))
+       if (!xe_gt_ccs_mode_enabled(gt) || IS_SRIOV_VF(xe))
                return 0;
 
        err = sysfs_create_files(gt->sysfs, gt_ccs_mode_attrs);