Commit c5d9af3e authored by Rusty Russell's avatar Rusty Russell Committed by Linus Torvalds

[PATCH] Clean up hotplug slab some more

This is a cleaner fix for the previous bogon fix.
parent 3d32d5d0
...@@ -601,7 +601,6 @@ static int __devinit cpuup_callback(struct notifier_block *nfb, ...@@ -601,7 +601,6 @@ static int __devinit cpuup_callback(struct notifier_block *nfb,
{ {
long cpu = (long)hcpu; long cpu = (long)hcpu;
kmem_cache_t* cachep; kmem_cache_t* cachep;
struct list_head *p;
switch (action) { switch (action) {
case CPU_UP_PREPARE: case CPU_UP_PREPARE:
...@@ -634,9 +633,8 @@ static int __devinit cpuup_callback(struct notifier_block *nfb, ...@@ -634,9 +633,8 @@ static int __devinit cpuup_callback(struct notifier_block *nfb,
case CPU_UP_CANCELED: case CPU_UP_CANCELED:
down(&cache_chain_sem); down(&cache_chain_sem);
list_for_each(p, &cache_chain) { list_for_each_entry(cachep, &cache_chain, next) {
struct array_cache *nc; struct array_cache *nc;
kmem_cache_t* cachep = list_entry(p, kmem_cache_t, next);
nc = cachep->array[cpu]; nc = cachep->array[cpu];
cachep->array[cpu] = NULL; cachep->array[cpu] = NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment