系列文章:https://blog.youkuaiyun.com/Vince_/article/details/89054330
调度的入口
Timer interrupt is responsible for decrementing the running process’s timeslice count.When the count reaches zero, need_resched is set and the kernel runs the scheduler as soon as possible
在时钟中断中更新进程执行时间信息,如果时间片用完,则设置need_resched,在接下来的调度过程中换出正在执行的进程。
RTC(Real-Time Clock)
实时时钟,非易失性设备存储系统时间,在系统启动时,通过COMS连接设备到系统,读取对应的时间信息提供给系统设置。
System Timer
系统定时器由电子时钟以可编程频率实现,驱动系统时钟中断定期发生,也有部分架构通过减法器decrementer实现,通过计数器设定初始值,以固定频率减少直到为0,然后出发时钟中断。
The timer interrupt is broken into two pieces: an architecture-dependent and an architecture-independent
routine.
The architecture-dependent routine is registered as the interrupt handler for the system
timer and, thus, runs when the timer interrupt hits.