forked from backup/30dayMakeOS
重新调整FIFO缓冲区(2)
This commit is contained in:
@@ -43,7 +43,7 @@ void timer_free(struct TIMER *timer)
|
||||
return;
|
||||
}
|
||||
|
||||
void timer_init(struct TIMER *timer, struct FIFO8 *fifo, unsigned char data)
|
||||
void timer_init(struct TIMER *timer, struct FIFO32 *fifo, unsigned char data)
|
||||
{
|
||||
timer->fifo = fifo;
|
||||
timer->data = data;
|
||||
@@ -91,7 +91,7 @@ void inthandler20(int *esp)
|
||||
}
|
||||
/* 超时*/
|
||||
timerctl.timers[i]->flags = TIMER_FLAGS_ALLOC;
|
||||
fifo8_put(timerctl.timers[i]->fifo, timerctl.timers[i]->data);
|
||||
fifo32_put(timerctl.timers[i]->fifo, timerctl.timers[i]->data);
|
||||
}
|
||||
/* 正好有i个定时器超时了。其余的进行移位。 */
|
||||
timerctl.using -= i;
|
||||
|
||||
Reference in New Issue
Block a user