Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\fork.c Create Date:2022-07-28 08:59:03
Last Modify:2020-03-17 11:04:53 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Helper to unshare the files of the current task.* We don't want to expose copy_files internals to* the exec layer of the kernel.

Proto:int unshare_files(struct files_struct **displaced)

Type:int

Parameter:

TypeParameterName
struct files_struct **displaced
3024  task = current process
3025  struct files_struct * copy = NULL
3028  error = Unshare file descriptor table if it is being shared
3029  If error || Not copy Then
3030  * displaced = NULL
3031  Return error
3033  displaced = Open file information:
3034  Protects ->fs, ->files, ->mm, ->group_info, ->comm, keyring* subscriptions and synchronises with wait4(). Also used in procfs. Also* pins the final release of task.io_context. Also protects ->cpuset and* ->cgroup.subsys[]. And ->vfork_done.
3035  Open file information: = copy
3036  task_unlock(task)
3037  Return 0
Caller
NameDescribe
do_coredump