diff options
57 files changed, 100 insertions, 100 deletions
diff --git a/arch/powerpc/platforms/cell/spufs/inode.c b/arch/powerpc/platforms/cell/spufs/inode.c index bffc934ceadb..8079983ef94f 100644 --- a/arch/powerpc/platforms/cell/spufs/inode.c +++ b/arch/powerpc/platforms/cell/spufs/inode.c | |||
@@ -220,7 +220,7 @@ static int spufs_dir_close(struct inode *inode, struct file *file) | |||
220 | return dcache_dir_close(inode, file); | 220 | return dcache_dir_close(inode, file); |
221 | } | 221 | } |
222 | 222 | ||
223 | struct inode_operations spufs_dir_inode_operations = { | 223 | const struct inode_operations spufs_dir_inode_operations = { |
224 | .lookup = simple_lookup, | 224 | .lookup = simple_lookup, |
225 | }; | 225 | }; |
226 | 226 | ||
diff --git a/fs/9p/vfs_inode.c b/fs/9p/vfs_inode.c index 378767c07bf1..5cf22134826b 100644 --- a/fs/9p/vfs_inode.c +++ b/fs/9p/vfs_inode.c | |||
@@ -41,10 +41,10 @@ | |||
41 | #include "v9fs_vfs.h" | 41 | #include "v9fs_vfs.h" |
42 | #include "fid.h" | 42 | #include "fid.h" |
43 | 43 | ||
44 | static struct inode_operations v9fs_dir_inode_operations; | 44 | static const struct inode_operations v9fs_dir_inode_operations; |
45 | static struct inode_operations v9fs_dir_inode_operations_ext; | 45 | static const struct inode_operations v9fs_dir_inode_operations_ext; |
46 | static struct inode_operations v9fs_file_inode_operations; | 46 | static const struct inode_operations v9fs_file_inode_operations; |
47 | static struct inode_operations v9fs_symlink_inode_operations; | 47 | static const struct inode_operations v9fs_symlink_inode_operations; |
48 | 48 | ||
49 | /** | 49 | /** |
50 | * unixmode2p9mode - convert unix mode bits to plan 9 | 50 | * unixmode2p9mode - convert unix mode bits to plan 9 |
@@ -1303,7 +1303,7 @@ v9fs_vfs_mknod(struct inode *dir, struct dentry *dentry, int mode, dev_t rdev) | |||
1303 | return retval; | 1303 | return retval; |
1304 | } | 1304 | } |
1305 | 1305 | ||
1306 | static struct inode_operations v9fs_dir_inode_operations_ext = { | 1306 | static const struct inode_operations v9fs_dir_inode_operations_ext = { |
1307 | .create = v9fs_vfs_create, | 1307 | .create = v9fs_vfs_create, |
1308 | .lookup = v9fs_vfs_lookup, | 1308 | .lookup = v9fs_vfs_lookup, |
1309 | .symlink = v9fs_vfs_symlink, | 1309 | .symlink = v9fs_vfs_symlink, |
@@ -1318,7 +1318,7 @@ static struct inode_operations v9fs_dir_inode_operations_ext = { | |||
1318 | .setattr = v9fs_vfs_setattr, | 1318 | .setattr = v9fs_vfs_setattr, |
1319 | }; | 1319 | }; |
1320 | 1320 | ||
1321 | static struct inode_operations v9fs_dir_inode_operations = { | 1321 | static const struct inode_operations v9fs_dir_inode_operations = { |
1322 | .create = v9fs_vfs_create, | 1322 | .create = v9fs_vfs_create, |
1323 | .lookup = v9fs_vfs_lookup, | 1323 | .lookup = v9fs_vfs_lookup, |
1324 | .unlink = v9fs_vfs_unlink, | 1324 | .unlink = v9fs_vfs_unlink, |
@@ -1330,12 +1330,12 @@ static struct inode_operations v9fs_dir_inode_operations = { | |||
1330 | .setattr = v9fs_vfs_setattr, | 1330 | .setattr = v9fs_vfs_setattr, |
1331 | }; | 1331 | }; |
1332 | 1332 | ||
1333 | static struct inode_operations v9fs_file_inode_operations = { | 1333 | static const struct inode_operations v9fs_file_inode_operations = { |
1334 | .getattr = v9fs_vfs_getattr, | 1334 | .getattr = v9fs_vfs_getattr, |
1335 | .setattr = v9fs_vfs_setattr, | 1335 | .setattr = v9fs_vfs_setattr, |
1336 | }; | 1336 | }; |
1337 | 1337 | ||
1338 | static struct inode_operations v9fs_symlink_inode_operations = { | 1338 | static const struct inode_operations v9fs_symlink_inode_operations = { |
1339 | .readlink = v9fs_vfs_readlink, | 1339 | .readlink = v9fs_vfs_readlink, |
1340 | .follow_link = v9fs_vfs_follow_link, | 1340 | .follow_link = v9fs_vfs_follow_link, |
1341 | .put_link = v9fs_vfs_put_link, | 1341 | .put_link = v9fs_vfs_put_link, |
diff --git a/fs/adfs/adfs.h b/fs/adfs/adfs.h index 29217ff36d44..936f2af39c43 100644 --- a/fs/adfs/adfs.h +++ b/fs/adfs/adfs.h | |||
@@ -84,7 +84,7 @@ void __adfs_error(struct super_block *sb, const char *function, | |||
84 | */ | 84 | */ |
85 | 85 | ||
86 | /* dir_*.c */ | 86 | /* dir_*.c */ |
87 | extern struct inode_operations adfs_dir_inode_operations; | 87 | extern const struct inode_operations adfs_dir_inode_operations; |
88 | extern const struct file_operations adfs_dir_operations; | 88 | extern const struct file_operations adfs_dir_operations; |
89 | extern struct dentry_operations adfs_dentry_operations; | 89 | extern struct dentry_operations adfs_dentry_operations; |
90 | extern struct adfs_dir_ops adfs_f_dir_ops; | 90 | extern struct adfs_dir_ops adfs_f_dir_ops; |
@@ -93,7 +93,7 @@ extern struct adfs_dir_ops adfs_fplus_dir_ops; | |||
93 | extern int adfs_dir_update(struct super_block *sb, struct object_info *obj); | 93 | extern int adfs_dir_update(struct super_block *sb, struct object_info *obj); |
94 | 94 | ||
95 | /* file.c */ | 95 | /* file.c */ |
96 | extern struct inode_operations adfs_file_inode_operations; | 96 | extern const struct inode_operations adfs_file_inode_operations; |
97 | extern const struct file_operations adfs_file_operations; | 97 | extern const struct file_operations adfs_file_operations; |
98 | 98 | ||
99 | static inline __u32 signed_asl(__u32 val, signed int shift) | 99 | static inline __u32 signed_asl(__u32 val, signed int shift) |
diff --git a/fs/adfs/dir.c b/fs/adfs/dir.c index 2b8903893d3f..fc1a8dc64d78 100644 --- a/fs/adfs/dir.c +++ b/fs/adfs/dir.c | |||
@@ -295,7 +295,7 @@ adfs_lookup(struct inode *dir, struct dentry *dentry, struct nameidata *nd) | |||
295 | /* | 295 | /* |
296 | * directories can handle most operations... | 296 | * directories can handle most operations... |
297 | */ | 297 | */ |
298 | struct inode_operations adfs_dir_inode_operations = { | 298 | const struct inode_operations adfs_dir_inode_operations = { |
299 | .lookup = adfs_lookup, | 299 | .lookup = adfs_lookup, |
300 | .setattr = adfs_notify_change, | 300 | .setattr = adfs_notify_change, |
301 | }; | 301 | }; |
diff --git a/fs/adfs/file.c b/fs/adfs/file.c index 6101ea679cb1..f544a2855923 100644 --- a/fs/adfs/file.c +++ b/fs/adfs/file.c | |||
@@ -36,6 +36,6 @@ const struct file_operations adfs_file_operations = { | |||
36 | .sendfile = generic_file_sendfile, | 36 | .sendfile = generic_file_sendfile, |
37 | }; | 37 | }; |
38 | 38 | ||
39 | struct inode_operations adfs_file_inode_operations = { | 39 | const struct inode_operations adfs_file_inode_operations = { |
40 | .setattr = adfs_notify_change, | 40 | .setattr = adfs_notify_change, |
41 | }; | 41 | }; |
diff --git a/fs/affs/affs.h b/fs/affs/affs.h index 1dc8438ef389..7db2d287e9f3 100644 --- a/fs/affs/affs.h +++ b/fs/affs/affs.h | |||
@@ -188,9 +188,9 @@ extern void affs_dir_truncate(struct inode *); | |||
188 | 188 | ||
189 | /* jump tables */ | 189 | /* jump tables */ |
190 | 190 | ||
191 | extern struct inode_operations affs_file_inode_operations; | 191 | extern const struct inode_operations affs_file_inode_operations; |
192 | extern struct inode_operations affs_dir_inode_operations; | 192 | extern const struct inode_operations affs_dir_inode_operations; |
193 | extern struct inode_operations affs_symlink_inode_operations; | 193 | extern const struct inode_operations affs_symlink_inode_operations; |
194 | extern const struct file_operations affs_file_operations; | 194 | extern const struct file_operations affs_file_operations; |
195 | extern const struct file_operations affs_file_operations_ofs; | 195 | extern const struct file_operations affs_file_operations_ofs; |
196 | extern const struct file_operations affs_dir_operations; | 196 | extern const struct file_operations affs_dir_operations; |
diff --git a/fs/affs/dir.c b/fs/affs/dir.c index cad3ee340063..6e3f282424b0 100644 --- a/fs/affs/dir.c +++ b/fs/affs/dir.c | |||
@@ -26,7 +26,7 @@ const struct file_operations affs_dir_operations = { | |||
26 | /* | 26 | /* |
27 | * directories can handle most operations... | 27 | * directories can handle most operations... |
28 | */ | 28 | */ |
29 | struct inode_operations affs_dir_inode_operations = { | 29 | const struct inode_operations affs_dir_inode_operations = { |
30 | .create = affs_create, | 30 | .create = affs_create, |
31 | .lookup = affs_lookup, | 31 | .lookup = affs_lookup, |
32 | .link = affs_link, | 32 | .link = affs_link, |
diff --git a/fs/affs/file.c b/fs/affs/file.c index 05b5e22de759..4aa8079e71be 100644 --- a/fs/affs/file.c +++ b/fs/affs/file.c | |||
@@ -38,7 +38,7 @@ const struct file_operations affs_file_operations = { | |||
38 | .sendfile = generic_file_sendfile, | 38 | .sendfile = generic_file_sendfile, |
39 | }; | 39 | }; |
40 | 40 | ||
41 | struct inode_operations affs_file_inode_operations = { | 41 | const struct inode_operations affs_file_inode_operations = { |
42 | .truncate = affs_truncate, | 42 | .truncate = affs_truncate, |
43 | .setattr = affs_notify_change, | 43 | .setattr = affs_notify_change, |
44 | }; | 44 | }; |
diff --git a/fs/affs/inode.c b/fs/affs/inode.c index 44d439cb69f4..fce6848a4641 100644 --- a/fs/affs/inode.c +++ b/fs/affs/inode.c | |||
@@ -12,7 +12,7 @@ | |||
12 | 12 | ||
13 | #include "affs.h" | 13 | #include "affs.h" |
14 | 14 | ||
15 | extern struct inode_operations affs_symlink_inode_operations; | 15 | extern const struct inode_operations affs_symlink_inode_operations; |
16 | extern struct timezone sys_tz; | 16 | extern struct timezone sys_tz; |
17 | 17 | ||
18 | void | 18 | void |
diff --git a/fs/affs/symlink.c b/fs/affs/symlink.c index f802256a5933..41782539c907 100644 --- a/fs/affs/symlink.c +++ b/fs/affs/symlink.c | |||
@@ -70,7 +70,7 @@ const struct address_space_operations affs_symlink_aops = { | |||
70 | .readpage = affs_symlink_readpage, | 70 | .readpage = affs_symlink_readpage, |
71 | }; | 71 | }; |
72 | 72 | ||
73 | struct inode_operations affs_symlink_inode_operations = { | 73 | const struct inode_operations affs_symlink_inode_operations = { |
74 | .readlink = generic_readlink, | 74 | .readlink = generic_readlink, |
75 | .follow_link = page_follow_link_light, | 75 | .follow_link = page_follow_link_light, |
76 | .put_link = page_put_link, | 76 | .put_link = page_put_link, |
diff --git a/fs/afs/dir.c b/fs/afs/dir.c index 4acd04134055..9908462bcadc 100644 --- a/fs/afs/dir.c +++ b/fs/afs/dir.c | |||
@@ -37,7 +37,7 @@ const struct file_operations afs_dir_file_operations = { | |||
37 | .readdir = afs_dir_readdir, | 37 | .readdir = afs_dir_readdir, |
38 | }; | 38 | }; |
39 | 39 | ||
40 | struct inode_operations afs_dir_inode_operations = { | 40 | const struct inode_operations afs_dir_inode_operations = { |
41 | .lookup = afs_dir_lookup, | 41 | .lookup = afs_dir_lookup, |
42 | .getattr = afs_inode_getattr, | 42 | .getattr = afs_inode_getattr, |
43 | #if 0 /* TODO */ | 43 | #if 0 /* TODO */ |
diff --git a/fs/afs/file.c b/fs/afs/file.c index 2e8c42639eaa..eeff14c3f748 100644 --- a/fs/afs/file.c +++ b/fs/afs/file.c | |||
@@ -30,7 +30,7 @@ static int afs_file_readpage(struct file *file, struct page *page); | |||
30 | static void afs_file_invalidatepage(struct page *page, unsigned long offset); | 30 | static void afs_file_invalidatepage(struct page *page, unsigned long offset); |
31 | static int afs_file_releasepage(struct page *page, gfp_t gfp_flags); | 31 | static int afs_file_releasepage(struct page *page, gfp_t gfp_flags); |
32 | 32 | ||
33 | struct inode_operations afs_file_inode_operations = { | 33 | const struct inode_operations afs_file_inode_operations = { |
34 | .getattr = afs_inode_getattr, | 34 | .getattr = afs_inode_getattr, |
35 | }; | 35 | }; |
36 | 36 | ||
diff --git a/fs/afs/internal.h b/fs/afs/internal.h index e88b3b65ae49..5151d5da2c2f 100644 --- a/fs/afs/internal.h +++ b/fs/afs/internal.h | |||
@@ -63,14 +63,14 @@ extern struct cachefs_index_def afs_cache_cell_index_def; | |||
63 | /* | 63 | /* |
64 | * dir.c | 64 | * dir.c |
65 | */ | 65 | */ |
66 | extern struct inode_operations afs_dir_inode_operations; | 66 | extern const struct inode_operations afs_dir_inode_operations; |
67 | extern const struct file_operations afs_dir_file_operations; | 67 | extern const struct file_operations afs_dir_file_operations; |
68 | 68 | ||
69 | /* | 69 | /* |
70 | * file.c | 70 | * file.c |
71 | */ | 71 | */ |
72 | extern const struct address_space_operations afs_fs_aops; | 72 | extern const struct address_space_operations afs_fs_aops; |
73 | extern struct inode_operations afs_file_inode_operations; | 73 | extern const struct inode_operations afs_file_inode_operations; |
74 | 74 | ||
75 | #ifdef AFS_CACHING_SUPPORT | 75 | #ifdef AFS_CACHING_SUPPORT |
76 | extern int afs_cache_get_page_cookie(struct page *page, | 76 | extern int afs_cache_get_page_cookie(struct page *page, |
@@ -104,7 +104,7 @@ extern struct cachefs_netfs afs_cache_netfs; | |||
104 | /* | 104 | /* |
105 | * mntpt.c | 105 | * mntpt.c |
106 | */ | 106 | */ |
107 | extern struct inode_operations afs_mntpt_inode_operations; | 107 | extern const struct inode_operations afs_mntpt_inode_operations; |
108 | extern const struct file_operations afs_mntpt_file_operations; | 108 | extern const struct file_operations afs_mntpt_file_operations; |
109 | extern struct afs_timer afs_mntpt_expiry_timer; | 109 | extern struct afs_timer afs_mntpt_expiry_timer; |
110 | extern struct afs_timer_ops afs_mntpt_expiry_timer_ops; | 110 | extern struct afs_timer_ops afs_mntpt_expiry_timer_ops; |
diff --git a/fs/afs/mntpt.c b/fs/afs/mntpt.c index 8f74e8450826..fdf23b2a2112 100644 --- a/fs/afs/mntpt.c +++ b/fs/afs/mntpt.c | |||
@@ -36,7 +36,7 @@ const struct file_operations afs_mntpt_file_operations = { | |||
36 | .open = afs_mntpt_open, | 36 | .open = afs_mntpt_open, |
37 | }; | 37 | }; |
38 | 38 | ||
39 | struct inode_operations afs_mntpt_inode_operations = { | 39 | const struct inode_operations afs_mntpt_inode_operations = { |
40 | .lookup = afs_mntpt_lookup, | 40 | .lookup = afs_mntpt_lookup, |
41 | .follow_link = afs_mntpt_follow_link, | 41 | .follow_link = afs_mntpt_follow_link, |
42 | .readlink = page_readlink, | 42 | .readlink = page_readlink, |
diff --git a/fs/autofs/autofs_i.h b/fs/autofs/autofs_i.h index 906ba5ce2261..4ef544434b51 100644 --- a/fs/autofs/autofs_i.h +++ b/fs/autofs/autofs_i.h | |||
@@ -142,8 +142,8 @@ struct autofs_dir_ent *autofs_expire(struct super_block *,struct autofs_sb_info | |||
142 | 142 | ||
143 | /* Operations structures */ | 143 | /* Operations structures */ |
144 | 144 | ||
145 | extern struct inode_operations autofs_root_inode_operations; | 145 | extern const struct inode_operations autofs_root_inode_operations; |
146 | extern struct inode_operations autofs_symlink_inode_operations; | 146 | extern const struct inode_operations autofs_symlink_inode_operations; |
147 | extern const struct file_operations autofs_root_operations; | 147 | extern const struct file_operations autofs_root_operations; |
148 | 148 | ||
149 | /* Initializing function */ | 149 | /* Initializing function */ |
diff --git a/fs/autofs/root.c b/fs/autofs/root.c index e698c51d2b02..f2597205939d 100644 --- a/fs/autofs/root.c +++ b/fs/autofs/root.c | |||
@@ -32,7 +32,7 @@ const struct file_operations autofs_root_operations = { | |||
32 | .ioctl = autofs_root_ioctl, | 32 | .ioctl = autofs_root_ioctl, |
33 | }; | 33 | }; |
34 | 34 | ||
35 | struct inode_operations autofs_root_inode_operations = { | 35 | const struct inode_operations autofs_root_inode_operations = { |
36 | .lookup = autofs_root_lookup, | 36 | .lookup = autofs_root_lookup, |
37 | .unlink = autofs_root_unlink, | 37 | .unlink = autofs_root_unlink, |
38 | .symlink = autofs_root_symlink, | 38 | .symlink = autofs_root_symlink, |
diff --git a/fs/autofs/symlink.c b/fs/autofs/symlink.c index c74f2eb65775..7ce9cb2c9ce2 100644 --- a/fs/autofs/symlink.c +++ b/fs/autofs/symlink.c | |||
@@ -20,7 +20,7 @@ static void *autofs_follow_link(struct dentry *dentry, struct nameidata *nd) | |||
20 | return NULL; | 20 | return NULL; |
21 | } | 21 | } |
22 | 22 | ||
23 | struct inode_operations autofs_symlink_inode_operations = { | 23 | const struct inode_operations autofs_symlink_inode_operations = { |
24 | .readlink = generic_readlink, | 24 | .readlink = generic_readlink, |
25 | .follow_link = autofs_follow_link | 25 | .follow_link = autofs_follow_link |
26 | }; | 26 | }; |
diff --git a/fs/autofs4/autofs_i.h b/fs/autofs4/autofs_i.h index 216b1a364ccb..6b4cec3f272f 100644 --- a/fs/autofs4/autofs_i.h +++ b/fs/autofs4/autofs_i.h | |||
@@ -168,11 +168,11 @@ int autofs4_expire_multi(struct super_block *, struct vfsmount *, | |||
168 | 168 | ||
169 | /* Operations structures */ | 169 | /* Operations structures */ |
170 | 170 | ||
171 | extern struct inode_operations autofs4_symlink_inode_operations; | 171 | extern const struct inode_operations autofs4_symlink_inode_operations; |
172 | extern struct inode_operations autofs4_dir_inode_operations; | 172 | extern const struct inode_operations autofs4_dir_inode_operations; |
173 | extern struct inode_operations autofs4_root_inode_operations; | 173 | extern const struct inode_operations autofs4_root_inode_operations; |
174 | extern struct inode_operations autofs4_indirect_root_inode_operations; | 174 | extern const struct inode_operations autofs4_indirect_root_inode_operations; |
175 | extern struct inode_operations autofs4_direct_root_inode_operations; | 175 | extern const struct inode_operations autofs4_direct_root_inode_operations; |
176 | extern const struct file_operations autofs4_dir_operations; | 176 | extern const struct file_operations autofs4_dir_operations; |
177 | extern const struct file_operations autofs4_root_operations; | 177 | extern const struct file_operations autofs4_root_operations; |
178 | 178 | ||
diff --git a/fs/autofs4/root.c b/fs/autofs4/root.c index 8d05b9f7578d..47fee96c2182 100644 --- a/fs/autofs4/root.c +++ b/fs/autofs4/root.c | |||
@@ -47,7 +47,7 @@ const struct file_operations autofs4_dir_operations = { | |||
47 | .readdir = autofs4_dir_readdir, | 47 | .readdir = autofs4_dir_readdir, |
48 | }; | 48 | }; |
49 | 49 | ||
50 | struct inode_operations autofs4_indirect_root_inode_operations = { | 50 | const struct inode_operations autofs4_indirect_root_inode_operations = { |
51 | .lookup = autofs4_lookup, | 51 | .lookup = autofs4_lookup, |
52 | .unlink = autofs4_dir_unlink, | 52 | .unlink = autofs4_dir_unlink, |
53 | .symlink = autofs4_dir_symlink, | 53 | .symlink = autofs4_dir_symlink, |
@@ -55,7 +55,7 @@ struct inode_operations autofs4_indirect_root_inode_operations = { | |||
55 | .rmdir = autofs4_dir_rmdir, | 55 | .rmdir = autofs4_dir_rmdir, |
56 | }; | 56 | }; |
57 | 57 | ||
58 | struct inode_operations autofs4_direct_root_inode_operations = { | 58 | const struct inode_operations autofs4_direct_root_inode_operations = { |
59 | .lookup = autofs4_lookup, | 59 | .lookup = autofs4_lookup, |
60 | .unlink = autofs4_dir_unlink, | 60 | .unlink = autofs4_dir_unlink, |
61 | .mkdir = autofs4_dir_mkdir, | 61 | .mkdir = autofs4_dir_mkdir, |
@@ -63,7 +63,7 @@ struct inode_operations autofs4_direct_root_inode_operations = { | |||
63 | .follow_link = autofs4_follow_link, | 63 | .follow_link = autofs4_follow_link, |
64 | }; | 64 | }; |
65 | 65 | ||
66 | struct inode_operations autofs4_dir_inode_operations = { | 66 | const struct inode_operations autofs4_dir_inode_operations = { |
67 | .lookup = autofs4_lookup, | 67 | .lookup = autofs4_lookup, |
68 | .unlink = autofs4_dir_unlink, | 68 | .unlink = autofs4_dir_unlink, |
69 | .symlink = autofs4_dir_symlink, | 69 | .symlink = autofs4_dir_symlink, |
diff --git a/fs/autofs4/symlink.c b/fs/autofs4/symlink.c index 2ea2c98fd84b..b4ea82934d2e 100644 --- a/fs/autofs4/symlink.c +++ b/fs/autofs4/symlink.c | |||
@@ -19,7 +19,7 @@ static void *autofs4_follow_link(struct dentry *dentry, struct nameidata *nd) | |||
19 | return NULL; | 19 | return NULL; |
20 | } | 20 | } |
21 | 21 | ||
22 | struct inode_operations autofs4_symlink_inode_operations = { | 22 | const struct inode_operations autofs4_symlink_inode_operations = { |
23 | .readlink = generic_readlink, | 23 | .readlink = generic_readlink, |
24 | .follow_link = autofs4_follow_link | 24 | .follow_link = autofs4_follow_link |
25 | }; | 25 | }; |
diff --git a/fs/bad_inode.c b/fs/bad_inode.c index 869f5193ecc2..efeab2fab40b 100644 --- a/fs/bad_inode.c +++ b/fs/bad_inode.c | |||
@@ -291,7 +291,7 @@ static int bad_inode_removexattr(struct dentry *dentry, const char *name) | |||
291 | return -EIO; | 291 | return -EIO; |
292 | } | 292 | } |
293 | 293 | ||
294 | static struct inode_operations bad_inode_ops = | 294 | static const struct inode_operations bad_inode_ops = |
295 | { | 295 | { |
296 | .create = bad_inode_create, | 296 | .create = bad_inode_create, |
297 | .lookup = bad_inode_lookup, | 297 | .lookup = bad_inode_lookup, |
diff --git a/fs/befs/linuxvfs.c b/fs/befs/linuxvfs.c index 481e59b9d91c..cc6cc8ed2e39 100644 --- a/fs/befs/linuxvfs.c +++ b/fs/befs/linuxvfs.c | |||
@@ -68,7 +68,7 @@ static const struct file_operations befs_dir_operations = { | |||
68 | .readdir = befs_readdir, | 68 | .readdir = befs_readdir, |
69 | }; | 69 | }; |
70 | 70 | ||
71 | static struct inode_operations befs_dir_inode_operations = { | 71 | static const struct inode_operations befs_dir_inode_operations = { |
72 | .lookup = befs_lookup, | 72 | .lookup = befs_lookup, |
73 | }; | 73 | }; |
74 | 74 | ||
@@ -78,7 +78,7 @@ static const struct address_space_operations befs_aops = { | |||
78 | .bmap = befs_bmap, | 78 | .bmap = befs_bmap, |
79 | }; | 79 | }; |
80 | 80 | ||
81 | static struct inode_operations befs_symlink_inode_operations = { | 81 | static const struct inode_operations befs_symlink_inode_operations = { |
82 | .readlink = generic_readlink, | 82 | .readlink = generic_readlink, |
83 | .follow_link = befs_follow_link, | 83 | .follow_link = befs_follow_link, |
84 | .put_link = befs_put_link, | 84 | .put_link = befs_put_link, |
diff --git a/fs/bfs/bfs.h b/fs/bfs/bfs.h index 31973bbbf057..130f6c66c5ba 100644 --- a/fs/bfs/bfs.h +++ b/fs/bfs/bfs.h | |||
@@ -48,12 +48,12 @@ static inline struct bfs_inode_info *BFS_I(struct inode *inode) | |||
48 | 48 | ||
49 | 49 | ||
50 | /* file.c */ | 50 | /* file.c */ |
51 | extern struct inode_operations bfs_file_inops; | 51 | extern const struct inode_operations bfs_file_inops; |
52 | extern const struct file_operations bfs_file_operations; | 52 | extern const struct file_operations bfs_file_operations; |
53 | extern const struct address_space_operations bfs_aops; | 53 | extern const struct address_space_operations bfs_aops; |
54 | 54 | ||
55 | /* dir.c */ | 55 | /* dir.c */ |
56 | extern struct inode_operations bfs_dir_inops; | 56 | extern const struct inode_operations bfs_dir_inops; |
57 | extern const struct file_operations bfs_dir_operations; | 57 | extern const struct file_operations bfs_dir_operations; |
58 | 58 | ||
59 | #endif /* _FS_BFS_BFS_H */ | 59 | #endif /* _FS_BFS_BFS_H */ |
diff --git a/fs/bfs/dir.c b/fs/bfs/dir.c index 2a746e688df5..097f1497f743 100644 --- a/fs/bfs/dir.c +++ b/fs/bfs/dir.c | |||
@@ -260,7 +260,7 @@ end_rename: | |||
260 | return error; | 260 | return error; |
261 | } | 261 | } |
262 | 262 | ||
263 | struct inode_operations bfs_dir_inops = { | 263 | const struct inode_operations bfs_dir_inops = { |
264 | .create = bfs_create, | 264 | .create = bfs_create, |
265 | .lookup = bfs_lookup, | 265 | .lookup = bfs_lookup, |
266 | .link = bfs_link, | 266 | .link = bfs_link, |
diff --git a/fs/bfs/file.c b/fs/bfs/file.c index a9164a87f8de..ef4d1fa04e65 100644 --- a/fs/bfs/file.c +++ b/fs/bfs/file.c | |||
@@ -164,4 +164,4 @@ const struct address_space_operations bfs_aops = { | |||
164 | .bmap = bfs_bmap, | 164 | .bmap = bfs_bmap, |
165 | }; | 165 | }; |
166 | 166 | ||
167 | struct inode_operations bfs_file_inops; | 167 | const struct inode_operations bfs_file_inops; |
diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c index 93ef09971d2f..481e84f5f361 100644 --- a/fs/cifs/cifsfs.c +++ b/fs/cifs/cifsfs.c | |||
@@ -533,7 +533,7 @@ static struct file_system_type cifs_fs_type = { | |||
533 | .kill_sb = kill_anon_super, | 533 | .kill_sb = kill_anon_super, |
534 | /* .fs_flags */ | 534 | /* .fs_flags */ |
535 | }; | 535 | }; |
536 | struct inode_operations cifs_dir_inode_ops = { | 536 | const struct inode_operations cifs_dir_inode_ops = { |
537 | .create = cifs_create, | 537 | .create = cifs_create, |
538 | .lookup = cifs_lookup, | 538 | .lookup = cifs_lookup, |
539 | .getattr = cifs_getattr, | 539 | .getattr = cifs_getattr, |
@@ -555,7 +555,7 @@ struct inode_operations cifs_dir_inode_ops = { | |||
555 | #endif | 555 | #endif |
556 | }; | 556 | }; |
557 | 557 | ||
558 | struct inode_operations cifs_file_inode_ops = { | 558 | const struct inode_operations cifs_file_inode_ops = { |
559 | /* revalidate:cifs_revalidate, */ | 559 | /* revalidate:cifs_revalidate, */ |
560 | .setattr = cifs_setattr, | 560 | .setattr = cifs_setattr, |
561 | .getattr = cifs_getattr, /* do we need this anymore? */ | 561 | .getattr = cifs_getattr, /* do we need this anymore? */ |
@@ -569,7 +569,7 @@ struct inode_operations cifs_file_inode_ops = { | |||
569 | #endif | 569 | #endif |
570 | }; | 570 | }; |
571 | 571 | ||
572 | struct inode_operations cifs_symlink_inode_ops = { | 572 | const struct inode_operations cifs_symlink_inode_ops = { |
573 | .readlink = generic_readlink, | 573 | .readlink = generic_readlink, |
574 | .follow_link = cifs_follow_link, | 574 | .follow_link = cifs_follow_link, |
575 | .put_link = cifs_put_link, | 575 | .put_link = cifs_put_link, |
diff --git a/fs/cifs/cifsfs.h b/fs/cifs/cifsfs.h index 8aa66dcf13bd..ab9e20a863f3 100644 --- a/fs/cifs/cifsfs.h +++ b/fs/cifs/cifsfs.h | |||
@@ -42,7 +42,7 @@ extern void cifs_delete_inode(struct inode *); | |||
42 | /* extern void cifs_write_inode(struct inode *); *//* BB not needed yet */ | 42 | /* extern void cifs_write_inode(struct inode *); *//* BB not needed yet */ |
43 | 43 | ||
44 | /* Functions related to inodes */ | 44 | /* Functions related to inodes */ |
45 | extern struct inode_operations cifs_dir_inode_ops; | 45 | extern const struct inode_operations cifs_dir_inode_ops; |
46 | extern int cifs_create(struct inode *, struct dentry *, int, | 46 | extern int cifs_create(struct inode *, struct dentry *, int, |
47 | struct nameidata *); | 47 | struct nameidata *); |
48 | extern struct dentry * cifs_lookup(struct inode *, struct dentry *, | 48 | extern struct dentry * cifs_lookup(struct inode *, struct dentry *, |
@@ -58,8 +58,8 @@ extern int cifs_revalidate(struct dentry *); | |||
58 | extern int cifs_getattr(struct vfsmount *, struct dentry *, struct kstat *); | 58 | extern int cifs_getattr(struct vfsmount *, struct dentry *, struct kstat *); |
59 | extern int cifs_setattr(struct dentry *, struct iattr *); | 59 | extern int cifs_setattr(struct dentry *, struct iattr *); |
60 | 60 | ||
61 | extern struct inode_operations cifs_file_inode_ops; | 61 | extern const struct inode_operations cifs_file_inode_ops; |
62 | extern struct inode_operations cifs_symlink_inode_ops; | 62 | extern const struct inode_operations cifs_symlink_inode_ops; |
63 | 63 | ||
64 | /* Functions related to files and directories */ | 64 | /* Functions related to files and directories */ |
65 | extern const struct file_operations cifs_file_ops; | 65 | extern const struct file_operations cifs_file_ops; |
diff --git a/fs/coda/cnode.c b/fs/coda/cnode.c index 4c9fecbfa91f..28c872747f81 100644 --- a/fs/coda/cnode.c +++ b/fs/coda/cnode.c | |||
@@ -16,7 +16,7 @@ static inline int coda_fideq(struct CodaFid *fid1, struct CodaFid *fid2) | |||
16 | return memcmp(fid1, fid2, sizeof(*fid1)) == 0; | 16 | return memcmp(fid1, fid2, sizeof(*fid1)) == 0; |
17 | } | 17 | } |
18 | 18 | ||
19 | static struct inode_operations coda_symlink_inode_operations = { | 19 | static const struct inode_operations coda_symlink_inode_operations = { |
20 | .readlink = generic_readlink, | 20 | .readlink = generic_readlink, |
21 | .follow_link = page_follow_link_light, | 21 | .follow_link = page_follow_link_light, |
22 | .put_link = page_put_link, | 22 | .put_link = page_put_link, |
diff --git a/fs/coda/dir.c b/fs/coda/dir.c index 0c6f7f3b3dd7..9ddf5ed62162 100644 --- a/fs/coda/dir.c +++ b/fs/coda/dir.c | |||
@@ -66,7 +66,7 @@ static struct dentry_operations coda_dentry_operations = | |||
66 | .d_delete = coda_dentry_delete, | 66 | .d_delete = coda_dentry_delete, |
67 | }; | 67 | }; |
68 | 68 | ||
69 | struct inode_operations coda_dir_inode_operations = | 69 | const struct inode_operations coda_dir_inode_operations = |
70 | { | 70 | { |
71 | .create = coda_create, | 71 | .create = coda_create, |
72 | .lookup = coda_lookup, | 72 | .lookup = coda_lookup, |
diff --git a/fs/coda/inode.c b/fs/coda/inode.c index 01395defed85..1562515efdb5 100644 --- a/fs/coda/inode.c +++ b/fs/coda/inode.c | |||
@@ -271,7 +271,7 @@ int coda_setattr(struct dentry *de, struct iattr *iattr) | |||
271 | return error; | 271 | return error; |
272 | } | 272 | } |
273 | 273 | ||
274 | struct inode_operations coda_file_inode_operations = { | 274 | const struct inode_operations coda_file_inode_operations = { |
275 | .permission = coda_permission, | 275 | .permission = coda_permission, |
276 | .getattr = coda_getattr, | 276 | .getattr = coda_getattr, |
277 | .setattr = coda_setattr, | 277 | .setattr = coda_setattr, |
diff --git a/fs/coda/pioctl.c b/fs/coda/pioctl.c index 214822be87bd..2bf3026adc80 100644 --- a/fs/coda/pioctl.c +++ b/fs/coda/pioctl.c | |||
@@ -30,7 +30,7 @@ static int coda_pioctl(struct inode * inode, struct file * filp, | |||
30 | unsigned int cmd, unsigned long user_data); | 30 | unsigned int cmd, unsigned long user_data); |
31 | 31 | ||
32 | /* exported from this file */ | 32 | /* exported from this file */ |
33 | struct inode_operations coda_ioctl_inode_operations = | 33 | const struct inode_operations coda_ioctl_inode_operations = |
34 | { | 34 | { |
35 | .permission = coda_ioctl_permission, | 35 | .permission = coda_ioctl_permission, |
36 | .setattr = coda_setattr, | 36 | .setattr = coda_setattr, |
diff --git a/fs/configfs/configfs_internal.h b/fs/configfs/configfs_internal.h index f92cd303d2c9..7b48c034b312 100644 --- a/fs/configfs/configfs_internal.h +++ b/fs/configfs/configfs_internal.h | |||
@@ -75,8 +75,8 @@ extern struct super_block * configfs_sb; | |||
75 | extern const struct file_operations configfs_dir_operations; | 75 | extern const struct file_operations configfs_dir_operations; |
76 | extern const struct file_operations configfs_file_operations; | 76 | extern const struct file_operations configfs_file_operations; |
77 | extern const struct file_operations bin_fops; | 77 | extern const struct file_operations bin_fops; |
78 | extern struct inode_operations configfs_dir_inode_operations; | 78 | extern const struct inode_operations configfs_dir_inode_operations; |
79 | extern struct inode_operations configfs_symlink_inode_operations; | 79 | extern const struct inode_operations configfs_symlink_inode_operations; |
80 | 80 | ||
81 | extern int configfs_symlink(struct inode *dir, struct dentry *dentry, | 81 | extern int configfs_symlink(struct inode *dir, struct dentry *dentry, |
82 | const char *symname); | 82 | const char *symname); |
diff --git a/fs/configfs/dir.c b/fs/configfs/dir.c index 9371ee209954..34750d5e4ff2 100644 --- a/fs/configfs/dir.c +++ b/fs/configfs/dir.c | |||
@@ -930,7 +930,7 @@ static int configfs_rmdir(struct inode *dir, struct dentry *dentry) | |||
930 | return 0; | 930 | return 0; |
931 | } | 931 | } |
932 | 932 | ||
933 | struct inode_operations configfs_dir_inode_operations = { | 933 | const struct inode_operations configfs_dir_inode_operations = { |
934 | .mkdir = configfs_mkdir, | 934 | .mkdir = configfs_mkdir, |
935 | .rmdir = configfs_rmdir, | 935 | .rmdir = configfs_rmdir, |
936 | .symlink = configfs_symlink, | 936 | .symlink = configfs_symlink, |
diff --git a/fs/configfs/inode.c b/fs/configfs/inode.c index fb18917954a9..2ec9beac17cf 100644 --- a/fs/configfs/inode.c +++ b/fs/configfs/inode.c | |||
@@ -49,7 +49,7 @@ static struct backing_dev_info configfs_backing_dev_info = { | |||
49 | .capabilities = BDI_CAP_NO_ACCT_DIRTY | BDI_CAP_NO_WRITEBACK, | 49 | .capabilities = BDI_CAP_NO_ACCT_DIRTY | BDI_CAP_NO_WRITEBACK, |
50 | }; | 50 | }; |
51 | 51 | ||
52 | static struct inode_operations configfs_inode_operations ={ | 52 | static const struct inode_operations configfs_inode_operations ={ |
53 | .setattr = configfs_setattr, | 53 | .setattr = configfs_setattr, |
54 | }; | 54 | }; |
55 | 55 | ||
diff --git a/fs/configfs/symlink.c b/fs/configfs/symlink.c index fb65e0800a86..22700d2857da 100644 --- a/fs/configfs/symlink.c +++ b/fs/configfs/symlink.c | |||
@@ -272,7 +272,7 @@ static void configfs_put_link(struct dentry *dentry, struct nameidata *nd, | |||
272 | } | 272 | } |
273 | } | 273 | } |
274 | 274 | ||
275 | struct inode_operations configfs_symlink_inode_operations = { | 275 | const struct inode_operations configfs_symlink_inode_operations = { |
276 | .follow_link = configfs_follow_link, | 276 | .follow_link = configfs_follow_link, |
277 | .readlink = generic_readlink, | 277 | .readlink = generic_readlink, |
278 | .put_link = configfs_put_link, | 278 | .put_link = configfs_put_link, |
diff --git a/fs/cramfs/inode.c b/fs/cramfs/inode.c index 6db03fb089dc..0367d200a2de 100644 --- a/fs/cramfs/inode.c +++ b/fs/cramfs/inode.c | |||
@@ -28,7 +28,7 @@ | |||
28 | #include <asm/uaccess.h> | 28 | #include <asm/uaccess.h> |
29 | 29 | ||
30 | static struct super_operations cramfs_ops; | 30 | static struct super_operations cramfs_ops; |
31 | static struct inode_operations cramfs_dir_inode_operations; | 31 | static const struct inode_operations cramfs_dir_inode_operations; |
32 | static const struct file_operations cramfs_directory_operations; | 32 | static const struct file_operations cramfs_directory_operations; |
33 | static const struct address_space_operations cramfs_aops; | 33 | static const struct address_space_operations cramfs_aops; |
34 | 34 | ||
@@ -518,7 +518,7 @@ static const struct file_operations cramfs_directory_operations = { | |||
518 | .readdir = cramfs_readdir, | 518 | .readdir = cramfs_readdir, |
519 | }; | 519 | }; |
520 | 520 | ||
521 | static struct inode_operations cramfs_dir_inode_operations = { | 521 | static const struct inode_operations cramfs_dir_inode_operations = { |
522 | .lookup = cramfs_lookup, | 522 | .lookup = cramfs_lookup, |
523 | }; | 523 | }; |
524 | 524 | ||
diff --git a/fs/ecryptfs/ecryptfs_kernel.h b/fs/ecryptfs/ecryptfs_kernel.h index 839a34fa6fab..275445d17162 100644 --- a/fs/ecryptfs/ecryptfs_kernel.h +++ b/fs/ecryptfs/ecryptfs_kernel.h | |||
@@ -446,9 +446,9 @@ void __ecryptfs_printk(const char *fmt, ...); | |||
446 | 446 | ||
447 | extern const struct file_operations ecryptfs_main_fops; | 447 | extern const struct file_operations ecryptfs_main_fops; |
448 | extern const struct file_operations ecryptfs_dir_fops; | 448 | extern const struct file_operations ecryptfs_dir_fops; |
449 | extern struct inode_operations ecryptfs_main_iops; | 449 | extern const struct inode_operations ecryptfs_main_iops; |
450 | extern struct inode_operations ecryptfs_dir_iops; | 450 | extern const struct inode_operations ecryptfs_dir_iops; |
451 | extern struct inode_operations ecryptfs_symlink_iops; | 451 | extern const struct inode_operations ecryptfs_symlink_iops; |
452 | extern struct super_operations ecryptfs_sops; | 452 | extern struct super_operations ecryptfs_sops; |
453 | extern struct dentry_operations ecryptfs_dops; | 453 | extern struct dentry_operations ecryptfs_dops; |
454 | extern struct address_space_operations ecryptfs_aops; | 454 | extern struct address_space_operations ecryptfs_aops; |
diff --git a/fs/ecryptfs/inode.c b/fs/ecryptfs/inode.c index 91357183398d..9fa7e0b27a96 100644 --- a/fs/ecryptfs/inode.c +++ b/fs/ecryptfs/inode.c | |||
@@ -989,7 +989,7 @@ int ecryptfs_inode_set(struct inode *inode, void *lower_inode) | |||
989 | return 0; | 989 | return 0; |
990 | } | 990 | } |
991 | 991 | ||
992 | struct inode_operations ecryptfs_symlink_iops = { | 992 | const struct inode_operations ecryptfs_symlink_iops = { |
993 | .readlink = ecryptfs_readlink, | 993 | .readlink = ecryptfs_readlink, |
994 | .follow_link = ecryptfs_follow_link, | 994 | .follow_link = ecryptfs_follow_link, |
995 | .put_link = ecryptfs_put_link, | 995 | .put_link = ecryptfs_put_link, |
@@ -1001,7 +1001,7 @@ struct inode_operations ecryptfs_symlink_iops = { | |||
1001 | .removexattr = ecryptfs_removexattr | 1001 | .removexattr = ecryptfs_removexattr |
1002 | }; | 1002 | }; |
1003 | 1003 | ||
1004 | struct inode_operations ecryptfs_dir_iops = { | 1004 | const struct inode_operations ecryptfs_dir_iops = { |
1005 | .create = ecryptfs_create, | 1005 | .create = ecryptfs_create, |
1006 | .lookup = ecryptfs_lookup, | 1006 | .lookup = ecryptfs_lookup, |
1007 | .link = ecryptfs_link, | 1007 | .link = ecryptfs_link, |
@@ -1019,7 +1019,7 @@ struct inode_operations ecryptfs_dir_iops = { | |||
1019 | .removexattr = ecryptfs_removexattr | 1019 | .removexattr = ecryptfs_removexattr |
1020 | }; | 1020 | }; |
1021 | 1021 | ||
1022 | struct inode_operations ecryptfs_main_iops = { | 1022 | const struct inode_operations ecryptfs_main_iops = { |
1023 | .permission = ecryptfs_permission, | 1023 | .permission = ecryptfs_permission, |
1024 | .setattr = ecryptfs_setattr, | 1024 | .setattr = ecryptfs_setattr, |
1025 | .setxattr = ecryptfs_setxattr, | 1025 | .setxattr = ecryptfs_setxattr, |
diff --git a/fs/efs/dir.c b/fs/efs/dir.c index b46c488eefc8..dfb5cb400217 100644 --- a/fs/efs/dir.c +++ b/fs/efs/dir.c | |||
@@ -15,7 +15,7 @@ const struct file_operations efs_dir_operations = { | |||
15 | .readdir = efs_readdir, | 15 | .readdir = efs_readdir, |
16 | }; | 16 | }; |
17 | 17 | ||
18 | struct inode_operations efs_dir_inode_operations = { | 18 | const struct inode_operations efs_dir_inode_operations = { |
19 | .lookup = efs_lookup, | 19 | .lookup = efs_lookup, |
20 | }; | 20 | }; |
21 | 21 | ||
diff --git a/fs/ext2/ext2.h b/fs/ext2/ext2.h index c19ac153f56b..e2a0ea50af1d 100644 --- a/fs/ext2/ext2.h +++ b/fs/ext2/ext2.h | |||
@@ -158,7 +158,7 @@ extern void ext2_write_super (struct super_block *); | |||
158 | extern const struct file_operations ext2_dir_operations; | 158 | extern const struct file_operations ext2_dir_operations; |
159 | 159 | ||
160 | /* file.c */ | 160 | /* file.c */ |
161 | extern struct inode_operations ext2_file_inode_operations; | 161 | extern const struct inode_operations ext2_file_inode_operations; |
162 | extern const struct file_operations ext2_file_operations; | 162 | extern const struct file_operations ext2_file_operations; |
163 | extern const struct file_operations ext2_xip_file_operations; | 163 | extern const struct file_operations ext2_xip_file_operations; |
164 | 164 | ||
@@ -168,9 +168,9 @@ extern const struct address_space_operations ext2_aops_xip; | |||
168 | extern const struct address_space_operations ext2_nobh_aops; | 168 | extern const struct address_space_operations ext2_nobh_aops; |
169 | 169 | ||
170 | /* namei.c */ | 170 | /* namei.c */ |
171 | extern struct inode_operations ext2_dir_inode_operations; | 171 | extern const struct inode_operations ext2_dir_inode_operations; |
172 | extern struct inode_operations ext2_special_inode_operations; | 172 | extern const struct inode_operations ext2_special_inode_operations; |
173 | 173 | ||
174 | /* symlink.c */ | 174 | /* symlink.c */ |
175 | extern struct inode_operations ext2_fast_symlink_inode_operations; | 175 | extern const struct inode_operations ext2_fast_symlink_inode_operations; |
176 | extern struct inode_operations ext2_symlink_inode_operations; | 176 | extern const struct inode_operations ext2_symlink_inode_operations; |
diff --git a/fs/ext2/file.c b/fs/ext2/file.c index 2dba473c524a..566d4e2d3852 100644 --- a/fs/ext2/file.c +++ b/fs/ext2/file.c | |||
@@ -75,7 +75,7 @@ const struct file_operations ext2_xip_file_operations = { | |||
75 | }; | 75 | }; |
76 | #endif | 76 | #endif |
77 | 77 | ||
78 | struct inode_operations ext2_file_inode_operations = { | 78 | const struct inode_operations ext2_file_inode_operations = { |
79 | .truncate = ext2_truncate, | 79 | .truncate = ext2_truncate, |
80 | #ifdef CONFIG_EXT2_FS_XATTR | 80 | #ifdef CONFIG_EXT2_FS_XATTR |
81 | .setxattr = generic_setxattr, | 81 | .setxattr = generic_setxattr, |
diff --git a/fs/ext2/namei.c b/fs/ext2/namei.c index e1af5b4cf80c..e69beed839ac 100644 --- a/fs/ext2/namei.c +++ b/fs/ext2/namei.c | |||
@@ -373,7 +373,7 @@ out: | |||
373 | return err; | 373 | return err; |
374 | } | 374 | } |
375 | 375 | ||
376 | struct inode_operations ext2_dir_inode_operations = { | 376 | const struct inode_operations ext2_dir_inode_operations = { |
377 | .create = ext2_create, | 377 | .create = ext2_create, |
378 | .lookup = ext2_lookup, | 378 | .lookup = ext2_lookup, |
379 | .link = ext2_link, | 379 | .link = ext2_link, |
@@ -393,7 +393,7 @@ struct inode_operations ext2_dir_inode_operations = { | |||
393 | .permission = ext2_permission, | 393 | .permission = ext2_permission, |
394 | }; | 394 | }; |
395 | 395 | ||
396 | struct inode_operations ext2_special_inode_operations = { | 396 | const struct inode_operations ext2_special_inode_operations = { |
397 | #ifdef CONFIG_EXT2_FS_XATTR | 397 | #ifdef CONFIG_EXT2_FS_XATTR |
398 | .setxattr = generic_setxattr, | 398 | .setxattr = generic_setxattr, |
399 | .getxattr = generic_getxattr, | 399 | .getxattr = generic_getxattr, |
diff --git a/fs/ext2/symlink.c b/fs/ext2/symlink.c index 1e67d87cfa91..4e2426e22bbe 100644 --- a/fs/ext2/symlink.c +++ b/fs/ext2/symlink.c | |||
@@ -28,7 +28,7 @@ static void *ext2_follow_link(struct dentry *dentry, struct nameidata *nd) | |||
28 | return NULL; | 28 | return NULL; |
29 | } | 29 | } |
30 | 30 | ||
31 | struct inode_operations ext2_symlink_inode_operations = { | 31 | const struct inode_operations ext2_symlink_inode_operations = { |
32 | .readlink = generic_readlink, | 32 | .readlink = generic_readlink, |
33 | .follow_link = page_follow_link_light, | 33 | .follow_link = page_follow_link_light, |
34 | .put_link = page_put_link, | 34 | .put_link = page_put_link, |
@@ -40,7 +40,7 @@ struct inode_operations ext2_symlink_inode_operations = { | |||
40 | #endif | 40 | #endif |
41 | }; | 41 | }; |
42 | 42 | ||
43 | struct inode_operations ext2_fast_symlink_inode_operations = { | 43 | const struct inode_operations ext2_fast_symlink_inode_operations = { |
44 | .readlink = generic_readlink, | 44 | .readlink = generic_readlink, |
45 | .follow_link = ext2_follow_link, | 45 | .follow_link = ext2_follow_link, |
46 | #ifdef CONFIG_EXT2_FS_XATTR | 46 | #ifdef CONFIG_EXT2_FS_XATTR |
diff --git a/fs/ext3/file.c b/fs/ext3/file.c index 881f6365c41a..1e6f13864536 100644 --- a/fs/ext3/file.c +++ b/fs/ext3/file.c | |||
@@ -125,7 +125,7 @@ const struct file_operations ext3_file_operations = { | |||
125 | .splice_write = generic_file_splice_write, | 125 | .splice_write = generic_file_splice_write, |
126 | }; | 126 | }; |
127 | 127 | ||
128 | struct inode_operations ext3_file_inode_operations = { | 128 | const struct inode_operations ext3_file_inode_operations = { |
129 | .truncate = ext3_truncate, | 129 | .truncate = ext3_truncate, |
130 | .setattr = ext3_setattr, | 130 | .setattr = ext3_setattr, |
131 | #ifdef CONFIG_EXT3_FS_XATTR | 131 | #ifdef CONFIG_EXT3_FS_XATTR |
diff --git a/fs/ext3/namei.c b/fs/ext3/namei.c index a8e89328e66d..49159f13cc1f 100644 --- a/fs/ext3/namei.c +++ b/fs/ext3/namei.c | |||
@@ -2365,7 +2365,7 @@ end_rename: | |||
2365 | /* | 2365 | /* |
2366 | * directories can handle most operations... | 2366 | * directories can handle most operations... |
2367 | */ | 2367 | */ |
2368 | struct inode_operations ext3_dir_inode_operations = { | 2368 | const struct inode_operations ext3_dir_inode_operations = { |
2369 | .create = ext3_create, | 2369 | .create = ext3_create, |
2370 | .lookup = ext3_lookup, | 2370 | .lookup = ext3_lookup, |
2371 | .link = ext3_link, | 2371 | .link = ext3_link, |
@@ -2385,7 +2385,7 @@ struct inode_operations ext3_dir_inode_operations = { | |||
2385 | .permission = ext3_permission, | 2385 | .permission = ext3_permission, |
2386 | }; | 2386 | }; |
2387 | 2387 | ||
2388 | struct inode_operations ext3_special_inode_operations = { | 2388 | const struct inode_operations ext3_special_inode_operations = { |
2389 | .setattr = ext3_setattr, | 2389 | .setattr = ext3_setattr, |
2390 | #ifdef CONFIG_EXT3_FS_XATTR | 2390 | #ifdef CONFIG_EXT3_FS_XATTR |
2391 | .setxattr = generic_setxattr, | 2391 | .setxattr = generic_setxattr, |
diff --git a/fs/ext3/symlink.c b/fs/ext3/symlink.c index 4f79122cde67..ff7b4ccd8983 100644 --- a/fs/ext3/symlink.c +++ b/fs/ext3/symlink.c | |||
@@ -30,7 +30,7 @@ static void * ext3_follow_link(struct dentry *dentry, struct nameidata *nd) | |||
30 | return NULL; | 30 | return NULL; |
31 | } | 31 | } |
32 | 32 | ||
33 | struct inode_operations ext3_symlink_inode_operations = { | 33 | const struct inode_operations ext3_symlink_inode_operations = { |
34 | .readlink = generic_readlink, | 34 | .readlink = generic_readlink, |
35 | .follow_link = page_follow_link_light, | 35 | .follow_link = page_follow_link_light, |
36 | .put_link = page_put_link, | 36 | .put_link = page_put_link, |
@@ -42,7 +42,7 @@ struct inode_operations ext3_symlink_inode_operations = { | |||
42 | #endif | 42 | #endif |
43 | }; | 43 | }; |
44 | 44 | ||
45 | struct inode_operations ext3_fast_symlink_inode_operations = { | 45 | const struct inode_operations ext3_fast_symlink_inode_operations = { |
46 | .readlink = generic_readlink, | 46 | .readlink = generic_readlink, |
47 | .follow_link = ext3_follow_link, | 47 | .follow_link = ext3_follow_link, |
48 | #ifdef CONFIG_EXT3_FS_XATTR | 48 | #ifdef CONFIG_EXT3_FS_XATTR |
diff --git a/fs/ext4/file.c b/fs/ext4/file.c index 3bbc24b58785..3c6c1fd2be90 100644 --- a/fs/ext4/file.c +++ b/fs/ext4/file.c | |||
@@ -125,7 +125,7 @@ const struct file_operations ext4_file_operations = { | |||
125 | .splice_write = generic_file_splice_write, | 125 | .splice_write = generic_file_splice_write, |
126 | }; | 126 | }; |
127 | 127 | ||
128 | struct inode_operations ext4_file_inode_operations = { | 128 | const struct inode_operations ext4_file_inode_operations = { |
129 | .truncate = ext4_truncate, | 129 | .truncate = ext4_truncate, |
130 | .setattr = ext4_setattr, | 130 | .setattr = ext4_setattr, |
131 | #ifdef CONFIG_EXT4DEV_FS_XATTR | 131 | #ifdef CONFIG_EXT4DEV_FS_XATTR |
diff --git a/fs/ext4/namei.c b/fs/ext4/namei.c index 34b3448b40f9..e7e1d79a7d75 100644 --- a/fs/ext4/namei.c +++ b/fs/ext4/namei.c | |||
@@ -2363,7 +2363,7 @@ end_rename: | |||
2363 | /* | 2363 | /* |
2364 | * directories can handle most operations... | 2364 | * directories can handle most operations... |
2365 | */ | 2365 | */ |
2366 | struct inode_operations ext4_dir_inode_operations = { | 2366 | const struct inode_operations ext4_dir_inode_operations = { |
2367 | .create = ext4_create, | 2367 | .create = ext4_create, |
2368 | .lookup = ext4_lookup, | 2368 | .lookup = ext4_lookup, |
2369 | .link = ext4_link, | 2369 | .link = ext4_link, |
@@ -2383,7 +2383,7 @@ struct inode_operations ext4_dir_inode_operations = { | |||
2383 | .permission = ext4_permission, | 2383 | .permission = ext4_permission, |
2384 | }; | 2384 | }; |
2385 | 2385 | ||
2386 | struct inode_operations ext4_special_inode_operations = { | 2386 | const struct inode_operations ext4_special_inode_operations = { |
2387 | .setattr = ext4_setattr, | 2387 | .setattr = ext4_setattr, |
2388 | #ifdef CONFIG_EXT4DEV_FS_XATTR | 2388 | #ifdef CONFIG_EXT4DEV_FS_XATTR |
2389 | .setxattr = generic_setxattr, | 2389 | .setxattr = generic_setxattr, |
diff --git a/fs/ext4/symlink.c b/fs/ext4/symlink.c index fcf527286d75..e6f9da4287c4 100644 --- a/fs/ext4/symlink.c +++ b/fs/ext4/symlink.c | |||
@@ -30,7 +30,7 @@ static void * ext4_follow_link(struct dentry *dentry, struct nameidata *nd) | |||
30 | return NULL; | 30 | return NULL; |
31 | } | 31 | } |
32 | 32 | ||
33 | struct inode_operations ext4_symlink_inode_operations = { | 33 | const struct inode_operations ext4_symlink_inode_operations = { |
34 | .readlink = generic_readlink, | 34 | .readlink = generic_readlink, |
35 | .follow_link = page_follow_link_light, | 35 | .follow_link = page_follow_link_light, |
36 | .put_link = page_put_link, | 36 | .put_link = page_put_link, |
@@ -42,7 +42,7 @@ struct inode_operations ext4_symlink_inode_operations = { | |||
42 | #endif | 42 | #endif |
43 | }; | 43 | }; |
44 | 44 | ||
45 | struct inode_operations ext4_fast_symlink_inode_operations = { | 45 | const struct inode_operations ext4_fast_symlink_inode_operations = { |
46 | .readlink = generic_readlink, | 46 | .readlink = generic_readlink, |
47 | .follow_link = ext4_follow_link, | 47 | .follow_link = ext4_follow_link, |
48 | #ifdef CONFIG_EXT4DEV_FS_XATTR | 48 | #ifdef CONFIG_EXT4DEV_FS_XATTR |
diff --git a/fs/fat/file.c b/fs/fat/file.c index c1237b70c1fe..55d3c7461c5b 100644 --- a/fs/fat/file.c +++ b/fs/fat/file.c | |||
@@ -312,7 +312,7 @@ int fat_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat) | |||
312 | } | 312 | } |
313 | EXPORT_SYMBOL_GPL(fat_getattr); | 313 | EXPORT_SYMBOL_GPL(fat_getattr); |
314 | 314 | ||
315 | struct inode_operations fat_file_inode_operations = { | 315 | const struct inode_operations fat_file_inode_operations = { |
316 | .truncate = fat_truncate, | 316 | .truncate = fat_truncate, |
317 | .setattr = fat_notify_change, | 317 | .setattr = fat_notify_change, |
318 | .getattr = fat_getattr, | 318 | .getattr = fat_getattr, |
diff --git a/fs/fat/inode.c b/fs/fat/inode.c index a9e4688582a2..f268fec6ed0a 100644 --- a/fs/fat/inode.c +++ b/fs/fat/inode.c | |||
@@ -1151,7 +1151,7 @@ static int fat_read_root(struct inode *inode) | |||
1151 | * Read the super block of an MS-DOS FS. | 1151 | * Read the super block of an MS-DOS FS. |
1152 | */ | 1152 | */ |
1153 | int fat_fill_super(struct super_block *sb, void *data, int silent, | 1153 | int fat_fill_super(struct super_block *sb, void *data, int silent, |
1154 | struct inode_operations *fs_dir_inode_ops, int isvfat) | 1154 | const struct inode_operations *fs_dir_inode_ops, int isvfat) |
1155 | { | 1155 | { |
1156 | struct inode *root_inode = NULL; | 1156 | struct inode *root_inode = NULL; |
1157 | struct buffer_head *bh; | 1157 | struct buffer_head *bh; |
diff --git a/fs/freevxfs/vxfs_extern.h b/fs/freevxfs/vxfs_extern.h index 1cf1fe8466a2..91ccee8723f7 100644 --- a/fs/freevxfs/vxfs_extern.h +++ b/fs/freevxfs/vxfs_extern.h | |||
@@ -62,7 +62,7 @@ extern void vxfs_read_inode(struct inode *); | |||
62 | extern void vxfs_clear_inode(struct inode *); | 62 | extern void vxfs_clear_inode(struct inode *); |
63 | 63 | ||
64 | /* vxfs_lookup.c */ | 64 | /* vxfs_lookup.c */ |
65 | extern struct inode_operations vxfs_dir_inode_ops; | 65 | extern const struct inode_operations vxfs_dir_inode_ops; |
66 | extern const struct file_operations vxfs_dir_operations; | 66 | extern const struct file_operations vxfs_dir_operations; |
67 | 67 | ||
68 | /* vxfs_olt.c */ | 68 | /* vxfs_olt.c */ |
diff --git a/fs/freevxfs/vxfs_immed.c b/fs/freevxfs/vxfs_immed.c index 4e25f3fbed86..24b5a775ff96 100644 --- a/fs/freevxfs/vxfs_immed.c +++ b/fs/freevxfs/vxfs_immed.c | |||
@@ -48,7 +48,7 @@ static int vxfs_immed_readpage(struct file *, struct page *); | |||
48 | * Unliked all other operations we do not go through the pagecache, | 48 | * Unliked all other operations we do not go through the pagecache, |
49 | * but do all work directly on the inode. | 49 | * but do all work directly on the inode. |
50 | */ | 50 | */ |
51 | struct inode_operations vxfs_immed_symlink_iops = { | 51 | const struct inode_operations vxfs_immed_symlink_iops = { |
52 | .readlink = generic_readlink, | 52 | .readlink = generic_readlink, |
53 | .follow_link = vxfs_immed_follow_link, | 53 | .follow_link = vxfs_immed_follow_link, |
54 | }; | 54 | }; |
diff --git a/fs/freevxfs/vxfs_inode.c b/fs/freevxfs/vxfs_inode.c index 0b7ae897cb78..098a915fd9a1 100644 --- a/fs/freevxfs/vxfs_inode.c +++ b/fs/freevxfs/vxfs_inode.c | |||
@@ -44,7 +44,7 @@ | |||
44 | extern const struct address_space_operations vxfs_aops; | 44 | extern const struct address_space_operations vxfs_aops; |
45 | extern const struct address_space_operations vxfs_immed_aops; | 45 | extern const struct address_space_operations vxfs_immed_aops; |
46 | 46 | ||
47 | extern struct inode_operations vxfs_immed_symlink_iops; | 47 | extern const struct inode_operations vxfs_immed_symlink_iops; |
48 | 48 | ||
49 | struct kmem_cache *vxfs_inode_cachep; | 49 | struct kmem_cache *vxfs_inode_cachep; |
50 | 50 | ||
diff --git a/fs/freevxfs/vxfs_lookup.c b/fs/freevxfs/vxfs_lookup.c index 3995d7fbedab..bf86e5444ea6 100644 --- a/fs/freevxfs/vxfs_lookup.c +++ b/fs/freevxfs/vxfs_lookup.c | |||
@@ -52,7 +52,7 @@ | |||
52 | static struct dentry * vxfs_lookup(struct inode *, struct dentry *, struct nameidata *); | 52 | static struct dentry * vxfs_lookup(struct inode *, struct dentry *, struct nameidata *); |
53 | static int vxfs_readdir(struct file *, void *, filldir_t); | 53 | static int vxfs_readdir(struct file *, void *, filldir_t); |
54 | 54 | ||
55 | struct inode_operations vxfs_dir_inode_ops = { | 55 | const struct inode_operations vxfs_dir_inode_ops = { |
56 | .lookup = vxfs_lookup, | 56 | .lookup = vxfs_lookup, |
57 | }; | 57 | }; |
58 | 58 | ||
diff --git a/fs/fuse/control.c b/fs/fuse/control.c index 1794305f9ed8..105d4a271e07 100644 --- a/fs/fuse/control.c +++ b/fs/fuse/control.c | |||
@@ -73,7 +73,7 @@ static struct dentry *fuse_ctl_add_dentry(struct dentry *parent, | |||
73 | struct fuse_conn *fc, | 73 | struct fuse_conn *fc, |
74 | const char *name, | 74 | const char *name, |
75 | int mode, int nlink, | 75 | int mode, int nlink, |
76 | struct inode_operations *iop, | 76 | const struct inode_operations *iop, |
77 | const struct file_operations *fop) | 77 | const struct file_operations *fop) |
78 | { | 78 | { |
79 | struct dentry *dentry; | 79 | struct dentry *dentry; |
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c index 40080477ceb4..406bf61ed510 100644 --- a/fs/fuse/dir.c +++ b/fs/fuse/dir.c | |||
@@ -1242,7 +1242,7 @@ static int fuse_removexattr(struct dentry *entry, const char *name) | |||
1242 | return err; | 1242 | return err; |
1243 | } | 1243 | } |
1244 | 1244 | ||
1245 | static struct inode_operations fuse_dir_inode_operations = { | 1245 | static const struct inode_operations fuse_dir_inode_operations = { |
1246 | .lookup = fuse_lookup, | 1246 | .lookup = fuse_lookup, |
1247 | .mkdir = fuse_mkdir, | 1247 | .mkdir = fuse_mkdir, |
1248 | .symlink = fuse_symlink, | 1248 | .symlink = fuse_symlink, |
@@ -1270,7 +1270,7 @@ static const struct file_operations fuse_dir_operations = { | |||
1270 | .fsync = fuse_dir_fsync, | 1270 | .fsync = fuse_dir_fsync, |
1271 | }; | 1271 | }; |
1272 | 1272 | ||
1273 | static struct inode_operations fuse_common_inode_operations = { | 1273 | static const struct inode_operations fuse_common_inode_operations = { |
1274 | .setattr = fuse_setattr, | 1274 | .setattr = fuse_setattr, |
1275 | .permission = fuse_permission, | 1275 | .permission = fuse_permission, |
1276 | .getattr = fuse_getattr, | 1276 | .getattr = fuse_getattr, |
@@ -1280,7 +1280,7 @@ static struct inode_operations fuse_common_inode_operations = { | |||
1280 | .removexattr = fuse_removexattr, | 1280 | .removexattr = fuse_removexattr, |
1281 | }; | 1281 | }; |
1282 | 1282 | ||
1283 | static struct inode_operations fuse_symlink_inode_operations = { | 1283 | static const struct inode_operations fuse_symlink_inode_operations = { |
1284 | .setattr = fuse_setattr, | 1284 | .setattr = fuse_setattr, |
1285 | .follow_link = fuse_follow_link, | 1285 | .follow_link = fuse_follow_link, |
1286 | .put_link = fuse_put_link, | 1286 | .put_link = fuse_put_link, |