nios2: reset timeslice on interrupt-induced swap

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2017-06-01 14:45:01 -07:00 committed by Anas Nashif
parent 7b7504e2b9
commit 7b7fbf851e

View file

@ -18,6 +18,9 @@ GTEXT(__swap)
GTEXT(_irq_do_offload)
GTEXT(_offload_routine)
#endif
#ifdef CONFIG_TIMESLICING
GTEXT(_update_time_slice_before_swap)
#endif
/* Allows use of r1/at register, otherwise reserved for assembler use */
.set noat
@ -145,6 +148,10 @@ on_irq_stack:
*/
ldw sp, 0(sp)
#ifdef CONFIG_TIMESLICING
call _update_time_slice_before_swap
#endif
/* Argument to Swap() is estatus since that's the state of the
* status register before the exception happened. When coming
* out of the context switch we need this info to restore