]> git.ipfire.org Git - people/arne_f/kernel.git/commit
drm/i915: Do a dummy DPCD read before the actual read
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Thu, 16 Oct 2014 17:46:09 +0000 (20:46 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 14 Nov 2014 18:10:39 +0000 (10:10 -0800)
commit6f5a3f0d46a7a9539b5c2e80f24e1ae4eae9a484
tree095babb03baacfd725ef7e24295876b7993948b0
parent14fee5dab7267bb8063f88f3664fd392156889be
drm/i915: Do a dummy DPCD read before the actual read

commit f6a1906674005377b64ee5431c1418077c1b2425 upstream.

Sometimes we seem to get utter garbage from DPCD reads. The resulting
buffer is filled with the same byte, and the operation completed without
errors. My HP ZR24w monitor seems particularly susceptible to this
problem once it's gone into a sleep mode.

The issue seems to happen only for the first AUX message that wakes the
sink up. But as the first AUX read we often do is the DPCD receiver
cap it does wreak a bit of havoc with subsequent link training etc. when
the receiver cap bw/lane/etc. information is garbage.

A sufficient workaround seems to be to perform a single byte dummy read
before reading the actual data. I suppose that just wakes up the sink
sufficiently and we can just throw away the returned data in case it's
crap. DP_DPCD_REV seems like a sufficiently safe location to read here.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Todd Previte <tprevite@gmail.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/i915/intel_dp.c