NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: kern/56355: dtrace triggers double-fault in supervisor mode
The following reply was made to PR kern/56355; it has been noted by GNATS.
From: Taylor R Campbell <riastradh%NetBSD.org@localhost>
To: bch <brad.harder%gmail.com@localhost>
Cc: gnats-bugs%netbsd.org@localhost
Subject: Re: kern/56355: dtrace triggers double-fault in supervisor mode
Date: Sun, 15 Aug 2021 18:42:14 +0000
> Date: Sun, 15 Aug 2021 09:05:52 -0700
> From: bch <brad.harder%gmail.com@localhost>
>
> On Sun, Aug 15, 2021 at 08:10 Taylor R Campbell <riastradh%netbsd.org@localhost>
> wrote:
>
> > > Date: Sun, 15 Aug 2021 15:08:11 +0000
> > > From: Taylor R Campbell <riastradh%NetBSD.org@localhost>
> > >
> > > This patch changes the semantics of the code so that it excludes any
> > > names that _start_ with `trap', `x86_curcpu', or `x86_curlwp', such as
> > > `trapsignal'. The use of strncmp instead of strcmp should be restored
> > > (and the list should maybe be sorted lexicographically).
> >
> > Errr, I mean: this code should use strcmp, not strncmp.
>
> If you read through to the MI exclusion code at fbt_exclude(), it's using
> strncmp(). Should that be changed too, or otherwise, why pick strcmp() v
> strncmp()?
fbt_excluded is meant to exclude any function whose name starts with
`dtrace_', `dtrace_safe_', `fbt_', &c., which is what, e.g.,
strncmp(name, "fbt_", 4) does. But we want to exclude the function
`trap' specifically, not all functions that happen to start with
`trap' like `trapsignal', hence strcmp(name, "trap").
Home |
Main Index |
Thread Index |
Old Index