]> Git Repo - linux.git/commitdiff
drm/amd/pm: use attr_update if the attr has it
authorSathishkumar S <[email protected]>
Wed, 26 May 2021 14:45:56 +0000 (20:15 +0530)
committerAlex Deucher <[email protected]>
Wed, 2 Jun 2021 02:36:40 +0000 (22:36 -0400)
use attr_update if its available as part of the attribute.
default_attr_update was used even if attr->attr_update is true.

Signed-off-by: Sathishkumar S <[email protected]>
Reviewed-by: Shashank Sharma <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
drivers/gpu/drm/amd/pm/amdgpu_pm.c

index 13da377888d2c504f5811f73582e8cf7e6444309..f48132bc089df257563fa572f9c5acb83bd08ff0 100644 (file)
@@ -1942,7 +1942,7 @@ static int amdgpu_device_attr_create(struct amdgpu_device *adev,
 
        BUG_ON(!attr);
 
-       attr_update = attr->attr_update ? attr_update : default_attr_update;
+       attr_update = attr->attr_update ? attr->attr_update : default_attr_update;
 
        ret = attr_update(adev, attr, mask, &attr_states);
        if (ret) {
This page took 0.062662 seconds and 4 git commands to generate.