diff options
author | Brian Behlendorf <[email protected]> | 2014-07-13 14:35:19 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2015-01-16 14:28:05 -0800 |
commit | 92119cc259ee2f9ebde14145f549d6313f557759 (patch) | |
tree | f401b89e39084c21c15049d26951a1e99d4aebef /include/sys | |
parent | d958324f97f4668a2a6e4a6ce3e5ca09b71b31d9 (diff) |
Mark IO pipeline with PF_FSTRANS
In order to avoid deadlocking in the IO pipeline it is critical that
pageout be avoided during direct memory reclaim. This ensures that
the pipeline threads can always make forward progress and never end
up blocking on a DMU transaction. For this very reason Linux now
provides the PF_FSTRANS flag which may be set in the process context.
Signed-off-by: Brian Behlendorf <[email protected]>
Diffstat (limited to 'include/sys')
-rw-r--r-- | include/sys/zfs_context.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/sys/zfs_context.h b/include/sys/zfs_context.h index d4c6fb810..1487a99f4 100644 --- a/include/sys/zfs_context.h +++ b/include/sys/zfs_context.h @@ -733,6 +733,11 @@ void ksiddomain_rele(ksiddomain_t *); (void) nanosleep(&ts, NULL); \ } while (0) -#endif /* _KERNEL */ +typedef int fstrans_cookie_t; + +extern fstrans_cookie_t spl_fstrans_mark(void); +extern void spl_fstrans_unmark(fstrans_cookie_t); +extern int spl_fstrans_check(void); +#endif /* _KERNEL */ #endif /* _SYS_ZFS_CONTEXT_H */ |