From: Jeremy Fitzhardinge <jeremy@goop.org>
To: Dong Feng <middle.fengdong@gmail.com>
Cc: Jan Engelhardt <jengelh@linux01.gwdg.de>, Andi Kleen <ak@suse.de>,
Nick Piggin <nickpiggin@yahoo.com.au>,
Arjan van de Ven <arjan@infradead.org>,
Paul Mackerras <paulus@samba.org>,
Christoph Lameter <clameter@sgi.com>,
David Howells <dhowells@redhat.com>,
linux-kernel@vger.kernel.org
Subject: Re: The 3G (or nG) Kernel Memory Space Offset
Date: Tue, 29 Aug 2006 09:42:52 -0700 [thread overview]
Message-ID: <44F46E8C.1000308@goop.org> (raw)
In-Reply-To: <a2ebde260608290901w73575e18hffd8a9d6c989f523@mail.gmail.com>
Dong Feng wrote:
> Sorry for my typo. I actually means "0-1G physical memory space." My
> question is actually why there is a 3G offset from linear kernel to
> physical kernel. Why not simply have kernel memory linear space
> located on 0-1G linear address, and therefore the physical kernel and
> linear kernel just coincide?
If kernel virtual addresses were low, you would either need to do an
address-space switch (=TLB flush) on every user-kernel switch, or
require userspace to be at some high address. The former would be very
expensive, and the latter very strange (the standard x86 ABI requires
low addresses). The clean solution is to map the kernel to the high
part of the address space, but it is easier to load the kernel into low
physical memory at boot, thus leading to a physical-virtual offset. The
selection of 3G is a reasonable tradeoff of physical memory size vs user
virtual address space size, but of course it can be adjusted, or you can
use highmem.
J
next prev parent reply other threads:[~2006-08-29 16:43 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-29 14:15 The 3G (or nG) Kernel Memory Space Offset Dong Feng
2006-08-29 14:32 ` Andi Kleen
2006-08-29 14:36 ` Jan Engelhardt
2006-08-29 16:01 ` Dong Feng
2006-08-29 16:05 ` Arjan van de Ven
2006-08-29 16:30 ` Jan Engelhardt
2006-08-29 16:44 ` Jeremy Fitzhardinge
2006-08-29 16:12 ` Christoph Lameter
2006-08-29 16:16 ` Dong Feng
2006-08-29 16:42 ` Jeremy Fitzhardinge [this message]
2006-08-29 18:37 ` Peter Grandi
2006-08-29 21:15 ` Jeremy Fitzhardinge
2006-08-30 6:11 ` Jan Engelhardt
-- strict thread matches above, loose matches on Subject: below --
2006-08-30 4:32 linux
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=44F46E8C.1000308@goop.org \
--to=jeremy@goop.org \
--cc=ak@suse.de \
--cc=arjan@infradead.org \
--cc=clameter@sgi.com \
--cc=dhowells@redhat.com \
--cc=jengelh@linux01.gwdg.de \
--cc=linux-kernel@vger.kernel.org \
--cc=middle.fengdong@gmail.com \
--cc=nickpiggin@yahoo.com.au \
--cc=paulus@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox