Add a macro mtx_intr_enable() to alter a spin lock such that interrupts
will be enabled when it is released.
This commit is contained in:
parent
d2712eafa7
commit
e109e2b4cd
@ -48,6 +48,7 @@
|
||||
|
||||
#define mtx_legal2block() \
|
||||
((alpha_pal_rdps() & ALPHA_PSL_IPL_MASK) == ALPHA_PSL_IPL_0)
|
||||
#define mtx_intr_enable(mutex) (mutex)->mtx_saveintr = ALPHA_PSL_IPL_0
|
||||
|
||||
/*
|
||||
* Assembly macros (for internal use only)
|
||||
|
@ -49,6 +49,7 @@ extern struct mtx clock_lock;
|
||||
"mpp->mtx_saveintr & PSL_I")
|
||||
|
||||
#define mtx_legal2block() (read_eflags() & PSL_I)
|
||||
#define mtx_intr_enable(mutex) (mutex)->mtx_saveintr |= PSL_I
|
||||
|
||||
/*
|
||||
* Assembly macros (for internal use only)
|
||||
|
@ -49,6 +49,7 @@ extern struct mtx clock_lock;
|
||||
"mpp->mtx_saveintr & PSL_I")
|
||||
|
||||
#define mtx_legal2block() (read_eflags() & PSL_I)
|
||||
#define mtx_intr_enable(mutex) (mutex)->mtx_saveintr |= PSL_I
|
||||
|
||||
/*
|
||||
* Assembly macros (for internal use only)
|
||||
|
@ -48,6 +48,7 @@
|
||||
|
||||
#define mtx_legal2block() \
|
||||
((alpha_pal_rdps() & ALPHA_PSL_IPL_MASK) == ALPHA_PSL_IPL_0)
|
||||
#define mtx_intr_enable(mutex) (mutex)->mtx_saveintr = ALPHA_PSL_IPL_0
|
||||
|
||||
/*
|
||||
* Assembly macros (for internal use only)
|
||||
|
Loading…
x
Reference in New Issue
Block a user