[Intel-xe] [06/10] revert intel_frontbuffer changes.
Hogander, Jouni
jouni.hogander at intel.com
Fri Oct 27 10:17:56 UTC 2023
On Wed, 2023-10-25 at 12:20 +0200, Maarten Lankhorst wrote:
> No functional change, just things removed.
Hello Maarten.
Instead of introducing completely new patch I think you should change
this as a fixup patch for "FIXME: drm/i915/display: Remaining changes
to make xe compile"
BR,
Jouni Högander
>
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst at linux.intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_frontbuffer.c | 7 ++++---
> drivers/gpu/drm/i915/display/intel_frontbuffer.h | 4 ----
> 2 files changed, 4 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_frontbuffer.c
> b/drivers/gpu/drm/i915/display/intel_frontbuffer.c
> index d64ce5bfeca82..2ea37c0414a95 100644
> --- a/drivers/gpu/drm/i915/display/intel_frontbuffer.c
> +++ b/drivers/gpu/drm/i915/display/intel_frontbuffer.c
> @@ -190,7 +190,7 @@ void __intel_fb_flush(struct intel_frontbuffer
> *front,
> enum fb_op_origin origin,
> unsigned int frontbuffer_bits)
> {
> - struct drm_i915_private *i915 = intel_bo_to_i915((front-
> >obj));
> + struct drm_i915_private *i915 = intel_bo_to_i915(front->obj);
>
> if (origin == ORIGIN_CS) {
> spin_lock(&i915->display.fb_tracking.lock);
> @@ -259,6 +259,7 @@ static void frontbuffer_release(struct kref *ref)
> drm_WARN_ON(&intel_bo_to_i915(obj)->drm, atomic_read(&front-
> >bits));
>
> i915_ggtt_clear_scanout(obj);
> +
> ret = i915_gem_object_set_frontbuffer(obj, NULL);
> drm_WARN_ON(&intel_bo_to_i915(obj)->drm, ret);
> spin_unlock(&intel_bo_to_i915(obj)-
> >display.fb_tracking.lock);
> @@ -289,12 +290,12 @@ intel_frontbuffer_get(struct
> drm_i915_gem_object *obj)
> frontbuffer_retire,
> I915_ACTIVE_RETIRE_SLEEPS);
> INIT_WORK(&front->flush_work, intel_frontbuffer_flush_work);
> +
> spin_lock(&i915->display.fb_tracking.lock);
> cur = i915_gem_object_set_frontbuffer(obj, front);
> spin_unlock(&i915->display.fb_tracking.lock);
> if (cur != front)
> kfree(front);
> -
> return cur;
> }
>
> @@ -337,7 +338,7 @@ void intel_frontbuffer_track(struct
> intel_frontbuffer *old,
> }
>
> if (new) {
> - drm_WARN_ON(&intel_bo_to_i915(old->obj)->drm,
> + drm_WARN_ON(&intel_bo_to_i915(new->obj)->drm,
> atomic_read(&new->bits) &
> frontbuffer_bits);
> atomic_or(frontbuffer_bits, &new->bits);
> }
> diff --git a/drivers/gpu/drm/i915/display/intel_frontbuffer.h
> b/drivers/gpu/drm/i915/display/intel_frontbuffer.h
> index 00467d513e74d..abb51e8bb9200 100644
> --- a/drivers/gpu/drm/i915/display/intel_frontbuffer.h
> +++ b/drivers/gpu/drm/i915/display/intel_frontbuffer.h
> @@ -28,10 +28,6 @@
> #include <linux/bits.h>
> #include <linux/kref.h>
>
> -#ifndef I915
> -#include "xe_bo.h"
> -#endif
> -
> #include "i915_active_types.h"
>
> struct drm_i915_private;
More information about the Intel-xe
mailing list