@@ -202,9 +202,11 @@ static int drm_dp_dpcd_access(struct drm_dp_aux *aux, u8 request,
if (err == -EAGAIN)
continue;
- /* FIXME: On BUSY we could wait before retrying */
- if (err == -EBUSY)
+ /* Give a time for aux channels to recover */
+ if (err == -EBUSY) {
+ usleep_range(1000, 1000);
continue;
+ }
return err;
}
@@ -557,8 +559,10 @@ static int drm_dp_i2c_do_msg(struct drm_dp_aux *aux, struct drm_dp_aux_msg *msg)
* -EAGAIN retries are handled by i2c layer with
* timeouts for repeated -EAGAINs
*/
- if (ret == -EBUSY)
+ if (ret == -EBUSY) {
+ usleep_range(1000, 1000);
continue;
+ }
DRM_DEBUG_KMS("transaction failed: %d\n", ret);
return ret;
@@ -757,7 +757,8 @@ struct drm_dp_aux {
* - -EPROTO: On a short, helpers will return -EPROTO to make it simpler
* to check for failure.
* - -EBUSY: When BUSY helpers will attempt retries before propagating
- * this error.
+ * this error, with 1ms between attempts to give a time for downstream
+ * devices to recover.
* - -EAGAIN: DPCD helper will attempt immediatelly retries before
* propagating this error. i2c helper will only propagate directly
* since i2c layer already perform retries with timeouts for repeated