Skip to content

Commit

Permalink
Merge tag 'vfs-6.7.xattr' of gitolite.kernel.org:pub/scm/linux/kernel…
Browse files Browse the repository at this point in the history
…/git/vfs/vfs

Pull vfs xattr updates from Christian Brauner:
 "The 's_xattr' field of 'struct super_block' currently requires a
  mutable table of 'struct xattr_handler' entries (although each handler
  itself is const). However, no code in vfs actually modifies the
  tables.

  This changes the type of 's_xattr' to allow const tables, and modifies
  existing file systems to move their tables to .rodata. This is
  desirable because these tables contain entries with function pointers
  in them; moving them to .rodata makes it considerably less likely to
  be modified accidentally or maliciously at runtime"

* tag 'vfs-6.7.xattr' of gitolite.kernel.org:pub/scm/linux/kernel/git/vfs/vfs: (30 commits)
  const_structs.checkpatch: add xattr_handler
  net: move sockfs_xattr_handlers to .rodata
  shmem: move shmem_xattr_handlers to .rodata
  overlayfs: move xattr tables to .rodata
  xfs: move xfs_xattr_handlers to .rodata
  ubifs: move ubifs_xattr_handlers to .rodata
  squashfs: move squashfs_xattr_handlers to .rodata
  smb: move cifs_xattr_handlers to .rodata
  reiserfs: move reiserfs_xattr_handlers to .rodata
  orangefs: move orangefs_xattr_handlers to .rodata
  ocfs2: move ocfs2_xattr_handlers and ocfs2_xattr_handler_map to .rodata
  ntfs3: move ntfs_xattr_handlers to .rodata
  nfs: move nfs4_xattr_handlers to .rodata
  kernfs: move kernfs_xattr_handlers to .rodata
  jfs: move jfs_xattr_handlers to .rodata
  jffs2: move jffs2_xattr_handlers to .rodata
  hfsplus: move hfsplus_xattr_handlers to .rodata
  hfs: move hfs_xattr_handlers to .rodata
  gfs2: move gfs2_xattr_handlers_max to .rodata
  fuse: move fuse_xattr_handlers to .rodata
  ...
  • Loading branch information
torvalds committed Oct 30, 2023
2 parents df9c65b + a640d88 commit 7352a67
Show file tree
Hide file tree
Showing 58 changed files with 71 additions and 70 deletions.
8 changes: 4 additions & 4 deletions fs/9p/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -162,27 +162,27 @@ static int v9fs_xattr_handler_set(const struct xattr_handler *handler,
return v9fs_xattr_set(dentry, full_name, value, size, flags);
}

