cpuidle: Fix panic in CPU off-lining with no idle driver
authorToshi Kani <toshi.kani@hp.com>
Sun, 1 Apr 2012 03:37:02 +0000 (21:37 -0600)
committerLen Brown <len.brown@intel.com>
Fri, 6 Apr 2012 19:01:25 +0000 (15:01 -0400)
commitee01e663373343c63e0e3d364d09f6155378dbcc
tree22448567769278f9af4f8bff9bfc7653be94885c
parent54f70077768e9aba37d9c5030b43497b6d5084fb
cpuidle: Fix panic in CPU off-lining with no idle driver

Fix a NULL pointer dereference panic in cpuidle_play_dead() during
CPU off-lining when no cpuidle driver is registered.  A cpuidle
driver may be registered at boot-time based on CPU type.  This patch
allows an off-lined CPU to enter HLT-based idle in this condition.

Signed-off-by: Toshi Kani <toshi.kani@hp.com>
Cc: Boris Ostrovsky <boris.ostrovsky@amd.com>
Reviewed-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Tested-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Signed-off-by: Len Brown <len.brown@intel.com>
drivers/cpuidle/cpuidle.c