[Intel-gfx] [PATCH] i830_driver.c:detect and initialize SDVOB and SDVOC at the same time.
Ma Ling
ling.ma at intel.com
Tue Feb 3 09:10:19 CET 2009
hi All,
SDVO chipset has one i2c pin pare from GMCH, usually port4.
So for sdvo detection we only need to check digital port B (bit 2) of SDVOB.
In another word we should initialize SDVOC port at the same time when SDVOB detection is successful.
The patch is based on our latest code, and intends to match the above logic.
Any comments are welcome !
Thanks
Ma Ling
---
src/i830_driver.c | 22 +++++++++-------------
1 files changed, 9 insertions(+), 13 deletions(-)
diff --git a/src/i830_driver.c b/src/i830_driver.c
index b8d8d37..19c832b 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -914,21 +914,17 @@ I830SetupOutputs(ScrnInfoPtr pScrn)
i830_lvds_init(pScrn);
if (IS_I9XX(pI830)) {
- if ((INREG(SDVOB) & SDVO_DETECTED) || pI830->force_sdvo_detect) {
- Bool found = i830_sdvo_init(pScrn, SDVOB);
+ if ((INREG(SDVOB) & SDVO_DETECTED) || pI830->force_sdvo_detect) {
+ Bool found;
- if (!found && SUPPORTS_INTEGRATED_HDMI(pI830))
- i830_hdmi_init(pScrn, SDVOB);
- }
-
- if ((INREG(SDVOC) & SDVO_DETECTED) || pI830->force_sdvo_detect ||
- /* SDVOC detect bit is reserved on 965G/965GM */
- (IS_I965G(pI830) && !IS_G4X(pI830))) {
- Bool found = i830_sdvo_init(pScrn, SDVOC);
+ found = i830_sdvo_init(pScrn, SDVOB);
+ if (!found && SUPPORTS_INTEGRATED_HDMI(pI830))
+ i830_hdmi_init(pScrn, SDVOB);
- if (!found && SUPPORTS_INTEGRATED_HDMI(pI830))
- i830_hdmi_init(pScrn, SDVOC);
- }
+ found = i830_sdvo_init(pScrn, SDVOC);
+ if (!found && SUPPORTS_INTEGRATED_HDMI(pI830))
+ i830_hdmi_init(pScrn, SDVOC);
+ }
} else {
i830_dvo_init(pScrn);
}
--
1.5.4.4
More information about the Intel-gfx
mailing list