lkml.org 
[lkml]   [2012]   [Sep]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: linux page table
On Sat, Sep 1, 2012 at 12:30 PM, Xin Tong <xerox.time.tech@gmail.com> wrote:
> When a process is created in Linux, corresponding page table is
> implemented. In the current x86 linux, the page table is a multi-level
> page table and CR3 points to the first level of the page table. I
> have 2 questions.
>
> 1. is the value in CR3 virtual address or physical address ?

It's a physical address. It points the CPU to it in physical memory.

More generally, all addresses in page tables, directories, etc are
physical addresses.

> 2. can the address of the first level of the page table during a
> process's lifetime change ?

This I don't know.

> 3. can two different processes have their CR3 being the same value
> even though they have different first level page tables ?

I'm not sure about this, but I think CR3 is actually bound to the
mm_struct and not the process.

Think about separate processes with the same address space, such as
multithreaded processes.

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


\
 
 \ /
  Last update: 2012-09-01 22:21    [W:1.022 / U:0.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site