From: David Rientjes <rientjes@google.com>
To: Shaohui Zheng <shaohui.zheng@intel.com>
Cc: akpm@linux-foundation.org, linux-mm@kvack.org,
linux-kernel@vger.kernel.org, haicheng.li@linux.intel.com,
lethal@linux-sh.org, ak@linux.intel.com, gregkh@suse.de,
shaohui.zheng@linux.intel.com
Subject: Re: [7/7,v8] NUMA Hotplug Emulator: Implement per-node add_memory debugfs interface
Date: Thu, 9 Dec 2010 13:29:28 -0800 (PST) [thread overview]
Message-ID: <alpine.DEB.2.00.1012091325530.13564@chino.kir.corp.google.com> (raw)
In-Reply-To: <20101209012124.GD5798@shaohui>
On Thu, 9 Dec 2010, Shaohui Zheng wrote:
> > I don't think you should be using memparse() to support this type of
> > interface, the standard way of writing memory locations is by writing
> > address in hex as the first example does. The idea is to not try to make
> > things simpler by introducing multiple ways of doing the same thing but
> > rather to standardize on a single interface.
>
> Undoubtedly, A hex is the best way to represent a physical address. If we use
> memparse function, we can use the much simpler way to represent an address,
> it is not the offical way, but it takes many conveniences if we just want to
> to some simple test.
>
Testing code should be removed from the patch prior to proposal.
> When we reserce memory, we use mempasre to parse the mem=XXX parameter, we can
> avoid the complicated translation when we add memory thru the add_memory interface,
> how about still use the memparse here? but remove it from the document since it is
> just for some simple testing.
>
We really don't want a public interface to have undocumented behavior, so
it would be much better to retain the documentation if you choose to keep
the memparse(). I disagree that converting the mem= parameter to hex is
"complicated," however, so I'd prefer that the interface is similar to
that of add_node.
> > > + printk(KERN_INFO "Add a memory section to node: %d.\n", nid);
> > > + phys_addr = memparse(buf, NULL);
> > > + ret = add_memory(nid, phys_addr, PAGES_PER_SECTION << PAGE_SHIFT);
> >
> > Does the add_memory() call handle memoryless nodes such that they
> > appropriately transition to N_HIGH_MEMORY when memory is added?
>
> For memoryless nodes, it will cause OOM issue on old kernel version, but now
> memoryless node is already supported, and the test result matches it well. The
> emulator is a tool to reproduce the OOM issue in eraly kernel.
>
That doesn't address the question. My question is whether or not adding
memory to a memoryless node in this way transitions its state to
N_HIGH_MEMORY in the VM?
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom policy in Canada: sign http://dissolvethecrtc.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2010-12-09 21:29 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <A24AE1FFE7AEC5489F83450EE98351BF2A40FED20A@shsmsx502.ccr.corp.intel.com>
2010-12-09 1:21 ` Shaohui Zheng
2010-12-09 21:29 ` David Rientjes [this message]
2010-12-09 23:57 ` Shaohui Zheng
2010-12-10 23:30 ` David Rientjes
2010-12-13 2:09 ` Shaohui Zheng
2010-12-13 20:56 ` David Rientjes
2010-12-07 1:00 [0/7,v8] NUMA Hotplug Emulator (v8) shaohui.zheng
2010-12-07 1:00 ` [7/7,v8] NUMA Hotplug Emulator: Implement per-node add_memory debugfs interface shaohui.zheng
2010-12-08 21:31 ` David Rientjes
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=alpine.DEB.2.00.1012091325530.13564@chino.kir.corp.google.com \
--to=rientjes@google.com \
--cc=ak@linux.intel.com \
--cc=akpm@linux-foundation.org \
--cc=gregkh@suse.de \
--cc=haicheng.li@linux.intel.com \
--cc=lethal@linux-sh.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=shaohui.zheng@intel.com \
--cc=shaohui.zheng@linux.intel.com \
/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