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

[RFC PATCH 0/4] arm: Implement ARM DEN 0057A PV time interface


  • To: xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Koichiro Den <den@xxxxxxxxxxxxx>
  • Date: Sun, 22 Jun 2025 00:11:57 +0900
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=valinux.co.jp; dmarc=pass action=none header.from=valinux.co.jp; dkim=pass header.d=valinux.co.jp; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=+MTRKS4LIBD1d3y/wd6/073T7aCD7eLmJnu+IO21Bv4=; b=V4JBInPtutYT1hH0Zh8F0UngZgK8MKOn+Ld2Ux3SFqV8X/lHqL8zyb1ps80bbfmwpYmLDrmUXxPaEzZqh/9e8moBi0rRaTcDMxrbJDPxT0KQjoj7KdWXNLlcMCRYrqczZYgopXOtjga0uplP1g2wG5qzUKrPzRWnJPL76hiWvNMecGJqtnyLE358AOs5uPxoghuA27q/a6aq2WAui+1h3Dzc2qGIGu+iwNUx+q7y0jRnbJBKhTJG3h63rXRmRc4IC1+KJDBz+io6zW0yDJu6+m2c8H+C82Kp3X6SPOenTR5POpjh/nqy09aAO8ppjNKHL6CnYA0I3OxH/HT19NKXTg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=icUGjXtiuEIQWDs7ZNQTRC6lj0pAS8KSXQCkYoJpRFURr+DdxMFVgc8Hw3uxNp28Ow2Q7CBsCUEctZ5L7VqU42CTC5Ox0FJwSwY93D6jbfWg0/Avy5ibbTG/P03VBusyFUzWzW57PeuwZ8vgqDXa+qljXXHzjo/sEYu0yuEeoSNjkfF+ZHca3l2mGXnfWZxmtdA8hd8+kv+T4WvB+g3hA7PQ/YFfimjpJa23RBBRVCgScULS5Ma70ARxwrbRiSlr3HA3f99tWxjIM4aFAvvxQJR1CVpqNRnM4CwuykoGnq13vfczvel55Qj6KMJdqzZpIiM4grUxBlXiEduAf6kqhA==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=valinux.co.jp;
  • Cc: Koichiro Den <den@xxxxxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Delivery-date: Sat, 21 Jun 2025 15:12:23 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

This series proposes the standard PV time implementation as per ARM DEN 0057A.
The first three commits are preparatory work, where no functional changes are
intended.

The motivation:

  The VCPUOP_register_runstate_memory_area hypercall is still actively
  used, e.g., in the Linux arm64. When KPTI is enabled, the area was not
  registered from the beginning due to the VA not always being valid. In
  such cases, Linux could fall back to using the standard PV time interface
  (ARM DEN 0057A), but this interface has not been implemented in Xen for
  arm64.

  Meanwhile, the VCPUOP_register_runstate_phys_area was introduced, though
  it's unclear whether this would be used in Linux arm64, nor when it will
  be prevalent amongst every possible downstream domain Linux variant even
  if so. And of course Linux is not an only option for the Xen arm64.

  Therefore, implementing the standard way of sharing PV time may be
  generically beneficial, reducing reliance on specially crafted
  hypercalls, the usage of which by guest VMs is not always guaranteed.
  Note that the PV_TIME_ST interface communicates with IPA (GPA), not GVA.


Koichiro Den (4):
  xen/arm: Add wrapper find_unused_regions
  xen/arm: Move make_hypervisor_node()
  xen/arm: Move make_resv_memory_node()
  xen/arm: Implement standard PV time interface as per ARM DEN 0057A

 xen/arch/arm/domain.c                   |  30 +++++
 xen/arch/arm/domain_build.c             | 168 +++++++++++++++++++++---
 xen/arch/arm/include/asm/domain.h       |  17 +++
 xen/arch/arm/include/asm/smccc.h        |  12 ++
 xen/arch/arm/vsmc.c                     |  38 ++++++
 xen/common/device-tree/dom0less-build.c |   2 +-
 xen/common/device-tree/static-shmem.c   |  40 ------
 xen/include/xen/fdt-domain-build.h      |   2 +
 xen/include/xen/static-shmem.h          |   9 --
 9 files changed, 248 insertions(+), 70 deletions(-)

-- 
2.48.1




 


Rackspace

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