#include <lttng/lttng.h>
#include <common/lttng-kernel.h>
#include <common/lttng-kernel-old.h>
+#include <common/defaults.h>
#include "consumer.h"
int fd;
int state;
/* Format is %s_%d respectively channel name and CPU number. */
- char name[LTTNG_SYMBOL_NAME_LEN];
+ char name[DEFAULT_STREAM_NAME_LEN];
struct cds_list_head list;
};
#include <lttng/lttng.h>
#include <common/hashtable/hashtable.h>
+#include <common/defaults.h>
#include "consumer.h"
#include "ust-ctl.h"
int handle;
char pathname[PATH_MAX];
/* Format is %s_%d respectively channel name and CPU number. */
- char name[LTTNG_SYMBOL_NAME_LEN];
+ char name[DEFAULT_STREAM_NAME_LEN];
struct lttng_ust_object_data *obj;
/* Using a list of streams to keep order. */
struct cds_list_head list;
*/
#define DEFAULT_POLL_SIZE 65535
+/*
+ * Format is %s_%d respectively channel name and CPU number. Eigth bytes
+ * are added here to add space for the CPU number. I guess 2^8 CPUs is more
+ * than enough. We might end up with quantum computing in a cell phone when
+ * reaching this limit.
+ */
+#define DEFAULT_STREAM_NAME_LEN LTTNG_SYMBOL_NAME_LEN + 8
+
/* Default channel attributes */
#define DEFAULT_CHANNEL_NAME "channel0"
#define DEFAULT_CHANNEL_OVERWRITE 0 /* usec */
#include <stdint.h>
#include <lttng/lttng.h>
+#include <common/defaults.h>
#define RELAYD_VERSION_COMM_MAJOR 2
#define RELAYD_VERSION_COMM_MINOR 1
* Used to add a stream on the relay daemon.
*/
struct lttcomm_relayd_add_stream {
- char channel_name[LTTNG_SYMBOL_NAME_LEN];
+ char channel_name[DEFAULT_STREAM_NAME_LEN];
char pathname[PATH_MAX];
} __attribute__ ((__packed__));
#include <lttng/lttng.h>
#include <common/compat/socket.h>
#include <common/uri.h>
+#include <common/defaults.h>
#include <arpa/inet.h>
#include <netinet/in.h>
char path_name[PATH_MAX];
int net_index;
unsigned int metadata_flag;
- char name[LTTNG_SYMBOL_NAME_LEN]; /* Name string of the stream */
+ char name[DEFAULT_STREAM_NAME_LEN]; /* Name string of the stream */
uint64_t session_id; /* Tracing session id of the stream */
} stream;
struct {