public inbox for dtrace@lists.linux.dev
 help / color / mirror / Atom feed
From: Eugene Loh <eugene.loh@oracle.com>
To: Kris Van Hees <kris.van.hees@oracle.com>
Cc: dtrace@lists.linux.dev, dtrace-devel@oss.oracle.com
Subject: Re: [PATCH 2/2] rawfbt: prvname is not properly set
Date: Fri, 16 Jan 2026 17:43:24 -0500	[thread overview]
Message-ID: <7631d4ee-49f4-d757-d1b2-705fea0ba8d7@oracle.com> (raw)
In-Reply-To: <aWq1YWvbTGl7nJni@kvh-deb-bpf.us.oracle.com>

On 1/16/26 17:02, Kris Van Hees wrote:

> On Fri, Jan 16, 2026 at 12:18:51AM -0500, Eugene Loh wrote:
>> On 1/15/26 17:18, Kris Van Hees wrote:
>>> On Tue, Jan 13, 2026 at 04:42:05PM -0500, eugene.loh@oracle.com wrote:
>>>> From: Eugene Loh <eugene.loh@oracle.com>
>>>>
>>>> [...]
>>>>
>>>> Add a test to check that a rawfbt probe can be found behind an fbt probe
>>>> when the probe description has a wildcard provider.
>>>>
>>>> Orabug: 38842114
>>>> Signed-off-by: Eugene Loh <eugene.loh@oracle.com>
>>>>
>>>> diff --git a/test/unittest/providers/rawfbt/tst.wildcard-provider.d b/test/unittest/providers/rawfbt/tst.wildcard-provider.d
>>>> new file mode 100644
>>>> @@ -0,0 +1,20 @@
>>>> +/*
>>>> + * ASSERTION: rawfbt probes can be found even when a wildcard provider
>>>> + * description also allows fbt probes.
>>>> + */
>>>> +
>>>> +#pragma D option quiet
>>>> +
>>>> +BEGIN,
>>>> +*fbt:vmlinux:do_sys_open*:entry
>>>> +{
>>>> +	printf("success\n");
>>>> +	exit(0);
>>>> +}
>>> I am confused how this test accomplishes verification of the assertion.  If
>>> a regular FBT probe satisfies the probe description, wouldn't this pass also?
>>> Wouldn't a -l based test be better here, where you can test that the output
>>> does indeed report both the fbt probe and the rawfbt probe that match?
>> It appears that -l is not an issue;  a -l test does not show the problem.
>> The test in the patch is derived from the user bug report that motivated
>> this patch.
>>
>> The whole prvname problem is that the bad prvname value makes GROUP_DATA
>> bad, which makes FBT_GROUP_DATA bad, which is an issue only in kprobe_attach
>> (and detach).  So, we need kprobe_attach() to see the problem.
> Ok, so yes, -l is not sufficient.  But still, even if the test is derived from
> the original reported problem, it still looks wrong to me.  Or rather, the test
> can pass when
>
> 	fbt:vmlinux:do_sys+open*:entry exists
> 	rawfbt:vmlinux:do_sys+open*:entry does NOT exist
>
> because as long as 1 probe matches the probe specification, compilation will
> succeed (and at runtime, the probe firing will complete the success criterium).
>
> But that is not a valid PASS result for the assertion that is posed for this
> test.  If you are specifically looking for a rawfbt probe using a wildcard, you
> might want to use r*fbt:vmlinux:do_sys+open*:entry instead perhaps?

This test is admittedly not the most stringent;  it could well pass even 
if some other bugs lurk somewhere.  The test simply reports a problem 
with the old bits and then passes with the fix.  It is a confirmation -- 
however weak -- that the fix is doing something right.

Meanwhile, I do not understand your concerns with regards to the 
assertion.  Specifically, using r*fbt would preclude any fbt probes;  so 
there would be nothing for the rawfbt probe to "hide behind."  And, 
fwiw, using r*fbt makes the test pass even without the fix.

  reply	other threads:[~2026-01-16 22:43 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-13 21:42 [PATCH 1/2] fbt: Populate just once eugene.loh
2026-01-13 21:42 ` [PATCH 2/2] rawfbt: prvname is not properly set eugene.loh
2026-01-15 22:18   ` Kris Van Hees
2026-01-16  5:18     ` Eugene Loh
2026-01-16 22:02       ` Kris Van Hees
2026-01-16 22:43         ` Eugene Loh [this message]
2026-01-26 21:11           ` Kris Van Hees
2026-01-15 21:35 ` [PATCH 1/2] fbt: Populate just once Kris Van Hees
2026-01-15 22:07   ` Eugene Loh

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7631d4ee-49f4-d757-d1b2-705fea0ba8d7@oracle.com \
    --to=eugene.loh@oracle.com \
    --cc=dtrace-devel@oss.oracle.com \
    --cc=dtrace@lists.linux.dev \
    --cc=kris.van.hees@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox