relayd: replace uses of block FDs by the fs_handle interface
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 30 Jan 2020 06:27:16 +0000 (01:27 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 30 Jan 2020 19:46:10 +0000 (14:46 -0500)
commit8bb66c3cd60938352927ee865759433387324250
tree921e184ca26c86c11a11b53fbc3cf9b90a57d7b9
parentf7c3ffd79ddcece895eb0de616001d549aced5fc
relayd: replace uses of block FDs by the fs_handle interface

Replace all usage of "raw" block-device file descriptors for
relay_streams, viewer_streams, and index files by the fs_handle.

Wrappers are introduced for read, write, seek and truncate operations
in order to reduce code duplication as all uses of fs_handles implies
getting an fd, using it, and putting it back. Those operations allow
the fd-tracker to suspend and restore fs_handles as needed.

The stream_fd util is eliminated as it is completely replaced by
the fs_handle interface.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: Iedff88d27aeba3891d4e8818b9e08e4b16a927cc
17 files changed:
src/bin/lttng-relayd/Makefile.am
src/bin/lttng-relayd/index.c
src/bin/lttng-relayd/index.h
src/bin/lttng-relayd/live.c
src/bin/lttng-relayd/stream-fd.c [deleted file]
src/bin/lttng-relayd/stream-fd.h [deleted file]
src/bin/lttng-relayd/stream.c
src/bin/lttng-relayd/stream.h
src/bin/lttng-relayd/viewer-stream.c
src/bin/lttng-relayd/viewer-stream.h
src/common/Makefile.am
src/common/fs-handle.c
src/common/fs-handle.h
src/common/index/index.c
src/common/index/index.h
src/common/trace-chunk.c
src/common/trace-chunk.h
This page took 0.027961 seconds and 4 git commands to generate.