mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-11-18 02:20:59 +03:00
26f7245c7c
When TQ_SLEEP is used, taskq_dispatch() should always succeed even if the number of pending tasks is above tq->tq_maxalloc. This semantic is similar to KM_SLEEP in kmem allocations, which also always succeed. However, we cannot block forever otherwise there is a risk of deadlock. Therefore, we still allow the number of pending tasks to go above tq->tq_maxalloc with TQ_SLEEP, but we may sleep up to 1 second per task dispatch, thereby throttling the task dispatch rate. One of the existing splat tests was also augmented to test for this scenario. The test would fail with the previous implementation but now it succeeds. Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> |
||
---|---|---|
.. | ||
.gitignore | ||
Makefile.in | ||
splat-atomic.c | ||
splat-condvar.c | ||
splat-cred.c | ||
splat-ctl.c | ||
splat-generic.c | ||
splat-internal.h | ||
splat-kmem.c | ||
splat-kobj.c | ||
splat-list.c | ||
splat-mutex.c | ||
splat-random.c | ||
splat-rwlock.c | ||
splat-taskq.c | ||
splat-thread.c | ||
splat-time.c | ||
splat-vnode.c |