On 10/18/24 13:02, Dmitry Baryshkov wrote:
On Fri, Oct 18, 2024 at 12:18:11PM +0100, Lukasz Luba wrote:
There is a need to check the returned value of the registration function.
Why?
The question can be:
why this driver doesn't check errors from frameworks during the
registration?
Is it a generic practice in that code (I hope not)?
When you check the API doc you will see that this fwk can fail and
return some error and the other functions in driver shouldn't
assume blindly that it was OK.
All other places in the kernel check that return value from
the PM QoS framework.
In case of returned error, print that and stop the init process.
Fixes: 7c0ffcd40b16 ("drm/msm/gpu: Respect PM QoS constraints")
Signed-off-by: Lukasz Luba <lukasz.luba@xxxxxxx>
---
drivers/gpu/drm/msm/msm_gpu_devfreq.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)