From: Nathan Lynch <ntl@pobox.com>
To: Michael Ellerman <michael@ellerman.id.au>
Cc: linuxppc-dev@ozlabs.org, Badari Pulavarty <pbadari@us.ibm.com>
Subject: Re: [PATCH 3/3] ppc64-specific memory notifier support
Date: Thu, 28 Feb 2008 18:39:06 -0600 [thread overview]
Message-ID: <20080229003906.GP16241@localdomain> (raw)
In-Reply-To: <1204243875.7729.3.camel@concordia.ozlabs.ibm.com>
Michael Ellerman wrote:
> On Thu, 2008-02-28 at 08:46 -0800, Badari Pulavarty wrote:
> > Hotplug memory notifier for ppc64. This gets invoked by writing
> > the device-node that needs to be removed to /proc/ppc64/ofdt.
> > We need to adjust the sections and remove sysfs entries by
> > calling __remove_pages(). Then call arch specific code to
> > get rid of htab mappings for the section of memory.
> >
> > Signed-off-by: Badari Pulavarty <pbadari@us.ibm.com>
> > ---
> > arch/powerpc/platforms/pseries/Makefile | 1
> > arch/powerpc/platforms/pseries/hotplug-memory.c | 98 ++++++++++++++++++++++++
> > 2 files changed, 99 insertions(+)
> >
> > Index: linux-2.6.25-rc2/arch/powerpc/platforms/pseries/hotplug-memory.c
> > ===================================================================
> > --- /dev/null 1970-01-01 00:00:00.000000000 +0000
> > +++ linux-2.6.25-rc2/arch/powerpc/platforms/pseries/hotplug-memory.c 2008-02-28 08:20:14.000000000 -0800
>
> > +
> > +static struct notifier_block pseries_smp_nb = {
> > + .notifier_call = pseries_memory_notifier,
> > +};
> > +
> > +static int __init pseries_memory_hotplug_init(void)
> > +{
> > + if (firmware_has_feature(FW_FEATURE_LPAR))
> > + pSeries_reconfig_notifier_register(&pseries_smp_nb);
> > +
> > + return 0;
> > +}
> > +arch_initcall(pseries_memory_hotplug_init);
>
> This is going to fire on non-pseries LPAR platforms, like iSeries and
> PS3. Which is not what you want I think.
Well, the notifier will be registered, yes, but it will never be
called because that path is reachable only from a write to
/proc/ppc64/ofdt, which is not created on non-pseries.
Maybe it should be
machine_device_initcall(pseries, pseries_memory_hotplug_init);
(and pseries_cpu_hotplug_init in hotplug-cpu.c should be changed to
machine_arch_initcall)
next prev parent reply other threads:[~2008-03-04 0:12 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-28 16:43 [PATCH 0/3] hotplug memory remove updates Badari Pulavarty
2008-02-28 16:44 ` [PATCH 1/3] ppc64-specific remove htab bolted mapping support Badari Pulavarty
2008-02-28 16:45 ` [PATCH 2/3] generic __remove_pages() support Badari Pulavarty
2008-02-28 16:46 ` [PATCH 3/3] ppc64-specific memory notifier support Badari Pulavarty
2008-02-28 17:20 ` Nathan Lynch
2008-02-28 18:57 ` Badari Pulavarty
2008-02-29 0:11 ` Michael Ellerman
2008-02-29 0:39 ` Nathan Lynch [this message]
2008-02-29 1:03 ` Michael Ellerman
2008-02-29 17:47 ` Badari Pulavarty
2008-03-01 2:51 ` Stephen Rothwell
2008-03-01 3:01 ` Badari Pulavarty
2008-03-03 0:49 ` Michael Ellerman
2008-02-29 17:56 ` [RFC] updating lmb.memory information for hot mem add/remove Badari Pulavarty
2008-03-01 1:12 ` Badari Pulavarty
2008-03-01 1:44 ` David Miller
2008-03-01 3:06 ` Badari Pulavarty
2008-02-29 1:39 ` [PATCH 0/3] hotplug memory remove updates Nathan Lynch
2008-02-29 2:19 ` Geoff Levand
2008-02-29 19:15 ` Nathan Lynch
2008-02-29 4:51 ` Badari Pulavarty
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=20080229003906.GP16241@localdomain \
--to=ntl@pobox.com \
--cc=linuxppc-dev@ozlabs.org \
--cc=michael@ellerman.id.au \
--cc=pbadari@us.ibm.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;
as well as URLs for NNTP newsgroup(s).