mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-10 12:57:06 +09:00
Merge branch 'pm-cpuidle'
* pm-cpuidle: cpuidle: Check the result of cpuidle_get_driver() against NULL
This commit is contained in:
@@ -331,7 +331,8 @@ struct cpuidle_driver *cpuidle_driver_ref(void)
|
||||
spin_lock(&cpuidle_driver_lock);
|
||||
|
||||
drv = cpuidle_get_driver();
|
||||
drv->refcnt++;
|
||||
if (drv)
|
||||
drv->refcnt++;
|
||||
|
||||
spin_unlock(&cpuidle_driver_lock);
|
||||
return drv;
|
||||
|
||||
Reference in New Issue
Block a user