Page 1 of 1

are 2 sets of segments needed?

Posted: Thu Sep 09, 2004 3:11 am
by srg
Hi

I was wondering, in a protected mode os there are at least 4 segments, flat of course over the 4GB address space.

Why not just have the supervisor mode segments used for user mode code with all protection using paging.

Would it muck things up?

thanks
srg

Re:are 2 sets of segments needed?

Posted: Thu Sep 09, 2004 4:19 am
by bakery2k
Someone correct me if I'm wrong, but AFAIK the privilege level of the current code segment defines the current privilege level. Thus, if you only have supervisor code segments, you will always be running code in supervisor mode. So, page protection attributes will be ignored - supervisor code can read and write all pages.