cpufreq: Split __cpufreq_remove_dev() into two parts
authorSrivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Fri, 6 Sep 2013 19:53:09 +0000 (01:23 +0530)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 10 Sep 2013 00:49:46 +0000 (02:49 +0200)
commitcedb70afd077b00bff7379042fdbf7eef32606c9
tree6524564121d1f57d5a6891da9f0776ea3d048e19
parenta857c0b9e24e39fe5be82451b65377795f9538d8
cpufreq: Split __cpufreq_remove_dev() into two parts

During CPU offline, the cpufreq core invokes __cpufreq_remove_dev()
to perform work such as stopping the cpufreq governor, clearing the
CPU from the policy structure etc, and finally cleaning up the
kobject.

There are certain subtle issues related to the kobject cleanup, and
it would be much easier to deal with them if we separate that part
from the rest of the cleanup-work in the CPU offline phase. So split
the __cpufreq_remove_dev() function into 2 parts: one that handles
the kobject cleanup, and the other that handles the rest of the work.

Reported-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/cpufreq/cpufreq.c