Skip to content
Snippets Groups Projects
Commit fb92b63f authored by alex's avatar alex
Browse files

changes to protect directory splitting from concurrent modifies/lookups:

 - mds_fid2locked_dentry() takes UPDATE lock on the inode. depending on the
   given mode for LOOKUP lock new routine mds_lock_mode_for_dir() learns
   what mode to use for UPDATE lock. it could be:
   - LCK_CR - lookup case. it protects directory from concurrent splitting
     and don't invalidate client cache readdir()
   - LCK_CW - modify case. it protects directory from concurrent splitting
     and invalidate client cache for readdir()
   - LCK_EX - modify with possible splitting. protects from any parallel access

 - mds_getattr_name(), mds_open(), mds_reint_setattr(), mds_reint_create(),
   mds_get_parent_child_locked(), mds_reint_unlink(), mds_reint_rename() and
   mds_get_parents_children_lock() have been modified to play new game with
   directory locking

 - mds_splitting_expected() predicts splitting possibility
parent c95a0148
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment