From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796135115; b=CyM21HcUGlYtktH+D7EcC6OR/pEdGWov2d70mPXbz04tEt5ZSh+fbfAwUlD1ux7M1Tdo VLnaCfwzHMSMAeUrmATBeycB7z9iW5i4L8frkQG7BG8nyaIXMx7yl7q3aW6e5FbSmGgRn pVuxkmIoYOPvR0uxaV3aPQH0T2jLVh0/V6985QVv28ynqd+HDDkGqAMifxgNLy1CF+4dV 35vxN5HD/lXejichXfkizhW0oqyDWwkQ5Sc72TRNkFN2uMWP7V2SA0s2u57H24zVGBXjc j0TxXCorV7RoloW5ssbeL0+c/+yJ6zFTERpUrMeX3ZRIGGaYRbkiWxW+UccVyb2xGHw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796135115; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=qODUVu0Aul9aA2juks7Vhl8M7/X3j/hrXXlg8JOaZEo=; b=s+mOs7vQkzyppvetqiTDxcXcfk8U7oGj55T14sGFUS9ypjMYXzEsrikzbQD2pacyoqCN Gp37Vj4hmd8PiTVqmjaEdxN8GFLLOGM1Sa51Tr4gsJXNTbklHuqQXOks77dkLDmpbBo/i 2v1oXp+8ohe7lDrsH0a64hk0qrRDqzqERZfN4En9wKobXLq+PCnBwGbF8xn4sEcOnWXW6 ledUMilHIr/o1tU5lUw2ZA6VjD++5ClKxU1pZZrUDsxxPjakFSoXND+T5Dcg9iyZZ4W3U NlFxD16ApDOPT+hlTDi/vokNVg229KTYYwH1h2l9mavgbi7pS3pB0XvXlPofUood0mg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b="WIY/ihgW"; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 154CC606A320; Tue, 1 Dec 2026 14:25:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=WIY/ihgW Received: by smtp.kernel.org (Postfix) with ESMTPSA id 825F61F00899; Tue, 1 Dec 2026 14:25:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796135114; bh=qODUVu0Aul9aA2juks7Vhl8M7/X3j/hrXXlg8JOaZEo=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=WIY/ihgWHPNeBhhaKuTyC/cdtoHctFvEIuvq2+FrE1yqbyKn1NmRzkUCVYXJJXjuw tBF7kFmUQukTYf3uzCbc63rvYjYUu+GDBVeD+LPHw9uKMW0tJ+fc+w0m3hVEjwKo4j w+e414cLWsaTC34aZyqp7achm3ECQJvjpuvFSq66sg2cHEM9hv5iDeXgrSmc88wp7M rpHbIUbz0qzl9aNHCvGFRNltcNxOmNotbGOdVWKrM4wIpJEXmOK2azlubHoyZP+uNG t9aDI+e0kXGsNlTcmhKrFOf7uld56bpChjG9Z9V+HmOrNkhBJ6LQurjs9+ziVUjrCV wKG3emf9rNvPA== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH v21 09/11] selftests: tracing: Add wprobe trigger testcases Reply-To: sashiko-reviews@lists.linux.dev To: =?utf-8?b?TWFzYW1pIEhpcmFtYXRzdSAoR29vZ2xlKQ==?= Cc: linux-trace-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org In-Reply-To: <20261130020252.32126-10-mhiramat@kernel.org> References: <20261130020252.32126-1-mhiramat@kernel.org> <20261130020252.32126-10-mhiramat@kernel.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Tue, 01 Dec 2026 14:25:14 +0000 X-Mailing-List: linux-perf-users@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Thank you for your contribution! Sashiko AI review found 1 potential issue to consider: - [Medium] selftests: tracing: 8-byte wprobe length in trigger tests fails on 32-bit x86 -- commit 263b18d5d77d66080ad14fc5ce05d30f64979439 Author: Masami Hiramatsu (Google) selftests: tracing: Add wprobe trigger testcases This commit adds ftrace selftests for set_wprobe and clear_wprobe event triggers, covering basic trigger operations, CPU hotplug transitions, and trigger syntax error logging. Link: https://lore.kernel.org/all/59637b96946653393a7ad3c7de094094796b39c2.= 1785067572.git.wangjinchao600@gmail.com/ > diff --git a/tools/testing/selftests/ftrace/test.d/trigger/trigger-wprobe= -hotplug.tc b/tools/testing/selftests/ftrace/test.d/trigger/trigger-wprobe-= hotplug.tc > new file mode 100644 > index 0000000000000..1847a39431054 > --- /dev/null > +++ b/tools/testing/selftests/ftrace/test.d/trigger/trigger-wprobe-hotplu= g.tc > @@ -0,0 +1,150 @@ [ ... ] > +:;: "Add a wprobe event used by trigger" ;: > +echo 'w:watch rw@-1:8 address=3D$addr value=3D$value' > dynamic_events [ ... ] > diff --git a/tools/testing/selftests/ftrace/test.d/trigger/trigger-wprobe= .tc b/tools/testing/selftests/ftrace/test.d/trigger/trigger-wprobe.tc > new file mode 100644 > index 0000000000000..f130bf589f7c0 > --- /dev/null > +++ b/tools/testing/selftests/ftrace/test.d/trigger/trigger-wprobe.tc > @@ -0,0 +1,157 @@ [ ... ] > +:;: "Add a wprobe event used by trigger" ;: > +echo 'w:watch rw@-1:8 address=3D$addr value=3D$value' > dynamic_events [ ... ] > +:;: "Verify dynamic_events preserves -1 spec and spec-based removal work= s" ;: > +if ! grep -q '^w:wprobes/watch rw@-1:8 ' dynamic_events; then > + fail "dynamic_events did not preserve rw@-1:8 after trigger teardown" > +fi > +echo '!w:wprobes/watch rw@-1:8 address=3D$addr value=3D$value' >> dynami= c_events [Severity: Medium] Will using an 8-byte watchpoint length (rw@-1:8) cause trigger-wprobe.tc and trigger-wprobe-hotplug.tc to fail on 32-bit x86? On 32-bit x86, CONFIG_WPROBE_TRIGGERS is enabled because X86 selects HAVE_MODIFY_LOCAL_HW_BREAKPOINT_ADDR. When set_wprobe:watch:timer is registered, wprobe_trigger_cmd_parse() enables the watchpoint with HW_BREAKPOINT_LEN_8, which arch_build_bp_info() rejects with -EOPNOTSUPP on 32-bit x86 CPUs without X86_FEATURE_BPEXT. Even when X86_FEATURE_BPEXT is present, struct foo_timer_data places struct timer_list timer right after the 4-byte const char *name pointer, so both timer and timer+16 are only 4-byte aligned and fail the 8-byte alignment check in trace_wprobe_is_valid_addr(). Using rw@-1:4 (as in trigger-wprobe-syntax-errors.tc) avoids both issues while still matching mod_timer() accesses on 32-bit and 64-bit kernels. --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261130020252.3212= 6-1-mhiramat@kernel.org?part=3D9