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: <eb050960-b2bb-4dbe-7879-a0dd3935556e@huawei.com>
Date:   Thu, 7 Sep 2023 09:01:30 +0800
From:   Zheng Yejian <zhengyejian1@...wei.com>
To:     Steven Rostedt <rostedt@...dmis.org>,
        Naresh Kamboju <naresh.kamboju@...aro.org>
CC:     <akaher@...are.com>, <linux-kernel@...r.kernel.org>,
        <linux-kselftest@...r.kernel.org>,
        <linux-trace-kernel@...r.kernel.org>, <mhiramat@...nel.org>,
        <shuah@...nel.org>, <skhan@...uxfoundation.org>,
        <yeweihua4@...wei.com>
Subject: Re: "[PATCH] selftests/ftrace: Correctly enable event in
 instance-event.tc"

On 2023/9/7 05:37, Steven Rostedt wrote:
> On Wed, 6 Sep 2023 10:37:18 -0400
> Steven Rostedt <rostedt@...dmis.org> wrote:
> 
>>> Log details,
>>> -------------
>>> # ok 45 ftrace - test tracing error log support
>>> <47>[ 1373.662292] systemd-journald[90]: Sent WATCHDOG=1 notification.
>>> # ok 46 Test creation and deletion of trace instances while setting an event
>>
>> It's definitely a race with the creation and deletion of instances.
>>
>> I'm going to run it on my laptop VM and see if that reproduces it. My other
>> VM is on a pretty powerful machine, and perhaps that's keeping it from
>> hitting the race.
> 
> Putting in a while loop of:
> 
>    # while :; do ./ftracetest test.d/instances/instance-event.tc ; done
> 

In test.d/instances/instance-event.tc, concurrently create/delete/access
intances just about 1 second and then killed them, it may cause missing
the race.

No longer sleep and kill, following testcase can also reproduce:
```
#!/bin/bash

cd /sys/kernel/tracing/instances

instance_slam() {
   while :; do
           mkdir foo 2> /dev/null
           rmdir foo 2> /dev/null
   done
}

instance_set() {
         while :; do
                 echo 1 > foo/events/sched/sched_switch/enable
         done 2> /dev/null
}

instance_slam &
p1=$!
echo $p1

instance_set &
p2=$!
echo $p2
```

--

Thanks,
Zheng Yejian

> eventually triggered the bug. Looks like this is really an existing bug not
> related to the eventfs, but the eventfs code actually opened up the window
> of this race.
> 
> Hopefully I'll have a fix shortly.
> 
> -- Steve
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