]> git.karo-electronics.de Git - linux-beck.git/commitdiff
staging: lustre: obdecho: constify lu_device_operations and cl_device_operations...
authorJulia Lawall <Julia.Lawall@lip6.fr>
Fri, 1 Jan 2016 08:37:03 +0000 (09:37 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 3 Feb 2016 22:22:53 +0000 (14:22 -0800)
These lu_device_operations and cl_device_operations structures are never
modified, so declare them as const.  Other structures of these types are
already const.

Done with the help of Coccinelle.

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/obdecho/echo_client.c

index 7b53f7dd1797c4c6013f0270cb8e407c28d51cfe..f32f1e72d5696661a1cfed14181864a814046acf 100644 (file)
@@ -582,13 +582,13 @@ static struct lu_object *echo_object_alloc(const struct lu_env *env,
        return obj;
 }
 
-static struct lu_device_operations echo_device_lu_ops = {
+static const struct lu_device_operations echo_device_lu_ops = {
        .ldo_object_alloc   = echo_object_alloc,
 };
 
 /** @} echo_lu_dev_ops */
 
-static struct cl_device_operations echo_device_cl_ops = {
+static const struct cl_device_operations echo_device_cl_ops = {
 };
 
 /** \defgroup echo_init Setup and teardown