函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:sys_membarrier - issue memory barriers on a set of threads*@cmd: Takes command values defined in enum membarrier_cmd

函数原型:SYSCALL_DEFINE2(membarrier, int, cmd, int, flags)

返回类型:

参数:

342  如果此条件成立可能性小(为编译器优化)(flags)则返回:负EINVAL
345  :cmd恒等于MEMBARRIER_CMD_QUERY
347  cmd_mask等于MEMBARRIER_CMD_BITMASK
349  如果tick_nohz_full_enabled()则cmd_mask与等于MEMBARRIER_CMD_GLOBAL的反
351  返回:cmd_mask
353  :cmd恒等于MEMBARRIER_CMD_GLOBAL
355  如果tick_nohz_full_enabled()则返回:负EINVAL
357  如果num_online_cpus()大于1则synchronize_rcu()
359  返回:0
360  :cmd恒等于MEMBARRIER_CMD_GLOBAL_EXPEDITED
361  返回:membarrier_global_expedited()
362  :cmd恒等于MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED
363  返回:membarrier_register_global_expedited()
364  :cmd恒等于MEMBARRIER_CMD_PRIVATE_EXPEDITED
365  返回:membarrier_private_expedited(0)
366  :cmd恒等于MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED
367  返回:membarrier_register_private_expedited(0)
368  :cmd恒等于MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE
369  返回:membarrier_private_expedited(MEMBARRIER_FLAG_SYNC_CORE)
370  :cmd恒等于MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE
371  返回:membarrier_register_private_expedited(MEMBARRIER_FLAG_SYNC_CORE)
372  默认
373  返回:负EINVAL