From nobody Tue Dec 23 08:42:37 2025 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 73D491632ED; Sat, 26 Oct 2024 04:38:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729917521; cv=none; b=jQeSUfax9kyvyyoplw1gAUDNkHFt2NNWjzlxUfx5FbOTm76ynnaTZQLdec8KlfBSSbybrGih7r5J41n76Dl2SBCuBzsoWHLS1Dfuc33QKwM0hsTzp24vXCBBnz4XFKJUQA42VC2kNwh5uciZi0fOaRbWrXhJYZ1G7CLTnvI8yi0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729917521; c=relaxed/simple; bh=MTl3WOEWmkU7N1ZYT3IdZA3wW+cclx8nbkw1UKe91tQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=j6z6NvVuMC7jSVqrUbqxR6zDglLyxReKHHk9qeE05I9nSVJDwY1DcpZiNLDp90owS4Dxmf6CLLTXQZg8/IS/h/QKlVJcY2Qx97ce4t9QuU+Cod0/CmBM+drcxkQ2V3RYF543TvxoZspqrFUGsZpKxOWHzAWmabPNPbFQtaqJo8w= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=oIt+kSOl; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="oIt+kSOl" Received: by smtp.kernel.org (Postfix) with ESMTPSA id F27D4C4CEC6; Sat, 26 Oct 2024 04:38:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1729917521; bh=MTl3WOEWmkU7N1ZYT3IdZA3wW+cclx8nbkw1UKe91tQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oIt+kSOlr2ZZomr+jNhvXv1MzK6q6gyfqkbanp1MyKUhJtoudniYPOXNVLXY4koRP 4XLQE9Ftd3ArY+uP5UxgxIpH8hQdxnGAvdTSXPdkVRNNTC7h6F+Hy1N30iLAzCBPeJ RNkYFtRqHiFNBhWfoSb5U4UokiobOPZjawBc6NCWw2x6Hg8Mmwqc54zrffA3D57uKz JytpHMo40sh3lk9Lm5nJAtX3loEyibXAE6Q/zllfxUqDuU9a+J3+AcZ99mR3m/AE+X KkFw6ue/QUazXhZBIvuJJHD2Q9DMuXo2AVyuXkT1uOlH0JxSg4nWt9QnD9RsTpygwY BplThSYVSkb6Q== From: "Masami Hiramatsu (Google)" To: Alexei Starovoitov , Steven Rostedt , Florent Revest Cc: linux-trace-kernel@vger.kernel.org, LKML , Martin KaFai Lau , bpf , Alexei Starovoitov , Jiri Olsa , Alan Maguire , Mark Rutland , linux-arch@vger.kernel.org Subject: [PATCH v18 15/17] selftests/ftrace: Add a test case for repeating register/unregister fprobe Date: Sat, 26 Oct 2024 13:38:35 +0900 Message-ID: <172991751550.443985.13331992311611471001.stgit@devnote2> X-Mailer: git-send-email 2.43.0 In-Reply-To: <172991731968.443985.4558065903004844780.stgit@devnote2> References: <172991731968.443985.4558065903004844780.stgit@devnote2> User-Agent: StGit/0.19 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable From: Masami Hiramatsu (Google) This test case repeats define and undefine the fprobe dynamic event to ensure that the fprobe does not cause any issue with such operations. Signed-off-by: Masami Hiramatsu (Google) --- .../test.d/dynevent/add_remove_fprobe_repeat.tc | 19 ++++++++++++++++= +++ 1 file changed, 19 insertions(+) create mode 100644 tools/testing/selftests/ftrace/test.d/dynevent/add_remo= ve_fprobe_repeat.tc diff --git a/tools/testing/selftests/ftrace/test.d/dynevent/add_remove_fpro= be_repeat.tc b/tools/testing/selftests/ftrace/test.d/dynevent/add_remove_fp= robe_repeat.tc new file mode 100644 index 000000000000..b4ad09237e2a --- /dev/null +++ b/tools/testing/selftests/ftrace/test.d/dynevent/add_remove_fprobe_repe= at.tc @@ -0,0 +1,19 @@ +#!/bin/sh +# SPDX-License-Identifier: GPL-2.0 +# description: Generic dynamic event - Repeating add/remove fprobe events +# requires: dynamic_events "f[:[/][]] [%return] [= ]":README + +echo 0 > events/enable +echo > dynamic_events + +PLACE=3D$FUNCTION_FORK +REPEAT_TIMES=3D64 + +for i in `seq 1 $REPEAT_TIMES`; do + echo "f:myevent $PLACE" >> dynamic_events + grep -q myevent dynamic_events + test -d events/fprobes/myevent + echo > dynamic_events +done + +clear_trace