Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:tracing_cpumask_write

Proto:static ssize_t tracing_cpumask_write(struct file *filp, const char __user *ubuf, size_t count, loff_t *ppos)

Type:ssize_t

Parameter:

TypeParameterName
struct file *filp
const char __user *ubuf
size_tcount
loff_t *ppos
4563  tr = s or device private pointer
4567  If Not alloc_cpumask_var( & tracing_cpumask_new, GFP_KERNEL) Then Return -ENOMEM
4570  err = pumask_parse_user - extract a cpumask from a user string*@buf: the buffer to extract from*@len: the length of the buffer*@dstp: the cpumask to set.* Returns -errno, or 0 for success.
4571  If err Then Go to err_unlock
4574  local_irq_disable()
4575  r sched/core.c and kernel_lock.c: ( & * max_lock is used to protect the swapping of buffers * when taking a max snapshot. The buffers themselves are * protected by per_cpu spinlocks. But the action of the swap * needs its own lock. * This is defined as a arch_spinlock_t in order to help * with)
4576  for_each_tracing_cpu(cpu)
4583  atomic_inc( & disabled)
4588  atomic_dec( & disabled)
4592  arch_spin_unlock( & * max_lock is used to protect the swapping of buffers * when taking a max snapshot. The buffers themselves are * protected by per_cpu spinlocks. But the action of the swap * needs its own lock. * This is defined as a arch_spinlock_t in order to help * with)
4593  The local_irq_*() APIs are equal to the raw_local_irq*()* if !TRACE_IRQFLAGS.()
4595  pumask_copy - *dstp = *srcp*@dstp: the result*@srcp: the input cpumask
4596  free_cpumask_var(tracing_cpumask_new)
4598  Return count
4600  err_unlock :
4601  free_cpumask_var(tracing_cpumask_new)
4603  Return err