Page MenuHomeFreeBSD

D40412.id.diff
No OneTemporary

D40412.id.diff

diff --git a/sys/cddl/dev/kinst/amd64/kinst_isa.c b/sys/cddl/dev/kinst/amd64/kinst_isa.c
--- a/sys/cddl/dev/kinst/amd64/kinst_isa.c
+++ b/sys/cddl/dev/kinst/amd64/kinst_isa.c
@@ -611,8 +611,8 @@
/*
* Exclude machine-dependent functions that are not safe-to-trace.
*/
-int
+bool
kinst_md_excluded(const char *name)
{
- return (0);
+ return (false);
}
diff --git a/sys/cddl/dev/kinst/kinst.h b/sys/cddl/dev/kinst/kinst.h
--- a/sys/cddl/dev/kinst/kinst.h
+++ b/sys/cddl/dev/kinst/kinst.h
@@ -47,8 +47,8 @@
struct linker_symval;
volatile void *kinst_memcpy(volatile void *, volatile const void *, size_t);
-int kinst_excluded(const char *);
-int kinst_md_excluded(const char *);
+bool kinst_excluded(const char *);
+bool kinst_md_excluded(const char *);
int kinst_invop(uintptr_t, struct trapframe *, uintptr_t);
int kinst_make_probe(struct linker_file *, int, struct linker_symval *,
void *);
diff --git a/sys/cddl/dev/kinst/kinst.c b/sys/cddl/dev/kinst/kinst.c
--- a/sys/cddl/dev/kinst/kinst.c
+++ b/sys/cddl/dev/kinst/kinst.c
@@ -86,11 +86,11 @@
return (dst);
}
-int
+bool
kinst_excluded(const char *name)
{
if (kinst_md_excluded(name))
- return (1);
+ return (true);
/*
* Anything beginning with "dtrace_" may be called from probe context
@@ -99,7 +99,7 @@
*/
if (strncmp(name, "dtrace_", strlen("dtrace_")) == 0 &&
strncmp(name, "dtrace_safe_", strlen("dtrace_safe_")) != 0)
- return (1);
+ return (true);
/*
* Omit instrumentation of functions that are probably in DDB. It
@@ -110,7 +110,7 @@
*/
if (strncmp(name, "db_", strlen("db_")) == 0 ||
strncmp(name, "kdb_", strlen("kdb_")) == 0)
- return (1);
+ return (true);
/*
* Lock owner methods may be called from probe context.
@@ -119,7 +119,7 @@
strcmp(name, "owner_rm") == 0 ||
strcmp(name, "owner_rw") == 0 ||
strcmp(name, "owner_sx") == 0)
- return (1);
+ return (true);
/*
* When DTrace is built into the kernel we need to exclude the kinst
@@ -127,13 +127,13 @@
*/
#ifndef _KLD_MODULE
if (strncmp(name, "kinst_", strlen("kinst_")) == 0)
- return (1);
+ return (true);
#endif
if (strcmp(name, "trap_check") == 0)
- return (1);
+ return (true);
- return (0);
+ return (false);
}
void

File Metadata

Mime Type
text/plain
Expires
Thu, Jan 29, 6:46 PM (11 h, 54 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28071501
Default Alt Text
D40412.id.diff (2 KB)

Event Timeline