diff --git a/drivers/gpu/drm/amd/powerplay/amd_powerplay.c b/drivers/gpu/drm/amd/powerplay/amd_powerplay.c index fa9d1615a2cc..4c3223a4d62b 100644 --- a/drivers/gpu/drm/amd/powerplay/amd_powerplay.c +++ b/drivers/gpu/drm/amd/powerplay/amd_powerplay.c @@ -718,6 +718,8 @@ static int pp_dpm_get_pp_num_states(void *handle, struct pp_instance *pp_handle = (struct pp_instance *)handle; int ret = 0; + memset(data, 0, sizeof(*data)); + ret = pp_check(pp_handle); if (ret)