From: Jérémie Galarneau Date: Fri, 19 Jun 2020 22:44:56 +0000 (-0400) Subject: uprobe: transmit binary file descritptor through lttng_payload X-Git-Url: http://git.efficios.com/?p=lttng-tools.git;a=commitdiff_plain;h=e368fb4396b9bdb22de16f0c93512c9f6d7ab0b4;hp=e368fb4396b9bdb22de16f0c93512c9f6d7ab0b4 uprobe: transmit binary file descritptor through lttng_payload Adapt the userspace probe objects to use the lttng_payload interface. This streamlines the acquisition of the file descriptors when those objects are serialized. File descriptors are transmitted in both directions between liblttng-ctl and the session daemon making it possible (and safe) to compare userspace probe instances. Currently the event listing API does not allow us to express userspace probe locations that contain a file descriptor. This is an unfortunate consequence of returning a "flat" array to list events. Indeed, we can't store a file descriptor in the userspace probe locations returned to the user in this API since the destructors of the probe locations are never called. The user simply free()'s the returned array, which would leak the file descriptors. The consequence of this is that we can't allow the creation of event rules using a probe location returned by an lttng_list_events() call. This is not unsolvable, but I'm not sure if there really is a use-case for this. Signed-off-by: Jérémie Galarneau Change-Id: I0f710cbe9deabfd163206fd03618eba183f3d1d2 ---