drm/i915: Reset GMBUS controller after NAK
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 30 Mar 2011 15:20:43 +0000 (16:20 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 31 Mar 2011 08:37:01 +0000 (09:37 +0100)
commit7f58aabc369014fda3a4a33604ba0a1b63b941ac
treeaeb82491f30b9565752d97a26b2292963c895185
parent9f01b25048ad12b5d71f4f7d3b62ef737639a08d
drm/i915: Reset GMBUS controller after NAK

Once a NAK has been asserted by the slave, we need to reset the GMBUS
controller in order to continue. This is done by asserting the Software
Clear Interrupt bit and then clearing it again to restore operations.

If we don't clear the NAK, then all future GMBUS xfers will fail,
including DDC probes and EDID retrieval.

v2: Add some comments as suggested by Keith Packard.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=35781
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Keith Packard <keithp@keithp.com>
Tested-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Tested-by: "Mengmeng Meng" <mengmeng.meng@intel.com>
drivers/gpu/drm/i915/intel_i2c.c