summaryrefslogtreecommitdiffstats
path: root/tapset/LKET/process.stp
diff options
context:
space:
mode:
authorguanglei <guanglei>2006-09-19 08:01:26 +0000
committerguanglei <guanglei>2006-09-19 08:01:26 +0000
commitb96baad9f8f5bf04c3d136ed16fe59270ae947e9 (patch)
treeb7b422525ee275287c3fc3f445532c36482e85b9 /tapset/LKET/process.stp
parent925cc0e2aab50e47acf8a005cdee7fc699944f41 (diff)
downloadsystemtap-steved-b96baad9f8f5bf04c3d136ed16fe59270ae947e9.tar.gz
systemtap-steved-b96baad9f8f5bf04c3d136ed16fe59270ae947e9.tar.xz
systemtap-steved-b96baad9f8f5bf04c3d136ed16fe59270ae947e9.zip
lket_trace.stp,process.stp,register_event.stp:
Be sync with the runtime printing changes made by Martin lket/b2a/lket_b2a.c, lket/b2a/lket_b2a.h: Be sync with the recent runtime printing changes made by Martin. Some clean up work before adding the support of dumping data into MySQL Bug fix of segment fault when an event is not registered.
Diffstat (limited to 'tapset/LKET/process.stp')
-rwxr-xr-xtapset/LKET/process.stp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tapset/LKET/process.stp b/tapset/LKET/process.stp
index 238f1b20..84a2bd80 100755
--- a/tapset/LKET/process.stp
+++ b/tapset/LKET/process.stp
@@ -36,6 +36,7 @@ function process_snapshot()
%{
struct task_struct *tsk;
struct list_head *cur, *head;
+ _stp_pbuf *pb;
int cpu = smp_processor_id();
char *total_length;
head = &(current->tasks);
@@ -47,8 +48,9 @@ function process_snapshot()
_lket_trace(_GROUP_PROCESS, _HOOKID_PROCESS_SNAPSHOT, "%4b%4b%4b%0s",
(_FMT_)tsk->pid, (_FMT_)tsk->tgid, (_FMT_)tsk->parent->tgid, tsk->comm);
#if !defined(ASCII_TRACE)
- total_length = &_stp_pbuf[cpu][STP_PRINT_BUF_START];
- *(int16_t *)total_length = _stp_pbuf_len[cpu] - 4;
+ pb = &__get_cpu_var(Stp_pbuf);
+ total_length = &pb->buf[0];
+ *(int16_t *)total_length = pb->len - 4;
#endif
_stp_print_flush();
}