static struct xattr_handler v9fs_xattr_user_handler = {
static const struct xattr_handler v9fs_xattr_user_handler = {
.prefix = XATTR_USER_PREFIX,
.get = v9fs_xattr_handler_get,
.set = v9fs_xattr_handler_set,
};

static struct xattr_handler v9fs_xattr_trusted_handler = {
static const struct xattr_handler v9fs_xattr_trusted_handler = {
.prefix = XATTR_TRUSTED_PREFIX,
.get = v9fs_xattr_handler_get,
.set = v9fs_xattr_handler_set,
};

#ifdef CONFIG_9P_FS_SECURITY
static struct xattr_handler v9fs_xattr_security_handler = {
static const struct xattr_handler v9fs_xattr_security_handler = {
.prefix = XATTR_SECURITY_PREFIX,
.get = v9fs_xattr_handler_get,
.set = v9fs_xattr_handler_set,
};
#endif

const struct xattr_handler *v9fs_xattr_handlers[] = {
const struct xattr_handler * const v9fs_xattr_handlers[] = {
&v9fs_xattr_user_handler,
&v9fs_xattr_trusted_handler,
#ifdef CONFIG_9P_FS_SECURITY
Expand Down
2 changes: 1 addition & 1 deletion fs/9p/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <net/9p/9p.h>
#include <net/9p/client.h>

extern const struct xattr_handler *v9fs_xattr_handlers[];
extern const struct xattr_handler * const v9fs_xattr_handlers[];

ssize_t v9fs_fid_xattr_get(struct p9_fid *fid, const char *name,
void *buffer, size_t buffer_size);
Expand Down
2 changes: 1 addition & 1 deletion fs/afs/internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -1541,7 +1541,7 @@ int afs_launder_folio(struct folio *);
/*
* xattr.c
*/
extern const struct xattr_handler *afs_xattr_handlers[];
extern const struct xattr_handler * const afs_xattr_handlers[];

/*
* yfsclient.c
Expand Down
2 changes: 1 addition & 1 deletion fs/afs/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ static const struct xattr_handler afs_xattr_afs_volume_handler = {
.get = afs_xattr_get_volume,
};

const struct xattr_handler *afs_xattr_handlers[] = {
const struct xattr_handler * const afs_xattr_handlers[] = {
&afs_xattr_afs_acl_handler,
&afs_xattr_afs_cell_handler,
&afs_xattr_afs_fid_handler,
Expand Down
2 changes: 1 addition & 1 deletion fs/btrfs/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ static const struct xattr_handler btrfs_btrfs_xattr_handler = {
.set = btrfs_xattr_handler_set_prop,
};

const struct xattr_handler *btrfs_xattr_handlers[] = {
const struct xattr_handler * const btrfs_xattr_handlers[] = {
&btrfs_security_xattr_handler,
&btrfs_trusted_xattr_handler,
&btrfs_user_xattr_handler,
Expand Down
2 changes: 1 addition & 1 deletion fs/btrfs/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

#include <linux/xattr.h>

extern const struct xattr_handler *btrfs_xattr_handlers[];
extern const struct xattr_handler * const btrfs_xattr_handlers[];

int btrfs_getxattr(struct inode *inode, const char *name,
void *buffer, size_t size);
Expand Down
2 changes: 1 addition & 1 deletion fs/ceph/super.h
Original file line number Diff line number Diff line change
Expand Up @@ -1119,7 +1119,7 @@ ssize_t __ceph_getxattr(struct inode *, const char *, void *, size_t);
extern ssize_t ceph_listxattr(struct dentry *, char *, size_t);
extern struct ceph_buffer *__ceph_build_xattrs_blob(struct ceph_inode_info *ci);
extern void __ceph_destroy_xattrs(struct ceph_inode_info *ci);
extern const struct xattr_handler *ceph_xattr_handlers[];
extern const struct xattr_handler * const ceph_xattr_handlers[];

struct ceph_acl_sec_ctx {
#ifdef CONFIG_CEPH_FS_POSIX_ACL
Expand Down
2 changes: 1 addition & 1 deletion fs/ceph/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1446,7 +1446,7 @@ void ceph_release_acl_sec_ctx(struct ceph_acl_sec_ctx *as_ctx)
* List of handlers for synthetic system.* attributes. Other
* attributes are handled directly.
*/
const struct xattr_handler *ceph_xattr_handlers[] = {
const struct xattr_handler * const ceph_xattr_handlers[] = {
&ceph_other_xattr_handler,
NULL,
};
2 changes: 1 addition & 1 deletion fs/ecryptfs/ecryptfs_kernel.h
Original file line number Diff line number Diff line change
Expand Up @@ -702,6 +702,6 @@ int ecryptfs_set_f_namelen(long *namelen, long lower_namelen,
int ecryptfs_derive_iv(char *iv, struct ecryptfs_crypt_stat *crypt_stat,
loff_t offset);

extern const struct xattr_handler *ecryptfs_xattr_handlers[];
extern const struct xattr_handler * const ecryptfs_xattr_handlers[];

#endif /* #ifndef ECRYPTFS_KERNEL_H */
2 changes: 1 addition & 1 deletion fs/ecryptfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -1210,7 +1210,7 @@ static const struct xattr_handler ecryptfs_xattr_handler = {
.set = ecryptfs_xattr_set,
};

const struct xattr_handler *ecryptfs_xattr_handlers[] = {
const struct xattr_handler * const ecryptfs_xattr_handlers[] = {
&ecryptfs_xattr_handler,
NULL
};
2 changes: 1 addition & 1 deletion fs/erofs/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ const struct xattr_handler __maybe_unused erofs_xattr_security_handler = {
};
#endif

const struct xattr_handler *erofs_xattr_handlers[] = {
const struct xattr_handler * const erofs_xattr_handlers[] = {
&erofs_xattr_user_handler,
&erofs_xattr_trusted_handler,
#ifdef CONFIG_EROFS_FS_SECURITY
Expand Down
4 changes: 2 additions & 2 deletions fs/erofs/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ static inline const char *erofs_xattr_prefix(unsigned int idx,
{
const struct xattr_handler *handler = NULL;

static const struct xattr_handler *xattr_handler_map[] = {
static const struct xattr_handler * const xattr_handler_map[] = {
[EROFS_XATTR_INDEX_USER] = &erofs_xattr_user_handler,
#ifdef CONFIG_EROFS_FS_POSIX_ACL
[EROFS_XATTR_INDEX_POSIX_ACL_ACCESS] = &nop_posix_acl_access,
Expand All @@ -44,7 +44,7 @@ static inline const char *erofs_xattr_prefix(unsigned int idx,
return xattr_prefix(handler);
}

extern const struct xattr_handler *erofs_xattr_handlers[];
extern const struct xattr_handler * const erofs_xattr_handlers[];

int erofs_xattr_prefixes_init(struct super_block *sb);
void erofs_xattr_prefixes_cleanup(struct super_block *sb);
Expand Down
4 changes: 2 additions & 2 deletions fs/ext2/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ static struct buffer_head *ext2_xattr_cache_find(struct inode *,
static void ext2_xattr_rehash(struct ext2_xattr_header *,
struct ext2_xattr_entry *);

static const struct xattr_handler *ext2_xattr_handler_map[] = {
static const struct xattr_handler * const ext2_xattr_handler_map[] = {
[EXT2_XATTR_INDEX_USER] = &ext2_xattr_user_handler,
#ifdef CONFIG_EXT2_FS_POSIX_ACL
[EXT2_XATTR_INDEX_POSIX_ACL_ACCESS] = &nop_posix_acl_access,
Expand All @@ -110,7 +110,7 @@ static const struct xattr_handler *ext2_xattr_handler_map[] = {
#endif
};

const struct xattr_handler *ext2_xattr_handlers[] = {
const struct xattr_handler * const ext2_xattr_handlers[] = {
&ext2_xattr_user_handler,
&ext2_xattr_trusted_handler,
#ifdef CONFIG_EXT2_FS_SECURITY
Expand Down
2 changes: 1 addition & 1 deletion fs/ext2/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ extern void ext2_xattr_delete_inode(struct inode *);
extern struct mb_cache *ext2_xattr_create_cache(void);
extern void ext2_xattr_destroy_cache(struct mb_cache *cache);

extern const struct xattr_handler *ext2_xattr_handlers[];
extern const struct xattr_handler * const ext2_xattr_handlers[];

# else /* CONFIG_EXT2_FS_XATTR */

Expand Down
2 changes: 1 addition & 1 deletion fs/ext4/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ static const struct xattr_handler * const ext4_xattr_handler_map[] = {
[EXT4_XATTR_INDEX_HURD] = &ext4_xattr_hurd_handler,
};

const struct xattr_handler *ext4_xattr_handlers[] = {
const struct xattr_handler * const ext4_xattr_handlers[] = {
&ext4_xattr_user_handler,
&ext4_xattr_trusted_handler,
#ifdef CONFIG_EXT4_FS_SECURITY
Expand Down
2 changes: 1 addition & 1 deletion fs/ext4/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ extern int ext4_expand_extra_isize_ea(struct inode *inode, int new_extra_isize,
struct ext4_inode *raw_inode, handle_t *handle);
extern void ext4_evict_ea_inode(struct inode *inode);

extern const struct xattr_handler *ext4_xattr_handlers[];
extern const struct xattr_handler * const ext4_xattr_handlers[];

extern int ext4_xattr_ibody_find(struct inode *inode, struct ext4_xattr_info *i,
struct ext4_xattr_ibody_find *is);
Expand Down
4 changes: 2 additions & 2 deletions fs/f2fs/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ const struct xattr_handler f2fs_xattr_security_handler = {
.set = f2fs_xattr_generic_set,
};

static const struct xattr_handler *f2fs_xattr_handler_map[] = {
static const struct xattr_handler * const f2fs_xattr_handler_map[] = {
[F2FS_XATTR_INDEX_USER] = &f2fs_xattr_user_handler,
#ifdef CONFIG_F2FS_FS_POSIX_ACL
[F2FS_XATTR_INDEX_POSIX_ACL_ACCESS] = &nop_posix_acl_access,
Expand All @@ -202,7 +202,7 @@ static const struct xattr_handler *f2fs_xattr_handler_map[] = {
[F2FS_XATTR_INDEX_ADVISE] = &f2fs_xattr_advise_handler,
};

const struct xattr_handler *f2fs_xattr_handlers[] = {
const struct xattr_handler * const f2fs_xattr_handlers[] = {
&f2fs_xattr_user_handler,
&f2fs_xattr_trusted_handler,
#ifdef CONFIG_F2FS_FS_SECURITY
Expand Down
2 changes: 1 addition & 1 deletion fs/f2fs/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ extern const struct xattr_handler f2fs_xattr_trusted_handler;
extern const struct xattr_handler f2fs_xattr_advise_handler;
extern const struct xattr_handler f2fs_xattr_security_handler;

extern const struct xattr_handler *f2fs_xattr_handlers[];
extern const struct xattr_handler * const f2fs_xattr_handlers[];

extern int f2fs_setxattr(struct inode *, int, const char *,
const void *, size_t, struct page *, int);
Expand Down
2 changes: 1 addition & 1 deletion fs/fuse/fuse_i.h
Original file line number Diff line number Diff line change
Expand Up @@ -1284,7 +1284,7 @@ ssize_t fuse_getxattr(struct inode *inode, const char *name, void *value,
size_t size);
ssize_t fuse_listxattr(struct dentry *entry, char *list, size_t size);
int fuse_removexattr(struct inode *inode, const char *name);
extern const struct xattr_handler *fuse_xattr_handlers[];
extern const struct xattr_handler * const fuse_xattr_handlers[];

struct posix_acl;
struct posix_acl *fuse_get_inode_acl(struct inode *inode, int type, bool rcu);
Expand Down
2 changes: 1 addition & 1 deletion fs/fuse/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ static const struct xattr_handler fuse_xattr_handler = {
.set = fuse_xattr_set,
};

const struct xattr_handler *fuse_xattr_handlers[] = {
const struct xattr_handler * const fuse_xattr_handlers[] = {
&fuse_xattr_handler,
NULL
};
4 changes: 2 additions & 2 deletions fs/gfs2/super.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ extern const struct export_operations gfs2_export_ops;
extern const struct super_operations gfs2_super_ops;
extern const struct dentry_operations gfs2_dops;

extern const struct xattr_handler *gfs2_xattr_handlers_max[];
extern const struct xattr_handler **gfs2_xattr_handlers_min;
extern const struct xattr_handler * const gfs2_xattr_handlers_max[];
extern const struct xattr_handler * const *gfs2_xattr_handlers_min;

#endif /* __SUPER_DOT_H__ */

4 changes: 2 additions & 2 deletions fs/gfs2/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1494,7 +1494,7 @@ static const struct xattr_handler gfs2_xattr_trusted_handler = {
.set = gfs2_xattr_set,
};

const struct xattr_handler *gfs2_xattr_handlers_max[] = {
const struct xattr_handler * const gfs2_xattr_handlers_max[] = {
/* GFS2_FS_FORMAT_MAX */
&gfs2_xattr_trusted_handler,

Expand All @@ -1504,4 +1504,4 @@ const struct xattr_handler *gfs2_xattr_handlers_max[] = {
NULL,
};

const struct xattr_handler **gfs2_xattr_handlers_min = gfs2_xattr_handlers_max + 1;
const struct xattr_handler * const *gfs2_xattr_handlers_min = gfs2_xattr_handlers_max + 1;
2 changes: 1 addition & 1 deletion fs/hfs/attr.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ static const struct xattr_handler hfs_type_handler = {
.set = hfs_xattr_set,
};

const struct xattr_handler *hfs_xattr_handlers[] = {
const struct xattr_handler * const hfs_xattr_handlers[] = {
&hfs_creator_handler,
&hfs_type_handler,
NULL
Expand Down
2 changes: 1 addition & 1 deletion fs/hfs/hfs_fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ extern void hfs_evict_inode(struct inode *);
extern void hfs_delete_inode(struct inode *);

/* attr.c */
extern const struct xattr_handler *hfs_xattr_handlers[];
extern const struct xattr_handler * const hfs_xattr_handlers[];

/* mdb.c */
extern int hfs_mdb_get(struct super_block *);
Expand Down
2 changes: 1 addition & 1 deletion fs/hfsplus/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

static int hfsplus_removexattr(struct inode *inode, const char *name);

const struct xattr_handler *hfsplus_xattr_handlers[] = {
const struct xattr_handler * const hfsplus_xattr_handlers[] = {
&hfsplus_xattr_osx_handler,
&hfsplus_xattr_user_handler,
&hfsplus_xattr_trusted_handler,
Expand Down
2 changes: 1 addition & 1 deletion fs/hfsplus/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ extern const struct xattr_handler hfsplus_xattr_user_handler;
extern const struct xattr_handler hfsplus_xattr_trusted_handler;
extern const struct xattr_handler hfsplus_xattr_security_handler;

extern const struct xattr_handler *hfsplus_xattr_handlers[];
extern const struct xattr_handler * const hfsplus_xattr_handlers[];

int __hfsplus_setxattr(struct inode *inode, const char *name,
const void *value, size_t size, int flags);
Expand Down
2 changes: 1 addition & 1 deletion fs/jffs2/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -920,7 +920,7 @@ struct jffs2_xattr_datum *jffs2_setup_xattr_datum(struct jffs2_sb_info *c,
* do_jffs2_setxattr(inode, xprefix, xname, buffer, size, flags)
* is an implementation of setxattr handler on jffs2.
* -------------------------------------------------- */
const struct xattr_handler *jffs2_xattr_handlers[] = {
const struct xattr_handler * const jffs2_xattr_handlers[] = {
&jffs2_user_xattr_handler,
#ifdef CONFIG_JFFS2_FS_SECURITY
&jffs2_security_xattr_handler,
Expand Down
2 changes: 1 addition & 1 deletion fs/jffs2/xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ extern int do_jffs2_getxattr(struct inode *inode, int xprefix, const char *xname
extern int do_jffs2_setxattr(struct inode *inode, int xprefix, const char *xname,
const char *buffer, size_t size, int flags);

extern const struct xattr_handler *jffs2_xattr_handlers[];
extern const struct xattr_handler * const jffs2_xattr_handlers[];
extern const struct xattr_handler jffs2_user_xattr_handler;
extern const struct xattr_handler jffs2_trusted_xattr_handler;

Expand Down
2 changes: 1 addition & 1 deletion fs/jfs/jfs_xattr.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ extern int __jfs_setxattr(tid_t, struct inode *, const char *, const void *,
extern ssize_t __jfs_getxattr(struct inode *, const char *, void *, size_t);
extern ssize_t jfs_listxattr(struct dentry *, char *, size_t);

extern const struct xattr_handler *jfs_xattr_handlers[];
extern const struct xattr_handler * const jfs_xattr_handlers[];

#ifdef CONFIG_JFS_SECURITY
extern int jfs_init_security(tid_t, struct inode *, struct inode *,
Expand Down
2 changes: 1 addition & 1 deletion fs/jfs/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -985,7 +985,7 @@ static const struct xattr_handler jfs_trusted_xattr_handler = {
.set = jfs_xattr_set,
};

const struct xattr_handler *jfs_xattr_handlers[] = {
const struct xattr_handler * const jfs_xattr_handlers[] = {
&jfs_os2_xattr_handler,
&jfs_user_xattr_handler,
&jfs_security_xattr_handler,
Expand Down
2 changes: 1 addition & 1 deletion fs/kernfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ static const struct xattr_handler kernfs_user_xattr_handler = {
.set = kernfs_vfs_user_xattr_set,
};

const struct xattr_handler *kernfs_xattr_handlers[] = {
const struct xattr_handler * const kernfs_xattr_handlers[] = {
&kernfs_trusted_xattr_handler,
&kernfs_security_xattr_handler,
&kernfs_user_xattr_handler,
Expand Down
2 changes: 1 addition & 1 deletion fs/kernfs/kernfs-internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ extern struct kmem_cache *kernfs_node_cache, *kernfs_iattrs_cache;
/*
* inode.c
*/
extern const struct xattr_handler *kernfs_xattr_handlers[];
extern const struct xattr_handler * const kernfs_xattr_handlers[];
void kernfs_evict_inode(struct inode *inode);
int kernfs_iop_permission(struct mnt_idmap *idmap,
struct inode *inode, int mask);
Expand Down
2 changes: 1 addition & 1 deletion fs/nfs/nfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ struct nfs_subversion {
const struct rpc_version *rpc_vers; /* NFS version information */
const struct nfs_rpc_ops *rpc_ops; /* NFS operations */
const struct super_operations *sops; /* NFS Super operations */
const struct xattr_handler **xattr; /* NFS xattr handlers */
const struct xattr_handler * const *xattr; /* NFS xattr handlers */
struct list_head list; /* List of NFS versions */
};

Expand Down
2 changes: 1 addition & 1 deletion fs/nfs/nfs4_fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ extern struct rpc_clnt *nfs4_proc_lookup_mountpoint(struct inode *,
struct nfs_fh *,
struct nfs_fattr *);
extern int nfs4_proc_secinfo(struct inode *, const struct qstr *, struct nfs4_secinfo_flavors *);
extern const struct xattr_handler *nfs4_xattr_handlers[];
extern const struct xattr_handler * const nfs4_xattr_handlers[];
extern int nfs4_set_rw_stateid(nfs4_stateid *stateid,
const struct nfs_open_context *ctx,
const struct nfs_lock_context *l_ctx,
Expand Down
2 changes: 1 addition & 1 deletion fs/nfs/nfs4proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -10737,7 +10737,7 @@ static const struct xattr_handler nfs4_xattr_nfs4_user_handler = {
};
#endif

const struct xattr_handler *nfs4_xattr_handlers[] = {
const struct xattr_handler * const nfs4_xattr_handlers[] = {
&nfs4_xattr_nfs4_acl_handler,
#if defined(CONFIG_NFS_V4_1)
&nfs4_xattr_nfs4_dacl_handler,
Expand Down
2 changes: 1 addition & 1 deletion fs/ntfs3/ntfs_fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -872,7 +872,7 @@ int ntfs_init_acl(struct mnt_idmap *idmap, struct inode *inode,

int ntfs_acl_chmod(struct mnt_idmap *idmap, struct dentry *dentry);
ssize_t ntfs_listxattr(struct dentry *dentry, char *buffer, size_t size);
extern const struct xattr_handler *ntfs_xattr_handlers[];
extern const struct xattr_handler * const ntfs_xattr_handlers[];

int ntfs_save_wsl_perm(struct inode *inode, __le16 *ea_size);
void ntfs_get_wsl_perm(struct inode *inode);
Expand Down
2 changes: 1 addition & 1 deletion fs/ntfs3/xattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1021,7 +1021,7 @@ static const struct xattr_handler ntfs_other_xattr_handler = {
.list = ntfs_xattr_user_list,
};

const struct xattr_handler *ntfs_xattr_handlers[] = {
const struct xattr_handler * const ntfs_xattr_handlers[] = {
&ntfs_other_xattr_handler,
NULL,
};
Expand Down
Loading

0 comments on commit 7352a67

Please sign in to comment.