diff options
author | 2013-07-04 09:59:07 +0000 | |
---|---|---|
committer | 2013-07-04 09:59:07 +0000 | |
commit | d8733f60086cf1c2691ba6e3e2342edfdb04a459 (patch) | |
tree | 6b9b27d5ca26e8cce51d89b7f76d260bbc7d5092 | |
parent | Fixup Oops in the pipe config computation (diff) | |
download | wireguard-openbsd-d8733f60086cf1c2691ba6e3e2342edfdb04a459.tar.xz wireguard-openbsd-d8733f60086cf1c2691ba6e3e2342edfdb04a459.zip |
Fall back to bit banging mode for DVO transmitter detection
from linux 3.8.13
-rw-r--r-- | sys/dev/pci/drm/i915/intel_dvo.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/sys/dev/pci/drm/i915/intel_dvo.c b/sys/dev/pci/drm/i915/intel_dvo.c index 1121144beb4..7d3d9431513 100644 --- a/sys/dev/pci/drm/i915/intel_dvo.c +++ b/sys/dev/pci/drm/i915/intel_dvo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: intel_dvo.c,v 1.1 2013/03/18 12:36:52 jsg Exp $ */ +/* $OpenBSD: intel_dvo.c,v 1.2 2013/07/04 09:59:07 jsg Exp $ */ /* * Copyright 2006 Dave Airlie <airlied@linux.ie> * Copyright © 2006-2007 Intel Corporation @@ -483,6 +483,7 @@ intel_dvo_init(struct drm_device *dev) const struct intel_dvo_device *dvo = &intel_dvo_devices[i]; struct i2c_controller *i2c; int gpio; + bool dvoinit; /* Allow the I2C driver info to specify the GPIO to be used in * special cases, but otherwise default to what's defined @@ -502,7 +503,17 @@ intel_dvo_init(struct drm_device *dev) i2c = intel_gmbus_get_adapter(dev_priv, gpio); intel_dvo->dev = *dvo; - if (!dvo->dev_ops->init(&intel_dvo->dev, i2c)) + + /* GMBUS NAK handling seems to be unstable, hence let the + * transmitter detection run in bit banging mode for now. + */ + intel_gmbus_force_bit(i2c, true); + + dvoinit = dvo->dev_ops->init(&intel_dvo->dev, i2c); + + intel_gmbus_force_bit(i2c, false); + + if (!dvoinit) continue; intel_encoder->type = INTEL_OUTPUT_DVO; |