Re: [PATCH v2] drm/amd/display: use a more accurate check in dm_helpers_dp_read_dpcd()

2023-03-20 Thread Harry Wentland
On 3/10/23 13:42, Hamza Mahfooz wrote: > We should be checking if drm_dp_dpcd_read() returns the size that we are > asking it to read instead of just checking if it is greater than zero. > So, compare the return value of drm_dp_dpcd_read() to the requested > read size. > > Signed-off-by: Hamza

[PATCH v2] drm/amd/display: use a more accurate check in dm_helpers_dp_read_dpcd()

2023-03-10 Thread Hamza Mahfooz
We should be checking if drm_dp_dpcd_read() returns the size that we are asking it to read instead of just checking if it is greater than zero. So, compare the return value of drm_dp_dpcd_read() to the requested read size. Signed-off-by: Hamza Mahfooz --- v2: drop the WARN_ON(). ---