drm/amd/display: Read all the trace entry if it is not empty
authorYongqiang Sun <yongqiang.sun@amd.com>
Tue, 23 Feb 2021 20:16:44 +0000 (15:16 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 24 Mar 2021 03:02:38 +0000 (23:02 -0400)
commit3c934f454dae53c56a983226516acb014244a8d0
treeeecd268c08f3804c84e567ffc6f309c7e3ae4cf0
parent0c66824be8f459f3f7010bb90c236d3142006e37
drm/amd/display: Read all the trace entry if it is not empty

[Why]
If interval of two interrupt from dmub outbox0 is too short,
some event might be skipped

[How]
Compare read pointer and write pointer until all the event
entry is processed

Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Yongqiang Sun <yongqiang.sun@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Eryk Brol <eryk.brol@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c