Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2a297450 authored by Julia Lawall's avatar Julia Lawall Committed by J. Bruce Fields
Browse files

lockd: constify nlmsvc_binding structure



The nlmsvc_binding structure is never modified, so declare it as const.

Done with the help of Coccinelle.

Signed-off-by: default avatarJulia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
parent ea44463f
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -48,7 +48,7 @@


static struct svc_program	nlmsvc_program;
static struct svc_program	nlmsvc_program;


struct nlmsvc_binding *		nlmsvc_ops;
const struct nlmsvc_binding	*nlmsvc_ops;
EXPORT_SYMBOL_GPL(nlmsvc_ops);
EXPORT_SYMBOL_GPL(nlmsvc_ops);


static DEFINE_MUTEX(nlmsvc_mutex);
static DEFINE_MUTEX(nlmsvc_mutex);
+1 −1
Original line number Original line Diff line number Diff line
@@ -58,7 +58,7 @@ nlm_fclose(struct file *filp)
	fput(filp);
	fput(filp);
}
}


static struct nlmsvc_binding	nfsd_nlm_ops = {
static const struct nlmsvc_binding nfsd_nlm_ops = {
	.fopen		= nlm_fopen,		/* open file for locking */
	.fopen		= nlm_fopen,		/* open file for locking */
	.fclose		= nlm_fclose,		/* close file */
	.fclose		= nlm_fclose,		/* close file */
};
};
+1 −1
Original line number Original line Diff line number Diff line
@@ -29,7 +29,7 @@ struct nlmsvc_binding {
	void			(*fclose)(struct file *);
	void			(*fclose)(struct file *);
};
};


extern struct nlmsvc_binding *	nlmsvc_ops;
extern const struct nlmsvc_binding *nlmsvc_ops;


/*
/*
 * Similar to nfs_client_initdata, but without the NFS-specific
 * Similar to nfs_client_initdata, but without the NFS-specific