From 08ea5ea2e890e8fbc9875294e6087179574a3057 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jouni=20H=C3=B6gander?= Date: Wed, 13 Sep 2023 12:54:12 +0300 Subject: [PATCH] drm/xe/display: Add Xe implementation for fence checks used by fbc code MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Xe doesn't support legacy fences. Implement legacy fence and fence id checks accordingly. Signed-off-by: Jouni Högander Reviewed-by: Maarten Lankhorst Signed-off-by: Rodrigo Vivi --- drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 1 + drivers/gpu/drm/xe/compat-i915-headers/i915_vma.h | 2 ++ .../gpu/drm/xe/compat-i915-headers/intel_gt_types.h | 11 +++++++++++ 3 files changed, 14 insertions(+) create mode 100644 drivers/gpu/drm/xe/compat-i915-headers/intel_gt_types.h diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index e5d1a4a3d8b42..5d2a77b52db41 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -24,6 +24,7 @@ #include "i915_gpu_error.h" #include "i915_reg_defs.h" #include "i915_utils.h" +#include "intel_gt_types.h" #include "intel_step.h" #include "intel_uc_fw.h" #include "intel_uncore.h" diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_vma.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_vma.h index 88771f5e03cc3..a20d2638ea7a6 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_vma.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_vma.h @@ -24,6 +24,8 @@ struct i915_vma { #define i915_ggtt_clear_scanout(bo) do { } while (0) +#define i915_vma_fence_id(vma) -1 + static inline u32 i915_ggtt_offset(const struct i915_vma *vma) { return vma->node.start; diff --git a/drivers/gpu/drm/xe/compat-i915-headers/intel_gt_types.h b/drivers/gpu/drm/xe/compat-i915-headers/intel_gt_types.h new file mode 100644 index 0000000000000..c15806d6c4f78 --- /dev/null +++ b/drivers/gpu/drm/xe/compat-i915-headers/intel_gt_types.h @@ -0,0 +1,11 @@ +/* SPDX-License-Identifier: MIT */ +/* + * Copyright © 2023 Intel Corporation + */ + +#ifndef __INTEL_GT_TYPES__ +#define __INTEL_GT_TYPES__ + +#define intel_gt_support_legacy_fencing(gt) 0 + +#endif -- 2.30.2