URL
https://opencores.org/ocsvn/or1k/or1k/trunk
Go to most recent revision |
Show entire file |
Details |
Blame |
View Log
Rev 1545 |
Rev 1559 |
Line 67... |
Line 67... |
|
|
/* Raises a timer exception */
|
/* Raises a timer exception */
|
void tick_raise_except(void *dat)
|
void tick_raise_except(void *dat)
|
{
|
{
|
cpu_state.sprs[SPR_TTMR] |= SPR_TTMR_IP;
|
cpu_state.sprs[SPR_TTMR] |= SPR_TTMR_IP;
|
/* be sure not to issue a timer exception if an exception occured before it */
|
|
if(cpu_state.sprs[SPR_SR] & SPR_SR_TEE)
|
|
except_handle(EXCEPT_TICK, cpu_state.sprs[SPR_EEAR_BASE]);
|
|
|
|
/* Reschedule unconditionally, since we have to raise the exception until
|
/* Reschedule unconditionally, since we have to raise the exception until
|
* TTMR_IP has been cleared */
|
* TTMR_IP has been cleared */
|
sched_next_insn(tick_raise_except, NULL);
|
sched_next_insn(tick_raise_except, NULL);
|
|
|
|
/* be sure not to issue a timer exception if an exception occured before it */
|
|
if(cpu_state.sprs[SPR_SR] & SPR_SR_TEE)
|
|
except_handle(EXCEPT_TICK, cpu_state.sprs[SPR_EEAR_BASE]);
|
}
|
}
|
|
|
/* Restarts the tick timer */
|
/* Restarts the tick timer */
|
void tick_restart(void *dat)
|
void tick_restart(void *dat)
|
{
|
{
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.