diff options
Diffstat (limited to 'drivers/cpuidle/cpuidle.c')
-rw-r--r-- | drivers/cpuidle/cpuidle.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/cpuidle/cpuidle.c b/drivers/cpuidle/cpuidle.c index e28f6ea46f1a..7f15b8514a18 100644 --- a/drivers/cpuidle/cpuidle.c +++ b/drivers/cpuidle/cpuidle.c | |||
@@ -368,7 +368,7 @@ EXPORT_SYMBOL_GPL(cpuidle_enable_device); | |||
368 | */ | 368 | */ |
369 | void cpuidle_disable_device(struct cpuidle_device *dev) | 369 | void cpuidle_disable_device(struct cpuidle_device *dev) |
370 | { | 370 | { |
371 | if (!dev->enabled) | 371 | if (!dev || !dev->enabled) |
372 | return; | 372 | return; |
373 | if (!cpuidle_get_driver() || !cpuidle_curr_governor) | 373 | if (!cpuidle_get_driver() || !cpuidle_curr_governor) |
374 | return; | 374 | return; |