SoW-2020-0002: Trace Hit Counters
[deliverable/lttng-ust.git] / include / lttng / ust-ctl.h
index 2c15a54e550bd88e36d5c54b57dbe584a590a447..56e7951c6a7212454f065764f585367f710113d3 100644 (file)
@@ -1,19 +1,8 @@
 /*
- * Copyright (C) 2011 - Julien Desfossez <julien.desfossez@polymtl.ca>
- * Copyright (C) 2011-2013 - Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+ * SPDX-License-Identifier: GPL-2.0-only
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License only.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ * Copyright (C) 2011 Julien Desfossez <julien.desfossez@polymtl.ca>
+ * Copyright (C) 2011-2013 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
  */
 
 #ifndef _LTTNG_UST_CTL_H
@@ -550,13 +539,15 @@ int ustctl_recv_register_event(int sock,
                                         */
        size_t *nr_fields,
        struct ustctl_field **fields,
-       char **model_emf_uri);
+       char **model_emf_uri,
+       uint64_t *user_token);
 
 /*
  * Returns 0 on success, negative error value on error.
  */
 int ustctl_reply_register_event(int sock,
-       uint32_t id,                    /* event id (input) */
+       uint32_t event_id,              /* event id (input) */
+       uint64_t counter_index,         /* counter index (input) */
        int ret_code);                  /* return code. 0 ok, negative error */
 
 /*
@@ -597,8 +588,8 @@ int ustctl_reply_register_channel(int sock,
  */
 
 enum ustctl_counter_bitness {
-       USTCTL_COUNTER_BITNESS_32 = 4,
-       USTCTL_COUNTER_BITNESS_64 = 8,
+       USTCTL_COUNTER_BITNESS_32 = 0,
+       USTCTL_COUNTER_BITNESS_64 = 1,
 };
 
 enum ustctl_counter_arithmetic {
@@ -633,7 +624,8 @@ struct ustctl_daemon_counter *
                const int *counter_cpu_fds,
                enum ustctl_counter_bitness bitness,
                enum ustctl_counter_arithmetic arithmetic,
-               uint32_t alloc_flags);
+               uint32_t alloc_flags,
+               bool coalesce_hits);
 
 int ustctl_create_counter_data(struct ustctl_daemon_counter *counter,
                struct lttng_ust_object_data **counter_data);
@@ -658,6 +650,11 @@ int ustctl_send_counter_cpu_data_to_ust(int sock,
                struct lttng_ust_object_data *counter_data,
                struct lttng_ust_object_data *counter_cpu_data);
 
+int ustctl_counter_create_event(int sock,
+               struct lttng_ust_counter_event *counter_event,
+               struct lttng_ust_object_data *counter_data,
+               struct lttng_ust_object_data **counter_event_data);
+
 int ustctl_counter_read(struct ustctl_daemon_counter *counter,
                const size_t *dimension_indexes,
                int cpu, int64_t *value,
This page took 0.025148 seconds and 5 git commands to generate.