Call d_instantiate before unlocking inode

Under Linux a dentry referencing an inode must be instantiated before
the inode is unlocked.  To accomplish this without overly modifing
the core ZFS code the dentry it passed via the vattr_t.  There are
cases such as replay when a dentry is not available.  In which case
it is obviously not initialized at inode creation time, if a dentry
is needed it will be spliced as when required via d_lookup().
This commit is contained in:
Brian Behlendorf
2011-03-29 23:04:39 -07:00
parent d433c20651
commit c85b224faf
3 changed files with 12 additions and 27 deletions
-4
View File
@@ -774,10 +774,6 @@ zfs_link_create(zfs_dirlock_t *dl, znode_t *zp, dmu_tx_t *tx, int flag)
8, 1, &value, tx);
ASSERT(error == 0);
#ifdef HAVE_DNLC
dnlc_update(ZTOI(dzp), dl->dl_name, vp);
#endif /* HAVE_DNLC */
return (0);
}