From c237e930615f1b048895efe988d28503f5d67c37 Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Thu, 21 Dec 2006 23:30:37 -0800 Subject: [PATCH] Use Vesa DDC timeouts for all I2C busses. The default I2C timeouts are very short, and while most modern monitors have no trouble responding at that rate, some older ones cannot manage. --- src/i830_i2c.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/i830_i2c.c b/src/i830_i2c.c index 8fd12ea9..450f9de0 100644 --- a/src/i830_i2c.c +++ b/src/i830_i2c.c @@ -365,6 +365,14 @@ I830I2CInit(ScrnInfoPtr pScrn, I2CBusPtr *bus_ptr, int i2c_reg, char *name) #endif pI2CBus->DriverPrivate.uval = i2c_reg; + /* Assume all busses are used for DDCish stuff */ + + pI2CBus->ByteTimeout = 2200; /* VESA DDC spec 3 p. 43 (+10 %) */ + pI2CBus->StartTimeout = 550; + pI2CBus->BitTimeout = 40; + pI2CBus->ByteTimeout = 40; + pI2CBus->AcknTimeout = 40; + if (!xf86I2CBusInit(pI2CBus)) return FALSE;