Thread (67 messages) 67 messages, 6 authors, 2013-02-04

Re: [PATCH v6 00/15] memory-hotplug: hot-remove physical memory

From: Simon Jeons <hidden>
Date: 2013-02-01 02:17:30
Also in: linux-acpi, linux-mm, linux-sh, linuxppc-dev, lkml, sparclinux

Hi Tang,
On Fri, 2013-02-01 at 09:57 +0800, Tang Chen wrote:
On 02/01/2013 09:36 AM, Simon Jeons wrote:
quoted
On Fri, 2013-02-01 at 09:32 +0800, Jianguo Wu wrote:
quoted
quoted
So if config NUMA, kernel memory will not be linear mapping anymore? For
example,

Node 0  Node 1

0 ~ 10G 11G~14G
It has nothing to do with linear mapping, I think.
quoted
quoted
quoted
kernel memory only at Node 0? Can part of kernel memory also at Node 1?
Please refer to find_zone_movable_pfns_for_nodes().
I see, thanks. :)
The kernel is not only on node0. It uses all the online nodes evenly. :)
quoted
quoted
quoted
How big is kernel direct mapping memory in x86_64? Is there max limit?

Max kernel direct mapping memory in x86_64 is 64TB.
For example, I have 8G memory, all of them will be direct mapping for
kernel? then userspace memory allocated from where?
I think you misunderstood what Wu tried to say. :)

The kernel mapped that large space, it doesn't mean it is using that 
large space.
The mapping is to make kernel be able to access all the memory, not for 
the kernel
to use only. User space can also use the memory, but each process has 
its own mapping.

For example:

                                        64TB, what ever 
    xxxTB, what ever
logic address space:     |_____kernel_______|_________user_________________|
                                        \  \  /  /
                                         \  /\  /
physical address space:              |___\/__\/_____________|  4GB or 
8GB, what ever
                                           *****
How much address space user process can have on x86_64? Also 8GB?
The ***** part physical is mapped to user space in the process' own 
pagetable.
It is also direct mapped in kernel's pagetable. So the kernel can also 
access it. :)
But how to protect user process not modify kernel memory?
quoted
quoted
quoted
It seems that only around 896MB on x86_32.
quoted
We need firmware take part in, such as SRAT in ACPI BIOS, or the firmware
based memory migration mentioned by Liu Jiang.
Is there any material about firmware based memory migration?
No, I don't have any because this is a functionality of machine from HUAWEI.
I think you can ask Liu Jiang or Wu Jianguo to share some with you. :)

Thanks. :)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help