diff options
author | Jesse Barnes <jbarnes@virtuousgeek.org> | 2008-09-30 12:46:20 -0700 |
---|---|---|
committer | Jesse Barnes <jbarnes@virtuousgeek.org> | 2008-09-30 12:46:20 -0700 |
commit | fa2586a40f20e73ec7420466638e8f595e0da987 (patch) | |
tree | 42afff9e5c1421d590087ae0ecfa39ef9d7ce874 | |
parent | f315e9d1ad92562195ce42b956d4be6b31e8a13e (diff) |
Use VBT LFP info pointers by default
On some machines it appears that the LFP info pointers give us more
accurate panel info than if we index into the LFP data table using the
panel type index. Early reports indicate that using the pointers
doesn't cause regressions, so switch to them by default to help 8xx
machines.
Fixes bug 17310 (and hopefully 17658 too).
-rw-r--r-- | src/i830_bios.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/i830_bios.c b/src/i830_bios.c index ff49025d..2cb0b07b 100644 --- a/src/i830_bios.c +++ b/src/i830_bios.c @@ -88,8 +88,8 @@ static void parse_panel_data(I830Ptr pI830, struct bdb_header *bdb) { struct bdb_lvds_options *lvds_options; - struct bdb_lvds_lfp_data *lvds_lfp_data; - struct bdb_lvds_lfp_data_entry *entry; + struct bdb_lvds_lfp_data_ptrs *lvds_lfp_data_ptrs; + int timing_offset; DisplayModePtr fixed_mode; unsigned char *timing_ptr; @@ -104,12 +104,13 @@ parse_panel_data(I830Ptr pI830, struct bdb_header *bdb) if (lvds_options->panel_type == 0xff) return; - lvds_lfp_data = find_section(bdb, BDB_LVDS_LFP_DATA); - if (!lvds_lfp_data) + lvds_lfp_data_ptrs = find_section(bdb, BDB_LVDS_LFP_DATA_PTRS); + if (!lvds_lfp_data_ptrs) return; - entry = &lvds_lfp_data->data[lvds_options->panel_type]; - timing_ptr = (unsigned char *)&entry->dvo_timing; + timing_offset = + lvds_lfp_data_ptrs->ptr[lvds_options->panel_type].dvo_timing_offset; + timing_ptr = (unsigned char *)bdb + timing_offset; fixed_mode = xnfalloc(sizeof(DisplayModeRec)); memset(fixed_mode, 0, sizeof(*fixed_mode)); |