public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [patch 0/9] CPU hotplug error handling fixes take2
@ 2007-07-22 15:33 Akinobu Mita
  2007-07-22 15:33 ` [patch 1/9] slab: cleanup cpuup_callback() Akinobu Mita
                   ` (8 more replies)
  0 siblings, 9 replies; 13+ messages in thread
From: Akinobu Mita @ 2007-07-22 15:33 UTC (permalink / raw)
  To: linux-kernel

This series of patches fixes the error handling for cpu hotplug.
The problem is revealed by CPU hotplug/unplug test with fault-injection.

The changes from previous patchset:

- Removed the patch titled sysfs: avoid kmem_cache_free(NULL)
  Because it was merged into mainline.

- Removed the patch titled sysdev: add error check in sysdev_register()
  It turned out that the patch needs more fixes for microcode and
  cpufreq. So I'll separate them from this series of patches.

- Added slab fix noticed by Gautham R Shenoy

The series of patches:

[patch 1/9] slab: cleanup cpuup_callback()
[patch 2/9] slab: fix memory leak in cpu hotplug error path
[patch 3/9] cpu: deliver CPU_UP_CANCELED only to NOTIFY_OKed callbacks
            with CPU_UP_PREPARE
[patch 4/9] topology: remove topology_dev_map
[patch 5/9] thermal_throttle: fix cpu hotplug error handling
[patch 6/9] msr: fix cpu hotplug error handling
[patch 7/9] cpuid: fix cpu hotplug error handling
[patch 8/9] mce: fix cpu hotplug error handling
[patch 9/9] intel_cacheinfo: fix cpu hotplug error handling

The patch 1/9 factors out some code from cpuup_callback() to simplify
what the patch 2/9 does.

The patch 2/9 fixes memory leak in allocation failure path. Also it
avoids the memory leak that will be introduced by the patch 3/9.

The patch 3/9 changes the behavior when one of the callbacks in notifier
chain returns NOTIFY_BAD with CPU_UP_PREPARE event. This change makes
cpu hotplug error handling simple.

The patch 4/9 simplifies the cpu hotplug event handling in topology.c
enabled by the patch 3/9.

The patch 5-9/9 are cpu hotplug error handling fixes in drivers.
Mainly these patches shift some callbacks from CPU_ONLINE to CPU_UP_PREPARE.

CPU hotplug/unplug test script:

----------[ cut here ]----------

#!/bin/bash

FAILTYPE=failslab
CPU=1
CPU_ONLINE=/sys/devices/system/cpu/cpu${CPU}/online

faulty_system()
{
	bash -c "echo 1 > /proc/self/make-it-fail && exec $*"
}

[ "$UID" == 0 ] || exit 1
[ -n "$FAILTYPE" -a -f /debug/$FAILTYPE/probability ] || exit 1
[ -f $CPU_ONLINE ] || exit 1

echo N > /debug/$FAILTYPE/ignore-gfp-wait
echo Y > /debug/$FAILTYPE/task-filter
echo 1 > /debug/$FAILTYPE/probability
echo -1 > /debug/$FAILTYPE/times

while true
do
	faulty_system "echo 0 > $CPU_ONLINE"
	faulty_system "echo 1 > $CPU_ONLINE"
done

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2007-07-24  9:46 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-22 15:33 [patch 0/9] CPU hotplug error handling fixes take2 Akinobu Mita
2007-07-22 15:33 ` [patch 1/9] slab: cleanup cpuup_callback() Akinobu Mita
2007-07-22 15:33 ` [patch 2/9] slab: fix memory leak in cpu hotplug error path Akinobu Mita
2007-07-24  9:46   ` Pekka Enberg
2007-07-22 15:33 ` [patch 3/9] cpu: deliver CPU_UP_CANCELED only to NOTIFY_OKed callbacks with CPU_UP_PREPARE Akinobu Mita
2007-07-22 23:48   ` Rusty Russell
2007-07-22 15:33 ` [patch 4/9] topology: remove topology_dev_map Akinobu Mita
2007-07-23 23:16   ` Greg KH
2007-07-22 15:33 ` [patch 5/9] thermal_throttle: fix cpu hotplug error handling Akinobu Mita
2007-07-22 15:33 ` [patch 6/9] msr: " Akinobu Mita
2007-07-22 15:33 ` [patch 7/9] cpuid: " Akinobu Mita
2007-07-22 15:33 ` [patch 8/9] mce: " Akinobu Mita
2007-07-22 15:33 ` [patch 9/9] intel_cacheinfo: " Akinobu Mita

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox