arm/libxl: Emulated PCI device tree node in libxl
authorRahul Singh <rahul.singh@arm.com>
Fri, 15 Oct 2021 16:51:45 +0000 (17:51 +0100)
committerStefano Stabellini <stefano.stabellini@xilinx.com>
Fri, 15 Oct 2021 19:40:21 +0000 (12:40 -0700)
commit52d0847d7c6972baa74156f14ee8544f5aba1d2d
tree3b4a98eb8338bb7d76f434e9f2417b760d05b79e
parent559ea0debabac5f142d3b901527d48cc99021588
arm/libxl: Emulated PCI device tree node in libxl

libxl will create an emulated PCI device tree node in the device tree to
enable the guest OS to discover the virtual PCI during guest boot.
Emulated PCI device tree node will only be created when there is any
device assigned to guest.

A new area has been reserved in the arm guest physical map at
which the VPCI bus is declared in the device tree (reg and ranges
parameters of the node).

Note that currently we are using num_pcidevs instead of
c_info->passthrough to decide whether to create a vPCI DT node.
This will be insufficient if and when ARM does PCI hotplug.
Add this note inside libxl_create.c where c_info->passthrough
is set.

Signed-off-by: Rahul Singh <rahul.singh@arm.com>
Signed-off-by: Michal Orzel <michal.orzel@arm.com>
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Julien Grall <jgrall@amazon.com>
Acked-by: Ian Jackson <iwj@xenproject.org>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
tools/libs/light/libxl_arm.c
tools/libs/light/libxl_create.c
xen/include/public/arch-arm.h