Introduce the VOP_OPENEXTATTR() and VOP_CLOSEEXTATTR() methods.

Together these two implement a simple transcation style grouping for
modifications of extended attributes on a vnode.

VOP_CLOSEEXTATTR() takes a boolean "commit" argument, which determines
if the aggregate changes are attempted written or not.  A commit will
fail if any of the VOP_SETEXTATTR() calls since the VOP_OPENEXTATTR()
have failed to meet their objective or if the flush to disk fails.

The default operations for these two VOP's is to return EOPNOTSUPP.

This API may still be subject to change.

Sponsored by:   DARPA & NAI Labs
This commit is contained in:
phk 2002-09-05 20:56:14 +00:00
parent 3303b3f624
commit aa2987768b

View File

@ -512,6 +512,16 @@ vop_aclcheck {
IN struct thread *td;
};
#
#% closeextattr vp L L L
#
vop_closeextattr {
IN struct vnode *vp;
IN int commit;
IN struct ucred *cred;
IN struct thread *td;
};
#
#% getextattr vp L L L
#
@ -525,6 +535,15 @@ vop_getextattr {
IN struct thread *td;
};
#
#% openextattr vp L L L
#
vop_openextattr {
IN struct vnode *vp;
IN struct ucred *cred;
IN struct thread *td;
};
#
#% setextattr vp L L L
#