Пример #1
0
int vfs_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat)
{
	int ret;

	if (scribe_resource_prepare())
		return -ENOMEM;

	scribe_lock_inode_read(dentry->d_inode);
	ret = __vfs_getattr(mnt, dentry, stat);
	scribe_unlock(dentry->d_inode);

	return ret;
}
Пример #2
0
int scribe_track_next_file(int flags)
{
	struct scribe_ps *scribe = current->scribe;

	if (!should_handle_resources(scribe))
		return 0;

	if (scribe_resource_prepare())
		return -ENOMEM;

	scribe->lock_next_file = flags;
	scribe->was_file_locking_interrupted = false;
	return 0;
}