selftests/ftrace: Fix bash specific "==" operator

[ Upstream commit 1e6b485c92 ]

Since commit a1d6cd88c8 ("selftests/ftrace: event_triggers: wait
longer for test_event_enable") introduced bash specific "=="
comparation operator, that test will fail when we run it on a
posix-shell. `checkbashisms` warned it as below.

possible bashism in ftrace/func_event_triggers.tc line 45 (should be 'b = a'):
        if [ "$e" == $val ]; then

This replaces it with "=".

Fixes: a1d6cd88c8 ("selftests/ftrace: event_triggers: wait longer for test_event_enable")
Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Reviewed-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
Masami Hiramatsu (Google) 2023-01-22 08:32:50 +09:00 committed by Greg Kroah-Hartman
parent 16a35042ff
commit 6e0a0eb18e

View file

@ -46,7 +46,7 @@ test_event_enabled() {
while [ $check_times -ne 0 ]; do
e=`cat $EVENT_ENABLE`
if [ "$e" == $val ]; then
if [ "$e" = $val ]; then
return 0
fi
sleep $SLEEP_TIME