| 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 | #include <stdint.h> |
| 14 | #include <common/trace-chunk.hpp> |
| 15 | |
| 16 | int ust_consumer_ask_channel(struct ust_app_session *ua_sess, |
| 17 | struct ust_app_channel *ua_chan, |
| 18 | struct consumer_output *consumer, |
| 19 | struct consumer_socket *socket, |
| 20 | lttng::sessiond::ust::registry_session *registry, |
| 21 | struct lttng_trace_chunk *trace_chunk); |
| 22 | |
| 23 | int ust_consumer_get_channel(struct consumer_socket *socket, |
| 24 | struct ust_app_channel *ua_chan); |
| 25 | |
| 26 | int ust_consumer_destroy_channel(struct consumer_socket *socket, |
| 27 | 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, struct ust_app_stream *stream); |
| 31 | |
| 32 | int ust_consumer_send_channel_to_ust(struct ust_app *app, |
| 33 | struct ust_app_session *ua_sess, struct ust_app_channel *channel); |
| 34 | |
| 35 | #ifdef HAVE_LIBLTTNG_UST_CTL |
| 36 | int ust_consumer_metadata_request(struct consumer_socket *sock); |
| 37 | #else |
| 38 | static inline |
| 39 | int ust_consumer_metadata_request( |
| 40 | struct consumer_socket *sock __attribute__((unused))) |
| 41 | { |
| 42 | return -ENOSYS; |
| 43 | } |
| 44 | #endif /* HAVE_LIBLTTNG_UST_CTL */ |
| 45 | |
| 46 | #endif /* _UST_CONSUMER_H */ |