summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1996-08-28 20:15:32 +0000
committerbde <bde@FreeBSD.org>1996-08-28 20:15:32 +0000
commitdc064fbaf3e7a79fe80c06259fbf0ffed69bb936 (patch)
tree65451cc1b368594d593c24934e438019b440be70 /lib
parentf79b9d498c61f152a80a65d2fc786f75c74aac4a (diff)
downloadFreeBSD-src-dc064fbaf3e7a79fe80c06259fbf0ffed69bb936.zip
FreeBSD-src-dc064fbaf3e7a79fe80c06259fbf0ffed69bb936.tar.gz
Cleaned up interrupt masking by declaring the state variable in a
machine-dependent macro and passing it to all machine-dependent macros. Eliminated the state variable for the GUPROF case.
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/gmon/mcount.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/lib/libc/gmon/mcount.c b/lib/libc/gmon/mcount.c
index 44d36d1..b44af99 100644
--- a/lib/libc/gmon/mcount.c
+++ b/lib/libc/gmon/mcount.c
@@ -36,7 +36,7 @@
static char sccsid[] = "@(#)mcount.c 8.1 (Berkeley) 6/4/93";
#endif
static const char rcsid[] =
- "$Id: mcount.c,v 1.5 1995/12/30 07:01:50 bde Exp $";
+ "$Id: mcount.c,v 1.6 1996/05/02 08:43:37 phk Exp $";
#endif
#include <sys/param.h>
@@ -79,8 +79,7 @@ _MCOUNT_DECL(frompc, selfpc) /* _mcount; may be static, inline, etc */
register struct gmonparam *p;
register long toindex;
#ifdef KERNEL
- register int s; /* XXX */
- u_long save_eflags; /* XXX */
+ MCOUNT_DECL(s)
#endif
p = &_gmonparam;
@@ -93,7 +92,7 @@ _MCOUNT_DECL(frompc, selfpc) /* _mcount; may be static, inline, etc */
return;
#endif
#ifdef KERNEL
- MCOUNT_ENTER;
+ MCOUNT_ENTER(s);
#else
p->state = GMON_PROF_BUSY;
#endif
@@ -261,7 +260,7 @@ skip_guprof_stuff:
}
done:
#ifdef KERNEL
- MCOUNT_EXIT;
+ MCOUNT_EXIT(s);
#else
p->state = GMON_PROF_ON;
#endif
@@ -269,7 +268,7 @@ done:
overflow:
p->state = GMON_PROF_ERROR;
#ifdef KERNEL
- MCOUNT_EXIT;
+ MCOUNT_EXIT(s);
#endif
return;
}
OpenPOWER on IntegriCloud