All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-02  6:32 ` Juergen Gross
  0 siblings, 0 replies; 14+ messages in thread
From: Juergen Gross @ 2016-08-02  6:32 UTC (permalink / raw)
  To: qemu-devel, xen-devel; +Cc: kraxel, sstabellini, anthony.perard, Juergen Gross

Instead of calling xen_be_register() for each supported backend type
for hvm and pv guests in their machine init functions use a common
function in order not to have to add new backends twice.

This at once fixes the error that hvm domains couldn't use the qusb
backend.

Signed-off-by: Juergen Gross <jgross@suse.com>
---
Is it on purpose the qnic and vfb backends are not registered for HVM?
---
 hw/xen/xen_backend.c         | 10 ++++++++++
 hw/xenpv/xen_machine_pv.c    |  7 +------
 include/hw/xen/xen_backend.h |  1 +
 xen-hvm.c                    |  4 +---
 4 files changed, 13 insertions(+), 9 deletions(-)

diff --git a/hw/xen/xen_backend.c b/hw/xen/xen_backend.c
index bab79b1..1b88891 100644
--- a/hw/xen/xen_backend.c
+++ b/hw/xen/xen_backend.c
@@ -800,6 +800,16 @@ int xen_be_register(const char *type, struct XenDevOps *ops)
     return xenstore_scan(type, xen_domid, ops);
 }
 
+void xen_be_register_common(void)
+{
+    xen_be_register("console", &xen_console_ops);
+    xen_be_register("vkbd", &xen_kbdmouse_ops);
+    xen_be_register("qdisk", &xen_blkdev_ops);
+#ifdef CONFIG_USB_LIBUSB
+    xen_be_register("qusb", &xen_usb_ops);
+#endif
+}
+
 int xen_be_bind_evtchn(struct XenDevice *xendev)
 {
     if (xendev->local_port != -1) {
diff --git a/hw/xenpv/xen_machine_pv.c b/hw/xenpv/xen_machine_pv.c
index 48f725c..79aef4e 100644
--- a/hw/xenpv/xen_machine_pv.c
+++ b/hw/xenpv/xen_machine_pv.c
@@ -67,14 +67,9 @@ static void xen_init_pv(MachineState *machine)
         break;
     }
 
-    xen_be_register("console", &xen_console_ops);
-    xen_be_register("vkbd", &xen_kbdmouse_ops);
+    xen_be_register_common();
     xen_be_register("vfb", &xen_framebuffer_ops);
-    xen_be_register("qdisk", &xen_blkdev_ops);
     xen_be_register("qnic", &xen_netdev_ops);
-#ifdef CONFIG_USB_LIBUSB
-    xen_be_register("qusb", &xen_usb_ops);
-#endif
 
     /* configure framebuffer */
     if (xenfb_enabled) {
diff --git a/include/hw/xen/xen_backend.h b/include/hw/xen/xen_backend.h
index 754c0a4..0df282a 100644
--- a/include/hw/xen/xen_backend.h
+++ b/include/hw/xen/xen_backend.h
@@ -87,6 +87,7 @@ void xen_be_check_state(struct XenDevice *xendev);
 
 /* xen backend driver bits */
 int xen_be_init(void);
+void xen_be_register_common(void);
 int xen_be_register(const char *type, struct XenDevOps *ops);
 int xen_be_set_state(struct XenDevice *xendev, enum xenbus_state state);
 int xen_be_bind_evtchn(struct XenDevice *xendev);
diff --git a/xen-hvm.c b/xen-hvm.c
index eb57792..3b0343a 100644
--- a/xen-hvm.c
+++ b/xen-hvm.c
@@ -1318,9 +1318,7 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
         error_report("xen backend core setup failed");
         goto err;
     }
-    xen_be_register("console", &xen_console_ops);
-    xen_be_register("vkbd", &xen_kbdmouse_ops);
-    xen_be_register("qdisk", &xen_blkdev_ops);
+    xen_be_register_common();
     xen_read_physmap(state);
     return;
 
-- 
2.6.6

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

* [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-02  6:32 ` Juergen Gross
  0 siblings, 0 replies; 14+ messages in thread
From: Juergen Gross @ 2016-08-02  6:32 UTC (permalink / raw)
  To: qemu-devel, xen-devel; +Cc: anthony.perard, Juergen Gross, sstabellini, kraxel

