[Intel-gfx] [PATCH] drm/i915/dmc: Eliminate remnant GEN<n> references

Tolakanahalli Pradeep, Madhumitha madhumitha.tolakanahalli.pradeep at intel.com
Thu Dec 23 03:18:57 UTC 2021


On Fri, 2021-12-17 at 21:37 +0000, Yokoyama, Caz wrote:
> On Thu, 2021-12-16 at 19:41 -0800, Madhumitha Tolakanahalli Pradeep
> wrote:
> > Replace GEN<n> with DISPLAY_VER<n>, in line with the naming
> > convention
> > followed in the i915 driver code.
> > 
> > Signed-off-by: Madhumitha Tolakanahalli Pradeep <
> > madhumitha.tolakanahalli.pradeep at intel.com>
> > ---
> >  drivers/gpu/drm/i915/display/intel_dmc.c | 14 +++++++-------
> >  1 file changed, 7 insertions(+), 7 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c
> > b/drivers/gpu/drm/i915/display/intel_dmc.c
> > index a69b28d65a9b..7616a3906b9e 100644
> > --- a/drivers/gpu/drm/i915/display/intel_dmc.c
> > +++ b/drivers/gpu/drm/i915/display/intel_dmc.c
> > @@ -43,9 +43,9 @@
> >         __stringify(major) "_"           \
> >         __stringify(minor) ".bin"
> >  
> > -#define GEN12_DMC_MAX_FW_SIZE          ICL_DMC_MAX_FW_SIZE
> > +#define DISPLAY_VER13_DMC_MAX_FW_SIZE  0x20000
> >  
> > -#define GEN13_DMC_MAX_FW_SIZE          0x20000
> > +#define DISPLAY_VER12_DMC_MAX_FW_SIZE  ICL_DMC_MAX_FW_SIZE
> Why the order of GEN12/13 and VER12/13 is reversed?
> Other than that, LGTM.
> -caz

I had first defined GEN13 below GEN12, interchanged them to follow
the usual convention of latest-gen-first.

- Madhumitha

> >  
> >  #define ADLP_DMC_PATH                  DMC_PATH(adlp, 2, 14)
> >  #define ADLP_DMC_VERSION_REQUIRED      DMC_VERSION(2, 14)
> > @@ -684,23 +684,23 @@ void intel_dmc_ucode_init(struct
> > drm_i915_private *dev_priv)
> >         if (IS_ALDERLAKE_P(dev_priv)) {
> >                 dmc->fw_path = ADLP_DMC_PATH;
> >                 dmc->required_version = ADLP_DMC_VERSION_REQUIRED;
> > -               dmc->max_fw_size = GEN13_DMC_MAX_FW_SIZE;
> > +               dmc->max_fw_size = DISPLAY_VER13_DMC_MAX_FW_SIZE;
> >         } else if (IS_ALDERLAKE_S(dev_priv)) {
> >                 dmc->fw_path = ADLS_DMC_PATH;
> >                 dmc->required_version = ADLS_DMC_VERSION_REQUIRED;
> > -               dmc->max_fw_size = GEN12_DMC_MAX_FW_SIZE;
> > +               dmc->max_fw_size = DISPLAY_VER12_DMC_MAX_FW_SIZE;
> >         } else if (IS_DG1(dev_priv)) {
> >                 dmc->fw_path = DG1_DMC_PATH;
> >                 dmc->required_version = DG1_DMC_VERSION_REQUIRED;
> > -               dmc->max_fw_size = GEN12_DMC_MAX_FW_SIZE;
> > +               dmc->max_fw_size = DISPLAY_VER12_DMC_MAX_FW_SIZE;
> >         } else if (IS_ROCKETLAKE(dev_priv)) {
> >                 dmc->fw_path = RKL_DMC_PATH;
> >                 dmc->required_version = RKL_DMC_VERSION_REQUIRED;
> > -               dmc->max_fw_size = GEN12_DMC_MAX_FW_SIZE;
> > +               dmc->max_fw_size = DISPLAY_VER12_DMC_MAX_FW_SIZE;
> >         } else if (DISPLAY_VER(dev_priv) >= 12) {
> >                 dmc->fw_path = TGL_DMC_PATH;
> >                 dmc->required_version = TGL_DMC_VERSION_REQUIRED;
> > -               dmc->max_fw_size = GEN12_DMC_MAX_FW_SIZE;
> > +               dmc->max_fw_size = DISPLAY_VER12_DMC_MAX_FW_SIZE;
> >         } else if (DISPLAY_VER(dev_priv) == 11) {
> >                 dmc->fw_path = ICL_DMC_PATH;
> >                 dmc->required_version = ICL_DMC_VERSION_REQUIRED;



More information about the Intel-gfx mailing list