Re: [PATCH] drm/amdgpu: Check if smu.ppt_funcs is initialized before accessing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>>> -       if (adev->smu.ppt_funcs->get_current_power_state)
>>> +       if (adev->smu.ppt_funcs && adev->smu.ppt_funcs-
>>> get_current_power_state)
>>
>> For consistency, I think we probably want something like:
>> if (is_support_sw_smu(adev) && adev->smu.ppt_funcs-
>>> get_current_power_state)
>>
>> Either way:
>> Reviewed-by: Alex Deucher <alexander.deucher@xxxxxxx>
> 
> Yes. The same comment with me. Please use is_support_sw_smu() to check it.
> With that fixed, please add Reviewed-by: Huang Rui <ray.huang@xxxxxxx>
> 

Will modify and merge.

Thanks,
Leo

>>
>>>                  pm = amdgpu_smu_get_current_power_state(adev);
>>>          else if (adev->powerplay.pp_funcs->get_current_power_state)
>>>                  pm = amdgpu_dpm_get_current_power_state(adev);
>>> --
>>> 2.7.4
>>>
>>> _______________________________________________
>>> amd-gfx mailing list
>>> amd-gfx@xxxxxxxxxxxxxxxxxxxxx
>>> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
>> _______________________________________________
>> amd-gfx mailing list
>> amd-gfx@xxxxxxxxxxxxxxxxxxxxx
>> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/amd-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux