Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Add/remove the given breakpoint in our constraint table

Proto:static void toggle_bp_slot(struct perf_event *bp, bool enable, enum bp_type_idx type, int weight)

Type:void

Parameter:

TypeParameterName
struct perf_event *bp
boolenable
enum bp_type_idxtype
intweight
194  cpumask = cpumask_of_bp(bp)
197  If Not enable Then weight = -weight
201  If Not target Then
202  Number of pinned cpu breakpoints in a cpu += weight
203  Return
207  for_each_cpu(cpu, cpumask)
208  Add a pinned breakpoint for the given task in our constraint table
210  If enable Then list_add_tail - add a new entry*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head.* This is useful for implementing queues.
212  Else deletes entry from list
Caller
NameDescribe
__reserve_bp_slotConstraints to check before allowing this new breakpoint counter:* == Non-pinned counter == (Considered as pinned for now)* - If attached to a single cpu, check:* (per_cpu(info->flexible, cpu) || (per_cpu(info->cpu_pinned, cpu)* +
__release_bp_slot