X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=tests%2Futils%2Ftestapp%2Fuserspace-probe-sdt-binary%2Fsema.c;fp=tests%2Futils%2Ftestapp%2Fuserspace-probe-sdt-binary%2Fsema.c;h=ef8ed2629ddc6bc6fafa5c3fb3f26238593776aa;hp=ffe2b5c6016a50355ba5de3d2f2df49b5e4a566d;hb=2f101846a0f504e64d37bf93c3b67d531f5a3b65;hpb=7ebbf3f02689e6d437206297230cbf264f67e3be diff --git a/tests/utils/testapp/userspace-probe-sdt-binary/sema.c b/tests/utils/testapp/userspace-probe-sdt-binary/sema.c index ffe2b5c60..ef8ed2629 100644 --- a/tests/utils/testapp/userspace-probe-sdt-binary/sema.c +++ b/tests/utils/testapp/userspace-probe-sdt-binary/sema.c @@ -5,9 +5,16 @@ * */ +/* + * The order of inclusion is important here: including sdt.h _after_ the probe + * declarations ensures that semaphore-protected SDT probes are + * generated. See SYSTEMTAP(2) for more details. + */ +/* clang-format off */ #include "foobar_provider.h" - #include +/* clang-format on */ + void sema_function() { FOOBAR_TP_WITH_SEMAPHORE();