summaryrefslogtreecommitdiff
path: root/src/i830_dvo.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2007-10-01 16:23:30 -0700
committerEric Anholt <eric@anholt.net>2007-10-01 16:23:30 -0700
commit263d48ad93a0fb7100729d0c6e0443797c20c80a (patch)
treea357b5f96eba8ae8b6cbd159ca8a70b94a37f048 /src/i830_dvo.c
parent219354af212c7b68c20df689692c55331e36a705 (diff)
Fix probing of the sample CH7017 device I found by allowing GPIO overrides.
It may be that the LVDS chips need to be DVOA and GPIOB only on mobility devices with them, and DVOC/GPIOE on non-mobility like this 845. But until more examples are found, just make this one device probe.
Diffstat (limited to 'src/i830_dvo.c')
-rw-r--r--src/i830_dvo.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/i830_dvo.c b/src/i830_dvo.c
index 8ba38bdb..e6ff6af6 100644
--- a/src/i830_dvo.c
+++ b/src/i830_dvo.c
@@ -99,9 +99,10 @@ struct _I830DVODriver i830_dvo_drivers[] =
.type = I830_OUTPUT_DVO_LVDS,
.modulename = "ch7017",
.fntablename = "ch7017_methods",
- .dvo_reg = DVOA,
+ .dvo_reg = DVOC,
.address = 0xea,
.symbols = ch7017_symbols,
+ .gpio = GPIOE,
}
};
@@ -430,7 +431,12 @@ i830_dvo_init(ScrnInfoPtr pScrn)
ret_ptr = NULL;
drv->vid_rec = LoaderSymbol(drv->fntablename);
- if (drv->type == I830_OUTPUT_DVO_LVDS)
+ /* Allow the I2C driver info to specify the GPIO to be used in
+ * special cases, but otherwise default to what's defined in the spec.
+ */
+ if (drv->gpio != 0)
+ gpio = drv->gpio;
+ else if (drv->type == I830_OUTPUT_DVO_LVDS)
gpio = GPIOB;
else
gpio = GPIOE;