X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=include%2Flttng%2Fkernel-probe-internal.h;h=06c3d7c7e77e097c2cc7b23b36f733a969252297;hb=4bd69c5f1161cd065f487da0f4c1aa03a73c47e4;hp=381c6a411e7dddf8225c415880fee3738812e4a0;hpb=077192fd1880652a61400b493a0b6cf5bb199435;p=lttng-tools.git diff --git a/include/lttng/kernel-probe-internal.h b/include/lttng/kernel-probe-internal.h index 381c6a411..06c3d7c7e 100644 --- a/include/lttng/kernel-probe-internal.h +++ b/include/lttng/kernel-probe-internal.h @@ -18,6 +18,7 @@ struct lttng_payload; struct lttng_payload_view; struct lttng_dynamic_buffer; +struct mi_writer; typedef bool (*kernel_probe_location_equal_cb)( const struct lttng_kernel_probe_location *a, @@ -31,6 +32,11 @@ typedef bool (*kernel_probe_location_equal_cb)( typedef ssize_t (*kernel_probe_location_create_from_payload_cb)( struct lttng_payload_view *view, struct lttng_kernel_probe_location **kernel_probe_location); +typedef unsigned long (*kernel_probe_location_hash_cb)( + const struct lttng_kernel_probe_location *location); +typedef enum lttng_error_code (*kernel_probe_location_mi_serialize_cb)( + const struct lttng_kernel_probe_location *location, + struct mi_writer *writer); struct lttng_kernel_probe_location_comm { /* enum lttng_kernel_probe_location_type */ @@ -63,6 +69,8 @@ struct lttng_kernel_probe_location { enum lttng_kernel_probe_location_type type; kernel_probe_location_equal_cb equal; kernel_probe_location_serialize_cb serialize; + kernel_probe_location_hash_cb hash; + kernel_probe_location_mi_serialize_cb mi_serialize; }; struct lttng_kernel_probe_location_symbol { @@ -76,23 +84,26 @@ struct lttng_kernel_probe_location_address { uint64_t address; }; -LTTNG_HIDDEN int lttng_kernel_probe_location_serialize( const struct lttng_kernel_probe_location *location, struct lttng_payload *payload); -LTTNG_HIDDEN ssize_t lttng_kernel_probe_location_create_from_payload( struct lttng_payload_view *view, struct lttng_kernel_probe_location **probe_location); -LTTNG_HIDDEN bool lttng_kernel_probe_location_is_equal( const struct lttng_kernel_probe_location *a, const struct lttng_kernel_probe_location *b); -LTTNG_HIDDEN struct lttng_kernel_probe_location *lttng_kernel_probe_location_copy( const struct lttng_kernel_probe_location *location); +unsigned long lttng_kernel_probe_location_hash( + const struct lttng_kernel_probe_location *location); + +enum lttng_error_code lttng_kernel_probe_location_mi_serialize( + const struct lttng_kernel_probe_location *location, + struct mi_writer *writer); + #endif /* LTTNG_KERNEL_PROBE_INTERNAL_H */