> -----Original Message-----
> From: Ville Syrjälä <[email protected]>
> Sent: Wednesday, March 25, 2026 5:46 PM
> To: Kandpal, Suraj <[email protected]>
> Cc: [email protected]; [email protected]; S,
> Sowmiya
> <[email protected]>; Shankar, Uma <[email protected]>; Sharma,
> Swati2 <[email protected]>; Borah, Chaitanya Kumar
> <[email protected]>; Murthy, Arun R
> <[email protected]>
> Subject: Re: [PATCH v3 09/26] drm/i915/writeback: Fill encoder->get_config
>
> On Wed, Mar 25, 2026 at 04:37:27PM +0530, Suraj Kandpal wrote:
> > Fill the encoder->get_config hook with relevant data which helps
> > verify state.
> >
> > Signed-off-by: Suraj Kandpal <[email protected]>
> > ---
> > drivers/gpu/drm/i915/display/intel_writeback.c | 9 +++++++++
> > 1 file changed, 9 insertions(+)
> >
> > diff --git a/drivers/gpu/drm/i915/display/intel_writeback.c
> > b/drivers/gpu/drm/i915/display/intel_writeback.c
> > index 64769609aefe..1df04538d48c 100644
> > --- a/drivers/gpu/drm/i915/display/intel_writeback.c
> > +++ b/drivers/gpu/drm/i915/display/intel_writeback.c
> > @@ -100,6 +100,14 @@ static const struct drm_connector_helper_funcs
> conn_helper_funcs = {
> > .mode_valid = intel_writeback_mode_valid, };
> >
> > +static void
> > +intel_writeback_get_config(struct intel_encoder *encoder,
> > + struct intel_crtc_state *crtc_state) {
> > + crtc_state->output_types |= BIT(INTEL_OUTPUT_WRITEBACK);
> > + crtc_state->output_format = INTEL_OUTPUT_FORMAT_RGB;
>
> That should already be covered by hsw_get_pipe_config()
Let me have a look at it once and what modifications this function would
require.
Regards,
Suraj Kandpal
>
> > +}
> > +
> > static bool
> > intel_writeback_get_hw_state(struct intel_encoder *encoder,
> > enum pipe *pipe)
> > @@ -170,6 +178,7 @@ int intel_writeback_init(struct intel_display
> *display)
> > encoder->type = INTEL_OUTPUT_WRITEBACK;
> > encoder->pipe_mask = ~0;
> > encoder->cloneable = 0;
> > + encoder->get_config = intel_writeback_get_config;
> > encoder->get_hw_state = intel_writeback_get_hw_state;
> >
> > connector = &writeback_conn->connector;
> > --
> > 2.34.1
>
> --
> Ville Syrjälä
> Intel