From: Geoff Levand <geoffrey.levand@am•sony.com>
To: Paul Mackerras <paulus@samba•org>
Cc: linuxppc-dev@ozlabs•org
Subject: Re: [RFC 2/3] zImage: SMP hold
Date: Mon, 19 Feb 2007 07:33:00 -0800 [thread overview]
Message-ID: <45D9C32C.7030706@am.sony.com> (raw)
In-Reply-To: <17880.61499.932513.926761@cargo.ozlabs.ibm.com>
Paul Mackerras wrote:
> Geoff Levand writes:
>
>> +void smp_secondary_hold(unsigned int cpu_id)
>> +{
>> + while(!smp_secondary_entry)
>> + (void)0;
>
> Using a barrier() here rather than making smp_secondary_entry volatile
> would be better, I think.
>
> Also, what's the lifetime of this code after smp_secondary_entry is
> set, i.e. how do we know the kernel running on the primary cpu will
> wait for the secondary cpus to have got through this code into the
> kernel before it reuses this memory for something else?
I was thinking the most (only?) reliably way is to do it from inside the kernel.
Once inside, the primary waits for all secondaries to enter before proceeding.
That's why I didn't have anything here. There is already a mechanism in the
kernel with __secondary_hold_acknowledge, but I don't yet know if it does
exactly what is needed. Do you see any trouble with this?
-Geoff
next prev parent reply other threads:[~2007-02-19 15:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-18 1:17 [RFC 2/3] zImage: SMP hold Geoff Levand
2007-02-19 0:32 ` Paul Mackerras
2007-02-19 15:33 ` Geoff Levand [this message]
2007-02-20 2:22 ` David Gibson
2007-02-20 14:32 ` Geoff Levand
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=45D9C32C.7030706@am.sony.com \
--to=geoffrey.levand@am$(echo .)sony.com \
--cc=linuxppc-dev@ozlabs$(echo .)org \
--cc=paulus@samba$(echo .)org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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