X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=tests%2Futils%2Futils.sh;h=da23f7abeb1780191b86e41a0a88219fd32eeb56;hb=654f9f5e49aae2669d8ae771650b5e2dce5d660f;hp=42b344138d9f176ef2fcb39e37fbec9acc2e994b;hpb=e4f8013bd2dadd7f44f8b70e15800193728e2dea;p=lttng-tools.git diff --git a/tests/utils/utils.sh b/tests/utils/utils.sh index 42b344138..da23f7abe 100644 --- a/tests/utils/utils.sh +++ b/tests/utils/utils.sh @@ -86,6 +86,16 @@ function randstring() echo } +# Return the number of _configured_ CPUs. +function conf_proc_count() +{ + getconf _NPROCESSORS_CONF + if [ $? -ne 0 ]; then + diag "Failed to get the number of configured CPUs" + fi + echo +} + function enable_kernel_lttng_event { local expected_to_fail="$1"