pagetables used in interrupt context

Subramaniam Appadodharana c.a.subramaniam at gmail.com
Thu Feb 23 09:41:28 EST 2012


On Thu, Feb 23, 2012 at 6:52 AM, 卜弋天 <buyit at live.cn> wrote:
> Hi Subin:
>
>     for kernel version 2.6.35, ARM architecture, when interrupt occurs,
> kernel will change from USER/SVC mode to IRQ mode,backup some registers and
> change to SVC mode immediately, handle the real interrupt handler in SVC
> mode, which people say in interrupt context.
>     kernel will use the stack(interrupt context) of interrupted thread to
> handle the interrupt, and there is no MMU operation which do page table
> switch.
>     so the thread which is interrupted by interrupt, it's kernel mode stack
> will be choosed as the interrupt context of current interrupt.
>
Thanks ! thats a terse explanation! Can you please mention why we do
not have a IRQ stack (in terms of size of the stack) to do the
processing?
>
>> Date: Tue, 21 Feb 2012 19:18:32 -0700
>> Subject: Re: pagetables used in interrupt context
>> From: subingangadharan at gmail.com
>> To: dhylands at gmail.com
>> CC: kernelnewbies at kernelnewbies.org
>
>>
>> Thank you for clearing my doubt.
>>
>> On Mon, Feb 20, 2012 at 8:39 PM, Dave Hylands <dhylands at gmail.com> wrote:
>> > Hi Subin,
>> >
>> > On Mon, Feb 20, 2012 at 6:47 PM, subin gangadharan
>> > <subingangadharan at gmail.com> wrote:
>> >> Hi All,
>> >>
>> >> Please correct me if I am wrong. In linux each process will have its
>> >> own page tables, so when a interrupt happens processor will switch to
>> >> interrupt context
>> >> and execute the proper handler. So my doubt, if this is the case,
>> >> interrupt hanlder will be using the pagetables of the interrupted
>> >> process or is there a separate page table for this.
>> >
>> > Yep - that's right. Conceptually you can imagine that the kernel page
>> > tables are replicated in each process, so when the interrupt occurs,
>> > the kernel mappings will always be in effect regardless of which task
>> > is running. How this is actually achieved may vary from architecture
>> > to architecture.
>> >
>> > --
>> > Dave Hylands
>> > Shuswap, BC, Canada
>> > http://www.davehylands.com
>>
>>
>>
>> --
>> With Regards
>> Subin Gangadharan
>>
>> I am not afraid and I am also not afraid of being afraid.
>>
>> _______________________________________________
>> Kernelnewbies mailing list
>> Kernelnewbies at kernelnewbies.org
>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>



More information about the Kernelnewbies mailing list