Skip to content

Commit

Permalink
drm/amd/display: Retry AUX write when fail occurs
Browse files Browse the repository at this point in the history
[Why]
In dm_dp_aux_transfer() now, we forget to handle AUX_WR fail cases. We
suppose every write wil get done successfully and hence some AUX
commands might not sent out indeed.

[How]
Check if AUX_WR success. If not, retry it.

Signed-off-by: Wayne Lin <Wayne.Lin@amd.com>
Reviewed-by: Hersen Wu <hersenxs.wu@amd.com>
Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
  • Loading branch information
Wayne Lin authored and alexdeucher committed Aug 26, 2020
1 parent b5b97ca commit ef67d79
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ static ssize_t dm_dp_aux_transfer(struct drm_dp_aux *aux,
result = dc_link_aux_transfer_raw(TO_DM_AUX(aux)->ddc_service, &payload,
&operation_result);

if (payload.write)
if (payload.write && result >= 0)
result = msg->size;

if (result < 0)
Expand Down

0 comments on commit ef67d79

Please sign in to comment.