1
0
mirror of https://git.proxmox.com/git/mirror_zfs.git synced 2025-03-11 22:13:10 +03:00
mirror_zfs/include/spl
ilbsmart 779a6c0bf6 deadlock between mm_sem and tx assign in zfs_write() and page fault
The bug time sequence:
1. thread , `zfs_write` assign a txg "n".
2. In a same process, thread , mmap page fault (which means the
   `mm_sem` is hold) occurred, `zfs_dirty_inode` open a txg failed,
   and wait previous txg "n" completed.
3. thread  call `uiomove` to write, however page fault is occurred
   in `uiomove`, which means it need `mm_sem`, but `mm_sem` is hold by
   thread , so it stuck and can't complete,  then txg "n" will
   not complete.

So thread  and thread  are deadlocked.

Reviewed-by: Chunwei Chen <tuxoko@gmail.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Matthew Ahrens <mahrens@delphix.com>
Signed-off-by: Grady Wong <grady.w@xtaotech.com>
Closes 
2018-10-16 11:11:24 -07:00
..
rpc Update build system and packaging 2018-05-29 16:00:33 -07:00
sys deadlock between mm_sem and tx assign in zfs_write() and page fault 2018-10-16 11:11:24 -07:00
Makefile.am Update build system and packaging 2018-05-29 16:00:33 -07:00