mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-02 18:04:38 -04:00
drm/amdgpu/swsmu/vangogh: return error if fetching metrics fails
rather than just dropping the error. Also fixes a set but not used variable warning. Reviewed-by: Evan Quan <evan.quan@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
@@ -410,6 +410,8 @@ static int vangogh_get_current_activity_percent(struct smu_context *smu,
|
||||
ret = vangogh_get_smu_metrics_data(smu,
|
||||
METRICS_AVERAGE_GFXACTIVITY,
|
||||
value);
|
||||
if (ret)
|
||||
return ret;
|
||||
break;
|
||||
default:
|
||||
dev_err(smu->adev->dev, "Invalid sensor for retrieving clock activity\n");
|
||||
|
||||
Reference in New Issue
Block a user