On device_busy, the runnable governor stops its sample timer and cancels
any queued runnable_work. However, it is possible for the cpuquiet
platform driver to call device_busy on cpuquiet_quiesence/wake_cpu calls
which can be invoked from the queued runnable_worker thread. This will
lead to the runnable_worker thread waiting infinitely on it self
finishing in cancel_work_sync.
Fix this by removing the cancel_work_sync call as it isn't necessary
because the worker doesn't requeue it self. Stopping the timer is
sufficient.
Bug
200002511
Change-Id: Ic69061b12d4dbb96b259ed9b62a0475271bd36d0
Signed-off-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
Reviewed-on: http://git-master/r/408994
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Kerwin Wan <kerwinw@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
mutex_lock(&runnables_lock);
if (runnables_state == RUNNING) {
runnables_state = IDLE;
- cancel_work_sync(&runnables_work);
del_timer_sync(&runnables_timer);
}
mutex_unlock(&runnables_lock);
runnables_state = DISABLED;
del_timer_sync(&runnables_timer);
- cancel_work_sync(&runnables_work);
kobject_put(runnables_kobject);
kfree(runnables_kobject);