函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:sched_partition_write

函数原型:static ssize_t sched_partition_write(struct kernfs_open_file *of, char *buf, size_t nbytes, loff_t off)

返回类型:ssize_t

参数:

类型参数名称
struct kernfs_open_file *of
char *buf
size_tnbytes
loff_toff
2501  cs等于css_cs(of_css(of))
2503  retval等于负ENODEV
2505  buf等于strstrip(buf)
2510  如果非字符串比较val等于PRS_ENABLED
2512  否则如果非字符串比较val等于Partition root states:* 0 - not a partition root* 1 - partition root* -1 - invalid partition root* None of the cpus in cpus_allowed can be put into the parent's* subparts_cpus. In this case, the cpuset is not a real partition* root anymore
2514  否则返回:负EINVAL
2517  获取指定CSS参考
2518  get_online_cpus()
2519  percpu_down_write( & cpuset_rwsem)
2520  如果非venient tests for these bits 则转到:out_unlock
2523  retval等于pdate_prstate - update partititon_root_state* Call with cpuset_mutex held.
2524  out_unlock :
2525  percpu_up_write( & cpuset_rwsem)
2526  put_online_cpus()
2527  设置一个css引用
2528  返回:如果retval否则nbytes