]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Use a dedicated taskq for vdev_file
authorChunwei Chen <tuxoko@gmail.com>
Tue, 13 May 2014 02:36:35 +0000 (10:36 +0800)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Wed, 14 May 2014 23:20:21 +0000 (16:20 -0700)
commitbc25c9325b0e5ced897b9820dad239539d561ec9
treedd7a9bf76d0f0aa232ce2eaaa61c083a5238edc9
parent2c33b9127569ad62b4cfe7dd4f651ceeee3d005c
Use a dedicated taskq for vdev_file

Originally, vdev_file used system_taskq. This would cause a deadlock,
especially on system with few CPUs. The reason is that the prefetcher
threads, which are on system_taskq, will sometimes be blocked waiting
for I/O to finish. If the prefetcher threads consume all the tasks in
system_taskq, the I/O cannot be served and thus results in a deadlock.

We fix this by creating a dedicated vdev_file_taskq for vdev_file I/O.

Signed-off-by: Chunwei Chen <tuxoko@gmail.com>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #2270
include/sys/vdev_file.h
module/zfs/spa_misc.c
module/zfs/vdev_file.c