selftests/ftrace: fix event-no-pid on 1-core machine
stable inclusion from stable-5.10.50 commit 786461739ac4bcd87218478920ade53c7ca04ce9 bugzilla: 174522 https://gitee.com/openeuler/kernel/issues/I4DNFY Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=786461739ac4bcd87218478920ade53c7ca04ce9 -------------------------------- [ Upstream commit 07b60713 ] 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: ebed9628 ("selftests/ftrace: Add test to test new set_event_notrace_pid file") Signed-off-by: NKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Acked-by: NSteven Rostedt (VMware) <rostedt@goodmis.org> Signed-off-by: NShuah Khan <skhan@linuxfoundation.org> Signed-off-by: NSasha Levin <sashal@kernel.org> Signed-off-by: NChen Jun <chenjun102@huawei.com> Acked-by: NWeilong Chen <chenweilong@huawei.com> Signed-off-by: NChen Jun <chenjun102@huawei.com> Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Showing
想要评论请 注册 或 登录