On Tue, Oct 06, 2020 at 01:00:21PM +0300, Jani Nikula wrote: > On Tue, 06 Oct 2020, Imre Deak <imre.deak@xxxxxxxxx> wrote: > > On Tue, Oct 06, 2020 at 12:42:58PM +0300, Jani Nikula wrote: > >> On Tue, 06 Oct 2020, Imre Deak <imre.deak@xxxxxxxxx> wrote: > >> > +static bool gen11_dsi_initial_fastset_check(struct intel_encoder *encoder, > >> > + struct intel_crtc_state *crtc_state) > >> > +{ > >> > + if (crtc_state->dsc.compression_enable) { > >> > + drm_dbg_kms(encoder->base.dev, "Forcing full modeset due to DSC being enabled\n"); > >> > + crtc_state->uapi.mode_changed = true; > >> > >> Just musing... if it's a *check*, why do we pass in a non-const > >> crtc_state and modify it here? > >> > >> Would it not be cleaner to pass in const crtc_state and set > >> crtc_state->uapi.mode_changed in the caller based on the return value? > > > > The encoder can update the *_changed flags in crtc_state depending on > > what is preventing a fastset. > > Okay... is this a good design? ;) That's how atomic_check hooks work.. > > BR, > Jani. > > > -- > Jani Nikula, Intel Open Source Graphics Center _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx