From: Dave Hansen <haveblue@us.ibm.com>
To: keith <kmannth@us.ibm.com>
Cc: linux-mm <linux-mm@kvack.org>,
"Martin J. Bligh" <mbligh@aracnet.com>,
matt dobson <colpatch@us.ibm.com>,
John Stultz <johnstul@us.ibm.com>,
Andy Whitcroft <andyw@uk.ibm.com>
Subject: Re: [RFC] [Patch] For booting a i386 numa system with no memory in a node
Date: Mon, 21 Feb 2005 14:24:40 -0800 [thread overview]
Message-ID: <1109024680.25666.4.camel@localhost> (raw)
In-Reply-To: <1109023409.9817.1667.camel@knk>
On Mon, 2005-02-21 at 14:03 -0800, keith wrote:
> On Mon, 2005-02-21 at 12:39, Dave Hansen wrote:
> > On Mon, 2005-02-21 at 12:17 -0800, keith wrote:
> > > + if (node_has_online_mem(nid)){
> > > + if (start > low) {
> >
> > Instead of indenting another level, can you just put a continue in the
> > loop? I think it makes it much easier to read.
>
> I cannot put a continue here. I know it makes ugly code worse but we
> have to call free area_init_node in all cases.
If !node_has_online_mem(nid), then (node_start_pfn[nid] ==
node_end_pfn[nid]), and running through this if() won't hurt anything
here:
> if (start > low) {
> #ifdef CONFIG_HIGHMEM
> BUG_ON(start > high);
> zones_size[ZONE_HIGHMEM] = high - start;
> #endif
> }
high==start, so the bug won't trip, and it will set
zones_size[ZONE_HIGHMEM]=0, which is also OK. Can you do this?
- if (start > low) {
+ if (node_has_online_mem(nid) || (start > low)) {
> +#define node_has_online_mem(nid) !(node_start_pfn[nid] == node_end_pfn[nid])
> +/*
> +inline int __node_has_online_mem(int nid) {
> + return !(node_start_pfn[nid]== node_end_pfn[nid]);
> +}
> +*/
You probably want to kill the extra definition. Also, I prefer
(node_start_pfn[nid] != node_end_pfn[nid])
to
!(node_start_pfn[nid] == node_end_pfn[nid])
But, that's the most minor of nits.
-- Dave
--
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/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>
next prev parent reply other threads:[~2005-02-21 22:24 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1106881119.2040.122.camel@cog.beaverton.ibm.com>
[not found] ` <1106882150.2040.126.camel@cog.beaverton.ibm.com>
[not found] ` <1106937253.27125.6.camel@knk>
[not found] ` <1106938993.14330.65.camel@localhost>
[not found] ` <1106941547.27125.25.camel@knk>
[not found] ` <1106942832.17936.3.camel@arrakis>
[not found] ` <1108611260.9817.1227.camel@knk>
[not found] ` <1108654782.19395.9.camel@localhost>
[not found] ` <1108664637.9817.1259.camel@knk>
[not found] ` <1108666091.19395.29.camel@localhost>
[not found] ` <1108671423.9817.1266.camel@knk>
[not found] ` <421510E9.3000901@us.ibm.com>
[not found] ` <1108677113.32193.8.camel@localhost>
[not found] ` <42152690.4030508@us.ibm.com>
[not found] ` <9230000.1108666127@flay>
[not found] ` <1108686742.6482.51.camel@localhost>
2005-02-21 20:17 ` [RFC] [Patch] For booting a i386 numa system with no memory in a node keith
2005-02-21 20:39 ` Dave Hansen
2005-02-21 22:03 ` keith
2005-02-21 22:24 ` Dave Hansen [this message]
2005-02-21 23:46 ` keith
2005-02-21 23:55 ` Dave Hansen
2005-02-22 0:09 ` Dave Hansen
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=1109024680.25666.4.camel@localhost \
--to=haveblue@us.ibm.com \
--cc=andyw@uk.ibm.com \
--cc=colpatch@us.ibm.com \
--cc=johnstul@us.ibm.com \
--cc=kmannth@us.ibm.com \
--cc=linux-mm@kvack.org \
--cc=mbligh@aracnet.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.