Ring0 and Ring3?
Posted: Sun Apr 05, 2009 10:58 pm
Hi
Suppose Ring0 task is running and we switch to Ring3.
Now we create another task, what will be the priveldge level of that task?
What I did is set up a syscall that creates new task ( loads the program from disk, creates new PCB node and sets up appropriate eip,esp and ebp,puts that node in the end and returns ).
The two task run fine and are prempted by scheduler, BUT as soon as i use qemu to check the CPL it shows 3 for older and 0 for this new task.
I am not able to understand what is wrong with it.
I might be missing something.
Please help?
Suppose Ring0 task is running and we switch to Ring3.
Now we create another task, what will be the priveldge level of that task?
What I did is set up a syscall that creates new task ( loads the program from disk, creates new PCB node and sets up appropriate eip,esp and ebp,puts that node in the end and returns ).
The two task run fine and are prempted by scheduler, BUT as soon as i use qemu to check the CPL it shows 3 for older and 0 for this new task.
I am not able to understand what is wrong with it.
I might be missing something.
Please help?