mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
Add TASKQ_NORECLAIM flag
It has become necessary to be able to optionally disable direct memory reclaim for certain taskqs. To support this the TASKQ_NORECLAIM flags has been added which sets the PF_MEMALLOC bit for all threads in the taskq.
This commit is contained in:
@@ -371,6 +371,10 @@ taskq_thread(void *args)
|
||||
ASSERT(tq);
|
||||
current->flags |= PF_NOFREEZE;
|
||||
|
||||
/* Disable the direct memory reclaim path */
|
||||
if (tq->tq_flags & TASKQ_NORECLAIM)
|
||||
current->flags |= PF_MEMALLOC;
|
||||
|
||||
sigfillset(&blocked);
|
||||
sigprocmask(SIG_BLOCK, &blocked, NULL);
|
||||
flush_signals(current);
|
||||
|
||||
Reference in New Issue
Block a user