From: Scott Wood <scottwood@freescale.com>
To: Dongsheng Wang <dongsheng.wang@freescale.com>
Cc: linuxppc-dev@lists.ozlabs.org, yorksun@freescale.com
Subject: Re: [PATCH] fsl/smp: add low power boot support to replace spin boot
Date: Mon, 19 Jan 2015 18:46:07 -0600 [thread overview]
Message-ID: <1421714767.4961.196.camel@freescale.com> (raw)
In-Reply-To: <1421301930-10035-1-git-send-email-dongsheng.wang@freescale.com>
On Thu, 2015-01-15 at 14:05 +0800, Dongsheng Wang wrote:
> From: Wang Dongsheng <dongsheng.wang@freescale.com>
>
> U-boot put non-boot cpus into an low power state(PW10/PW20 or DOZE) when cpu
> powered up. To exit low power state kernel will send DOORBELL or MPIC-IPI
> signal to all those CPUs.
U-Boot does not do this yet. A patch was just posted to propose such a
change.
> @@ -292,11 +315,58 @@ static int smp_85xx_kick_cpu(int nr)
> __secondary_hold_acknowledge = -1;
> }
> #endif
> +
> flush_spin_table(spin_table);
> - out_be32(&spin_table->pir, hw_cpu);
> + /*
> + * U-boot will wait kernel send eoi to MPIC, after EOI has send
> + * kernel will set PIR for uboot, let uboot know EOI has send.
> + */
> + out_be32(&spin_table->pir, 0);
Why is the kernel sending EOI for an interrupt U-Boot receives? Why are
you abusing PIR for anything other than setting the desired PIR value?
What happens when you enter the kernel with secondaries having PIR = 0?
> + /* Let cpu exit low power state, and from u-boot jump to kernel */
> + arch_send_call_function_single_ipi(kick_cpus);
> +
> + /*
> + * Let we ACK interrput and Send EOI signal to finish INT server
> + * U-boot has read EPR to ACK interrput when MPIC work in external
> + * proxy mode. Without the external proxy facility, we need to read
> + * MPIC ACK register.
> + *
> + * There just ACK interrput, we don't need to get the interrupt vector
> + * and to handle it. Because there just IPI or DOORBELL interrupt to
> + * make u-boot exit low power state and jump to kernel.
> + */
> + mpic_cpu_ack(nr);
How do you know the interrupt is ready to be acked at this point?
-Scott
prev parent reply other threads:[~2015-01-20 0:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-15 6:05 [PATCH] fsl/smp: add low power boot support to replace spin boot Dongsheng Wang
2015-01-15 6:46 ` Dongsheng.Wang
2015-01-15 17:08 ` York Sun
2015-01-16 2:49 ` Dongsheng.Wang
2015-01-20 0:46 ` Scott Wood [this message]
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=1421714767.4961.196.camel@freescale.com \
--to=scottwood@freescale.com \
--cc=dongsheng.wang@freescale.com \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=yorksun@freescale.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).