From: Dave Hansen <haveblue@us.ibm.com>
To: linux-ia64@vger.kernel.org
Subject: Re: [PATCH] ia64_cleanup_topology_init
Date: Thu, 10 Jun 2004 23:23:10 +0000 [thread overview]
Message-ID: <1086909790.26658.51.camel@nighthawk> (raw)
In-Reply-To: <ORSMSX409FRaqbC8wSA0000000c@orsmsx409.amr.corp.intel.com>
On Thu, 2004-06-10 at 16:00, Keshavamurthy, Anil S wrote:
> Side-effects with this patch:
> With this patch register_cpu() is now called only for _online_ cpu's and
> not for all _possible_ cpu's as the code was doing in
> arch/ia64/dig/topology.c. The reason for this is when the new cpu or
> node gets hot added at that time one can dynamically call these register
> functions.
I personally like this a lot better than the current ppc64 scheme where
all possible cpus are brought online. It's just confusing.
> +static int __init topology_init(void)
> +{
> + int i, err = 0;
> +
> +#ifdef CONFIG_NUMA
> + sysfs_nodes = kmalloc(sizeof(struct node) * numnodes,
> GFP_KERNEL);
> + if (!sysfs_nodes) {
> + err = -ENOMEM;
> + goto out;
> + }
> + memset(sysfs_nodes, 0, sizeof(struct node) * numnodes);
> +
> + for (i = 0; i < numnodes; i++)
> + if ((err = register_node(&sysfs_nodes[i], i, 0)))
> + goto out;
> +#endif
...
I wonder there should be a numa_topology_init() function to do this
part, instead if ifdef'ing it here. In fact, it might even be able to
be a completely generic function.
-- Dave
next prev parent reply other threads:[~2004-06-10 23:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-06-10 23:20 [PATCH] ia64_cleanup_topology_init Anil
2004-06-10 23:23 ` Dave Hansen [this message]
2004-06-10 23:30 ` Anil
2004-06-10 23:40 ` Dave Hansen
2004-06-10 23:54 ` David Mosberger
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=1086909790.26658.51.camel@nighthawk \
--to=haveblue@us.ibm.com \
--cc=linux-ia64@vger.kernel.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