Revert "padata: add separate cpuhp node for CPUHP_PADATA_DEAD"
This reverts commitd6c434ae9dwhich is commit93175d935dupstream. It breaks the Android kernel abi and is not needed in this branch at this point in time. Signed-off-by: Greg Kroah-Hartman <gregkh@google.com> Change-Id: I53f15ad34f2124aa7a4e06dafcdb828666a91278
This commit is contained in:
@@ -138,8 +138,7 @@ struct parallel_data {
|
|||||||
/**
|
/**
|
||||||
* struct padata_instance - The overall control structure.
|
* struct padata_instance - The overall control structure.
|
||||||
*
|
*
|
||||||
* @cpu_online_node: Linkage for CPU online callback.
|
* @cpu_notifier: cpu hotplug notifier.
|
||||||
* @cpu_dead_node: Linkage for CPU offline callback.
|
|
||||||
* @wq: The workqueue in use.
|
* @wq: The workqueue in use.
|
||||||
* @pd: The internal control structure.
|
* @pd: The internal control structure.
|
||||||
* @cpumask: User supplied cpumasks for parallel and serial works.
|
* @cpumask: User supplied cpumasks for parallel and serial works.
|
||||||
@@ -151,8 +150,7 @@ struct parallel_data {
|
|||||||
* @flags: padata flags.
|
* @flags: padata flags.
|
||||||
*/
|
*/
|
||||||
struct padata_instance {
|
struct padata_instance {
|
||||||
struct hlist_node cpu_online_node;
|
struct hlist_node node;
|
||||||
struct hlist_node cpu_dead_node;
|
|
||||||
struct workqueue_struct *wq;
|
struct workqueue_struct *wq;
|
||||||
struct parallel_data *pd;
|
struct parallel_data *pd;
|
||||||
struct padata_cpumask cpumask;
|
struct padata_cpumask cpumask;
|
||||||
|
|||||||
@@ -748,7 +748,7 @@ static int padata_cpu_online(unsigned int cpu, struct hlist_node *node)
|
|||||||
struct padata_instance *pinst;
|
struct padata_instance *pinst;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
pinst = hlist_entry_safe(node, struct padata_instance, cpu_online_node);
|
pinst = hlist_entry_safe(node, struct padata_instance, node);
|
||||||
if (!pinst_has_cpu(pinst, cpu))
|
if (!pinst_has_cpu(pinst, cpu))
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
@@ -763,7 +763,7 @@ static int padata_cpu_dead(unsigned int cpu, struct hlist_node *node)
|
|||||||
struct padata_instance *pinst;
|
struct padata_instance *pinst;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
pinst = hlist_entry_safe(node, struct padata_instance, cpu_dead_node);
|
pinst = hlist_entry_safe(node, struct padata_instance, node);
|
||||||
if (!pinst_has_cpu(pinst, cpu))
|
if (!pinst_has_cpu(pinst, cpu))
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
@@ -779,9 +779,8 @@ static enum cpuhp_state hp_online;
|
|||||||
static void __padata_free(struct padata_instance *pinst)
|
static void __padata_free(struct padata_instance *pinst)
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_HOTPLUG_CPU
|
#ifdef CONFIG_HOTPLUG_CPU
|
||||||
cpuhp_state_remove_instance_nocalls(CPUHP_PADATA_DEAD,
|
cpuhp_state_remove_instance_nocalls(CPUHP_PADATA_DEAD, &pinst->node);
|
||||||
&pinst->cpu_dead_node);
|
cpuhp_state_remove_instance_nocalls(hp_online, &pinst->node);
|
||||||
cpuhp_state_remove_instance_nocalls(hp_online, &pinst->cpu_online_node);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
padata_stop(pinst);
|
padata_stop(pinst);
|
||||||
@@ -965,10 +964,9 @@ static struct padata_instance *padata_alloc(struct workqueue_struct *wq,
|
|||||||
mutex_init(&pinst->lock);
|
mutex_init(&pinst->lock);
|
||||||
|
|
||||||
#ifdef CONFIG_HOTPLUG_CPU
|
#ifdef CONFIG_HOTPLUG_CPU
|
||||||
cpuhp_state_add_instance_nocalls_cpuslocked(hp_online,
|
cpuhp_state_add_instance_nocalls_cpuslocked(hp_online, &pinst->node);
|
||||||
&pinst->cpu_online_node);
|
|
||||||
cpuhp_state_add_instance_nocalls_cpuslocked(CPUHP_PADATA_DEAD,
|
cpuhp_state_add_instance_nocalls_cpuslocked(CPUHP_PADATA_DEAD,
|
||||||
&pinst->cpu_dead_node);
|
&pinst->node);
|
||||||
#endif
|
#endif
|
||||||
return pinst;
|
return pinst;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user