On Fri, Nov 14, 2025 at 04:15:59PM +0200, Ville Syrjälä wrote: > On Fri, Nov 14, 2025 at 12:26:47PM +0200, Jani Nikula wrote: > > Make the RPS boost code independent of i915 request code by moving the > > dma_fence_is_i915() check to the RPS boost call. > > > > Signed-off-by: Jani Nikula <[email protected]> > > > > --- > > > > I'm not actually sure what the non-i915 fences would be here, and what > > kind of overhead they would cause. > > The fence could be from another GPU driver that did the rendering, > and then we can't convert the fence to i915 request. > > At some point we should probably look into using the fence > .set_deadline() stuff instead of this "boost when late" > approach, but that's one of those things that probably needs > some amount of hand tuning, so real work required. > > Anyways I think this should be fine, we just set up the vblank > miss thingy even for non-i915 fences now and then do nothing > if it triggers. > > aReviewed-by: Ville Syrjälä <[email protected]>
Rather Reviewed-by: Ville Syrjälä <[email protected]> > > > --- > > drivers/gpu/drm/i915/display/intel_display_rps.c | 4 ---- > > drivers/gpu/drm/i915/gt/intel_rps.c | 7 ++++++- > > 2 files changed, 6 insertions(+), 5 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/display/intel_display_rps.c > > b/drivers/gpu/drm/i915/display/intel_display_rps.c > > index e70c4f0eab80..86e757423c0a 100644 > > --- a/drivers/gpu/drm/i915/display/intel_display_rps.c > > +++ b/drivers/gpu/drm/i915/display/intel_display_rps.c > > @@ -9,7 +9,6 @@ > > #include <drm/drm_vblank.h> > > > > #include "i915_reg.h" > > -#include "i915_request.h" > > #include "intel_display_core.h" > > #include "intel_display_irq.h" > > #include "intel_display_rps.h" > > @@ -49,9 +48,6 @@ void intel_display_rps_boost_after_vblank(struct drm_crtc > > *crtc, > > if (!intel_parent_rps_available(display)) > > return; > > > > - if (!dma_fence_is_i915(fence)) > > - return; > > - > > if (DISPLAY_VER(display) < 6) > > return; > > > > diff --git a/drivers/gpu/drm/i915/gt/intel_rps.c > > b/drivers/gpu/drm/i915/gt/intel_rps.c > > index 61d746bda462..05b21de6c24b 100644 > > --- a/drivers/gpu/drm/i915/gt/intel_rps.c > > +++ b/drivers/gpu/drm/i915/gt/intel_rps.c > > @@ -2917,7 +2917,12 @@ EXPORT_SYMBOL_GPL(i915_gpu_turbo_disable); > > > > static void boost(struct dma_fence *fence) > > { > > - struct i915_request *rq = to_request(fence); > > + struct i915_request *rq; > > + > > + if (!dma_fence_is_i915(fence)) > > + return; > > + > > + rq = to_request(fence); > > > > /* > > * If we missed the vblank, but the request is already running it > > -- > > 2.47.3 > > -- > Ville Syrjälä > Intel -- Ville Syrjälä Intel
