UPSTREAM: kernfs: add exportfs operations
Now we have the facilities to implement exportfs operations. The idea is cgroup can export the fhandle info to userspace, then userspace uses fhandle to find the cgroup name. Another example is userspace can get fhandle for a cgroup and BPF uses the fhandle to filter info for the cgroup. Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Shaohua Li <shli@fb.com> Signed-off-by: Jens Axboe <axboe@kernel.dk> Signed-off-by: Sorayukii <sorayukii69@gmail.com>
This commit is contained in:
parent
30f27ca7ab
commit
fe8db576ef
1 changed files with 70 additions and 1 deletions
|
|
@ -1973,7 +1973,8 @@ int cgroup_setup_root(struct cgroup_root *root, u16 ss_mask)
|
|||
&cgroup_kf_syscall_ops : &cgroup1_kf_syscall_ops;
|
||||
|
||||
root->kf_root = kernfs_create_root(kf_sops,
|
||||
KERNFS_ROOT_CREATE_DEACTIVATED,
|
||||
KERNFS_ROOT_CREATE_DEACTIVATED |
|
||||
KERNFS_ROOT_SUPPORT_EXPORTOP,
|
||||
root_cgrp);
|
||||
if (IS_ERR(root->kf_root)) {
|
||||
ret = PTR_ERR(root->kf_root);
|
||||
|
|
|
|||
Loading…
Reference in a new issue