diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-02-22 11:55:32 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-02-22 11:55:32 -0500 |
commit | bee415ce427d1eab6cfb30221461c7d20cbf1903 (patch) | |
tree | 406b70a86768535105b226c2b2f0a59b301cc52e /tools | |
parent | 627fa177a1502ad24390d945851209ac022f3a36 (diff) | |
parent | 388c3aab5d4f1b0bbfe2d5f47e7cd681866bc573 (diff) |
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 probe: Init struct probe_point and set counter correctly
hw-breakpoint: Keep track of dr7 local enable bits
hw-breakpoints: Accept breakpoints on NULL address
perf_events: Fix FORK events
Diffstat (limited to 'tools')
-rw-r--r-- | tools/perf/util/probe-event.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c index 29465d440043..fde17b090a47 100644 --- a/tools/perf/util/probe-event.c +++ b/tools/perf/util/probe-event.c | |||
@@ -272,6 +272,7 @@ int synthesize_perf_probe_point(struct probe_point *pp) | |||
272 | int ret; | 272 | int ret; |
273 | 273 | ||
274 | pp->probes[0] = buf = zalloc(MAX_CMDLEN); | 274 | pp->probes[0] = buf = zalloc(MAX_CMDLEN); |
275 | pp->found = 1; | ||
275 | if (!buf) | 276 | if (!buf) |
276 | die("Failed to allocate memory by zalloc."); | 277 | die("Failed to allocate memory by zalloc."); |
277 | if (pp->offset) { | 278 | if (pp->offset) { |
@@ -294,6 +295,7 @@ int synthesize_perf_probe_point(struct probe_point *pp) | |||
294 | error: | 295 | error: |
295 | free(pp->probes[0]); | 296 | free(pp->probes[0]); |
296 | pp->probes[0] = NULL; | 297 | pp->probes[0] = NULL; |
298 | pp->found = 0; | ||
297 | } | 299 | } |
298 | return ret; | 300 | return ret; |
299 | } | 301 | } |
@@ -455,6 +457,7 @@ void show_perf_probe_events(void) | |||
455 | struct strlist *rawlist; | 457 | struct strlist *rawlist; |
456 | struct str_node *ent; | 458 | struct str_node *ent; |
457 | 459 | ||
460 | memset(&pp, 0, sizeof(pp)); | ||
458 | fd = open_kprobe_events(O_RDONLY, 0); | 461 | fd = open_kprobe_events(O_RDONLY, 0); |
459 | rawlist = get_trace_kprobe_event_rawlist(fd); | 462 | rawlist = get_trace_kprobe_event_rawlist(fd); |
460 | close(fd); | 463 | close(fd); |