> -----Original Message-----
> From: Garg, Nemesa
> Sent: Tuesday, December 16, 2025 8:29 PM
> To: 'Ville Syrjälä' <[email protected]>
> Cc: [email protected]; [email protected]; Syrjala,
> Ville <[email protected]>; Shankar, Uma <[email protected]>
> Subject: RE: [PATCH 3/5] drm/i915/display: Pass dsb_commit to CASF helpers
> 
> 
> 
> > -----Original Message-----
> > From: Ville Syrjälä <[email protected]>
> > Sent: Friday, December 12, 2025 10:05 PM
> > To: Garg, Nemesa <[email protected]>
> > Cc: [email protected]; [email protected];
> > Syrjala, Ville <[email protected]>; Shankar, Uma
> > <[email protected]>
> > Subject: Re: [PATCH 3/5] drm/i915/display: Pass dsb_commit to CASF
> > helpers
> >
> > On Tue, Dec 09, 2025 at 11:55:25AM +0530, Nemesa Garg wrote:
> > > Incase of non-modeset enable the casf, update the strength or
> > > disable the casf through dsb.
> > >
> > > Signed-off-by: Nemesa Garg <[email protected]>
> > > ---
> > >  drivers/gpu/drm/i915/display/intel_display.c | 12 ++++++++++++
> > >  1 file changed, 12 insertions(+)
> > >
> > > diff --git a/drivers/gpu/drm/i915/display/intel_display.c
> > > b/drivers/gpu/drm/i915/display/intel_display.c
> > > index 256103d55409..7edfc8c2ae21 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_display.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_display.c
> > > @@ -7300,6 +7300,8 @@ static void intel_atomic_dsb_finish(struct
> > intel_atomic_state *state,
> > >   struct intel_display *display = to_intel_display(state);
> > >   struct intel_crtc_state *new_crtc_state =
> > >           intel_atomic_get_new_crtc_state(state, crtc);
> > > + struct intel_crtc_state *old_crtc_state =
> > > +         intel_atomic_get_old_crtc_state(state, crtc);
> > >   unsigned int size = new_crtc_state->plane_color_changed ? 8192 :
> > > 1024;
> > >
> > >   if (!new_crtc_state->use_flipq &&
> > > @@ -7332,6 +7334,16 @@ static void intel_atomic_dsb_finish(struct
> > intel_atomic_state *state,
> > >           if (intel_crtc_needs_color_update(new_crtc_state))
> > >                   intel_color_commit_noarm(new_crtc_state-
> > >dsb_commit,
> > >                                            new_crtc_state);
> > > +         if (intel_casf_enabling(new_crtc_state, old_crtc_state))
> > > +                 intel_casf_enable(new_crtc_state->dsb_commit,
> > > +                                   new_crtc_state);
> > > +         else if (new_crtc_state->hw.casf_params.strength !=
> > > +                         old_crtc_state->hw.casf_params.strength)
> > > +                 intel_casf_update_strength(new_crtc_state-
> > >dsb_commit,
> > > +                                            new_crtc_state);
> > > +         if (intel_casf_disabling(old_crtc_state, new_crtc_state))
> > > +                 intel_casf_disable(new_crtc_state->dsb_commit,
> > > +                                    new_crtc_state);
> >
> > I don't want to see this casf stuff becoming even more special. It
> > needs to be made less special. So I think it should get completely
> > buried inside the existing pipe scaler/pfit codepaths.
> >
> Hi Ville,
> 
> For sharpness we need to call casf_enable during modeset as it will enable all
> registers related to scaler and sharpness and then we need to call
> casf_update_strength during fastest as only sharpness_strength needs to be
> updated.
> 
> Do I need to add something like this :
>                if (new_crtc_state->pch_pfit.enabled || crtc_state-
> >hw.casf_params.casf_enable )
>                         skl_pfit_enable(new_crtc_state); and then call
> intel_casf_enable() and casf_update_strength() from skl_pfit_enable();
> 
I meant either we can have this check if (new_crtc_state->pch_pfit.enabled || 
crtc_state-
> >hw.casf_params.casf_enable )
And then call skl_pfit_enable(new_crtc_state); or > intel_casf_enable();

Or inside skl_pfit_enable(new_crtc_state); we can have a check 
crtc_state->hw.casf_params.casf_enable ) and then call > intel_casf_enable();

> > >           intel_crtc_planes_update_noarm(new_crtc_state-
> > >dsb_commit,
> > >                                          state, crtc);
> > >
> > > --
> > > 2.25.1
> >
> > --
> > Ville Syrjälä
> > Intel

Reply via email to