Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Functions
hw_breakpoint.c File Reference
#include <linux/irqflags.h>
#include <linux/kallsyms.h>
#include <linux/notifier.h>
#include <linux/kprobes.h>
#include <linux/kdebug.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/percpu.h>
#include <linux/sched.h>
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/list.h>
#include <linux/cpu.h>
#include <linux/smp.h>
#include <linux/hw_breakpoint.h>

Go to the source code of this file.

Data Structures

struct  bp_busy_slots
 

Functions

__weak int hw_breakpoint_weight (struct perf_event *bp)
 
__weak void arch_unregister_hw_breakpoint (struct perf_event *bp)
 
int reserve_bp_slot (struct perf_event *bp)
 
void release_bp_slot (struct perf_event *bp)
 
int dbg_reserve_bp_slot (struct perf_event *bp)
 
int dbg_release_bp_slot (struct perf_event *bp)
 
int register_perf_hw_breakpoint (struct perf_event *bp)
 
struct perf_eventregister_user_hw_breakpoint (struct perf_event_attr *attr, perf_overflow_handler_t triggered, void *context, struct task_struct *tsk)
 
 EXPORT_SYMBOL_GPL (register_user_hw_breakpoint)
 
int modify_user_hw_breakpoint (struct perf_event *bp, struct perf_event_attr *attr)
 
 EXPORT_SYMBOL_GPL (modify_user_hw_breakpoint)
 
void unregister_hw_breakpoint (struct perf_event *bp)
 
 EXPORT_SYMBOL_GPL (unregister_hw_breakpoint)
 
struct perf_event *__percpuregister_wide_hw_breakpoint (struct perf_event_attr *attr, perf_overflow_handler_t triggered, void *context)
 
 EXPORT_SYMBOL_GPL (register_wide_hw_breakpoint)
 
void unregister_wide_hw_breakpoint (struct perf_event *__percpu *cpu_events)
 
 EXPORT_SYMBOL_GPL (unregister_wide_hw_breakpoint)
 
int __init init_hw_breakpoint (void)
 

Function Documentation

__weak void arch_unregister_hw_breakpoint ( struct perf_event bp)

Definition at line 249 of file hw_breakpoint.c.

int dbg_release_bp_slot ( struct perf_event bp)

Definition at line 378 of file hw_breakpoint.c.

int dbg_reserve_bp_slot ( struct perf_event bp)

Definition at line 370 of file hw_breakpoint.c.

EXPORT_SYMBOL_GPL ( register_user_hw_breakpoint  )
EXPORT_SYMBOL_GPL ( modify_user_hw_breakpoint  )
EXPORT_SYMBOL_GPL ( unregister_hw_breakpoint  )
EXPORT_SYMBOL_GPL ( register_wide_hw_breakpoint  )
EXPORT_SYMBOL_GPL ( unregister_wide_hw_breakpoint  )
__weak int hw_breakpoint_weight ( struct perf_event bp)

Definition at line 80 of file hw_breakpoint.c.

int __init init_hw_breakpoint ( void  )

Definition at line 651 of file hw_breakpoint.c.

int modify_user_hw_breakpoint ( struct perf_event bp,
struct perf_event_attr attr 
)

modify_user_hw_breakpoint - modify a user-space hardware breakpoint : the breakpoint structure to modify : new breakpoint attributes : callback to trigger when we hit the breakpoint : pointer to 'task_struct' of the process to which the address belongs

Definition at line 451 of file hw_breakpoint.c.

int register_perf_hw_breakpoint ( struct perf_event bp)

Definition at line 410 of file hw_breakpoint.c.

struct perf_event* register_user_hw_breakpoint ( struct perf_event_attr attr,
perf_overflow_handler_t  triggered,
void context,
struct task_struct tsk 
)
read

register_user_hw_breakpoint - register a hardware breakpoint for user space : breakpoint attributes : callback to trigger when we hit the breakpoint : pointer to 'task_struct' of the process to which the address belongs

Definition at line 434 of file hw_breakpoint.c.

struct perf_event* __percpu* register_wide_hw_breakpoint ( struct perf_event_attr attr,
perf_overflow_handler_t  triggered,
void context 
)
read

register_wide_hw_breakpoint - register a wide breakpoint in the kernel : breakpoint attributes : callback to trigger when we hit the breakpoint

Returns
a set of per_cpu pointers to perf events

Definition at line 517 of file hw_breakpoint.c.

void release_bp_slot ( struct perf_event bp)

Definition at line 355 of file hw_breakpoint.c.

int reserve_bp_slot ( struct perf_event bp)

Definition at line 332 of file hw_breakpoint.c.

void unregister_hw_breakpoint ( struct perf_event bp)

unregister_hw_breakpoint - unregister a user-space hardware breakpoint : the breakpoint structure to unregister

Definition at line 501 of file hw_breakpoint.c.

void unregister_wide_hw_breakpoint ( struct perf_event *__percpu cpu_events)

unregister_wide_hw_breakpoint - unregister a wide breakpoint in the kernel : the per cpu set of events to unregister

Definition at line 564 of file hw_breakpoint.c.