Received: by 2002:ab2:69cc:0:b0:1f4:be93:e15a with SMTP id n12csp1430403lqp; Mon, 15 Apr 2024 06:31:34 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX2hvbXJYl+b1L9D41jo6nI0ZkSemU41jAzjMRto5X59O1Jg6I9fc881Z4jBZMWmY49Kxe38prTlLn6ULCaEdv92yV3gjEzgHav/w47YQ== X-Google-Smtp-Source: AGHT+IFHZ/gGDbU4RZSQIUdu16Sjhe3vP0L6qySh7xzQrAWl7yZVvkrXe60vD4M7/fSnIkrH2pqs X-Received: by 2002:a05:6a20:9742:b0:1a8:4e82:b1e5 with SMTP id hs2-20020a056a20974200b001a84e82b1e5mr8169756pzc.32.1713187894243; Mon, 15 Apr 2024 06:31:34 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713187894; cv=pass; d=google.com; s=arc-20160816; b=JMfDv3hCfgH3Yi2xUuoDzOfDgsKOZQ5w3Jhbn/tTfy8W0e+p9FtMYrar6fVS8O0PTB R0+xl6KNKg2iVj67ae9qegwsn6aXPA9UqM3aLH/1rEPKltpWRb63C53m73YzzLp0Z6+O L38vbrgydPG7JOIp0PwShi18X3215tV+J5078N/5W1l3QN3vIDO7smM34eDUDAlmvr/a bukzbY1K4Un/fL5uesa7o8Mwg3tfjUeNuRfyb5GpcdP2H9ONf7KUMYC75VkGchYufAe0 MKvtOF8wCvbx8oEffXPJdx5P9gCWuDapzTUuvT0i0Cz+4H5uKqhP6+HHOJv7Dka8gkfV HYgg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:user-agent:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=mV5TwTTFofo7Hr0MUgPsm9fSGisdc/rZSPC/dKdQApI=; fh=SIgps5XdV0XNwjZfT2uAI7g3mrspDldK9Qs8qQAfoa4=; b=N26g8OYaplDRXjeYlePM2ZyFf9qF4Piw+jMb8nE0N2FCZu44T4wbwZLC3eBXKpylvK 2GOqHjdugpuERXbCbO8kRIV3rIfd6d+3BDh16Wlq9OWghxPUIhvzYvjBimW5CRfXFvPl wLrWZvj/yh43QNGPlRK53qXz26vE4jqdpB+lc3DBz0O26vln56tCKiULLMJIRPb8hfhs nrhVFXstrR4zz4Fl4/01ZZTI3QxYGp7AM38IH91m//S9ra8e8RzJqSmasuGRa6JLQHun HOcDBp/2NP/11ZRtbaEcCMm2gJDeFrdDWrKBNDn/S1v1y7CZP6Lc9oxqZuvPkJQeCC4r Dtuw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aWYJJHi2; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-145205-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-145205-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id k64-20020a628443000000b006ed1790830bsi8041445pfd.68.2024.04.15.06.31.33 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Apr 2024 06:31:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-145205-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aWYJJHi2; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-145205-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-145205-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 484FB28C7FD for ; Mon, 15 Apr 2024 13:16:56 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 49EEB84DFC; Mon, 15 Apr 2024 12:55:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="aWYJJHi2" 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 6C71C71743; Mon, 15 Apr 2024 12:55:43 +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=1713185743; cv=none; b=cERI9aVFVa527L+7VGJBnxb1NVkxIWG6FdRCto7DBU7nPwxm6wtlUzGACaCioW4Y0xfl06fwYZ3Ufo5SjsR3mUGi/+1nItMeEKjsTJumDo20GGqEPZf+5IPrLgmsNyohuz/X0TZsueyCaxV51L/wI/IzHQW8HgSFNusq76obzK0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713185743; c=relaxed/simple; bh=MTl3WOEWmkU7N1ZYT3IdZA3wW+cclx8nbkw1UKe91tQ=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version:Content-Type; b=gtj1zO+MkajHjoOaqb+XIGElj+NH3nLS3RfEzS7YXwZckRzT8p4QFCWTE7Bd+cIa5bCwqrO3jVeTVcEfacM3c2HKGMiRumbFdunAqKVEPzSB0H9PE8avKTgPGYsdNmPA4GE0tpHhnlLKNlecpKJcNfS3JREOfaIYVt7gxywrAo4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=aWYJJHi2; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id BD880C113CC; Mon, 15 Apr 2024 12:55:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1713185743; bh=MTl3WOEWmkU7N1ZYT3IdZA3wW+cclx8nbkw1UKe91tQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=aWYJJHi2t+orKfhSNG+IHnPiMPNkzL/ZN5HnX0rTTbuOteeJGbTfKNLKwWJiW6pzG kKyQayGbu67LN4s6HBEdn0SzzXwwvm+dpcFEUIW3WPFxKbGlHnxGzXFnWgDnP0U3Yo wEMGwGCeKrpgE64cVbgCVfbbphs+D2PZsXxZPquqqBZWL3DTYBd7w73nwknbKxNomX ObOQ4s5oj83lqLaSevWNPMGM9K48chCMvt+41QUVWnGp8Id38Dn67X1Ga+RiL2MAzt ej/zqpP8nhBkFBxQdUpESkcIxZxU/IoutM83qz1x+Rx7CZ/PQOubx5Q3KpPPZerwYF 4qOVUwQbvkwAw== From: "Masami Hiramatsu (Google)" To: Alexei Starovoitov , Steven Rostedt , Florent Revest Cc: linux-trace-kernel@vger.kernel.org, LKML , Martin KaFai Lau , bpf , Sven Schnelle , Alexei Starovoitov , Jiri Olsa , Arnaldo Carvalho de Melo , Daniel Borkmann , Alan Maguire , Mark Rutland , Peter Zijlstra , Thomas Gleixner , Guo Ren Subject: [PATCH v9 34/36] selftests/ftrace: Add a test case for repeating register/unregister fprobe Date: Mon, 15 Apr 2024 21:55:37 +0900 Message-Id: <171318573735.254850.12911788069293216933.stgit@devnote2> X-Mailer: git-send-email 2.34.1 In-Reply-To: <171318533841.254850.15841395205784342850.stgit@devnote2> References: <171318533841.254850.15841395205784342850.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: 8bit 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_remove_fprobe_repeat.tc diff --git a/tools/testing/selftests/ftrace/test.d/dynevent/add_remove_fprobe_repeat.tc b/tools/testing/selftests/ftrace/test.d/dynevent/add_remove_fprobe_repeat.tc new file mode 100644 index 000000000000..b4ad09237e2a --- /dev/null +++ b/tools/testing/selftests/ftrace/test.d/dynevent/add_remove_fprobe_repeat.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=$FUNCTION_FORK +REPEAT_TIMES=64 + +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