xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/3] disable Xen on ARM (until supported)
@ 2017-07-11  2:57 Philippe Mathieu-Daudé
  2017-07-11  2:57 ` [RFC PATCH 1/3] configure: disable Xen PCI Passthrough on !x86 archs Philippe Mathieu-Daudé
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Philippe Mathieu-Daudé @ 2017-07-11  2:57 UTC (permalink / raw)
  To: qemu-devel, xen-devel, Peter Maydell, Paolo Bonzini,
	Stefano Stabellini, qemu-arm
  Cc: Juergen Gross, Marcelo Tosatti, Philippe Mathieu-Daudé,
	Anthony Xu, Anoob Soman, Anthony Perard, xen-arm, Paul Durrant

Hi,

Those errors were triggered installing libxen v4.8 on debian Stretch
ARM (32b and 64b).

It seems QEMU only support Xen on x86 host.

patch 1 disable PCI Passthrough if not on x86,
patch 2 disable xen_map_cache() on ARM, I don't think it is the correct
way to do it, then
patch 3 add few comments to think about spliting x86 part from arch
agnostic Xen code.

That said, I realize there is no Xen ARM entry in MAINTAINERS, I'll Cc:
X86 maintainers although.

Regards,

Phil.

Philippe Mathieu-Daudé (3):
  configure: disable Xen PCI Passthrough on !x86 archs
  [XXX] xen/mapcache: disable on arm*
  [XXX] xen/pt: comment about !x86 archs

 configure                     | 11 +++++++++--
 hw/xen/xen_pt.c               |  4 ++--
 include/sysemu/xen-mapcache.h |  4 +++-
 3 files changed, 14 insertions(+), 5 deletions(-)

-- 
2.13.2


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [RFC PATCH 1/3] configure: disable Xen PCI Passthrough on !x86 archs
  2017-07-11  2:57 [RFC PATCH 0/3] disable Xen on ARM (until supported) Philippe Mathieu-Daudé
@ 2017-07-11  2:57 ` Philippe Mathieu-Daudé
  2017-07-11  2:57 ` [RFC PATCH 2/3] xen/mapcache: disable Xen on arm* Philippe Mathieu-Daudé
  2017-07-11  2:57 ` [RFC PATCH 3/3] xen/pt: add comments about !x86 archs Philippe Mathieu-Daudé
  2 siblings, 0 replies; 4+ messages in thread
From: Philippe Mathieu-Daudé @ 2017-07-11  2:57 UTC (permalink / raw)
  To: qemu-devel, xen-devel, Peter Maydell, Paolo Bonzini,
	Stefano Stabellini, qemu-arm
  Cc: Juergen Gross, Marcelo Tosatti, Philippe Mathieu-Daudé,
	Anthony Xu, Anoob Soman, Anthony Perard, xen-arm, Paul Durrant

linking on Linux debian/stretch/arm64 with libxen-4.8:

    hw/xen/xen_pt.o: In function `xen_pt_pci_read_config':
    qemu/hw/xen/xen_pt.c:206: undefined reference to `xen_shutdown_fatal_error'
    hw/xen/xen_pt.o: In function `xen_igd_passthrough_isa_bridge_create':
    qemu/hw/xen/xen_pt.c:698: undefined reference to `igd_passthrough_isa_bridge_create'
    hw/xen/xen_pt.o: In function `xen_pt_pci_write_config':
    qemu/hw/xen/xen_pt.c:355: undefined reference to `xen_shutdown_fatal_error'
    hw/xen/xen_pt_config_init.o: In function `xen_pt_status_reg_init':
    qemu/hw/xen/xen_pt_config_init.c:281: undefined reference to `xen_shutdown_fatal_error'
    qemu/hw/xen/xen_pt_config_init.c:275: undefined reference to `xen_shutdown_fatal_error'
    hw/xen/xen_pt_graphics.o: In function `get_vgabios':
    qemu/hw/xen/xen_pt_graphics.c:135: undefined reference to `pci_assign_dev_load_option_rom'
    collect2: error: ld returned 1 exit status
    Makefile:197: recipe for target 'qemu-system-aarch64' failed
    make[1]: *** [qemu-system-aarch64] Error 1

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 configure | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/configure b/configure
index 806658c98b..e4b173405a 100755
--- a/configure
+++ b/configure
@@ -2344,8 +2344,15 @@ EOF
 fi
 
 if test "$xen_pci_passthrough" != "no"; then
-  if test "$xen" = "yes" && test "$linux" = "yes"; then
-    xen_pci_passthrough=yes
+  if test "$xen" = "yes"; then
+    case "$cpu" in
+    i386|x32|x86_64)
+        if test "$linux" = "yes"; then
+            xen_pci_passthrough=yes
+        fi ;;
+    *)  echo "Disabling Xen PCI Passthrough (not implemented on $cpu)"
+        xen_pci_passthrough=no ;;
+    esac
   else
     if test "$xen_pci_passthrough" = "yes"; then
       error_exit "User requested feature Xen PCI Passthrough" \
-- 
2.13.2


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [RFC PATCH 2/3] xen/mapcache: disable Xen on arm*
  2017-07-11  2:57 [RFC PATCH 0/3] disable Xen on ARM (until supported) Philippe Mathieu-Daudé
  2017-07-11  2:57 ` [RFC PATCH 1/3] configure: disable Xen PCI Passthrough on !x86 archs Philippe Mathieu-Daudé
