diff --git a/drivers/gpu/msm/kgsl_pwrctrl.c b/drivers/gpu/msm/kgsl_pwrctrl.c index 3a2345e7c50..046bbbbae73 100644 --- a/drivers/gpu/msm/kgsl_pwrctrl.c +++ b/drivers/gpu/msm/kgsl_pwrctrl.c @@ -1505,7 +1505,8 @@ int kgsl_active_count_get(struct kgsl_device *device) int ret = 0; BUG_ON(!mutex_is_locked(&device->mutex)); - if (device->active_cnt == 0) { + if (device->active_cnt == 0 && + device->state != KGSL_STATE_ACTIVE) { mutex_unlock(&device->mutex); wait_for_completion(&device->hwaccess_gate); wait_for_completion(&device->ft_gate);