2nd bit in a page table entry, this is a specific question

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
ITchimp
Member
Member
Posts: 134
Joined: Sat Aug 18, 2018 8:44 pm

2nd bit in a page table entry, this is a specific question

Post by ITchimp »

ok, this is very very specific and I got intel manual in front of me...

The second bit in a page table entry is user supervisor bit...

for kernel should I set that bit to supervisor, which is 0...

my logic... kernel/user isolation is obvious, but in the case of syscall, kernel code should
be able to access kernel data segments on behalf of user... so

that bit should be set to zero for kernel...

Is this right?
User avatar
iansjack
Member
Member
Posts: 4703
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: 2nd bit in a page table entry, this is a specific questi

Post by iansjack »

You don't want user code to be able to access kernel data, so the bit should be set to 0. As you say, the system call access data on behalf of the user, if necessary.
Post Reply