Merge branch 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: perf: Provide generic perf_sample_data initialization MAINTAINERS: Add Arnaldo as tools/perf/ co-maintainer perf trace: Don't use pager if scripting perf trace/scripting: Remove extraneous header read perf, ARM: Modify kuser rmb() call to compile for Thumb-2 x86/stacktrace: Don't dereference bad frame pointers perf archive: Don't try to collect files without a build-id perf_events, x86: Fixup fixed counter constraints perf, x86: Restrict the ANY flag perf, x86: rename macro in ARCH_PERFMON_EVENTSEL_ENABLE perf, x86: add some IBS macros to perf_event.h perf, x86: make IBS macros available in perf_event.h hw-breakpoints: Remove stub unthrottle callback x86/hw-breakpoints: Remove the name field perf: Remove pointless breakpoint union perf lock: Drop the buffers multiplexing dependency perf lock: Fix and add misc documentally things percpu: Add __percpu sparse annotations to hw_breakpoint
This commit is contained in:
commit
9fdfbc2bff
27 changed files with 327 additions and 129 deletions
|
|
@ -66,14 +66,14 @@ register_wide_hw_breakpoint_cpu(struct perf_event_attr *attr,
|
|||
perf_overflow_handler_t triggered,
|
||||
int cpu);
|
||||
|
||||
extern struct perf_event **
|
||||
extern struct perf_event * __percpu *
|
||||
register_wide_hw_breakpoint(struct perf_event_attr *attr,
|
||||
perf_overflow_handler_t triggered);
|
||||
|
||||
extern int register_perf_hw_breakpoint(struct perf_event *bp);
|
||||
extern int __register_perf_hw_breakpoint(struct perf_event *bp);
|
||||
extern void unregister_hw_breakpoint(struct perf_event *bp);
|
||||
extern void unregister_wide_hw_breakpoint(struct perf_event **cpu_events);
|
||||
extern void unregister_wide_hw_breakpoint(struct perf_event * __percpu *cpu_events);
|
||||
|
||||
extern int dbg_reserve_bp_slot(struct perf_event *bp);
|
||||
extern int dbg_release_bp_slot(struct perf_event *bp);
|
||||
|
|
@ -100,7 +100,7 @@ static inline struct perf_event *
|
|||
register_wide_hw_breakpoint_cpu(struct perf_event_attr *attr,
|
||||
perf_overflow_handler_t triggered,
|
||||
int cpu) { return NULL; }
|
||||
static inline struct perf_event **
|
||||
static inline struct perf_event * __percpu *
|
||||
register_wide_hw_breakpoint(struct perf_event_attr *attr,
|
||||
perf_overflow_handler_t triggered) { return NULL; }
|
||||
static inline int
|
||||
|
|
@ -109,7 +109,7 @@ static inline int
|
|||
__register_perf_hw_breakpoint(struct perf_event *bp) { return -ENOSYS; }
|
||||
static inline void unregister_hw_breakpoint(struct perf_event *bp) { }
|
||||
static inline void
|
||||
unregister_wide_hw_breakpoint(struct perf_event **cpu_events) { }
|
||||
unregister_wide_hw_breakpoint(struct perf_event * __percpu *cpu_events) { }
|
||||
static inline int
|
||||
reserve_bp_slot(struct perf_event *bp) {return -ENOSYS; }
|
||||
static inline void release_bp_slot(struct perf_event *bp) { }
|
||||
|
|
|
|||
|
|
@ -487,9 +487,8 @@ struct hw_perf_event {
|
|||
struct hrtimer hrtimer;
|
||||
};
|
||||
#ifdef CONFIG_HAVE_HW_BREAKPOINT
|
||||
union { /* breakpoint */
|
||||
struct arch_hw_breakpoint info;
|
||||
};
|
||||
/* breakpoint */
|
||||
struct arch_hw_breakpoint info;
|
||||
#endif
|
||||
};
|
||||
atomic64_t prev_count;
|
||||
|
|
@ -802,6 +801,13 @@ struct perf_sample_data {
|
|||
struct perf_raw_record *raw;
|
||||
};
|
||||
|
||||
static inline
|
||||
void perf_sample_data_init(struct perf_sample_data *data, u64 addr)
|
||||
{
|
||||
data->addr = addr;
|
||||
data->raw = NULL;
|
||||
}
|
||||
|
||||
extern void perf_output_sample(struct perf_output_handle *handle,
|
||||
struct perf_event_header *header,
|
||||
struct perf_sample_data *data,
|
||||
|
|
@ -858,6 +864,21 @@ extern int sysctl_perf_event_paranoid;
|
|||
extern int sysctl_perf_event_mlock;
|
||||
extern int sysctl_perf_event_sample_rate;
|
||||
|
||||
static inline bool perf_paranoid_tracepoint_raw(void)
|
||||
{
|
||||
return sysctl_perf_event_paranoid > -1;
|
||||
}
|
||||
|
||||
static inline bool perf_paranoid_cpu(void)
|
||||
{
|
||||
return sysctl_perf_event_paranoid > 0;
|
||||
}
|
||||
|
||||
static inline bool perf_paranoid_kernel(void)
|
||||
{
|
||||
return sysctl_perf_event_paranoid > 1;
|
||||
}
|
||||
|
||||
extern void perf_event_init(void);
|
||||
extern void perf_tp_event(int event_id, u64 addr, u64 count, void *record, int entry_size);
|
||||
extern void perf_bp_event(struct perf_event *event, void *data);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue