Implement snapshot commands in lttng-sessiond

Basic functionalities are implemented in the session daemon so handle
snapshots and send the command to the consumer but note that at this
commit the consumer does not handle snapshot.

Signed-off-by: David Goulet <dgoulet@efficios.com>
[HEAD MERGE] Flight recorder feature

Signed-off-by: David Goulet <dgoulet@efficios.com>
[HEAD MERGE] Kernel snapshot support

**ADD CHANGELOG**

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] add kernel consumer destroy channel. NOT COMPLETED

Signed-off-by: David Goulet <dgoulet@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] free stream in the no monitor list on del channel

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] Some fixes. Veille technologique (RLNX inside)

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] destroy kernel channel fix

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] sessiond destroy metadata

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] close and free metadata stream on destroy channel kernel

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] add destroy metadata after metadata snapshot in sessiond

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] don't send metadata if session no output

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] fix crass malfait

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] fix crass malfait

Signed-off-by: David Goulet <dgoulet@efficios.com>
[MERGE] don't close metadata stream on del channel

Signed-off-by: David Goulet <dgoulet@efficios.com>
Squash 5 commits

fix channel/stream output mixup, return core and add basic test
close metadata
fix return code + validate trace multiple events
test files
enable all tests

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
fix refcount metadata no-monitor

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
fix return line

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
test files

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
fix num_tests and add to root_regression

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Fix: update channel refcount if in monitor mode

Also RCU read side lock are added. There are not needed but it's an
extra precaution to we don't have a hard requirement for those functions
to be called with it.

Signed-off-by: David Goulet <dgoulet@efficios.com>