Message ID | 20221026113906.10551-5-ville.syrjala@linux.intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | drm/i915: More gamma work | expand |
Seems the offset is same since IVB. The Gamma correction max seem to be defined since IVB, but this doesnt seem to be used during ivb_load_luts, but only for multi-segmented gamma. Is it that the default value of 1.0 is sufficient for other platforms? Regards, Ankit On 10/26/2022 5:08 PM, Ville Syrjala wrote: > From: Ville Syrjälä <ville.syrjala@linux.intel.com> > > Unify icl_load_gcmax() with the rest of the function > naming scheme by calling it ivb_load_lut_max() instead. > > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> > --- > drivers/gpu/drm/i915/display/intel_color.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/drivers/gpu/drm/i915/display/intel_color.c b/drivers/gpu/drm/i915/display/intel_color.c > index 415e0a6839a4..e73e6ea6f82f 100644 > --- a/drivers/gpu/drm/i915/display/intel_color.c > +++ b/drivers/gpu/drm/i915/display/intel_color.c > @@ -935,8 +935,8 @@ static u32 ilk_lut_12p4_ldw(const struct drm_color_lut *color) > } > > static void > -icl_load_gcmax(const struct intel_crtc_state *crtc_state, > - const struct drm_color_lut *color) > +ivb_load_lut_max(const struct intel_crtc_state *crtc_state, > + const struct drm_color_lut *color) > { > struct intel_crtc *crtc = to_intel_crtc(crtc_state->uapi.crtc); > enum pipe pipe = crtc->pipe; > @@ -1028,7 +1028,7 @@ icl_program_gamma_multi_segment(const struct intel_crtc_state *crtc_state) > > /* The last entry in the LUT is to be programmed in GCMAX */ > entry = &lut[256 * 8 * 128]; > - icl_load_gcmax(crtc_state, entry); > + ivb_load_lut_max(crtc_state, entry); > ivb_load_lut_ext_max(crtc_state); > } >
On Thu, Nov 03, 2022 at 11:49:20AM +0530, Nautiyal, Ankit K wrote: > Seems the offset is same since IVB. > > The Gamma correction max seem to be defined since IVB, but this doesnt > seem to be used during ivb_load_luts, but only for multi-segmented gamma. It would be used for the 12.4 interpolated gamma mode on earlier platforms, but we don't expose that currently. > > Is it that the default value of 1.0 is sufficient for other platforms? Since it's not used in any of the gamma modes we do expose it doesn't matter what we leave there atm. > > Regards, > > Ankit > > On 10/26/2022 5:08 PM, Ville Syrjala wrote: > > From: Ville Syrjälä <ville.syrjala@linux.intel.com> > > > > Unify icl_load_gcmax() with the rest of the function > > naming scheme by calling it ivb_load_lut_max() instead. > > > > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> > > --- > > drivers/gpu/drm/i915/display/intel_color.c | 6 +++--- > > 1 file changed, 3 insertions(+), 3 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/display/intel_color.c b/drivers/gpu/drm/i915/display/intel_color.c > > index 415e0a6839a4..e73e6ea6f82f 100644 > > --- a/drivers/gpu/drm/i915/display/intel_color.c > > +++ b/drivers/gpu/drm/i915/display/intel_color.c > > @@ -935,8 +935,8 @@ static u32 ilk_lut_12p4_ldw(const struct drm_color_lut *color) > > } > > > > static void > > -icl_load_gcmax(const struct intel_crtc_state *crtc_state, > > - const struct drm_color_lut *color) > > +ivb_load_lut_max(const struct intel_crtc_state *crtc_state, > > + const struct drm_color_lut *color) > > { > > struct intel_crtc *crtc = to_intel_crtc(crtc_state->uapi.crtc); > > enum pipe pipe = crtc->pipe; > > @@ -1028,7 +1028,7 @@ icl_program_gamma_multi_segment(const struct intel_crtc_state *crtc_state) > > > > /* The last entry in the LUT is to be programmed in GCMAX */ > > entry = &lut[256 * 8 * 128]; > > - icl_load_gcmax(crtc_state, entry); > > + ivb_load_lut_max(crtc_state, entry); > > ivb_load_lut_ext_max(crtc_state); > > } > >
On 11/3/2022 3:04 PM, Ville Syrjälä wrote: > On Thu, Nov 03, 2022 at 11:49:20AM +0530, Nautiyal, Ankit K wrote: >> Seems the offset is same since IVB. >> >> The Gamma correction max seem to be defined since IVB, but this doesnt >> seem to be used during ivb_load_luts, but only for multi-segmented gamma. > It would be used for the 12.4 interpolated gamma mode on > earlier platforms, but we don't expose that currently. > >> Is it that the default value of 1.0 is sufficient for other platforms? > Since it's not used in any of the gamma modes we do expose > it doesn't matter what we leave there atm. Fair enough. LGTM. Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com> > >> Regards, >> >> Ankit >> >> On 10/26/2022 5:08 PM, Ville Syrjala wrote: >>> From: Ville Syrjälä <ville.syrjala@linux.intel.com> >>> >>> Unify icl_load_gcmax() with the rest of the function >>> naming scheme by calling it ivb_load_lut_max() instead. >>> >>> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> >>> --- >>> drivers/gpu/drm/i915/display/intel_color.c | 6 +++--- >>> 1 file changed, 3 insertions(+), 3 deletions(-) >>> >>> diff --git a/drivers/gpu/drm/i915/display/intel_color.c b/drivers/gpu/drm/i915/display/intel_color.c >>> index 415e0a6839a4..e73e6ea6f82f 100644 >>> --- a/drivers/gpu/drm/i915/display/intel_color.c >>> +++ b/drivers/gpu/drm/i915/display/intel_color.c >>> @@ -935,8 +935,8 @@ static u32 ilk_lut_12p4_ldw(const struct drm_color_lut *color) >>> } >>> >>> static void >>> -icl_load_gcmax(const struct intel_crtc_state *crtc_state, >>> - const struct drm_color_lut *color) >>> +ivb_load_lut_max(const struct intel_crtc_state *crtc_state, >>> + const struct drm_color_lut *color) >>> { >>> struct intel_crtc *crtc = to_intel_crtc(crtc_state->uapi.crtc); >>> enum pipe pipe = crtc->pipe; >>> @@ -1028,7 +1028,7 @@ icl_program_gamma_multi_segment(const struct intel_crtc_state *crtc_state) >>> >>> /* The last entry in the LUT is to be programmed in GCMAX */ >>> entry = &lut[256 * 8 * 128]; >>> - icl_load_gcmax(crtc_state, entry); >>> + ivb_load_lut_max(crtc_state, entry); >>> ivb_load_lut_ext_max(crtc_state); >>> } >>>
diff --git a/drivers/gpu/drm/i915/display/intel_color.c b/drivers/gpu/drm/i915/display/intel_color.c index 415e0a6839a4..e73e6ea6f82f 100644 --- a/drivers/gpu/drm/i915/display/intel_color.c +++ b/drivers/gpu/drm/i915/display/intel_color.c @@ -935,8 +935,8 @@ static u32 ilk_lut_12p4_ldw(const struct drm_color_lut *color) } static void -icl_load_gcmax(const struct intel_crtc_state *crtc_state, - const struct drm_color_lut *color) +ivb_load_lut_max(const struct intel_crtc_state *crtc_state, + const struct drm_color_lut *color) { struct intel_crtc *crtc = to_intel_crtc(crtc_state->uapi.crtc); enum pipe pipe = crtc->pipe; @@ -1028,7 +1028,7 @@ icl_program_gamma_multi_segment(const struct intel_crtc_state *crtc_state) /* The last entry in the LUT is to be programmed in GCMAX */ entry = &lut[256 * 8 * 128]; - icl_load_gcmax(crtc_state, entry); + ivb_load_lut_max(crtc_state, entry); ivb_load_lut_ext_max(crtc_state); }