Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\trace\ring_buffer.c Create Date:2022-07-28 11:53:12
Last Modify:2020-03-17 19:30:04 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:g_buffer_poll_wait - poll on buffer input*@buffer: buffer to wait on*@cpu: the cpu buffer to wait on*@filp: the file descriptor*@poll_table: The poll descriptor* If @cpu == RING_BUFFER_ALL_CPUS then the task will wake up as soon

Proto:__poll_t ring_buffer_poll_wait(struct ring_buffer *buffer, int cpu, struct file *filp, poll_table *poll_table)

Type:__poll_t

Parameter:

TypeParameterName
struct ring_buffer *buffer
intcpu
struct file *filp
poll_table *poll_table
693  If cpu == RING_BUFFER_ALL_CPUS Then work = irq_work
695  Else
696  If Not pumask_test_cpu - test for a cpu in a cpumask*@cpu: cpu number (< nr_cpu_ids)*@cpumask: the cpumask pointer* Returns 1 if @cpu is set in @cpumask, else returns 0 Then Return -EINVAL
699  cpu_buffer = buffers[cpu]
700  work = irq_work
703  poll_wait(filp, & waiters, poll_table)
704  waiters_pending = true
718  smp_mb()
720  If cpu == RING_BUFFER_ALL_CPUS && Not d_buffer_empty - is the ring buffer empty?*@buffer: The ring buffer to test || cpu != RING_BUFFER_ALL_CPUS && Not g_buffer_empty_cpu - is a cpu buffer of a ring buffer empty?*@buffer: The ring buffer*@cpu: The CPU buffer to test Then Return Epoll event masks | EPOLLRDNORM
723  Return 0
Caller
NameDescribe
trace_poll