Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\sched\core.c Create Date:2022-07-28 09:36:51
Last Modify:2022-05-22 13:40:38 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:get_user_cpu_mask

Proto:static int get_user_cpu_mask(unsigned long __user *user_mask_ptr, unsigned len, struct cpumask *new_mask)

Type:int

Parameter:

TypeParameterName
unsigned long __user *user_mask_ptr
unsignedlen
struct cpumask *new_mask
5492  If len < pumask_size - size to allocate for a 'struct cpumask' in bytes Then pumask_clear - clear all cpus (< nr_cpu_ids) in a cpumask*@dstp: the cpumask pointer
5494  Else if len > pumask_size - size to allocate for a 'struct cpumask' in bytes Then len = pumask_size - size to allocate for a 'struct cpumask' in bytes
5497  Return If copy_from_user(new_mask, user_mask_ptr, len) Then -EFAULT Else 0
Caller
NameDescribe
SYSCALL_DEFINE3sys_sched_setaffinity - set the CPU affinity of a process*@pid: pid of the process*@len: length in bytes of the bitmask pointed to by user_mask_ptr*@user_mask_ptr: user-space pointer to the new CPU mask* Return: 0 on success. An error code otherwise.