函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:- search for a free slot.

函数原型:static unsigned long xol_take_insn_slot(struct xol_area *area)

返回类型:unsigned long

参数:

类型参数名称
struct xol_area *area
1590  循环
1591  slot_nr等于find_first_zero_bit(0 = free slot , UINSNS_PER_PAGE)
1592  如果slot_nr小于UINSNS_PER_PAGE
1596  slot_nr等于UINSNS_PER_PAGE
1597  继续下一循环
1599  wait_event - sleep until a condition gets true*@wq_head: the waitqueue to wait on*@condition: a C expression for the event to wait for* The process is put to sleep (TASK_UNINTERRUPTIBLE) until the*@condition evaluates to true( all slots are busy , (atomic_read( & umber of in-use slots ) < UINSNS_PER_PAGE))
1600 slot_nr大于等于UINSNS_PER_PAGE循环
1602  slot_addr等于Page(s) of instruction slots slot_nr keep it cache aligned
1603  atomic_inc( & umber of in-use slots )
1605  返回:slot_addr
调用者
名称描述
xol_get_insn_slotxol_get_insn_slot - allocate a slot for xol.* Returns the allocated slot address or 0.