Use usleep_range() instead of mdelay() to matche the behavior
of ras_fw_get_badpage_count() in rascore path.

Signed-off-by: Candice Li <[email protected]>
---
 drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_12_ppt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_12_ppt.c 
b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_12_ppt.c
index 7193e3e4946ac6..12b57a0f4fc48f 100644
--- a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_12_ppt.c
+++ b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_12_ppt.c
@@ -1042,7 +1042,7 @@ static int smu_v13_0_12_get_badpage_count(struct 
amdgpu_device *adev, uint32_t *
                /* eeprom is not ready */
                if (ret != -EBUSY)
                        return ret;
-               mdelay(10);
+               usleep_range(10000, 15000);
                now = (uint64_t)ktime_to_ms(ktime_get());
        } while (now < end);
 
-- 
2.25.1

Reply via email to