[mkc2008] Platform-Specific Optimizations - Small Address Spaces (IA-32)

Torsten Frenzel frenzel at os.inf.tu-dresden.de
Mon Apr 6 18:16:25 CEST 2009


Jan Bierbaum(s3306700 at mail.inf.tu-dresden.de)@2009.04.06 16:51:05 +0200:
> Hello!
> On slides 12-14 Small Address Spaces are introduced: To save the
> expenses of address space switching, some small AS are established
> inside the kernel memory region. Mutual protection and relocation is
> provided through segmentation.
> But since this memory is located inside the kernel region wouldn't that
> mean the tasks inside those small AS need kernel privileges to access
> this memory? I cannot believe this, because it would also allow them to
> execute privileged instructions.
Just that a user-level program has access to a region above 3GB doesn't
mean that it needs kernel privileges and has access to kernel memory.
The SMAS application has only access to a dedicated part in the kernel
region that is mapped user accessible. (Therefore it can't execute privileged
instructions because it runs with user privileges.)

> An alternative would be that with small AS there is no "kernel memory"
> at all - access to all pages is allowed with user privilege (in the page
> tables) and isolation is done solely via segmentation. So segmentation
> does not only isolate the small AS from each other but also the normal
> user AS from kernel memory. Is that was is done?
In principle yes. All SMAS applications and the kernel live in the same
address space (using the same page table) and are isolation via segmentation.


More information about the mkc2008 mailing list