Added function read_cpu_flags() that returns current cpu flags as a

long.  This is used to check for interrupts being disabled at the time
of a lock() call, if enabled in config.h. The number of times this
happens is then counted in the kinfo structure. These events (recursive
lockings) lead to nasty race conditions.
This commit is contained in:
Ben Gras
2005-06-20 14:53:13 +00:00
parent c60302c1e7
commit 3eeff022fb
4 changed files with 23 additions and 1 deletions

View File

@@ -97,6 +97,7 @@ _PROTOTYPE( void reset, (void) );
_PROTOTYPE( void level0, (void (*func)(void)) );
_PROTOTYPE( void monitor, (void) );
_PROTOTYPE( void read_tsc, (unsigned long *high, unsigned long *low) );
_PROTOTYPE( unsigned long read_cpu_flags, (void) );
/* mpx*.s */
_PROTOTYPE( void idle_task, (void) );