aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_drv.h
diff options
context:
space:
mode:
authorVille Syrjälä <ville.syrjala@linux.intel.com>2021-11-04 16:45:09 +0200
committerVille Syrjälä <ville.syrjala@linux.intel.com>2021-11-11 15:18:11 +0200
commit41b85a5202b775ce7eece34648a4b592ed18f5d2 (patch)
tree8f886ff2e4aac91a9781d8d12624d08413f91653 /drivers/gpu/drm/i915/i915_drv.h
parentdrm/i915/fbc: Extract helpers to compute FBC control register values (diff)
downloadlinux-dev-41b85a5202b775ce7eece34648a4b592ed18f5d2.tar.xz
linux-dev-41b85a5202b775ce7eece34648a4b592ed18f5d2.zip
drm/i915/fbc: Introduce intel_fbc_funcs
Replace the "if-ladders everywhere" approach with vfuncs. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20211104144520.22605-7-ville.syrjala@linux.intel.com Acked-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_drv.h')
-rw-r--r--drivers/gpu/drm/i915/i915_drv.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
index cf88a47799f9..6d091187ecd8 100644
--- a/drivers/gpu/drm/i915/i915_drv.h
+++ b/drivers/gpu/drm/i915/i915_drv.h
@@ -402,10 +402,13 @@ struct drm_i915_display_funcs {
void (*commit_modeset_enables)(struct intel_atomic_state *state);
};
+struct intel_fbc_funcs;
#define I915_COLOR_UNEVICTABLE (-1) /* a non-vma sharing the address space */
struct intel_fbc {
+ const struct intel_fbc_funcs *funcs;
+
/* This is always the inner lock when overlapping with struct_mutex and
* it's the outer lock when overlapping with stolen_lock. */
struct mutex lock;