Callsite: add "ip" context
authorWoegerer, Paul <Paul_Woegerer@mentor.com>
Wed, 10 Jul 2013 09:06:45 +0000 (11:06 +0200)
committerDavid Goulet <dgoulet@efficios.com>
Wed, 10 Jul 2013 22:17:24 +0000 (18:17 -0400)
Support ip context in lttng add-context -t.

Acked-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
include/lttng/lttng.h
src/bin/lttng-sessiond/lttng-ust-abi.h
src/bin/lttng-sessiond/trace-ust.c
src/bin/lttng/commands/add_context.c

index 83232454f865c5b38d5ed00dcd117c8b538c40e0..3e7fb63169e83b780ad247a3fda616bbade91050 100644 (file)
@@ -126,6 +126,7 @@ enum lttng_event_context_type {
        LTTNG_EVENT_CONTEXT_VPPID             = 9,
        LTTNG_EVENT_CONTEXT_PTHREAD_ID        = 10,
        LTTNG_EVENT_CONTEXT_HOSTNAME          = 11,
+       LTTNG_EVENT_CONTEXT_IP                = 12,
 };
 
 enum lttng_calibrate_type {
index 03d2e65f6059ed4bd6359ef10f860fd7c79c95ac..6326b1e6c1413375ab732e5928127aec0f48aed9 100644 (file)
@@ -139,6 +139,7 @@ enum lttng_ust_context_type {
        LTTNG_UST_CONTEXT_VPID                  = 1,
        LTTNG_UST_CONTEXT_PTHREAD_ID            = 2,
        LTTNG_UST_CONTEXT_PROCNAME              = 3,
+       LTTNG_UST_CONTEXT_IP                    = 4,
 };
 
 #define LTTNG_UST_CONTEXT_PADDING1     16
index 65fe84b7d37617a17d3d4a68130d2138158f1a8d..77f5e2510552f36b784e38816d5539671e66d26f 100644 (file)
@@ -432,6 +432,9 @@ struct ltt_ust_context *trace_ust_create_context(
        case LTTNG_EVENT_CONTEXT_PROCNAME:
                utype = LTTNG_UST_CONTEXT_PROCNAME;
                break;
+       case LTTNG_EVENT_CONTEXT_IP:
+               utype = LTTNG_UST_CONTEXT_IP;
+               break;
        default:
                ERR("Invalid UST context");
                return NULL;
index 4904d2772b5181bb835d928595671b456b38f562..fad85b50aa5c263fa108f0faae44fa9936e4ed20 100644 (file)
@@ -67,6 +67,7 @@ enum context_type {
        CONTEXT_VPPID        = 9,
        CONTEXT_PTHREAD_ID   = 10,
        CONTEXT_HOSTNAME     = 11,
+       CONTEXT_IP           = 12,
 };
 
 /*
@@ -203,6 +204,7 @@ const struct ctx_opts {
        { "ppid", CONTEXT_PPID },
        { "vppid", CONTEXT_VPPID },
        { "hostname", CONTEXT_HOSTNAME },
+       { "ip", CONTEXT_IP },
        /* Perf options */
        PERF_HW(cpu-cycles, CPU_CYCLES),
        PERF_HW(cycles, CPU_CYCLES),
This page took 0.027299 seconds and 4 git commands to generate.