freebsd-dev/module
Brian Behlendorf a8ad3bf02c Fix z_xattr_lock/z_teardown_lock lock inversion
There exists a lock inversion between the z_xattr_lock and the
z_teardown_lock.  Detect this case and return EBUSY so zfs_resume_fs()
will mark the inode stale and it can be safely revalidated on next
access.

* process-1
zpl_xattr_get -> Takes zp->z_xattr_lock
  __zpl_xattr_get
    zfs_lookup -> Takes zsb->z_teardown_lock in ZFS_ENTER macro

* process-2
zfs_ioc_recv -> Takes zsb->z_teardown_lock in zfs_suspend_fs()
  zfs_resume_fs
    zfs_rezget -> Takes zp->z_xattr_lock

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Chunwei Chen <david.chen@osnexus.com>
Closes #3969
2015-12-18 13:17:44 -08:00
..
avl Support parallel build trees (VPATH builds) 2015-07-17 13:42:51 -07:00
nvpair Support parallel build trees (VPATH builds) 2015-07-17 13:42:51 -07:00
unicode Support parallel build trees (VPATH builds) 2015-07-17 13:42:51 -07:00
zcommon Fix uio_prefaultpages for 0 length iovec 2015-12-15 16:19:55 -08:00
zfs Fix z_xattr_lock/z_teardown_lock lock inversion 2015-12-18 13:17:44 -08:00
zpios Add large block support to zpios(1) benchmark 2015-09-22 09:13:20 -07:00
.gitignore gitignore: anchor entries at their respective directory 2013-04-02 10:50:17 -07:00
Makefile.in Prevent rm modules.* when make install 2015-12-02 14:39:12 -08:00