/* Initialize a lease, use the default lock manager operations  */
static int lease_init(struct file *filp, int type, struct file_lock *fl)
/* Initialize a lease, use the default lock manager operations  */
static int lease_init(struct file *filp, int type, struct file_lock *fl)
{
	if (assign_type(fl, type) != 0)
		return -EINVAL;
	fl->fl_owner = current->files;
	fl->fl_pid = current->tgid;
	fl->fl_file = filp;
	fl->fl_flags = FL_LEASE;
	fl->fl_start = 0;
	fl->fl_end = OFFSET_MAX;
	fl->fl_ops = NULL;
	fl->fl_lmops = &lease_manager_ops;
	return 0;
}