blob: f3eaa8869f42ff12d037893b78d64535c1c7b6fa [file] [log] [blame]
Thomas Gleixner55716d22019-06-01 10:08:42 +02001// SPDX-License-Identifier: GPL-2.0-only
Tejun Heob8441ed2013-11-24 09:54:58 -05002/*
3 * fs/kernfs/inode.c - kernfs inode implementation
4 *
5 * Copyright (c) 2001-3 Patrick Mochel
6 * Copyright (c) 2007 SUSE Linux Products GmbH
7 * Copyright (c) 2007, 2013 Tejun Heo <tj@kernel.org>
Tejun Heob8441ed2013-11-24 09:54:58 -05008 */
Tejun Heoffed24e2013-11-28 14:54:32 -05009
10#include <linux/pagemap.h>
11#include <linux/backing-dev.h>
12#include <linux/capability.h>
13#include <linux/errno.h>
14#include <linux/slab.h>
15#include <linux/xattr.h>
16#include <linux/security.h>
17
18#include "kernfs-internal.h"
19
Tejun Heoa797bfc2013-12-11 14:11:57 -050020static const struct address_space_operations kernfs_aops = {
Tejun Heoffed24e2013-11-28 14:54:32 -050021 .readpage = simple_readpage,
22 .write_begin = simple_write_begin,
23 .write_end = simple_write_end,
24};
25
Tejun Heoa797bfc2013-12-11 14:11:57 -050026static const struct inode_operations kernfs_iops = {
Tejun Heoc637b8a2013-12-11 14:11:58 -050027 .permission = kernfs_iop_permission,
28 .setattr = kernfs_iop_setattr,
29 .getattr = kernfs_iop_getattr,
Tejun Heoc637b8a2013-12-11 14:11:58 -050030 .listxattr = kernfs_iop_listxattr,
Tejun Heoffed24e2013-11-28 14:54:32 -050031};
32
Ondrej Mosnacekd0c9c152019-02-22 15:57:13 +010033static struct kernfs_iattrs *__kernfs_iattrs(struct kernfs_node *kn, int alloc)
Tejun Heoffed24e2013-11-28 14:54:32 -050034{
Tejun Heo4afddd62014-04-02 16:40:52 -040035 static DEFINE_MUTEX(iattr_mutex);
36 struct kernfs_iattrs *ret;
Tejun Heoffed24e2013-11-28 14:54:32 -050037
Tejun Heo4afddd62014-04-02 16:40:52 -040038 mutex_lock(&iattr_mutex);
39
Ondrej Mosnacekd0c9c152019-02-22 15:57:13 +010040 if (kn->iattr || !alloc)
Tejun Heo4afddd62014-04-02 16:40:52 -040041 goto out_unlock;
Tejun Heo9a8049a2013-11-23 17:40:01 -050042
Ayush Mittal26e28d62019-02-06 10:25:42 +053043 kn->iattr = kmem_cache_zalloc(kernfs_iattrs_cache, GFP_KERNEL);
Tejun Heoadc5e8b2013-12-11 14:11:54 -050044 if (!kn->iattr)
Tejun Heo4afddd62014-04-02 16:40:52 -040045 goto out_unlock;
Tejun Heoffed24e2013-11-28 14:54:32 -050046
47 /* assign default attributes */
Ondrej Mosnacek05895212019-02-22 15:57:12 +010048 kn->iattr->ia_uid = GLOBAL_ROOT_UID;
49 kn->iattr->ia_gid = GLOBAL_ROOT_GID;
Deepa Dinamani3a3a5fe2016-02-22 07:17:53 -080050
Ondrej Mosnacek05895212019-02-22 15:57:12 +010051 ktime_get_real_ts64(&kn->iattr->ia_atime);
52 kn->iattr->ia_mtime = kn->iattr->ia_atime;
53 kn->iattr->ia_ctime = kn->iattr->ia_atime;
Tejun Heoffed24e2013-11-28 14:54:32 -050054
Tejun Heoadc5e8b2013-12-11 14:11:54 -050055 simple_xattrs_init(&kn->iattr->xattrs);
Tejun Heo4afddd62014-04-02 16:40:52 -040056out_unlock:
57 ret = kn->iattr;
58 mutex_unlock(&iattr_mutex);
59 return ret;
Tejun Heoffed24e2013-11-28 14:54:32 -050060}
61
Ondrej Mosnacekd0c9c152019-02-22 15:57:13 +010062static struct kernfs_iattrs *kernfs_iattrs(struct kernfs_node *kn)
63{
64 return __kernfs_iattrs(kn, 1);
65}
66
67static struct kernfs_iattrs *kernfs_iattrs_noalloc(struct kernfs_node *kn)
68{
69 return __kernfs_iattrs(kn, 0);
70}
71
Dmitry Torokhov488dee92018-07-20 21:56:47 +000072int __kernfs_setattr(struct kernfs_node *kn, const struct iattr *iattr)
Tejun Heoffed24e2013-11-28 14:54:32 -050073{
Tejun Heoc525aad2013-12-11 14:11:55 -050074 struct kernfs_iattrs *attrs;
Tejun Heoffed24e2013-11-28 14:54:32 -050075 unsigned int ia_valid = iattr->ia_valid;
76
Tejun Heoc525aad2013-12-11 14:11:55 -050077 attrs = kernfs_iattrs(kn);
Tejun Heo9a8049a2013-11-23 17:40:01 -050078 if (!attrs)
79 return -ENOMEM;
Tejun Heoffed24e2013-11-28 14:54:32 -050080
Tejun Heoffed24e2013-11-28 14:54:32 -050081 if (ia_valid & ATTR_UID)
Ondrej Mosnacek05895212019-02-22 15:57:12 +010082 attrs->ia_uid = iattr->ia_uid;
Tejun Heoffed24e2013-11-28 14:54:32 -050083 if (ia_valid & ATTR_GID)
Ondrej Mosnacek05895212019-02-22 15:57:12 +010084 attrs->ia_gid = iattr->ia_gid;
Tejun Heoffed24e2013-11-28 14:54:32 -050085 if (ia_valid & ATTR_ATIME)
Ondrej Mosnacek05895212019-02-22 15:57:12 +010086 attrs->ia_atime = iattr->ia_atime;
Tejun Heoffed24e2013-11-28 14:54:32 -050087 if (ia_valid & ATTR_MTIME)
Ondrej Mosnacek05895212019-02-22 15:57:12 +010088 attrs->ia_mtime = iattr->ia_mtime;
Tejun Heoffed24e2013-11-28 14:54:32 -050089 if (ia_valid & ATTR_CTIME)
Ondrej Mosnacek05895212019-02-22 15:57:12 +010090 attrs->ia_ctime = iattr->ia_ctime;
91 if (ia_valid & ATTR_MODE)
92 kn->mode = iattr->ia_mode;
Tejun Heoffed24e2013-11-28 14:54:32 -050093 return 0;
94}
95
96/**
97 * kernfs_setattr - set iattr on a node
Tejun Heo324a56e2013-12-11 14:11:53 -050098 * @kn: target node
Tejun Heoffed24e2013-11-28 14:54:32 -050099 * @iattr: iattr to set
100 *
101 * Returns 0 on success, -errno on failure.
102 */
Tejun Heo324a56e2013-12-11 14:11:53 -0500103int kernfs_setattr(struct kernfs_node *kn, const struct iattr *iattr)
Tejun Heoffed24e2013-11-28 14:54:32 -0500104{
105 int ret;
106
Tejun Heoa797bfc2013-12-11 14:11:57 -0500107 mutex_lock(&kernfs_mutex);
Tejun Heo324a56e2013-12-11 14:11:53 -0500108 ret = __kernfs_setattr(kn, iattr);
Tejun Heoa797bfc2013-12-11 14:11:57 -0500109 mutex_unlock(&kernfs_mutex);
Tejun Heoffed24e2013-11-28 14:54:32 -0500110 return ret;
111}
112
Tejun Heoc637b8a2013-12-11 14:11:58 -0500113int kernfs_iop_setattr(struct dentry *dentry, struct iattr *iattr)
Tejun Heoffed24e2013-11-28 14:54:32 -0500114{
David Howells2b0143b2015-03-17 22:25:59 +0000115 struct inode *inode = d_inode(dentry);
Shaohua Li319ba912017-07-12 11:49:49 -0700116 struct kernfs_node *kn = inode->i_private;
Tejun Heoffed24e2013-11-28 14:54:32 -0500117 int error;
118
Tejun Heo324a56e2013-12-11 14:11:53 -0500119 if (!kn)
Tejun Heoffed24e2013-11-28 14:54:32 -0500120 return -EINVAL;
121
Tejun Heoa797bfc2013-12-11 14:11:57 -0500122 mutex_lock(&kernfs_mutex);
Jan Kara31051c82016-05-26 16:55:18 +0200123 error = setattr_prepare(dentry, iattr);
Tejun Heoffed24e2013-11-28 14:54:32 -0500124 if (error)
125 goto out;
126
Tejun Heo324a56e2013-12-11 14:11:53 -0500127 error = __kernfs_setattr(kn, iattr);
Tejun Heoffed24e2013-11-28 14:54:32 -0500128 if (error)
129 goto out;
130
131 /* this ignores size changes */
132 setattr_copy(inode, iattr);
133
134out:
Tejun Heoa797bfc2013-12-11 14:11:57 -0500135 mutex_unlock(&kernfs_mutex);
Tejun Heoffed24e2013-11-28 14:54:32 -0500136 return error;
137}
138
Tejun Heoc637b8a2013-12-11 14:11:58 -0500139ssize_t kernfs_iop_listxattr(struct dentry *dentry, char *buf, size_t size)
Tejun Heo23223922013-11-23 17:40:02 -0500140{
Shaohua Li319ba912017-07-12 11:49:49 -0700141 struct kernfs_node *kn = kernfs_dentry_node(dentry);
Tejun Heoc525aad2013-12-11 14:11:55 -0500142 struct kernfs_iattrs *attrs;
Tejun Heo23223922013-11-23 17:40:02 -0500143
Tejun Heoc525aad2013-12-11 14:11:55 -0500144 attrs = kernfs_iattrs(kn);
Tejun Heo23223922013-11-23 17:40:02 -0500145 if (!attrs)
146 return -ENOMEM;
147
Andreas Gruenbacher786534b2015-12-02 14:44:39 +0100148 return simple_xattr_list(d_inode(dentry), &attrs->xattrs, buf, size);
Tejun Heoffed24e2013-11-28 14:54:32 -0500149}
150
151static inline void set_default_inode_attr(struct inode *inode, umode_t mode)
152{
153 inode->i_mode = mode;
Deepa Dinamani3a3a5fe2016-02-22 07:17:53 -0800154 inode->i_atime = inode->i_mtime =
Deepa Dinamanic2050a42016-09-14 07:48:06 -0700155 inode->i_ctime = current_time(inode);
Tejun Heoffed24e2013-11-28 14:54:32 -0500156}
157
Ondrej Mosnacek05895212019-02-22 15:57:12 +0100158static inline void set_inode_attr(struct inode *inode,
159 struct kernfs_iattrs *attrs)
Tejun Heoffed24e2013-11-28 14:54:32 -0500160{
Ondrej Mosnacek05895212019-02-22 15:57:12 +0100161 inode->i_uid = attrs->ia_uid;
162 inode->i_gid = attrs->ia_gid;
Deepa Dinamani3818c192019-06-15 09:00:05 -0700163 inode->i_atime = timestamp_truncate(attrs->ia_atime, inode);
164 inode->i_mtime = timestamp_truncate(attrs->ia_mtime, inode);
165 inode->i_ctime = timestamp_truncate(attrs->ia_ctime, inode);
Tejun Heoffed24e2013-11-28 14:54:32 -0500166}
167
Tejun Heoc637b8a2013-12-11 14:11:58 -0500168static void kernfs_refresh_inode(struct kernfs_node *kn, struct inode *inode)
Tejun Heoffed24e2013-11-28 14:54:32 -0500169{
Tejun Heoc525aad2013-12-11 14:11:55 -0500170 struct kernfs_iattrs *attrs = kn->iattr;
Tejun Heoffed24e2013-11-28 14:54:32 -0500171
Tejun Heoadc5e8b2013-12-11 14:11:54 -0500172 inode->i_mode = kn->mode;
Ondrej Mosnacek0ac60752019-02-22 15:57:15 +0100173 if (attrs)
Tejun Heo324a56e2013-12-11 14:11:53 -0500174 /*
175 * kernfs_node has non-default attributes get them from
176 * persistent copy in kernfs_node.
Tejun Heoffed24e2013-11-28 14:54:32 -0500177 */
Ondrej Mosnacek05895212019-02-22 15:57:12 +0100178 set_inode_attr(inode, attrs);
Tejun Heoffed24e2013-11-28 14:54:32 -0500179
Tejun Heodf23fc32013-12-11 14:11:56 -0500180 if (kernfs_type(kn) == KERNFS_DIR)
Tejun Heoadc5e8b2013-12-11 14:11:54 -0500181 set_nlink(inode, kn->dir.subdirs + 2);
Tejun Heoffed24e2013-11-28 14:54:32 -0500182}
183
David Howellsa528d352017-01-31 16:46:22 +0000184int kernfs_iop_getattr(const struct path *path, struct kstat *stat,
185 u32 request_mask, unsigned int query_flags)
Tejun Heoffed24e2013-11-28 14:54:32 -0500186{
David Howellsa528d352017-01-31 16:46:22 +0000187 struct inode *inode = d_inode(path->dentry);
Shaohua Li319ba912017-07-12 11:49:49 -0700188 struct kernfs_node *kn = inode->i_private;
Tejun Heoffed24e2013-11-28 14:54:32 -0500189
Tejun Heoa797bfc2013-12-11 14:11:57 -0500190 mutex_lock(&kernfs_mutex);
Tejun Heoc637b8a2013-12-11 14:11:58 -0500191 kernfs_refresh_inode(kn, inode);
Tejun Heoa797bfc2013-12-11 14:11:57 -0500192 mutex_unlock(&kernfs_mutex);
Tejun Heoffed24e2013-11-28 14:54:32 -0500193
194 generic_fillattr(inode, stat);
195 return 0;
196}
197
Tejun Heoc637b8a2013-12-11 14:11:58 -0500198static void kernfs_init_inode(struct kernfs_node *kn, struct inode *inode)
Tejun Heoffed24e2013-11-28 14:54:32 -0500199{
Tejun Heo324a56e2013-12-11 14:11:53 -0500200 kernfs_get(kn);
201 inode->i_private = kn;
Tejun Heoa797bfc2013-12-11 14:11:57 -0500202 inode->i_mapping->a_ops = &kernfs_aops;
Tejun Heoa797bfc2013-12-11 14:11:57 -0500203 inode->i_op = &kernfs_iops;
Shaohua Lic53cd492017-07-12 11:49:50 -0700204 inode->i_generation = kn->id.generation;
Tejun Heoffed24e2013-11-28 14:54:32 -0500205
Tejun Heoadc5e8b2013-12-11 14:11:54 -0500206 set_default_inode_attr(inode, kn->mode);
Tejun Heoc637b8a2013-12-11 14:11:58 -0500207 kernfs_refresh_inode(kn, inode);
Tejun Heoffed24e2013-11-28 14:54:32 -0500208
209 /* initialize inode according to type */
Tejun Heodf23fc32013-12-11 14:11:56 -0500210 switch (kernfs_type(kn)) {
211 case KERNFS_DIR:
Tejun Heoa797bfc2013-12-11 14:11:57 -0500212 inode->i_op = &kernfs_dir_iops;
213 inode->i_fop = &kernfs_dir_fops;
Eric W. Biedermanea015212015-05-13 16:09:29 -0500214 if (kn->flags & KERNFS_EMPTY_DIR)
215 make_empty_dir_inode(inode);
Tejun Heoffed24e2013-11-28 14:54:32 -0500216 break;
Tejun Heodf23fc32013-12-11 14:11:56 -0500217 case KERNFS_FILE:
Tejun Heoadc5e8b2013-12-11 14:11:54 -0500218 inode->i_size = kn->attr.size;
Tejun Heoa797bfc2013-12-11 14:11:57 -0500219 inode->i_fop = &kernfs_file_fops;
Tejun Heoffed24e2013-11-28 14:54:32 -0500220 break;
Tejun Heodf23fc32013-12-11 14:11:56 -0500221 case KERNFS_LINK:
Tejun Heoa797bfc2013-12-11 14:11:57 -0500222 inode->i_op = &kernfs_symlink_iops;
Tejun Heoffed24e2013-11-28 14:54:32 -0500223 break;
224 default:
225 BUG();
226 }
227
228 unlock_new_inode(inode);
229}
230
231/**
Tejun Heoc637b8a2013-12-11 14:11:58 -0500232 * kernfs_get_inode - get inode for kernfs_node
Tejun Heoffed24e2013-11-28 14:54:32 -0500233 * @sb: super block
Tejun Heo324a56e2013-12-11 14:11:53 -0500234 * @kn: kernfs_node to allocate inode for
Tejun Heoffed24e2013-11-28 14:54:32 -0500235 *
Tejun Heo324a56e2013-12-11 14:11:53 -0500236 * Get inode for @kn. If such inode doesn't exist, a new inode is
237 * allocated and basics are initialized. New inode is returned
238 * locked.
Tejun Heoffed24e2013-11-28 14:54:32 -0500239 *
240 * LOCKING:
241 * Kernel thread context (may sleep).
242 *
243 * RETURNS:
244 * Pointer to allocated inode on success, NULL on failure.
245 */
Tejun Heoc637b8a2013-12-11 14:11:58 -0500246struct inode *kernfs_get_inode(struct super_block *sb, struct kernfs_node *kn)
Tejun Heoffed24e2013-11-28 14:54:32 -0500247{
248 struct inode *inode;
249
Shaohua Lic53cd492017-07-12 11:49:50 -0700250 inode = iget_locked(sb, kn->id.ino);
Tejun Heoffed24e2013-11-28 14:54:32 -0500251 if (inode && (inode->i_state & I_NEW))
Tejun Heoc637b8a2013-12-11 14:11:58 -0500252 kernfs_init_inode(kn, inode);
Tejun Heoffed24e2013-11-28 14:54:32 -0500253
254 return inode;
255}
256
257/*
Tejun Heoc637b8a2013-12-11 14:11:58 -0500258 * The kernfs_node serves as both an inode and a directory entry for
259 * kernfs. To prevent the kernfs inode numbers from being freed
260 * prematurely we take a reference to kernfs_node from the kernfs inode. A
Tejun Heoffed24e2013-11-28 14:54:32 -0500261 * super_operations.evict_inode() implementation is needed to drop that
262 * reference upon inode destruction.
263 */
Tejun Heoc637b8a2013-12-11 14:11:58 -0500264void kernfs_evict_inode(struct inode *inode)
Tejun Heoffed24e2013-11-28 14:54:32 -0500265{
Tejun Heo324a56e2013-12-11 14:11:53 -0500266 struct kernfs_node *kn = inode->i_private;
Tejun Heoffed24e2013-11-28 14:54:32 -0500267
Johannes Weiner91b0abe2014-04-03 14:47:49 -0700268 truncate_inode_pages_final(&inode->i_data);
Tejun Heoffed24e2013-11-28 14:54:32 -0500269 clear_inode(inode);
Tejun Heo324a56e2013-12-11 14:11:53 -0500270 kernfs_put(kn);
Tejun Heoffed24e2013-11-28 14:54:32 -0500271}
272
Tejun Heoc637b8a2013-12-11 14:11:58 -0500273int kernfs_iop_permission(struct inode *inode, int mask)
Tejun Heoffed24e2013-11-28 14:54:32 -0500274{
Tejun Heo324a56e2013-12-11 14:11:53 -0500275 struct kernfs_node *kn;
Tejun Heoffed24e2013-11-28 14:54:32 -0500276
277 if (mask & MAY_NOT_BLOCK)
278 return -ECHILD;
279
Tejun Heo324a56e2013-12-11 14:11:53 -0500280 kn = inode->i_private;
Tejun Heoffed24e2013-11-28 14:54:32 -0500281
Tejun Heoa797bfc2013-12-11 14:11:57 -0500282 mutex_lock(&kernfs_mutex);
Tejun Heoc637b8a2013-12-11 14:11:58 -0500283 kernfs_refresh_inode(kn, inode);
Tejun Heoa797bfc2013-12-11 14:11:57 -0500284 mutex_unlock(&kernfs_mutex);
Tejun Heoffed24e2013-11-28 14:54:32 -0500285
286 return generic_permission(inode, mask);
287}
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200288
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200289int kernfs_xattr_get(struct kernfs_node *kn, const char *name,
290 void *value, size_t size)
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200291{
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200292 struct kernfs_iattrs *attrs = kernfs_iattrs_noalloc(kn);
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200293 if (!attrs)
Ondrej Mosnacekd0c9c152019-02-22 15:57:13 +0100294 return -ENODATA;
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200295
296 return simple_xattr_get(&attrs->xattrs, name, value, size);
297}
298
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200299int kernfs_xattr_set(struct kernfs_node *kn, const char *name,
300 const void *value, size_t size, int flags)
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200301{
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200302 struct kernfs_iattrs *attrs = kernfs_iattrs(kn);
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200303 if (!attrs)
304 return -ENOMEM;
305
306 return simple_xattr_set(&attrs->xattrs, name, value, size, flags);
307}
308
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200309static int kernfs_vfs_xattr_get(const struct xattr_handler *handler,
310 struct dentry *unused, struct inode *inode,
311 const char *suffix, void *value, size_t size)
Ondrej Mosnacekb230d5a2019-02-22 15:57:16 +0100312{
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200313 const char *name = xattr_full_name(handler, suffix);
Ondrej Mosnacekb230d5a2019-02-22 15:57:16 +0100314 struct kernfs_node *kn = inode->i_private;
315
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200316 return kernfs_xattr_get(kn, name, value, size);
Ondrej Mosnacekb230d5a2019-02-22 15:57:16 +0100317}
318
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200319static int kernfs_vfs_xattr_set(const struct xattr_handler *handler,
320 struct dentry *unused, struct inode *inode,
321 const char *suffix, const void *value,
322 size_t size, int flags)
Ondrej Mosnacekb230d5a2019-02-22 15:57:16 +0100323{
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200324 const char *name = xattr_full_name(handler, suffix);
Ondrej Mosnacekb230d5a2019-02-22 15:57:16 +0100325 struct kernfs_node *kn = inode->i_private;
326
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200327 return kernfs_xattr_set(kn, name, value, size, flags);
Ondrej Mosnacekb230d5a2019-02-22 15:57:16 +0100328}
329
Bart Van Asscheb5a06232016-11-11 16:45:58 -0800330static const struct xattr_handler kernfs_trusted_xattr_handler = {
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200331 .prefix = XATTR_TRUSTED_PREFIX,
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200332 .get = kernfs_vfs_xattr_get,
333 .set = kernfs_vfs_xattr_set,
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200334};
335
Bart Van Asscheb5a06232016-11-11 16:45:58 -0800336static const struct xattr_handler kernfs_security_xattr_handler = {
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200337 .prefix = XATTR_SECURITY_PREFIX,
Ondrej Mosnacek1537ad12019-04-03 09:29:41 +0200338 .get = kernfs_vfs_xattr_get,
339 .set = kernfs_vfs_xattr_set,
Andreas Gruenbachere72a1a82016-09-29 17:48:33 +0200340};
341
342const struct xattr_handler *kernfs_xattr_handlers[] = {
343 &kernfs_trusted_xattr_handler,
344 &kernfs_security_xattr_handler,
345 NULL
346};