lkml.org 
[lkml]   [1999]   [Jan]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: Linux and physical memory
Date
> Maybe I am stupid, but while I understand this is correct (i.e. reserve a part 
> of processes address space to point to kernel code/data), I don't
> understand why the kernel needs to always have all physical memory mapped
> in its address space.

The kernel doesn't neccessarily need all of it - indeed we only map the
main memory as a physical view, selected pieces of PCI space (the bits with
cards in) and the ISA hole into kernel memory.

There are two ways to handle "kernel" space on an x86. One is to use the page
protection bits and put the kernel into the user page tables but so the user
cannot access them at their process priviledge level. This is cheap to do.

The second is to change page tables when entering the kernel. This requires
a TLB flush and is expensive to do.

Alan


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:49    [from the cache]
©2003-2011 Jasper Spaans