Stack for ring 0
Posted: Fri Jun 20, 2003 11:00 pm
I want to implement my system calls via call gates. It is my understanding that the application programs transfer the parameters to the kernel using the stack and when it arrives to the kernel a 'stack switch' happens.
My OS has just 2 levels (ring 0 and ring3) so I just need to set ss0/esp0 to pass parameters from the application programs to the kernel.
My question is: could I use the kernel's stack to set ss0/esp0, or do I need to create a special stack to pass parameters? How big should that stack be?
Thank you
pepito
My OS has just 2 levels (ring 0 and ring3) so I just need to set ss0/esp0 to pass parameters from the application programs to the kernel.
My question is: could I use the kernel's stack to set ss0/esp0, or do I need to create a special stack to pass parameters? How big should that stack be?
Thank you
pepito