xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Andre Przywara <andre.przywara@linaro.org>
To: Ian Campbell <Ian.Campbell@citrix.com>
Cc: George Dunlap <George.Dunlap@eu.citrix.com>,
	Julien Grall <julien.grall@linaro.org>,
	"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>,
	"patches@linaro.org" <patches@linaro.org>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Subject: Re: [PATCH 0/4] ARM: add PSCI host support
Date: Mon, 25 Nov 2013 15:21:12 +0100	[thread overview]
Message-ID: <52935CD8.1070800@linaro.org> (raw)
In-Reply-To: <1385388206.22002.68.camel@kazak.uk.xensource.com>

On 11/25/2013 03:03 PM, Ian Campbell wrote:
> On Mon, 2013-11-25 at 13:00 +0000, George Dunlap wrote:
>> On Mon, Nov 25, 2013 at 12:02 PM, Andre Przywara
>> <andre.przywara@linaro.org> wrote:
>>> Xen did not make use of the host provided ARM PSCI (Power State
>>> Coordination Interface) functionality so far, but relied on platform
>>> specific SMP bringup functions.
>>> This series adds support for PSCI on the host by reading the required
>>> information from the DTB and invoking the appropriate handler when
>>> bringing up each single CPU.
>>> Since PSCI is defined for both ARM32 and ARM64, I put the code in a
>>> file shared by both.
>>> The ARM32 code was tested on Midway, but the ARM64 code was compile
>>> tested only.
>>>
>>> This approach seems to be the least intrusive, but one could also use
>>> more of the current ARM64 code by copying the PSCI/spin-table
>>> distinction code to a shared file and use that from both
>>> architectures. However that seems more complicated.
>>>
>>> Please take a look and complain ;-)
>>>
>>> Signed-off-by: Andre Przywara <andre.przywara@linaro.org>
>>
>> Ian, do you agree that this is too late for 4.4?
>
> I'm in two minds. On the one hand none of the existing platforms
> currently require this functionality, so it has clearly not been
> necessary up to now.
>
> On the other hand it plays into the strategy of allowing people to
> trivially support their platform, and since it is a standard way to do
> power control on ARM (albeit quite new and so far uptake is not huge) I
> think it is expected that many new platforms will use it.
>
> Of our current platforms Midway can optionally use PSCI (we have
> "native" code at the minute)

but which is not upstream yet, right?
So if you are considering dropping PSCI for 4.4, I'd like to know so 
that I can ack Julien's "native" SMP patch.
I hope at least this patch can make it for 4.4?

> and sunxi is going to need it whenever SMP
> is enabled (patches to u-boot are circulating now).

That is a good point. We would get sunxi SMP support basically for free, 
also the timing for this is independent of any Xen release cycle.

> I'm inclined towards punting on this for 4.4.0 but be open to the idea
> of adding it in 4.4.1 if it turns out to be something that people are
> needing in practice.

4.4.1 sounds OK for me. But it would be nice to have the native SMP 
support then in 4.4.0.

> An alternative could be requiring for 4.4 that the platform code
> explicitly call into/request PSCI for 4.4 and only move to automatically
> using it in the absence of the platform code saying otherwise for 4.5.

So you are thinking about a change in the priorities? The Linux kernel 
prefers PSCI over a native method, which is how I modeled the Xen patch 
also. This has the advantage of having control in the DTB, so if PSCI 
fails in Xen, one could do "fdt rm /psci" in u-boot to get the old 
behavior back.

> This has the advantage of being zero risk, but the downside of not being
> very well tested (we could enable it for Midway, with the attendant
> increase in risk).

So are you concerned about one of the existing platforms breaking SMP as 
soon as it gets PSCI support? One could change the patch to only use 
PSCI if platform_cpu_up() does _not_ return an explicit "ignore PSCI" 
value, if that helps.

Regards,
Andre.

  reply	other threads:[~2013-11-25 14:21 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-25 12:02 [PATCH 0/4] ARM: add PSCI host support Andre Przywara
2013-11-25 12:02 ` [PATCH 1/4] arm: parse PSCI node from the host device-tree Andre Przywara
2013-11-26 11:12   ` Ian Campbell
2013-11-26 11:25     ` Ian Campbell
2013-11-28 10:56     ` Andre Przywara
2013-11-25 12:02 ` [PATCH 2/4] arm: add a function to invoke the PSCI handler and use it Andre Przywara
2013-11-26 11:18   ` Ian Campbell
2013-11-28 10:59     ` Andre Przywara
2013-11-25 12:02 ` [PATCH 3/4] arm: dont give up on EAGAIN if PSCI is defined Andre Przywara
2013-11-26 11:20   ` Ian Campbell
2013-11-25 12:02 ` [PATCH 4/4] arm64: defer CPU initialization on ARM64 if PSCI is present Andre Przywara
2013-11-26 11:24   ` Ian Campbell
2013-11-25 13:00 ` [PATCH 0/4] ARM: add PSCI host support George Dunlap
2013-11-25 14:03   ` Ian Campbell
2013-11-25 14:21     ` Andre Przywara [this message]
2013-11-25 14:50       ` Ian Campbell
2013-11-25 15:03         ` Andre Przywara
2013-11-25 16:35     ` George Dunlap
2013-11-26 11:01       ` Ian Campbell
2013-11-26 11:05 ` Ian Campbell
2013-11-27 13:45   ` Andre Przywara
2013-11-27 14:28     ` Ian Campbell

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=52935CD8.1070800@linaro.org \
    --to=andre.przywara@linaro.org \
    --cc=George.Dunlap@eu.citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=julien.grall@linaro.org \
    --cc=patches@linaro.org \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xen.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;
as well as URLs for NNTP newsgroup(s).