Files
linux-nvgpu/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
Deepak Nibade d256b2aa52 gpu: nvgpu: fix mutex leak on fecs_mutex
In gk20a_gr_reset(), we acquire g->gr.fecs_mutex and call a bunch of APIs
But in case any of these APIs fail, we don't release the mutex and just
return the error leaking the mutex

So the next attempt to acquire g->gr.fecs_mutex results in a deadlock

Fix this by releasing the mutex before returning error

Bug 2015370

Change-Id: I9a0214ff53515f819c6566c7d44d1898027416e1
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1589062
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
2017-11-02 05:11:11 -07:00

242 KiB