| 1 | /* |
| 2 | * Copyright (C) 2011 EfficiOS Inc. |
| 3 | * |
| 4 | * SPDX-License-Identifier: GPL-2.0-only |
| 5 | * |
| 6 | */ |
| 7 | |
| 8 | #ifndef _UST_CONSUMER_H |
| 9 | #define _UST_CONSUMER_H |
| 10 | |
| 11 | #include "consumer.hpp" |
| 12 | #include "ust-app.hpp" |
| 13 | |
| 14 | #include <common/trace-chunk.hpp> |
| 15 | |
| 16 | #include <stdint.h> |
| 17 | |
| 18 | int ust_consumer_ask_channel(struct ust_app_session *ua_sess, |
| 19 | struct ust_app_channel *ua_chan, |
| 20 | struct consumer_output *consumer, |
| 21 | struct consumer_socket *socket, |
| 22 | lttng::sessiond::ust::registry_session *registry, |
| 23 | struct lttng_trace_chunk *trace_chunk); |
| 24 | |
| 25 | int ust_consumer_get_channel(struct consumer_socket *socket, struct ust_app_channel *ua_chan); |
| 26 | |
| 27 | int ust_consumer_destroy_channel(struct consumer_socket *socket, struct ust_app_channel *ua_chan); |
| 28 | |
| 29 | int ust_consumer_send_stream_to_ust(struct ust_app *app, |
| 30 | struct ust_app_channel *channel, |
| 31 | struct ust_app_stream *stream); |
| 32 | |
| 33 | int ust_consumer_send_channel_to_ust(struct ust_app *app, |
| 34 | struct ust_app_session *ua_sess, |
| 35 | struct ust_app_channel *channel); |
| 36 | |
| 37 | #ifdef HAVE_LIBLTTNG_UST_CTL |
| 38 | int ust_consumer_metadata_request(struct consumer_socket *sock); |
| 39 | #else |
| 40 | static inline int ust_consumer_metadata_request(struct consumer_socket *sock |
| 41 | __attribute__((unused))) |
| 42 | { |
| 43 | return -ENOSYS; |
| 44 | } |
| 45 | #endif /* HAVE_LIBLTTNG_UST_CTL */ |
| 46 | |
| 47 | #endif /* _UST_CONSUMER_H */ |