small cleanuo to smp asm files
This commit is contained in:
@@ -80,20 +80,15 @@ _tx_thread_schedule:
|
||||
la t0, _tx_thread_execute_ptr // Pickup address of execute ptr
|
||||
add t0, t0, t4 // Select this hart's execute slot
|
||||
_tx_thread_schedule_loop:
|
||||
csrci mstatus, 0x08 // Lockout interrupts
|
||||
LOAD t1, 0(t0) // Pickup next thread to execute
|
||||
bnez t1, _tx_thread_schedule_thread // If non-NULL, continue
|
||||
csrsi mstatus, 0x08 // Enable interrupts
|
||||
#ifdef TX_ENABLE_WFI
|
||||
csrci mstatus, 0x08 // Lockout interrupts
|
||||
LOAD t1, 0(t0) // Pickup next thread to execute
|
||||
bnez t1, _tx_thread_schedule_thread // If non-NULL, continue
|
||||
csrsi mstatus, 0x08 // Enable interrupts
|
||||
wfi // Wait for interrupt
|
||||
j _tx_thread_schedule_loop // Keep looking for a thread
|
||||
#else
|
||||
csrci mstatus, 0x08 // Lockout interrupts
|
||||
LOAD t1, 0(t0) // Pickup next thread to execute
|
||||
bnez t1, _tx_thread_schedule_thread // If non-NULL, continue
|
||||
csrsi mstatus, 0x08 // Enable interrupts
|
||||
j _tx_thread_schedule_loop // Keep looking for a thread
|
||||
#endif
|
||||
j _tx_thread_schedule_loop // Keep looking for a thread
|
||||
|
||||
_tx_thread_schedule_thread:
|
||||
|
||||
/* Atomically claim the thread's ready token so only one hart can
|
||||
|
||||
Reference in New Issue
Block a user