Move the getcpu plugin implementation to liblttn-ust-common
[lttng-ust.git] / src / lib / lttng-ust / ust-core.c
index d4829904304c2314bfefe78c6f4f7e5b5d6b466e..e547a4972b2c9f0344973c89a226ce5110a6ea74 100644 (file)
 #include <stdlib.h>
 
 #include "context-internal.h"
-#include "ust-events-internal.h"
+#include "lib/lttng-ust/events.h"
 #include "common/logging.h"
 #include "lttng-tracer-core.h"
 #include "lttng-rb-clients.h"
 #include "lttng-counter-client.h"
-#include "jhash.h"
+#include "common/jhash.h"
 
 static CDS_LIST_HEAD(lttng_transport_list);
 static CDS_LIST_HEAD(lttng_counter_transport_list);
@@ -86,41 +86,21 @@ void lttng_counter_transport_unregister(struct lttng_counter_transport *transpor
        cds_list_del(&transport->node);
 }
 
-/*
- * Needed by comm layer.
- */
-struct lttng_enum *lttng_ust_enum_get_from_desc(struct lttng_ust_session *session,
-               const struct lttng_ust_enum_desc *enum_desc)
-{
-       struct lttng_enum *_enum;
-       struct cds_hlist_head *head;
-       struct cds_hlist_node *node;
-       size_t name_len = strlen(enum_desc->name);
-       uint32_t hash;
-
-       hash = jhash(enum_desc->name, name_len, 0);
-       head = &session->priv->enums_ht.table[hash & (LTTNG_UST_ENUM_HT_SIZE - 1)];
-       cds_hlist_for_each_entry(_enum, node, head, hlist) {
-               assert(_enum->desc);
-               if (_enum->desc == enum_desc)
-                       return _enum;
-       }
-       return NULL;
-}
-
 size_t lttng_ust_dummy_get_size(void *priv __attribute__((unused)),
+               struct lttng_ust_probe_ctx *probe_ctx __attribute__((unused)),
                size_t offset)
 {
        size_t size = 0;
 
-       size += lttng_ust_lib_ring_buffer_align(offset, lttng_ust_rb_alignof(char));
+       size += lttng_ust_ring_buffer_align(offset, lttng_ust_rb_alignof(char));
        size += sizeof(char);           /* tag */
        return size;
 }
 
 void lttng_ust_dummy_record(void *priv __attribute__((unused)),
-                struct lttng_ust_lib_ring_buffer_ctx *ctx,
-                struct lttng_ust_channel_buffer *chan)
+               struct lttng_ust_probe_ctx *probe_ctx __attribute__((unused)),
+               struct lttng_ust_ring_buffer_ctx *ctx,
+               struct lttng_ust_channel_buffer *chan)
 {
        char sel_char = (char) LTTNG_UST_DYNAMIC_TYPE_NONE;
 
@@ -128,6 +108,7 @@ void lttng_ust_dummy_record(void *priv __attribute__((unused)),
 }
 
 void lttng_ust_dummy_get_value(void *priv __attribute__((unused)),
+               struct lttng_ust_probe_ctx *probe_ctx __attribute__((unused)),
                struct lttng_ust_ctx_value *value)
 {
        value->sel = LTTNG_UST_DYNAMIC_TYPE_NONE;
This page took 0.024099 seconds and 4 git commands to generate.