[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v2 02/15] xen/arm: vpsci: Add support for PSCI 1.1

On 09.02.18 18:13, Julien Grall wrote:

On 02/09/2018 04:07 PM, Volodymyr Babchuk wrote:
Hi Julien,

Hi Volodymyr,

On 08.02.18 21:21, Julien Grall wrote:
At the moment, Xen provides virtual PSCI interface compliant with 0.1
and 0.2. Since them, the specification has been updated and the latest
version is 1.1 (see ARM DEN 0022D).

 From an implementation point of view, only PSCI_FEATURES is mandatory.
The rest is optional and can be left unimplemented for now.

At the same time, the compatible for PSCI node have been updated to
expose "arm,psci-1.0".

Signed-off-by: Julien Grall <julien.grall@xxxxxxx>
Cc: Wei Liu <wei.liu2@xxxxxxxxxx>
Cc: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
Cc: mirela.simonovic@xxxxxxxxxx
Reviewed-by: Volodymyr Babchuk <volodymyr_babchuk@xxxxxxxx>

     We may want to provide a way for the toolstack to specify a PSCI
     version. This could be useful if a guest is expecting a given

     Changes in v2:
         - Return v1.1 on GET_VERSION call as claimed by this patch
         - Order by function ID the calls in FEATURES call
  tools/libxl/libxl_arm.c          |  3 ++-
  xen/arch/arm/domain_build.c      |  1 +
  xen/arch/arm/vpsci.c             | 39 ++++++++++++++++++++++++++++++++++++++-
  xen/include/asm-arm/perfc_defn.h |  1 +
  xen/include/asm-arm/psci.h       |  1 +
  xen/include/asm-arm/vpsci.h      |  2 +-
  6 files changed, 44 insertions(+), 3 deletions(-)

diff --git a/tools/libxl/libxl_arm.c b/tools/libxl/libxl_arm.c
index 3e46554301..86f59c0d80 100644
--- a/tools/libxl/libxl_arm.c
+++ b/tools/libxl/libxl_arm.c
@@ -410,7 +410,8 @@ static int make_psci_node(libxl__gc *gc, void *fdt)
      res = fdt_begin_node(fdt, "psci");
      if (res) return res;
-    res = fdt_property_compat(gc, fdt, 2, "arm,psci-0.2","arm,psci");
+    res = fdt_property_compat(gc, fdt, 3, "arm,psci-1.0",
+                              "arm,psci-0.2", "arm,psci");
What about this place? Should it be "arm,psci-1.1"?

arm,psci-1.1 compatible string does not exist. Technically after 0.2 you should discover the PSCI version through GET_VERSION. So I am not entirely sure why arm,psci-1.0 compatible was added.

From the documentation (Documentation/devicetree/bindings/arm/psci.txt), the compatibles means the PSCI implementation comply to a given version. Our implementation complies to 0.1, 0.2 and 1.0. So I have added 1.0 just in case a guest decides to check the compatible.

Okay, makes sense

Volodymyr Babchuk

Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.