Re: Interrupt Context

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 7/12/05, Rik van Riel <riel@xxxxxxxxxxx> wrote:
> On Mon, 11 Jul 2005, Karane Mariano Vieira wrote:
> 
> > Just a silly doubt,
> >
> > when the schedule() runs activated by the timer interrupt handler, it
> > runs in which context? interrupt context?
> 
> The function schedule() is never directly activated by the
> timer interrupt handler.
> 
> Instead, when the timer irq handler notices the scheduler
> should run, it sets a flag.  After the irq handler has
> finished (and quit), the part of the kernel that is
> responsible for switching back to userspace mode notices
> that the flag got set.
> 
> That part of the kernel, running in process context,
> then calls the scheduler.
> 

For more details about how the kernel "returns from interrupt" read 

Understanding the Linux Kernel, Second Edition 
By Daniel P. Bovet, Marco Cesati

An excellent book to clear your fundamentals about Linux. 

Ketan

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux