]> www.infradead.org Git - users/jedix/linux-maple.git/commit
intel_idle: Don't overreact to a cpuidle registration failure.
authorRichard Cochran <rcochran@linutronix.de>
Wed, 6 Apr 2016 21:00:55 +0000 (17:00 -0400)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 3 Nov 2016 17:25:51 +0000 (10:25 -0700)
commitd11fa43bb716482c176a44d256d1896e2ed3b4ce
tree2fa70d24c9a68829d4c208f897348bb012b6f64c
parenteb2356e896f2ba46bc7dc48a17a357f0cafd860d
intel_idle: Don't overreact to a cpuidle registration failure.

Orabug: 24810432

The helper function, intel_idle_cpu_init, registers one new device
with the cpuidle layer.  If the registration should fail, that
function immediately calls intel_idle_cpuidle_devices_uninit() to
unregister every last CPU's device.  However, it makes no sense to do
so, when called from the hot plug notifier callback.

This patch moves the call to intel_idle_cpuidle_devices_uninit()
outside of the helper function to the one call site that actually
needs to perform the de-registrations.

Signed-off-by: Richard Cochran <rcochran@linutronix.de>
Signed-off-by: Len Brown <len.brown@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
(cherry picked from commit b69ef2c099c3e5f11bd5c33a9530d6522f72c9aa)
Signed-off-by: Brian Maly <brian.maly@oracle.com>
drivers/idle/intel_idle.c