58
58
#define SLAVE_ADDR1 0x70
59
59
#define SLAVE_ADDR2 0x72
60
60
61
- static int panel_type ;
62
-
63
61
/* Get BDB block size given a pointer to Block ID. */
64
62
static u32 _get_blocksize (const u8 * block_base )
65
63
{
@@ -205,6 +203,7 @@ parse_lfp_panel_data(struct drm_i915_private *dev_priv,
205
203
const struct lvds_dvo_timing * panel_dvo_timing ;
206
204
const struct lvds_fp_timing * fp_timing ;
207
205
struct drm_display_mode * panel_fixed_mode ;
206
+ int panel_type ;
208
207
int drrs_mode ;
209
208
210
209
lvds_options = find_section (bdb , BDB_LVDS_OPTIONS );
@@ -219,6 +218,7 @@ parse_lfp_panel_data(struct drm_i915_private *dev_priv,
219
218
}
220
219
221
220
panel_type = lvds_options -> panel_type ;
221
+ dev_priv -> vbt .panel_type = panel_type ;
222
222
223
223
drrs_mode = (lvds_options -> dps_panel_type_bits
224
224
>> (panel_type * 2 )) & MODE_MASK ;
@@ -254,7 +254,7 @@ parse_lfp_panel_data(struct drm_i915_private *dev_priv,
254
254
255
255
panel_dvo_timing = get_lvds_dvo_timing (lvds_lfp_data ,
256
256
lvds_lfp_data_ptrs ,
257
- lvds_options -> panel_type );
257
+ panel_type );
258
258
259
259
panel_fixed_mode = kzalloc (sizeof (* panel_fixed_mode ), GFP_KERNEL );
260
260
if (!panel_fixed_mode )
@@ -269,7 +269,7 @@ parse_lfp_panel_data(struct drm_i915_private *dev_priv,
269
269
270
270
fp_timing = get_lvds_fp_timing (bdb , lvds_lfp_data ,
271
271
lvds_lfp_data_ptrs ,
272
- lvds_options -> panel_type );
272
+ panel_type );
273
273
if (fp_timing ) {
274
274
/* check the resolution, just to be sure */
275
275
if (fp_timing -> x_res == panel_fixed_mode -> hdisplay &&
@@ -287,6 +287,7 @@ parse_lfp_backlight(struct drm_i915_private *dev_priv,
287
287
{
288
288
const struct bdb_lfp_backlight_data * backlight_data ;
289
289
const struct bdb_lfp_backlight_data_entry * entry ;
290
+ int panel_type = dev_priv -> vbt .panel_type ;
290
291
291
292
backlight_data = find_section (bdb , BDB_LVDS_BACKLIGHT );
292
293
if (!backlight_data )
@@ -549,6 +550,7 @@ parse_edp(struct drm_i915_private *dev_priv, const struct bdb_header *bdb)
549
550
const struct bdb_edp * edp ;
550
551
const struct edp_power_seq * edp_pps ;
551
552
const struct edp_link_params * edp_link_params ;
553
+ int panel_type = dev_priv -> vbt .panel_type ;
552
554
553
555
edp = find_section (bdb , BDB_EDP );
554
556
if (!edp ) {
@@ -660,6 +662,7 @@ parse_psr(struct drm_i915_private *dev_priv, const struct bdb_header *bdb)
660
662
{
661
663
const struct bdb_psr * psr ;
662
664
const struct psr_table * psr_table ;
665
+ int panel_type = dev_priv -> vbt .panel_type ;
663
666
664
667
psr = find_section (bdb , BDB_PSR );
665
668
if (!psr ) {
@@ -706,6 +709,7 @@ parse_mipi_config(struct drm_i915_private *dev_priv,
706
709
const struct bdb_mipi_config * start ;
707
710
const struct mipi_config * config ;
708
711
const struct mipi_pps_data * pps ;
712
+ int panel_type = dev_priv -> vbt .panel_type ;
709
713
710
714
/* parse MIPI blocks only if LFP type is MIPI */
711
715
if (!intel_bios_is_dsi_present (dev_priv , NULL ))
@@ -913,6 +917,7 @@ static void
913
917
parse_mipi_sequence (struct drm_i915_private * dev_priv ,
914
918
const struct bdb_header * bdb )
915
919
{
920
+ int panel_type = dev_priv -> vbt .panel_type ;
916
921
const struct bdb_mipi_sequence * sequence ;
917
922
const u8 * seq_data ;
918
923
u32 seq_size ;
0 commit comments