lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210623094614.1aa35179@gandalf.local.home>
Date:   Wed, 23 Jun 2021 09:46:14 -0400
From:   Steven Rostedt <rostedt@...dmis.org>
To:     Krzysztof Kozlowski <krzysztof.kozlowski@...onical.com>
Cc:     Ingo Molnar <mingo@...hat.com>, Shuah Khan <shuah@...nel.org>,
        linux-kselftest@...r.kernel.org, linux-kernel@...r.kernel.org,
        Shuah Khan <skhan@...uxfoundation.org>
Subject: Re: [PATCH v2] selftests/ftrace: fix event-no-pid on 1-core machine

Shuah,

Want to take this in your tree?

-- Steve


On Wed, 23 Jun 2021 15:43:15 +0200
Krzysztof Kozlowski <krzysztof.kozlowski@...onical.com> wrote:

> When running event-no-pid test on small machines (e.g. cloud 1-core
> instance), other events might not happen:
> 
>     + cat trace
>     + cnt=0
>     + [ 0 -eq 0 ]
>     + fail No other events were recorded
>     [15] event tracing - restricts events based on pid notrace filtering [FAIL]
> 
> Schedule a simple sleep task to be sure that some other process events
> get recorded.
> 
> Fixes: ebed9628f5c2 ("selftests/ftrace: Add test to test new set_event_notrace_pid file")
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...onical.com>
> Acked-by: Steven Rostedt (VMware) <rostedt@...dmis.org>
> 
> ---
> 
> Changes since v1:
> 1. Correct spelling in commit msg.
> 2. Add Steven's ack.
> ---
>  .../testing/selftests/ftrace/test.d/event/event-no-pid.tc  | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/tools/testing/selftests/ftrace/test.d/event/event-no-pid.tc b/tools/testing/selftests/ftrace/test.d/event/event-no-pid.tc
> index e6eb78f0b954..9933ed24f901 100644
> --- a/tools/testing/selftests/ftrace/test.d/event/event-no-pid.tc
> +++ b/tools/testing/selftests/ftrace/test.d/event/event-no-pid.tc
> @@ -57,6 +57,10 @@ enable_events() {
>      echo 1 > tracing_on
>  }
>  
> +other_task() {
> +    sleep .001 || usleep 1 || sleep 1
> +}
> +
>  echo 0 > options/event-fork
>  
>  do_reset
> @@ -94,6 +98,9 @@ child=$!
>  echo "child = $child"
>  wait $child
>  
> +# Be sure some other events will happen for small systems (e.g. 1 core)
> +other_task
> +
>  echo 0 > tracing_on
>  
>  cnt=`count_pid $mypid`

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