Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\fs_context.c Create Date:2022-07-28 20:13:05
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:vfs_dup_fc_config: Duplicate a filesystem context.*@src_fc: The context to copy.

Proto:struct fs_context *vfs_dup_fs_context(struct fs_context *src_fc)

Type:struct fs_context

Parameter:

TypeParameterName
struct fs_context *src_fc
347  If Not dup Then Return ERR_PTR( - EOPNOTSUPP)
350  fc = kmemdup - duplicate region of memory*@src: memory region to duplicate*@len: memory region length*@gfp: GFP mask to use* Return: newly allocated copy of @src or %NULL in case of error
351  If Not fc Then Return ERR_PTR( - ENOMEM)
354  mutex_init - initialize the mutex*@mutex: the mutex to be initialized* Initialize the mutex to unlocked state.* It is not allowed to initialize an already locked mutex.( & uapi_mutex)
356  fs_private = NULL
357  s_fs_info = NULL
358  source = NULL
359  security = NULL
360  WARNING: This can be used only if we _already_ own a reference
361  get_net(net_ns)
362  get_user_ns(user_ns)
363  get_cred - Get a reference on a set of credentials*@cred: The credentials to reference* Get a reference on the specified set of credentials. The caller must* release the reference. If %NULL is passed, it is returned with no action.
364  If log Then _inc - increment a refcount*@r: the refcount to increment* Similar to atomic_inc(), but will saturate at REFCOUNT_SATURATED and WARN
368  ret = dup(fc, src_fc)
369  If ret < 0 Then Go to err_fc
372  ret = security_fs_context_dup(fc, src_fc)
373  If ret < 0 Then Go to err_fc
375  Return fc
377  err_fc :
378  put_fs_context - Dispose of a superblock configuration context.*@fc: The context to dispose of.
379  Return ERR_PTR(ret)