@ 2017-07-11  2:57 ` Philippe Mathieu-Daudé
  2017-07-11  2:57 ` [RFC PATCH 3/3] xen/pt: add comments about !x86 archs Philippe Mathieu-Daudé
  2 siblings, 0 replies; 4+ messages in thread
From: Philippe Mathieu-Daudé @ 2017-07-11  2:57 UTC (permalink / raw)
  To: qemu-devel, xen-devel, Peter Maydell, Paolo Bonzini,
	Stefano Stabellini, qemu-arm
  Cc: Juergen Gross, Marcelo Tosatti, Philippe Mathieu-Daudé,
	Anthony Xu, Anoob Soman, Anthony Perard, xen-arm, Paul Durrant

linking on Linux debian/stretch/arm[64] with libxen-4.8:

    exec.o: In function `reclaim_ramblock':
    qemu/exec.c:2071: undefined reference to `xen_invalidate_map_cache_entry'
    exec.o: In function `qemu_map_ram_ptr':
    qemu/exec.c:2177: undefined reference to `xen_map_cache'
    qemu/exec.c:2174: undefined reference to `xen_map_cache'
    exec.o: In function `qemu_ram_block_from_host':
    qemu/exec.c:2242: undefined reference to `xen_ram_addr_from_mapcache'
    qemu/exec.c:2242: undefined reference to `xen_ram_addr_from_mapcache'
    exec.o: In function `qemu_ram_ptr_length':
    qemu/exec.c:2210: undefined reference to `xen_map_cache'
    qemu/exec.c:2207: undefined reference to `xen_map_cache'
    exec.o: In function `address_space_unmap':
    qemu/exec.c:3357: undefined reference to `xen_invalidate_map_cache_entry'
    collect2: error: ld returned 1 exit status
    Makefile:197: recipe for target 'qemu-system-aarch64' failed
    make[1]: *** [qemu-system-aarch64] Error 1

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 include/sysemu/xen-mapcache.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/include/sysemu/xen-mapcache.h b/include/sysemu/xen-mapcache.h
index 01daaad00c..75f0988e04 100644
--- a/include/sysemu/xen-mapcache.h
+++ b/include/sysemu/xen-mapcache.h
@@ -12,7 +12,9 @@
 typedef hwaddr (*phys_offset_to_gaddr_t)(hwaddr start_addr,
                                                      ram_addr_t size,
                                                      void *opaque);
-#ifdef CONFIG_XEN
+/* FIXME ARM supported since Xen 4.3? */
+#if defined(CONFIG_XEN) /* XXX supported_xen_target() wrong? */ && \
+    !defined(HOST_ARM) && !defined(HOST_AARCH64)
 
 void xen_map_cache_init(phys_offset_to_gaddr_t f,
                         void *opaque);
-- 
2.13.2


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [RFC PATCH 3/3] xen/pt: add comments about !x86 archs
  2017-07-11  2:57 [RFC PATCH 0/3] disable Xen on ARM (until supported) Philippe Mathieu-Daudé
  2017-07-11  2:57 ` [RFC PATCH 1/3] configure: disable Xen PCI Passthrough on !x86 archs Philippe Mathieu-Daudé
  2017-07-11  2:57 ` [RFC PATCH 2/3] xen/mapcache: disable Xen on arm* Philippe Mathieu-Daudé
@ 2017-07-11  2:57 ` Philippe Mathieu-Daudé
  2 siblings, 0 replies; 4+ messages in thread
From: Philippe Mathieu-Daudé @ 2017-07-11  2:57 UTC (permalink / raw)
  To: qemu-devel, xen-devel, Peter Maydell, Paolo Bonzini,
	Stefano Stabellini
  Cc: Juergen Gross, Marcelo Tosatti, Philippe Mathieu-Daudé,
	Anthony Xu, Anoob Soman, Anthony Perard, Paul Durrant

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 hw/xen/xen_pt.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/xen/xen_pt.c b/hw/xen/xen_pt.c
index 375efa68f6..21c32b0991 100644
--- a/hw/xen/xen_pt.c
+++ b/hw/xen/xen_pt.c
@@ -58,7 +58,7 @@
 
 #include "hw/pci/pci.h"
 #include "hw/xen/xen.h"
-#include "hw/i386/pc.h"
+#include "hw/i386/pc.h" /* TODO check !x86 */
 #include "hw/xen/xen_backend.h"
 #include "xen_pt.h"
 #include "qemu/range.h"
@@ -687,7 +687,7 @@ static const MemoryListener xen_pt_io_listener = {
     .priority = 10,
 };
 
-static void
+static void /* TODO check !x86 */
 xen_igd_passthrough_isa_bridge_create(XenPCIPassthroughState *s,
                                       XenHostPCIDevice *dev)
 {
-- 
2.13.2


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-07-11  2:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-07-11  2:57 [RFC PATCH 0/3] disable Xen on ARM (until supported) Philippe Mathieu-Daudé
2017-07-11  2:57 ` [RFC PATCH 1/3] configure: disable Xen PCI Passthrough on !x86 archs Philippe Mathieu-Daudé
2017-07-11  2:57 ` [RFC PATCH 2/3] xen/mapcache: disable Xen on arm* Philippe Mathieu-Daudé
2017-07-11  2:57 ` [RFC PATCH 3/3] xen/pt: add comments about !x86 archs Philippe Mathieu-Daudé

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).