Message ID | 20240503122449.27266-14-ville.syrjala@linux.intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | drm/i915/bios: Define (almost) all BDB blocks | expand |
On Fri, 03 May 2024, Ville Syrjala <ville.syrjala@linux.intel.com> wrote: > From: Ville Syrjälä <ville.syrjala@linux.intel.com> > > Define the contents of VBT block 10 (Mode Removal Table). > > There seem to be two variants: > - 8 byte entries for desktop systems > - 10 byte entries for mobile systems, with the extra > panel_flags being a bitmask of LFPs > > It seems starting from HSW only the mobile variant is > used anymore. > > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Awful stuff. Reviewed-by: Jani Nikula <jani.nikula@intel.com> > --- > drivers/gpu/drm/i915/display/intel_vbt_defs.h | 23 +++++++++++++++++++ > 1 file changed, 23 insertions(+) > > diff --git a/drivers/gpu/drm/i915/display/intel_vbt_defs.h b/drivers/gpu/drm/i915/display/intel_vbt_defs.h > index 4f0b8be3034c..d78523cd4214 100644 > --- a/drivers/gpu/drm/i915/display/intel_vbt_defs.h > +++ b/drivers/gpu/drm/i915/display/intel_vbt_defs.h > @@ -677,6 +677,29 @@ struct bdb_psr { > u32 psr2_tp2_tp3_wakeup_time; /* 226+ */ > } __packed; > > +/* > + * Block 10 - Mode Removal Table > + */ > + > +struct mode_removal_table { > + u16 x_res; > + u16 y_res; > + u8 bpp; > + u16 refresh_rate; > + u8 removal_flags; > + u16 panel_flags; > +} __packed; > + > +struct bdb_mode_removal { > + u8 row_size; /* 8 or 10 bytes */ > + /* > + * VBT spec says this is always 20 entries, > + * but ALM seems to have only 15 entries. > + */ > + struct mode_removal_table modes[]; > + /* u16 terminator; 0x0000 */ > +} __packed; > + > /* > * Block 12 - Driver Features Data Block > */
diff --git a/drivers/gpu/drm/i915/display/intel_vbt_defs.h b/drivers/gpu/drm/i915/display/intel_vbt_defs.h index 4f0b8be3034c..d78523cd4214 100644 --- a/drivers/gpu/drm/i915/display/intel_vbt_defs.h +++ b/drivers/gpu/drm/i915/display/intel_vbt_defs.h @@ -677,6 +677,29 @@ struct bdb_psr { u32 psr2_tp2_tp3_wakeup_time; /* 226+ */ } __packed; +/* + * Block 10 - Mode Removal Table + */ + +struct mode_removal_table { + u16 x_res; + u16 y_res; + u8 bpp; + u16 refresh_rate; + u8 removal_flags; + u16 panel_flags; +} __packed; + +struct bdb_mode_removal { + u8 row_size; /* 8 or 10 bytes */ + /* + * VBT spec says this is always 20 entries, + * but ALM seems to have only 15 entries. + */ + struct mode_removal_table modes[]; + /* u16 terminator; 0x0000 */ +} __packed; + /* * Block 12 - Driver Features Data Block */