mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
[PATCH] mark struct inode_operations const 3
Many struct inode_operations in the kernel can be "const". Marking them const moves these to the .rodata section, which avoids false sharing with potential dirty data. In addition it'll catch accidental writes at compile time to these shared resources. Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
92e1d5be91
commit
c5ef1c42c5
48 changed files with 103 additions and 103 deletions
|
@ -331,9 +331,9 @@ static inline void nfs_fattr_init(struct nfs_fattr *fattr)
|
|||
/*
|
||||
* linux/fs/nfs/file.c
|
||||
*/
|
||||
extern struct inode_operations nfs_file_inode_operations;
|
||||
extern const struct inode_operations nfs_file_inode_operations;
|
||||
#ifdef CONFIG_NFS_V3
|
||||
extern struct inode_operations nfs3_file_inode_operations;
|
||||
extern const struct inode_operations nfs3_file_inode_operations;
|
||||
#endif /* CONFIG_NFS_V3 */
|
||||
extern const struct file_operations nfs_file_operations;
|
||||
extern const struct address_space_operations nfs_file_aops;
|
||||
|
@ -380,9 +380,9 @@ extern ssize_t nfs_file_direct_write(struct kiocb *iocb,
|
|||
/*
|
||||
* linux/fs/nfs/dir.c
|
||||
*/
|
||||
extern struct inode_operations nfs_dir_inode_operations;
|
||||
extern const struct inode_operations nfs_dir_inode_operations;
|
||||
#ifdef CONFIG_NFS_V3
|
||||
extern struct inode_operations nfs3_dir_inode_operations;
|
||||
extern const struct inode_operations nfs3_dir_inode_operations;
|
||||
#endif /* CONFIG_NFS_V3 */
|
||||
extern const struct file_operations nfs_dir_operations;
|
||||
extern struct dentry_operations nfs_dentry_operations;
|
||||
|
@ -392,7 +392,7 @@ extern int nfs_instantiate(struct dentry *dentry, struct nfs_fh *fh, struct nfs_
|
|||
/*
|
||||
* linux/fs/nfs/symlink.c
|
||||
*/
|
||||
extern struct inode_operations nfs_symlink_inode_operations;
|
||||
extern const struct inode_operations nfs_symlink_inode_operations;
|
||||
|
||||
/*
|
||||
* linux/fs/nfs/sysctl.c
|
||||
|
@ -409,8 +409,8 @@ extern void nfs_unregister_sysctl(void);
|
|||
* linux/fs/nfs/namespace.c
|
||||
*/
|
||||
extern struct list_head nfs_automount_list;
|
||||
extern struct inode_operations nfs_mountpoint_inode_operations;
|
||||
extern struct inode_operations nfs_referral_inode_operations;
|
||||
extern const struct inode_operations nfs_mountpoint_inode_operations;
|
||||
extern const struct inode_operations nfs_referral_inode_operations;
|
||||
extern int nfs_mountpoint_expiry_timeout;
|
||||
extern void nfs_release_automount_timer(void);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue