mirror of
https://github.com/drasko/codezero.git
synced 2026-03-19 18:51:49 +01:00
Fixed few more anomalies with threaded irqs.
There is a bug that causes the sleeping irq thread to never wake up. Investigating.
This commit is contained in:
@@ -42,17 +42,20 @@ static inline void disable_irqs()
|
||||
/* Disable the irqs unconditionally, but also keep the previous state such that
|
||||
* if it was already disabled before the call, the restore call would retain
|
||||
* this state. */
|
||||
static inline void irq_local_disable_save(unsigned long *state)
|
||||
void irq_local_disable_save(unsigned long *state);
|
||||
#if 0
|
||||
{
|
||||
unsigned long temp;
|
||||
__asm__ __volatile__ (
|
||||
"mrs %0, cpsr_fc\n"
|
||||
"orr %1, %0, #0x80\n"
|
||||
"msr cpsr_fc, %1\n"
|
||||
"orr %2, %0, #0x80\n"
|
||||
"msr cpsr_fc, %2\n"
|
||||
: "=r" (*state)
|
||||
: "r" (*state),"r" (temp)
|
||||
);
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Simply change it back to original state supplied in @flags. This might enable
|
||||
* or retain disabled state of the irqs for example. Useful for nested calls. */
|
||||
static inline void irq_local_restore(unsigned long state)
|
||||
|
||||
Reference in New Issue
Block a user