Commit b87221de6a4934eda856475a0065688d12973a04

Authored by Alexey Dobriyan
Committed by Linus Torvalds
1 parent 0d54b217a2

const: mark remaining super_operations const

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 18 changed files with 23 additions and 24 deletions Side-by-side Diff

arch/powerpc/platforms/cell/spufs/inode.c
... ... @@ -773,7 +773,7 @@
773 773 spufs_fill_super(struct super_block *sb, void *data, int silent)
774 774 {
775 775 struct spufs_sb_info *info;
776   - static struct super_operations s_ops = {
  776 + static const struct super_operations s_ops = {
777 777 .alloc_inode = spufs_alloc_inode,
778 778 .destroy_inode = spufs_destroy_inode,
779 779 .statfs = simple_statfs,
arch/s390/hypfs/inode.c
... ... @@ -41,7 +41,7 @@
41 41  
42 42 static const struct file_operations hypfs_file_ops;
43 43 static struct file_system_type hypfs_type;
44   -static struct super_operations hypfs_s_ops;
  44 +static const struct super_operations hypfs_s_ops;
45 45  
46 46 /* start of list of all dentries, which have to be deleted on update */
47 47 static struct dentry *hypfs_last_dentry;
... ... @@ -472,7 +472,7 @@
472 472 .kill_sb = hypfs_kill_super
473 473 };
474 474  
475   -static struct super_operations hypfs_s_ops = {
  475 +static const struct super_operations hypfs_s_ops = {
476 476 .statfs = simple_statfs,
477 477 .drop_inode = hypfs_drop_inode,
478 478 .show_options = hypfs_show_options,
drivers/isdn/capi/capifs.c
... ... @@ -89,7 +89,7 @@
89 89 return 0;
90 90 }
91 91  
92   -static struct super_operations capifs_sops =
  92 +static const struct super_operations capifs_sops =
93 93 {
94 94 .statfs = simple_statfs,
95 95 .remount_fs = capifs_remount,
drivers/misc/ibmasm/ibmasmfs.c
... ... @@ -97,7 +97,7 @@
97 97 return get_sb_single(fst, flags, data, ibmasmfs_fill_super, mnt);
98 98 }
99 99  
100   -static struct super_operations ibmasmfs_s_ops = {
  100 +static const struct super_operations ibmasmfs_s_ops = {
101 101 .statfs = simple_statfs,
102 102 .drop_inode = generic_delete_inode,
103 103 };
drivers/oprofile/oprofilefs.c
... ... @@ -35,7 +35,7 @@
35 35 }
36 36  
37 37  
38   -static struct super_operations s_ops = {
  38 +static const struct super_operations s_ops = {
39 39 .statfs = simple_statfs,
40 40 .drop_inode = generic_delete_inode,
41 41 };
drivers/usb/core/inode.c
... ... @@ -48,7 +48,6 @@
48 48 #define USBFS_DEFAULT_BUSMODE (S_IXUGO | S_IRUGO)
49 49 #define USBFS_DEFAULT_LISTMODE S_IRUGO
50 50  
51   -static struct super_operations usbfs_ops;
52 51 static const struct file_operations default_file_operations;
53 52 static struct vfsmount *usbfs_mount;
54 53 static int usbfs_mount_count; /* = 0 */
... ... @@ -449,7 +448,7 @@
449 448 .llseek = default_file_lseek,
450 449 };
451 450  
452   -static struct super_operations usbfs_ops = {
  451 +static const struct super_operations usbfs_ops = {
453 452 .statfs = simple_statfs,
454 453 .drop_inode = generic_delete_inode,
455 454 .remount_fs = remount,
drivers/usb/gadget/inode.c
... ... @@ -2033,7 +2033,7 @@
2033 2033 return inode;
2034 2034 }
2035 2035  
2036   -static struct super_operations gadget_fs_operations = {
  2036 +static const struct super_operations gadget_fs_operations = {
2037 2037 .statfs = simple_statfs,
2038 2038 .drop_inode = generic_delete_inode,
2039 2039 };
... ... @@ -842,7 +842,7 @@
842 842 sb->s_magic = BEFS_SUPER_MAGIC;
843 843 /* Set real blocksize of fs */
844 844 sb_set_blocksize(sb, (ulong) befs_sb->block_size);
845   - sb->s_op = (struct super_operations *) &befs_sops;
  845 + sb->s_op = &befs_sops;
846 846 root = befs_iget(sb, iaddr2blockno(sb, &(befs_sb->root_dir)));
847 847 if (IS_ERR(root)) {
848 848 ret = PTR_ERR(root);
... ... @@ -51,7 +51,7 @@
51 51 #include "export.h"
52 52 #include "compression.h"
53 53  
54   -static struct super_operations btrfs_super_ops;
  54 +static const struct super_operations btrfs_super_ops;
55 55  
56 56 static void btrfs_put_super(struct super_block *sb)
57 57 {
... ... @@ -675,7 +675,7 @@
675 675 return 0;
676 676 }
677 677  
678   -static struct super_operations btrfs_super_ops = {
  678 +static const struct super_operations btrfs_super_ops = {
679 679 .delete_inode = btrfs_delete_inode,
680 680 .put_super = btrfs_put_super,
681 681 .sync_fs = btrfs_sync_fs,
... ... @@ -504,7 +504,7 @@
504 504 return 0;
505 505 }
506 506  
507   -static struct super_operations nilfs_sops = {
  507 +static const struct super_operations nilfs_sops = {
508 508 .alloc_inode = nilfs_alloc_inode,
509 509 .destroy_inode = nilfs_destroy_inode,
510 510 .dirty_inode = nilfs_dirty_inode,
... ... @@ -278,7 +278,7 @@
278 278 return 0;
279 279 }
280 280  
281   -static struct super_operations omfs_sops = {
  281 +static const struct super_operations omfs_sops = {
282 282 .write_inode = omfs_write_inode,
283 283 .delete_inode = omfs_delete_inode,
284 284 .put_super = omfs_put_super,
... ... @@ -44,7 +44,7 @@
44 44 #include "squashfs.h"
45 45  
46 46 static struct file_system_type squashfs_fs_type;
47   -static struct super_operations squashfs_super_ops;
  47 +static const struct super_operations squashfs_super_ops;
48 48  
49 49 static int supported_squashfs_filesystem(short major, short minor, short comp)
50 50 {
... ... @@ -444,7 +444,7 @@
444 444 .fs_flags = FS_REQUIRES_DEV
445 445 };
446 446  
447   -static struct super_operations squashfs_super_ops = {
  447 +static const struct super_operations squashfs_super_ops = {
448 448 .alloc_inode = squashfs_alloc_inode,
449 449 .destroy_inode = squashfs_destroy_inode,
450 450 .statfs = squashfs_statfs,
... ... @@ -54,7 +54,7 @@
54 54 static struct super_block *alloc_super(struct file_system_type *type)
55 55 {
56 56 struct super_block *s = kzalloc(sizeof(struct super_block), GFP_USER);
57   - static struct super_operations default_op;
  57 + static const struct super_operations default_op;
58 58  
59 59 if (s) {
60 60 if (security_sb_alloc(s)) {
fs/xfs/linux-2.6/xfs_super.c
... ... @@ -67,7 +67,7 @@
67 67 #include <linux/freezer.h>
68 68 #include <linux/parser.h>
69 69  
70   -static struct super_operations xfs_super_operations;
  70 +static const struct super_operations xfs_super_operations;
71 71 static kmem_zone_t *xfs_ioend_zone;
72 72 mempool_t *xfs_ioend_pool;
73 73  
... ... @@ -1536,7 +1536,7 @@
1536 1536 mnt);
1537 1537 }
1538 1538  
1539   -static struct super_operations xfs_super_operations = {
  1539 +static const struct super_operations xfs_super_operations = {
1540 1540 .alloc_inode = xfs_fs_alloc_inode,
1541 1541 .destroy_inode = xfs_fs_destroy_inode,
1542 1542 .write_inode = xfs_fs_write_inode,
... ... @@ -77,7 +77,7 @@
77 77  
78 78 static const struct inode_operations mqueue_dir_inode_operations;
79 79 static const struct file_operations mqueue_file_operations;
80   -static struct super_operations mqueue_super_ops;
  80 +static const struct super_operations mqueue_super_ops;
81 81 static void remove_notification(struct mqueue_inode_info *info);
82 82  
83 83 static struct kmem_cache *mqueue_inode_cachep;
... ... @@ -1224,7 +1224,7 @@
1224 1224 .read = mqueue_read_file,
1225 1225 };
1226 1226  
1227   -static struct super_operations mqueue_super_ops = {
  1227 +static const struct super_operations mqueue_super_ops = {
1228 1228 .alloc_inode = mqueue_alloc_inode,
1229 1229 .destroy_inode = mqueue_destroy_inode,
1230 1230 .statfs = simple_statfs,
... ... @@ -961,7 +961,7 @@
961 961 return ret;
962 962 }
963 963  
964   -static struct super_operations cgroup_ops = {
  964 +static const struct super_operations cgroup_ops = {
965 965 .statfs = simple_statfs,
966 966 .drop_inode = generic_delete_inode,
967 967 .show_options = cgroup_show_options,
... ... @@ -285,7 +285,7 @@
285 285 return 0;
286 286 }
287 287  
288   -static struct super_operations sockfs_ops = {
  288 +static const struct super_operations sockfs_ops = {
289 289 .alloc_inode = sock_alloc_inode,
290 290 .destroy_inode =sock_destroy_inode,
291 291 .statfs = simple_statfs,
net/sunrpc/rpc_pipe.c
... ... @@ -930,7 +930,7 @@
930 930 /*
931 931 * populate the filesystem
932 932 */
933   -static struct super_operations s_ops = {
  933 +static const struct super_operations s_ops = {
934 934 .alloc_inode = rpc_alloc_inode,
935 935 .destroy_inode = rpc_destroy_inode,
936 936 .statfs = simple_statfs,