diff options
author | Luiz Fernando N. Capitulino <lcapitulino@mandriva.com.br> | 2006-08-05 19:37:11 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-09-27 14:58:52 -0400 |
commit | 066202dd48cf3296b6cc22b5fcf89aef33fa0efc (patch) | |
tree | 1730104f5b1634e0dca42c5ea7a331fb1c773813 /drivers/usb/host/uhci-debug.c | |
parent | f2ebf92c9e1930a8f79b7eb49a32122931929014 (diff) |
USB: Make file operations structs in drivers/usb const.
Making structs const prevents accidental bugs and with the proper debug
options they're protected against corruption.
Signed-off-by: Luiz Fernando N. Capitulino <lcapitulino@mandriva.com.br>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/uhci-debug.c')
-rw-r--r-- | drivers/usb/host/uhci-debug.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/host/uhci-debug.c b/drivers/usb/host/uhci-debug.c index d1372cb27f33..e345f15b7d87 100644 --- a/drivers/usb/host/uhci-debug.c +++ b/drivers/usb/host/uhci-debug.c | |||
@@ -16,7 +16,7 @@ | |||
16 | 16 | ||
17 | #include "uhci-hcd.h" | 17 | #include "uhci-hcd.h" |
18 | 18 | ||
19 | #define uhci_debug_operations (* (struct file_operations *) NULL) | 19 | #define uhci_debug_operations (* (const struct file_operations *) NULL) |
20 | static struct dentry *uhci_debugfs_root; | 20 | static struct dentry *uhci_debugfs_root; |
21 | 21 | ||
22 | #ifdef DEBUG | 22 | #ifdef DEBUG |
@@ -500,7 +500,7 @@ static int uhci_debug_release(struct inode *inode, struct file *file) | |||
500 | } | 500 | } |
501 | 501 | ||
502 | #undef uhci_debug_operations | 502 | #undef uhci_debug_operations |
503 | static struct file_operations uhci_debug_operations = { | 503 | static const struct file_operations uhci_debug_operations = { |
504 | .owner = THIS_MODULE, | 504 | .owner = THIS_MODULE, |
505 | .open = uhci_debug_open, | 505 | .open = uhci_debug_open, |
506 | .llseek = uhci_debug_lseek, | 506 | .llseek = uhci_debug_lseek, |