Commit 495ea0d9 authored by Julia Lawall's avatar Julia Lawall Committed by Greg Kroah-Hartman

staging: lustre: obdclass: constify obd_psdev_fops structure

obd_psdev_fops, of type struct file_operations, 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 avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d6a80699
...@@ -192,7 +192,7 @@ static long obd_class_ioctl(struct file *filp, unsigned int cmd, ...@@ -192,7 +192,7 @@ static long obd_class_ioctl(struct file *filp, unsigned int cmd,
} }
/* declare character device */ /* declare character device */
static struct file_operations obd_psdev_fops = { static const struct file_operations obd_psdev_fops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.unlocked_ioctl = obd_class_ioctl, /* unlocked_ioctl */ .unlocked_ioctl = obd_class_ioctl, /* unlocked_ioctl */
.open = obd_class_open, /* open */ .open = obd_class_open, /* open */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment