Re: Kernel stack question

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

 



On 9/4/06, pandari kashyap <pandari.kashyap@xxxxxxxxx> wrote:
Hello Newbies,

I wanted to know whether Kernel maintains a kernel mode stack for each user
process? or does it maintain one kernel mode stack for all user processes?.
Where exactly in memory is this stack space allocated?.

The stack space is allocated in the kernel virtual memory address
space (3GB - 4GB). There is one kernel mode stack per user process.
There is also one kernel mode stack per kernel process (i.e. the
processes that are not attached to any user process - created using
kernel_thread()).

I'm not sure about the interrupt mode stack though, but I guess there
is ONE interrupt mode stack per CPU (And all drivers share it?).


How does kernel get the address of the process descriptor from the stack
pointer?

Look for the "current" macro in current.h.

Thanks,

Rajat

--
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