Instead of calling xen_be_register() for each supported backend type
for hvm and pv guests in their machine init functions use a common
function in order not to have to add new backends twice.

This at once fixes the error that hvm domains couldn't use the qusb
backend.

Signed-off-by: Juergen Gross <jgross@suse.com>
---
Is it on purpose the qnic and vfb backends are not registered for HVM?
---
 hw/xen/xen_backend.c         | 10 ++++++++++
 hw/xenpv/xen_machine_pv.c    |  7 +------
 include/hw/xen/xen_backend.h |  1 +
 xen-hvm.c                    |  4 +---
 4 files changed, 13 insertions(+), 9 deletions(-)

diff --git a/hw/xen/xen_backend.c b/hw/xen/xen_backend.c
index bab79b1..1b88891 100644
--- a/hw/xen/xen_backend.c
+++ b/hw/xen/xen_backend.c
@@ -800,6 +800,16 @@ int xen_be_register(const char *type, struct XenDevOps *ops)
     return xenstore_scan(type, xen_domid, ops);
 }
 
+void xen_be_register_common(void)
+{
+    xen_be_register("console", &xen_console_ops);
+    xen_be_register("vkbd", &xen_kbdmouse_ops);
+    xen_be_register("qdisk", &xen_blkdev_ops);
+#ifdef CONFIG_USB_LIBUSB
+    xen_be_register("qusb", &xen_usb_ops);
+#endif
+}
+
 int xen_be_bind_evtchn(struct XenDevice *xendev)
 {
     if (xendev->local_port != -1) {
diff --git a/hw/xenpv/xen_machine_pv.c b/hw/xenpv/xen_machine_pv.c
index 48f725c..79aef4e 100644
--- a/hw/xenpv/xen_machine_pv.c
+++ b/hw/xenpv/xen_machine_pv.c
@@ -67,14 +67,9 @@ static void xen_init_pv(MachineState *machine)
         break;
     }
 
-    xen_be_register("console", &xen_console_ops);
-    xen_be_register("vkbd", &xen_kbdmouse_ops);
+    xen_be_register_common();
     xen_be_register("vfb", &xen_framebuffer_ops);
-    xen_be_register("qdisk", &xen_blkdev_ops);
     xen_be_register("qnic", &xen_netdev_ops);
-#ifdef CONFIG_USB_LIBUSB
-    xen_be_register("qusb", &xen_usb_ops);
-#endif
 
     /* configure framebuffer */
     if (xenfb_enabled) {
diff --git a/include/hw/xen/xen_backend.h b/include/hw/xen/xen_backend.h
index 754c0a4..0df282a 100644
--- a/include/hw/xen/xen_backend.h
+++ b/include/hw/xen/xen_backend.h
@@ -87,6 +87,7 @@ void xen_be_check_state(struct XenDevice *xendev);
 
 /* xen backend driver bits */
 int xen_be_init(void);
+void xen_be_register_common(void);
 int xen_be_register(const char *type, struct XenDevOps *ops);
 int xen_be_set_state(struct XenDevice *xendev, enum xenbus_state state);
 int xen_be_bind_evtchn(struct XenDevice *xendev);
diff --git a/xen-hvm.c b/xen-hvm.c
index eb57792..3b0343a 100644
--- a/xen-hvm.c
+++ b/xen-hvm.c
@@ -1318,9 +1318,7 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
         error_report("xen backend core setup failed");
         goto err;
     }
-    xen_be_register("console", &xen_console_ops);
-    xen_be_register("vkbd", &xen_kbdmouse_ops);
-    xen_be_register("qdisk", &xen_blkdev_ops);
+    xen_be_register_common();
     xen_read_physmap(state);
     return;
 
-- 
2.6.6

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

* Re: [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls
  2016-08-02  6:32 ` Juergen Gross
@ 2016-08-02 11:40   ` Gerd Hoffmann
  -1 siblings, 0 replies; 14+ messages in thread
From: Gerd Hoffmann @ 2016-08-02 11:40 UTC (permalink / raw)
  To: Juergen Gross; +Cc: qemu-devel, xen-devel, sstabellini, anthony.perard

On Di, 2016-08-02 at 08:32 +0200, Juergen Gross wrote:
> Instead of calling xen_be_register() for each supported backend type
> for hvm and pv guests in their machine init functions use a common
> function in order not to have to add new backends twice.
> 
> This at once fixes the error that hvm domains couldn't use the qusb
> backend.

Looks good to me.  Should I take this through the usb patch queue,
together with the other xen-usb fixes (once codestyle issues are fixed)?
If so, can I get an ack from xen please, preferably fast enough for
-rc2?

thanks,
  Gerd

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

* Re: [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-02 11:40   ` Gerd Hoffmann
  0 siblings, 0 replies; 14+ messages in thread
From: Gerd Hoffmann @ 2016-08-02 11:40 UTC (permalink / raw)
  To: Juergen Gross; +Cc: anthony.perard, xen-devel, sstabellini, qemu-devel

On Di, 2016-08-02 at 08:32 +0200, Juergen Gross wrote:
> Instead of calling xen_be_register() for each supported backend type
> for hvm and pv guests in their machine init functions use a common
> function in order not to have to add new backends twice.
> 
> This at once fixes the error that hvm domains couldn't use the qusb
> backend.

Looks good to me.  Should I take this through the usb patch queue,
together with the other xen-usb fixes (once codestyle issues are fixed)?
If so, can I get an ack from xen please, preferably fast enough for
-rc2?

thanks,
  Gerd

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

* Re: [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls
  2016-08-02  6:32 ` Juergen Gross
@ 2016-08-02 17:43   ` Anthony PERARD
  -1 siblings, 0 replies; 14+ messages in thread
From: Anthony PERARD @ 2016-08-02 17:43 UTC (permalink / raw)
  To: Juergen Gross; +Cc: qemu-devel, xen-devel, kraxel, sstabellini

On Tue, Aug 02, 2016 at 08:32:32AM +0200, Juergen Gross wrote:
> Instead of calling xen_be_register() for each supported backend type
> for hvm and pv guests in their machine init functions use a common
> function in order not to have to add new backends twice.
> 
> This at once fixes the error that hvm domains couldn't use the qusb
> backend.
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>

Acked-by: Anthony PERARD <anthony.perard@citrix.com>

> ---
> Is it on purpose the qnic and vfb backends are not registered for HVM?

I guess it has not been usefull. Stefano may have a better answer.

-- 
Anthony PERARD

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

* Re: [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-02 17:43   ` Anthony PERARD
  0 siblings, 0 replies; 14+ messages in thread
From: Anthony PERARD @ 2016-08-02 17:43 UTC (permalink / raw)
  To: Juergen Gross; +Cc: xen-devel, sstabellini, qemu-devel, kraxel

On Tue, Aug 02, 2016 at 08:32:32AM +0200, Juergen Gross wrote:
> Instead of calling xen_be_register() for each supported backend type
> for hvm and pv guests in their machine init functions use a common
> function in order not to have to add new backends twice.
> 
> This at once fixes the error that hvm domains couldn't use the qusb
> backend.
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>

Acked-by: Anthony PERARD <anthony.perard@citrix.com>

> ---
> Is it on purpose the qnic and vfb backends are not registered for HVM?

I guess it has not been usefull. Stefano may have a better answer.

-- 
Anthony PERARD

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

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

* Re: [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls
  2016-08-02  6:32 ` Juergen Gross
@ 2016-08-02 18:27   ` Stefano Stabellini
  -1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2016-08-02 18:27 UTC (permalink / raw)
  To: Juergen Gross; +Cc: qemu-devel, xen-devel, kraxel, sstabellini, anthony.perard

On Tue, 2 Aug 2016, Juergen Gross wrote:
> Instead of calling xen_be_register() for each supported backend type
> for hvm and pv guests in their machine init functions use a common
> function in order not to have to add new backends twice.
> 
> This at once fixes the error that hvm domains couldn't use the qusb
> backend.
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>
> ---
> Is it on purpose the qnic and vfb backends are not registered for HVM?

Yes, it is on purpose: there is no code in any toolstacks to use qnic,
and the presence of vfb can cause problems to Linux HVM guests (or at
least it used to), additionally vfb for HVM guests is also disabled in
libxl.

In general, it is a good idea to disable code that is not supposed to be
used.

Can qusb be used with HVM guests with libxl/xl?


>  hw/xen/xen_backend.c         | 10 ++++++++++
>  hw/xenpv/xen_machine_pv.c    |  7 +------
>  include/hw/xen/xen_backend.h |  1 +
>  xen-hvm.c                    |  4 +---
>  4 files changed, 13 insertions(+), 9 deletions(-)
> 
> diff --git a/hw/xen/xen_backend.c b/hw/xen/xen_backend.c
> index bab79b1..1b88891 100644
> --- a/hw/xen/xen_backend.c
> +++ b/hw/xen/xen_backend.c
> @@ -800,6 +800,16 @@ int xen_be_register(const char *type, struct XenDevOps *ops)
>      return xenstore_scan(type, xen_domid, ops);
>  }
>  
> +void xen_be_register_common(void)
> +{
> +    xen_be_register("console", &xen_console_ops);
> +    xen_be_register("vkbd", &xen_kbdmouse_ops);
> +    xen_be_register("qdisk", &xen_blkdev_ops);
> +#ifdef CONFIG_USB_LIBUSB
> +    xen_be_register("qusb", &xen_usb_ops);
> +#endif
> +}
> +
>  int xen_be_bind_evtchn(struct XenDevice *xendev)
>  {
>      if (xendev->local_port != -1) {
> diff --git a/hw/xenpv/xen_machine_pv.c b/hw/xenpv/xen_machine_pv.c
> index 48f725c..79aef4e 100644
> --- a/hw/xenpv/xen_machine_pv.c
> +++ b/hw/xenpv/xen_machine_pv.c
> @@ -67,14 +67,9 @@ static void xen_init_pv(MachineState *machine)
>          break;
>      }
>  
> -    xen_be_register("console", &xen_console_ops);
> -    xen_be_register("vkbd", &xen_kbdmouse_ops);
> +    xen_be_register_common();
>      xen_be_register("vfb", &xen_framebuffer_ops);
> -    xen_be_register("qdisk", &xen_blkdev_ops);
>      xen_be_register("qnic", &xen_netdev_ops);
> -#ifdef CONFIG_USB_LIBUSB
> -    xen_be_register("qusb", &xen_usb_ops);
> -#endif
>  
>      /* configure framebuffer */
>      if (xenfb_enabled) {
> diff --git a/include/hw/xen/xen_backend.h b/include/hw/xen/xen_backend.h
> index 754c0a4..0df282a 100644
> --- a/include/hw/xen/xen_backend.h
> +++ b/include/hw/xen/xen_backend.h
> @@ -87,6 +87,7 @@ void xen_be_check_state(struct XenDevice *xendev);
>  
>  /* xen backend driver bits */
>  int xen_be_init(void);
> +void xen_be_register_common(void);
>  int xen_be_register(const char *type, struct XenDevOps *ops);
>  int xen_be_set_state(struct XenDevice *xendev, enum xenbus_state state);
>  int xen_be_bind_evtchn(struct XenDevice *xendev);
> diff --git a/xen-hvm.c b/xen-hvm.c
> index eb57792..3b0343a 100644
> --- a/xen-hvm.c
> +++ b/xen-hvm.c
> @@ -1318,9 +1318,7 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
>          error_report("xen backend core setup failed");
>          goto err;
>      }
> -    xen_be_register("console", &xen_console_ops);
> -    xen_be_register("vkbd", &xen_kbdmouse_ops);
> -    xen_be_register("qdisk", &xen_blkdev_ops);
> +    xen_be_register_common();
>      xen_read_physmap(state);
>      return;
>  
> -- 
> 2.6.6
> 

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

* Re: [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-02 18:27   ` Stefano Stabellini
  0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2016-08-02 18:27 UTC (permalink / raw)
  To: Juergen Gross; +Cc: anthony.perard, xen-devel, sstabellini, qemu-devel, kraxel

On Tue, 2 Aug 2016, Juergen Gross wrote:
> Instead of calling xen_be_register() for each supported backend type
> for hvm and pv guests in their machine init functions use a common
> function in order not to have to add new backends twice.
> 
> This at once fixes the error that hvm domains couldn't use the qusb
> backend.
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>
> ---
> Is it on purpose the qnic and vfb backends are not registered for HVM?

Yes, it is on purpose: there is no code in any toolstacks to use qnic,
and the presence of vfb can cause problems to Linux HVM guests (or at
least it used to), additionally vfb for HVM guests is also disabled in
libxl.

In general, it is a good idea to disable code that is not supposed to be
used.

Can qusb be used with HVM guests with libxl/xl?


>  hw/xen/xen_backend.c         | 10 ++++++++++
>  hw/xenpv/xen_machine_pv.c    |  7 +------
>  include/hw/xen/xen_backend.h |  1 +
>  xen-hvm.c                    |  4 +---
>  4 files changed, 13 insertions(+), 9 deletions(-)
> 
> diff --git a/hw/xen/xen_backend.c b/hw/xen/xen_backend.c
> index bab79b1..1b88891 100644
> --- a/hw/xen/xen_backend.c
> +++ b/hw/xen/xen_backend.c
> @@ -800,6 +800,16 @@ int xen_be_register(const char *type, struct XenDevOps *ops)
>      return xenstore_scan(type, xen_domid, ops);
>  }
>  
> +void xen_be_register_common(void)
> +{
> +    xen_be_register("console", &xen_console_ops);
> +    xen_be_register("vkbd", &xen_kbdmouse_ops);
> +    xen_be_register("qdisk", &xen_blkdev_ops);
> +#ifdef CONFIG_USB_LIBUSB
> +    xen_be_register("qusb", &xen_usb_ops);
> +#endif
> +}
> +
>  int xen_be_bind_evtchn(struct XenDevice *xendev)
>  {
>      if (xendev->local_port != -1) {
> diff --git a/hw/xenpv/xen_machine_pv.c b/hw/xenpv/xen_machine_pv.c
> index 48f725c..79aef4e 100644
> --- a/hw/xenpv/xen_machine_pv.c
> +++ b/hw/xenpv/xen_machine_pv.c
> @@ -67,14 +67,9 @@ static void xen_init_pv(MachineState *machine)
>          break;
>      }
>  
> -    xen_be_register("console", &xen_console_ops);
> -    xen_be_register("vkbd", &xen_kbdmouse_ops);
> +    xen_be_register_common();
>      xen_be_register("vfb", &xen_framebuffer_ops);
> -    xen_be_register("qdisk", &xen_blkdev_ops);
>      xen_be_register("qnic", &xen_netdev_ops);
> -#ifdef CONFIG_USB_LIBUSB
> -    xen_be_register("qusb", &xen_usb_ops);
> -#endif
>  
>      /* configure framebuffer */
>      if (xenfb_enabled) {
> diff --git a/include/hw/xen/xen_backend.h b/include/hw/xen/xen_backend.h
> index 754c0a4..0df282a 100644
> --- a/include/hw/xen/xen_backend.h
> +++ b/include/hw/xen/xen_backend.h
> @@ -87,6 +87,7 @@ void xen_be_check_state(struct XenDevice *xendev);
>  
>  /* xen backend driver bits */
>  int xen_be_init(void);
> +void xen_be_register_common(void);
>  int xen_be_register(const char *type, struct XenDevOps *ops);
>  int xen_be_set_state(struct XenDevice *xendev, enum xenbus_state state);
>  int xen_be_bind_evtchn(struct XenDevice *xendev);
> diff --git a/xen-hvm.c b/xen-hvm.c
> index eb57792..3b0343a 100644
> --- a/xen-hvm.c
> +++ b/xen-hvm.c
> @@ -1318,9 +1318,7 @@ void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory)
>          error_report("xen backend core setup failed");
>          goto err;
>      }
> -    xen_be_register("console", &xen_console_ops);
> -    xen_be_register("vkbd", &xen_kbdmouse_ops);
> -    xen_be_register("qdisk", &xen_blkdev_ops);
> +    xen_be_register_common();
>      xen_read_physmap(state);
>      return;
>  
> -- 
> 2.6.6
> 

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

* Re: [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls
  2016-08-02 11:40   ` Gerd Hoffmann
@ 2016-08-02 18:32     ` Stefano Stabellini
  -1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2016-08-02 18:32 UTC (permalink / raw)
  To: Gerd Hoffmann
  Cc: Juergen Gross, qemu-devel, xen-devel, sstabellini, anthony.perard

On Tue, 2 Aug 2016, Gerd Hoffmann wrote:
> On Di, 2016-08-02 at 08:32 +0200, Juergen Gross wrote:
> > Instead of calling xen_be_register() for each supported backend type
> > for hvm and pv guests in their machine init functions use a common
> > function in order not to have to add new backends twice.
> > 
> > This at once fixes the error that hvm domains couldn't use the qusb
> > backend.
> 
> Looks good to me.  Should I take this through the usb patch queue,
> together with the other xen-usb fixes (once codestyle issues are fixed)?
> If so, can I get an ack from xen please, preferably fast enough for
> -rc2?

Hi Gerd, I am happy for you to handle all three patches (if for any
reasons you change your mind I can do it).
"xen: bug fixes in Xen backend handling" v2 is ready to be committed,
and I am just waiting for an answer on this patch.

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

* Re: [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-02 18:32     ` Stefano Stabellini
  0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2016-08-02 18:32 UTC (permalink / raw)
  To: Gerd Hoffmann
  Cc: Juergen Gross, anthony.perard, xen-devel, sstabellini, qemu-devel

On Tue, 2 Aug 2016, Gerd Hoffmann wrote:
> On Di, 2016-08-02 at 08:32 +0200, Juergen Gross wrote:
> > Instead of calling xen_be_register() for each supported backend type
> > for hvm and pv guests in their machine init functions use a common
> > function in order not to have to add new backends twice.
> > 
> > This at once fixes the error that hvm domains couldn't use the qusb
> > backend.
> 
> Looks good to me.  Should I take this through the usb patch queue,
> together with the other xen-usb fixes (once codestyle issues are fixed)?
> If so, can I get an ack from xen please, preferably fast enough for
> -rc2?

Hi Gerd, I am happy for you to handle all three patches (if for any
reasons you change your mind I can do it).
"xen: bug fixes in Xen backend handling" v2 is ready to be committed,
and I am just waiting for an answer on this patch.

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

* Re: [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls
  2016-08-02 18:27   ` Stefano Stabellini
@ 2016-08-03  3:56     ` Juergen Gross
  -1 siblings, 0 replies; 14+ messages in thread
From: Juergen Gross @ 2016-08-03  3:56 UTC (permalink / raw)
  To: Stefano Stabellini; +Cc: qemu-devel, xen-devel, kraxel, anthony.perard

On 02/08/16 20:27, Stefano Stabellini wrote:
> On Tue, 2 Aug 2016, Juergen Gross wrote:
>> Instead of calling xen_be_register() for each supported backend type
>> for hvm and pv guests in their machine init functions use a common
>> function in order not to have to add new backends twice.
>>
>> This at once fixes the error that hvm domains couldn't use the qusb
>> backend.
>>
>> Signed-off-by: Juergen Gross <jgross@suse.com>
>> ---
>> Is it on purpose the qnic and vfb backends are not registered for HVM?
> 
> Yes, it is on purpose: there is no code in any toolstacks to use qnic,
> and the presence of vfb can cause problems to Linux HVM guests (or at
> least it used to), additionally vfb for HVM guests is also disabled in
> libxl.
> 
> In general, it is a good idea to disable code that is not supposed to be
> used.
> 
> Can qusb be used with HVM guests with libxl/xl?

Yes. You have to specify "type=qusb" for usbctrl, then it will work.
I have verified that.


Juergen

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

* Re: [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-03  3:56     ` Juergen Gross
  0 siblings, 0 replies; 14+ messages in thread
From: Juergen Gross @ 2016-08-03  3:56 UTC (permalink / raw)
  To: Stefano Stabellini; +Cc: anthony.perard, xen-devel, qemu-devel, kraxel

On 02/08/16 20:27, Stefano Stabellini wrote:
> On Tue, 2 Aug 2016, Juergen Gross wrote:
>> Instead of calling xen_be_register() for each supported backend type
>> for hvm and pv guests in their machine init functions use a common
>> function in order not to have to add new backends twice.
>>
>> This at once fixes the error that hvm domains couldn't use the qusb
>> backend.
>>
>> Signed-off-by: Juergen Gross <jgross@suse.com>
>> ---
>> Is it on purpose the qnic and vfb backends are not registered for HVM?
> 
> Yes, it is on purpose: there is no code in any toolstacks to use qnic,
> and the presence of vfb can cause problems to Linux HVM guests (or at
> least it used to), additionally vfb for HVM guests is also disabled in
> libxl.
> 
> In general, it is a good idea to disable code that is not supposed to be
> used.
> 
> Can qusb be used with HVM guests with libxl/xl?

Yes. You have to specify "type=qusb" for usbctrl, then it will work.
I have verified that.


Juergen

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

* Re: [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls
  2016-08-03  3:56     ` Juergen Gross
@ 2016-08-03 17:50       ` Stefano Stabellini
  -1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2016-08-03 17:50 UTC (permalink / raw)
  To: Juergen Gross
  Cc: Stefano Stabellini, qemu-devel, xen-devel, kraxel, anthony.perard

On Wed, 3 Aug 2016, Juergen Gross wrote:
> On 02/08/16 20:27, Stefano Stabellini wrote:
> > On Tue, 2 Aug 2016, Juergen Gross wrote:
> >> Instead of calling xen_be_register() for each supported backend type
> >> for hvm and pv guests in their machine init functions use a common
> >> function in order not to have to add new backends twice.
> >>
> >> This at once fixes the error that hvm domains couldn't use the qusb
> >> backend.
> >>
> >> Signed-off-by: Juergen Gross <jgross@suse.com>
> >> ---
> >> Is it on purpose the qnic and vfb backends are not registered for HVM?
> > 
> > Yes, it is on purpose: there is no code in any toolstacks to use qnic,
> > and the presence of vfb can cause problems to Linux HVM guests (or at
> > least it used to), additionally vfb for HVM guests is also disabled in
> > libxl.
> > 
> > In general, it is a good idea to disable code that is not supposed to be
> > used.
> > 
> > Can qusb be used with HVM guests with libxl/xl?
> 
> Yes. You have to specify "type=qusb" for usbctrl, then it will work.
> I have verified that.

Good, thanks.

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

* Re: [PATCH] xen: use a common function for pv and hvm guest backend register calls
@ 2016-08-03 17:50       ` Stefano Stabellini
  0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2016-08-03 17:50 UTC (permalink / raw)
  To: Juergen Gross
  Cc: xen-devel, anthony.perard, Stefano Stabellini, qemu-devel, kraxel

On Wed, 3 Aug 2016, Juergen Gross wrote:
> On 02/08/16 20:27, Stefano Stabellini wrote:
> > On Tue, 2 Aug 2016, Juergen Gross wrote:
> >> Instead of calling xen_be_register() for each supported backend type
> >> for hvm and pv guests in their machine init functions use a common
> >> function in order not to have to add new backends twice.
> >>
> >> This at once fixes the error that hvm domains couldn't use the qusb
> >> backend.
> >>
> >> Signed-off-by: Juergen Gross <jgross@suse.com>
> >> ---
> >> Is it on purpose the qnic and vfb backends are not registered for HVM?
> > 
> > Yes, it is on purpose: there is no code in any toolstacks to use qnic,
> > and the presence of vfb can cause problems to Linux HVM guests (or at
> > least it used to), additionally vfb for HVM guests is also disabled in
> > libxl.
> > 
> > In general, it is a good idea to disable code that is not supposed to be
> > used.
> > 
> > Can qusb be used with HVM guests with libxl/xl?
> 
> Yes. You have to specify "type=qusb" for usbctrl, then it will work.
> I have verified that.

Good, thanks.

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

end of thread, other threads:[~2016-08-03 17:50 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-02  6:32 [Qemu-devel] [PATCH] xen: use a common function for pv and hvm guest backend register calls Juergen Gross
2016-08-02  6:32 ` Juergen Gross
2016-08-02 11:40 ` [Qemu-devel] " Gerd Hoffmann
2016-08-02 11:40   ` Gerd Hoffmann
2016-08-02 18:32   ` [Qemu-devel] " Stefano Stabellini
2016-08-02 18:32     ` Stefano Stabellini
2016-08-02 17:43 ` [Qemu-devel] " Anthony PERARD
2016-08-02 17:43   ` Anthony PERARD
2016-08-02 18:27 ` [Qemu-devel] " Stefano Stabellini
2016-08-02 18:27   ` Stefano Stabellini
2016-08-03  3:56   ` [Qemu-devel] " Juergen Gross
2016-08-03  3:56     ` Juergen Gross
2016-08-03 17:50     ` [Qemu-devel] " Stefano Stabellini
2016-08-03 17:50       ` Stefano Stabellini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.