[PATCH 0/4] blk-mq: fix race conditions on cpu hotplug handling

From: Akinobu Mita
Date: Sun Jun 21 2015 - 09:53:03 EST


This patchset addresses several race conditions on cpu hotplug handling
for blk-mq. All problems are reproducible by the following script.

while true; do
echo 0 > /sys/devices/system/cpu/cpu1/online
echo 1 > /sys/devices/system/cpu/cpu1/online
done &

while true; do
modprobe -r null_blk
modprobe null_blk queue_mode=2 irqmode=1
sleep 0.1
done

Akinobu Mita (4):
blk-mq: fix sysfs registration/unregistration race
blk-mq: fix q->mq_map access race
blk-mq: establish new mapping before cpu starts handling requests
blk-mq: fix mq_usage_counter race when switching to percpu mode

block/blk-mq-cpumap.c | 9 ++++----
block/blk-mq-sysfs.c | 21 +++++++++++++++++--
block/blk-mq.c | 56 +++++++++++++++++++++++++++++++++-----------------
block/blk-mq.h | 3 ++-
include/linux/blk-mq.h | 1 +
include/linux/blkdev.h | 6 ++++++
6 files changed, 70 insertions(+), 26 deletions(-)

--
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
Please read the FAQ at http://www.tux.org/lkml/