[kgtp] r919 committed - Update patch

  • From: kgtp@xxxxxxxxxxxxxx
  • To: kgtp@xxxxxxxxxxxxx
  • Date: Fri, 17 Feb 2012 15:03:20 +0000

Revision: 919
Author:   teawater
Date:     Fri Feb 17 07:02:46 2012
Log:      Update patch

http://code.google.com/p/kgtp/source/detail?r=919

Modified:
 /trunk/gtp_for_review.patch

=======================================
--- /trunk/gtp_for_review.patch Mon Feb 13 16:28:10 2012
+++ /trunk/gtp_for_review.patch Fri Feb 17 07:02:46 2012
@@ -10,11 +10,11 @@
  kernel/events/core.c                   |   14
  lib/Kconfig.debug                      |   10
  lib/Makefile                           |    4
- lib/gtp.c | 8433 +++++++++++++++++++++++++++++++++ + lib/gtp.c | 8452 +++++++++++++++++++++++++++++++++
  lib/gtp_rb.c                           |  495 +
  scripts/getgtprsp.pl                   |  102
  scripts/getmod.py                      |  132
- 13 files changed, 11007 insertions(+), 2 deletions(-)
+ 13 files changed, 11026 insertions(+), 2 deletions(-)

 --- /dev/null
 +++ b/Documentation/trace/gtp.txt
@@ -1951,7 +1951,7 @@
 +gtp.o: gtp_rb.c
 --- /dev/null
 +++ b/lib/gtp.c
-@@ -0,0 +1,8433 @@
+@@ -0,0 +1,8452 @@
 +/*
 + * Kernel GDB tracepoint module.
 + *
@@ -2231,7 +2231,8 @@
 +      GTP_VAR_HARDIRQ_COUNT_ID,
 +      GTP_VAR_SOFTIRQ_COUNT_ID,
 +      GTP_VAR_IRQ_COUNT_ID,
-+      GTP_VAR_SPECIAL_MAX = GTP_VAR_IRQ_COUNT_ID,
++      GTP_VAR_PIPE_TRACE_ID,
++      GTP_VAR_SPECIAL_MAX = GTP_VAR_PIPE_TRACE_ID,
 +};
 +
 +#define PREV_VAR      NULL
@@ -2365,6 +2366,15 @@
 +#undef PREV_VAR
 +#define PREV_VAR      (&gtp_var_no_self_trace)
 +
++static struct gtp_var         gtp_var_pipe_trace = {
++      .next           = PREV_VAR,
++      .num            = GTP_VAR_PIPE_TRACE_ID,
++      .src            = "0:1:706970655f7472616365",
++      .per_cpu        = NULL,
++};
++#undef PREV_VAR
++#define PREV_VAR      (&gtp_var_pipe_trace)
++
 +static struct gtp_var         gtp_var_cpu_number = {
 +      .next           = PREV_VAR,
 +      .num            = GTP_VAR_CPU_NUMBER_ID,
@@ -2524,6 +2534,8 @@
 +static uint64_t                       gtp_start_last_errno;
 +static int                    gtp_start_ignore_error;
 +
++static int                    gtp_pipe_trace;
++
 +#ifdef GTP_RB
 +#include "gtp_rb.c"
 +#endif
@@ -4868,14 +4880,15 @@
 +      if (gts->tpe->kpreg == 0)
 +              return;
 +
-+      if (gts->tpe->no_self_trace) {
-+              if (get_current()->pid == gtp_gtp_pid
-+                  || get_current()->pid == gtp_gtpframe_pid)
-+                      return;
 +#if defined(GTP_FTRACE_RING_BUFFER) || defined(GTP_RB)
-+              if (get_current()->pid == gtp_gtpframe_pipe_pid)
-+                      return;
++      if (!gtp_pipe_trace && get_current()->pid == gtp_gtpframe_pipe_pid)
++              return;
 +#endif
++
++      if (gts->tpe->no_self_trace
++          && (get_current()->pid == gtp_gtp_pid
++              || get_current()->pid == gtp_gtpframe_pid)) {
++                      return;
 +      }
 +
 +      if (gts->tpe->have_printk) {
@@ -7441,6 +7454,8 @@
 +                      var->val = val;
 +              if (num == GTP_VAR_IGNORE_ERROR_ID)
 +                      gtp_start_ignore_error = (int)val;
++              else if (num == GTP_VAR_PIPE_TRACE_ID)
++                      gtp_pipe_trace = (int)val;
 +
 +              return 0;
 +      }
@@ -8103,6 +8118,9 @@
 +      } else if (num == GTP_VAR_IGNORE_ERROR_ID) {
 +              val = (uint64_t)gtp_start_ignore_error;
 +              goto output_value;
++      } else if (num == GTP_VAR_PIPE_TRACE_ID) {
++              val = (uint64_t)gtp_pipe_trace;
++              goto output_value;
 +      } else if (num == GTP_VAR_VERSION_ID) {
 +              val = (uint64_t)GTP_VERSION;
 +              goto output_value;
@@ -10275,6 +10293,7 @@
 +      }
 +      gtp_start_last_errno = 0;
 +      gtp_start_ignore_error = 0;
++      gtp_pipe_trace = 0;
 +#ifdef GTP_RB
 +      gtp_traceframe_info = NULL;
 +      gtp_traceframe_info_len = 0;

Other related posts:

  • » [kgtp] r919 committed - Update patch - kgtp