函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\fs_context.c Create Date:2022-07-29 10:44:03
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Add a parameter to a legacy config. We build up a comma-separated list of* options.

函数原型:static int legacy_parse_param(struct fs_context *fc, struct fs_parameter *param)

返回类型:int

参数:

类型参数名称
struct fs_context *fc
struct fs_parameter *param
559  ctx等于fs_private
560  size等于data_size
561  len等于0
563  如果字符串比较恒等于0则
564  如果The type of value here 不等于fs_value_is_string则返回:valf - Store supplementary invalid argument error message*@fc: The context in which to log the error message*@fmt: The format string* Store the supplementary error message for the process if the process has* enabled the facility and return -EINVAL.(fc, "VFS: Legacy: Non-string source")
566  如果source则返回:valf - Store supplementary invalid argument error message*@fc: The context in which to log the error message*@fmt: The format string* Store the supplementary error message for the process if the process has* enabled the facility and return -EINVAL.(fc, "VFS: Legacy: Multiple sources")
568  source等于string
569  string = NULL
570  返回:0
573  如果param_type恒等于LEGACY_FS_MONOLITHIC_PARAMS则返回:valf - Store supplementary invalid argument error message*@fc: The context in which to log the error message*@fmt: The format string* Store the supplementary error message for the process if the process has* enabled the facility and return -EINVAL.(fc, "VFS: Legacy: Can't mix monolithic and individual options")
577  :The type of value here 恒等于Value is a string
578  len等于1加size
580  :The type of value here 恒等于Value not given a value
581  len加等于strlen - Find the length of a string*@s: The string to be sized
582  退出
583  默认
584  返回:valf - Store supplementary invalid argument error message*@fc: The context in which to log the error message*@fmt: The format string* Store the supplementary error message for the process if the process has* enabled the facility and return -EINVAL.(fc, "VFS: Legacy: Parameter type for '%s' not supported", Parameter name )
588  如果len大于PAGE_SIZE减2减size则返回:valf - Store supplementary invalid argument error message*@fc: The context in which to log the error message*@fmt: The format string* Store the supplementary error message for the process if the process has* enabled the facility and return -EINVAL.(fc, "VFS: Legacy: Cumulative options too large")
590  如果strchr - Find the first occurrence of the character c in the string s.*@s: the string to be searched*@c: the character to search forThe type of value here 恒等于Value is a string memchr(string, ',', size)则返回:valf - Store supplementary invalid argument error message*@fc: The context in which to log the error message*@fmt: The format string* Store the supplementary error message for the process if the process has* enabled the facility and return -EINVAL.(fc, "VFS: Legacy: Option '%s' contained comma", Parameter name )
595  如果非 Data page for legacy filesystems
596  Data page for legacy filesystems 等于开辟内存
597  如果非 Data page for legacy filesystems 则返回:负ENOMEM
601  Data page for legacy filesystems [size++]等于','
602  len等于strlen - Find the length of a string*@s: The string to be sized
603  memcpy( Data page for legacy filesystems + size, Parameter name , len)
604  size加等于len
605  如果The type of value here 恒等于Value is a string
606  Data page for legacy filesystems [size++]等于'='
607  memcpy( Data page for legacy filesystems + size, string, size)
608  size加等于size
610  Data page for legacy filesystems [size]等于'\0'
611  data_size等于size
612  param_type等于LEGACY_FS_INDIVIDUAL_PARAMS
613  返回:0