* [Qemu-devel] [PATCH 0/3] Xen related fixes
@ 2013-05-27 18:13 ` Stefano Stabellini
0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, Anthony Perard,
Paolo Bonzini, afaerber
Hi all,
I have few simple fixes for Xen for the next release:
- the first one fixes a regression in qemu-char;
- the second one is just a cleanup (that is needed to simplify preprocessor
dependencies);
- the last one avoids setting nonblocking on Xen (as is already done for
KVM).
The last two patches should be backported to older branches.
Stefano Stabellini (3):
qemu_chr_new_from_opts: do not overwrite existing chr->filename
xen: simplify xen_enabled
main_loop: do not set nonblocking if xen_enabled()
include/hw/xen/xen.h | 4 ----
qemu-char.c | 5 +++--
vl.c | 2 +-
3 files changed, 4 insertions(+), 7 deletions(-)
- Stefano
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 0/3] Xen related fixes
@ 2013-05-27 18:13 ` Stefano Stabellini
0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, Anthony Perard,
Paolo Bonzini, afaerber
Hi all,
I have few simple fixes for Xen for the next release:
- the first one fixes a regression in qemu-char;
- the second one is just a cleanup (that is needed to simplify preprocessor
dependencies);
- the last one avoids setting nonblocking on Xen (as is already done for
KVM).
The last two patches should be backported to older branches.
Stefano Stabellini (3):
qemu_chr_new_from_opts: do not overwrite existing chr->filename
xen: simplify xen_enabled
main_loop: do not set nonblocking if xen_enabled()
include/hw/xen/xen.h | 4 ----
qemu-char.c | 5 +++--
vl.c | 2 +-
3 files changed, 4 insertions(+), 7 deletions(-)
- Stefano
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Qemu-devel] [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
2013-05-27 18:13 ` Stefano Stabellini
@ 2013-05-27 18:13 ` Stefano Stabellini
-1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, anthony.perard,
pbonzini, afaerber
Set the new filename only if it hasn't been already set (for example by
qemu_chr_open_pty).
This fixes a regression that prevents Xen HVM domains from booting.
It was introduced by:
commit 2b220025993e76d4116781ca91a4fabc5ad9c722
Author: Lei Li <lilei@linux.vnet.ibm.com>
Date: Tue May 21 18:27:59 2013 +0800
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
---
qemu-char.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/qemu-char.c b/qemu-char.c
index 4f8382e..06ffd93 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -3276,7 +3276,6 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
ChardevReturn *ret = NULL;
const char *id = qemu_opts_id(opts);
const char *bid = NULL;
- char *filename = g_strdup(qemu_opt_get(opts, "backend"));
if (qemu_opt_get_bool(opts, "mux", 0)) {
bid = g_strdup_printf("%s-base", id);
@@ -3309,7 +3308,9 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
}
chr = qemu_chr_find(id);
- chr->filename = filename;
+ if (!chr->filename) {
+ chr->filename = g_strdup(qemu_opt_get(opts, "backend"));
+ }
qapi_out:
qapi_free_ChardevBackend(backend);
--
1.7.2.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
@ 2013-05-27 18:13 ` Stefano Stabellini
0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, anthony.perard,
pbonzini, afaerber
Set the new filename only if it hasn't been already set (for example by
qemu_chr_open_pty).
This fixes a regression that prevents Xen HVM domains from booting.
It was introduced by:
commit 2b220025993e76d4116781ca91a4fabc5ad9c722
Author: Lei Li <lilei@linux.vnet.ibm.com>
Date: Tue May 21 18:27:59 2013 +0800
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
---
qemu-char.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/qemu-char.c b/qemu-char.c
index 4f8382e..06ffd93 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -3276,7 +3276,6 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
ChardevReturn *ret = NULL;
const char *id = qemu_opts_id(opts);
const char *bid = NULL;
- char *filename = g_strdup(qemu_opt_get(opts, "backend"));
if (qemu_opt_get_bool(opts, "mux", 0)) {
bid = g_strdup_printf("%s-base", id);
@@ -3309,7 +3308,9 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
}
chr = qemu_chr_find(id);
- chr->filename = filename;
+ if (!chr->filename) {
+ chr->filename = g_strdup(qemu_opt_get(opts, "backend"));
+ }
qapi_out:
qapi_free_ChardevBackend(backend);
--
1.7.2.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [Qemu-devel] [PATCH 2/3] xen: simplify xen_enabled
2013-05-27 18:13 ` Stefano Stabellini
@ 2013-05-27 18:13 ` Stefano Stabellini
-1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, qemu-stable,
anthony.perard, pbonzini, afaerber
No need for preprocessor conditionals in xen_enabled: xen_allowed is
always defined.
Please backport this patch to stable branches (it is needed by the
following patch to remove the dependency on a preprocessor identifier
defined by config-target.h).
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
CC: qemu-stable@nongnu.org
---
include/hw/xen/xen.h | 4 ----
1 files changed, 0 insertions(+), 4 deletions(-)
diff --git a/include/hw/xen/xen.h b/include/hw/xen/xen.h
index 7451c5a..b42b0fd 100644
--- a/include/hw/xen/xen.h
+++ b/include/hw/xen/xen.h
@@ -25,11 +25,7 @@ extern bool xen_allowed;
static inline bool xen_enabled(void)
{
-#if defined(CONFIG_XEN_BACKEND) && defined(CONFIG_XEN)
return xen_allowed;
-#else
- return 0;
-#endif
}
int xen_pci_slot_get_pirq(PCIDevice *pci_dev, int irq_num);
--
1.7.2.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 2/3] xen: simplify xen_enabled
@ 2013-05-27 18:13 ` Stefano Stabellini
0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, qemu-stable,
anthony.perard, pbonzini, afaerber
No need for preprocessor conditionals in xen_enabled: xen_allowed is
always defined.
Please backport this patch to stable branches (it is needed by the
following patch to remove the dependency on a preprocessor identifier
defined by config-target.h).
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
CC: qemu-stable@nongnu.org
---
include/hw/xen/xen.h | 4 ----
1 files changed, 0 insertions(+), 4 deletions(-)
diff --git a/include/hw/xen/xen.h b/include/hw/xen/xen.h
index 7451c5a..b42b0fd 100644
--- a/include/hw/xen/xen.h
+++ b/include/hw/xen/xen.h
@@ -25,11 +25,7 @@ extern bool xen_allowed;
static inline bool xen_enabled(void)
{
-#if defined(CONFIG_XEN_BACKEND) && defined(CONFIG_XEN)
return xen_allowed;
-#else
- return 0;
-#endif
}
int xen_pci_slot_get_pirq(PCIDevice *pci_dev, int irq_num);
--
1.7.2.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [Qemu-devel] [PATCH 3/3] main_loop: do not set nonblocking if xen_enabled()
2013-05-27 18:13 ` Stefano Stabellini
@ 2013-05-27 18:13 ` Stefano Stabellini
-1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, qemu-stable,
anthony.perard, pbonzini, afaerber
Please backport this patch to stable branches.
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
CC: qemu-stable@nongnu.org
---
vl.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/vl.c b/vl.c
index 510d2c2..47ab45d 100644
--- a/vl.c
+++ b/vl.c
@@ -2022,7 +2022,7 @@ static void main_loop(void)
int64_t ti;
#endif
do {
- nonblocking = !kvm_enabled() && last_io > 0;
+ nonblocking = !kvm_enabled() && !xen_enabled() && last_io > 0;
#ifdef CONFIG_PROFILER
ti = profile_getclock();
#endif
--
1.7.2.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 3/3] main_loop: do not set nonblocking if xen_enabled()
@ 2013-05-27 18:13 ` Stefano Stabellini
0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-27 18:13 UTC (permalink / raw)
To: qemu-devel
Cc: aliguori, xen-devel, Stefano Stabellini, qemu-stable,
anthony.perard, pbonzini, afaerber
Please backport this patch to stable branches.
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
CC: qemu-stable@nongnu.org
---
vl.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/vl.c b/vl.c
index 510d2c2..47ab45d 100644
--- a/vl.c
+++ b/vl.c
@@ -2022,7 +2022,7 @@ static void main_loop(void)
int64_t ti;
#endif
do {
- nonblocking = !kvm_enabled() && last_io > 0;
+ nonblocking = !kvm_enabled() && !xen_enabled() && last_io > 0;
#ifdef CONFIG_PROFILER
ti = profile_getclock();
#endif
--
1.7.2.5
^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: [Qemu-devel] [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
2013-05-27 18:13 ` Stefano Stabellini
@ 2013-05-28 6:37 ` Gerd Hoffmann
-1 siblings, 0 replies; 14+ messages in thread
From: Gerd Hoffmann @ 2013-05-28 6:37 UTC (permalink / raw)
To: Stefano Stabellini
Cc: aliguori, xen-devel, qemu-devel, anthony.perard, pbonzini, afaerber
On 05/27/13 20:13, Stefano Stabellini wrote:
> Set the new filename only if it hasn't been already set (for example by
> qemu_chr_open_pty).
>
> This fixes a regression that prevents Xen HVM domains from booting.
> It was introduced by:
>
> commit 2b220025993e76d4116781ca91a4fabc5ad9c722
> Author: Lei Li <lilei@linux.vnet.ibm.com>
> Date: Tue May 21 18:27:59 2013 +0800
FYI: just posted a pull req which reverts this one (you are cc'ed).
cheers,
Gerd
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
@ 2013-05-28 6:37 ` Gerd Hoffmann
0 siblings, 0 replies; 14+ messages in thread
From: Gerd Hoffmann @ 2013-05-28 6:37 UTC (permalink / raw)
To: Stefano Stabellini
Cc: aliguori, xen-devel, qemu-devel, anthony.perard, pbonzini, afaerber
On 05/27/13 20:13, Stefano Stabellini wrote:
> Set the new filename only if it hasn't been already set (for example by
> qemu_chr_open_pty).
>
> This fixes a regression that prevents Xen HVM domains from booting.
> It was introduced by:
>
> commit 2b220025993e76d4116781ca91a4fabc5ad9c722
> Author: Lei Li <lilei@linux.vnet.ibm.com>
> Date: Tue May 21 18:27:59 2013 +0800
FYI: just posted a pull req which reverts this one (you are cc'ed).
cheers,
Gerd
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [Qemu-devel] [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
2013-05-28 6:37 ` Gerd Hoffmann
@ 2013-05-28 10:43 ` Stefano Stabellini
-1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-28 10:43 UTC (permalink / raw)
To: Gerd Hoffmann
Cc: aliguori, xen-devel, Stefano Stabellini, qemu-devel,
anthony.perard, pbonzini, afaerber
On Tue, 28 May 2013, Gerd Hoffmann wrote:
> On 05/27/13 20:13, Stefano Stabellini wrote:
> > Set the new filename only if it hasn't been already set (for example by
> > qemu_chr_open_pty).
> >
> > This fixes a regression that prevents Xen HVM domains from booting.
> > It was introduced by:
> >
> > commit 2b220025993e76d4116781ca91a4fabc5ad9c722
> > Author: Lei Li <lilei@linux.vnet.ibm.com>
> > Date: Tue May 21 18:27:59 2013 +0800
>
> FYI: just posted a pull req which reverts this one (you are cc'ed).
Right, your two patches also solve the problem I was seeing.
I'll drop the first patch of my series.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
@ 2013-05-28 10:43 ` Stefano Stabellini
0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-28 10:43 UTC (permalink / raw)
To: Gerd Hoffmann
Cc: aliguori, xen-devel, Stefano Stabellini, qemu-devel,
anthony.perard, pbonzini, afaerber
On Tue, 28 May 2013, Gerd Hoffmann wrote:
> On 05/27/13 20:13, Stefano Stabellini wrote:
> > Set the new filename only if it hasn't been already set (for example by
> > qemu_chr_open_pty).
> >
> > This fixes a regression that prevents Xen HVM domains from booting.
> > It was introduced by:
> >
> > commit 2b220025993e76d4116781ca91a4fabc5ad9c722
> > Author: Lei Li <lilei@linux.vnet.ibm.com>
> > Date: Tue May 21 18:27:59 2013 +0800
>
> FYI: just posted a pull req which reverts this one (you are cc'ed).
Right, your two patches also solve the problem I was seeing.
I'll drop the first patch of my series.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [Qemu-devel] [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
2013-05-27 18:13 ` Stefano Stabellini
@ 2013-05-28 10:44 ` Stefano Stabellini
-1 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-28 10:44 UTC (permalink / raw)
To: Stefano Stabellini
Cc: aliguori, xen-devel, qemu-devel, anthony.perard, pbonzini, afaerber
On Mon, 27 May 2013, Stefano Stabellini wrote:
> Set the new filename only if it hasn't been already set (for example by
> qemu_chr_open_pty).
>
> This fixes a regression that prevents Xen HVM domains from booting.
> It was introduced by:
>
> commit 2b220025993e76d4116781ca91a4fabc5ad9c722
> Author: Lei Li <lilei@linux.vnet.ibm.com>
> Date: Tue May 21 18:27:59 2013 +0800
>
> Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Gerd submitted an alternative fix to this issue here:
http://marc.info/?l=qemu-devel&m=136972286727453
I'll drop this patch.
> qemu-char.c | 5 +++--
> 1 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/qemu-char.c b/qemu-char.c
> index 4f8382e..06ffd93 100644
> --- a/qemu-char.c
> +++ b/qemu-char.c
> @@ -3276,7 +3276,6 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
> ChardevReturn *ret = NULL;
> const char *id = qemu_opts_id(opts);
> const char *bid = NULL;
> - char *filename = g_strdup(qemu_opt_get(opts, "backend"));
>
> if (qemu_opt_get_bool(opts, "mux", 0)) {
> bid = g_strdup_printf("%s-base", id);
> @@ -3309,7 +3308,9 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
> }
>
> chr = qemu_chr_find(id);
> - chr->filename = filename;
> + if (!chr->filename) {
> + chr->filename = g_strdup(qemu_opt_get(opts, "backend"));
> + }
>
> qapi_out:
> qapi_free_ChardevBackend(backend);
> --
> 1.7.2.5
>
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename
@ 2013-05-28 10:44 ` Stefano Stabellini
0 siblings, 0 replies; 14+ messages in thread
From: Stefano Stabellini @ 2013-05-28 10:44 UTC (permalink / raw)
To: Stefano Stabellini
Cc: aliguori, xen-devel, qemu-devel, anthony.perard, pbonzini, afaerber
On Mon, 27 May 2013, Stefano Stabellini wrote:
> Set the new filename only if it hasn't been already set (for example by
> qemu_chr_open_pty).
>
> This fixes a regression that prevents Xen HVM domains from booting.
> It was introduced by:
>
> commit 2b220025993e76d4116781ca91a4fabc5ad9c722
> Author: Lei Li <lilei@linux.vnet.ibm.com>
> Date: Tue May 21 18:27:59 2013 +0800
>
> Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Gerd submitted an alternative fix to this issue here:
http://marc.info/?l=qemu-devel&m=136972286727453
I'll drop this patch.
> qemu-char.c | 5 +++--
> 1 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/qemu-char.c b/qemu-char.c
> index 4f8382e..06ffd93 100644
> --- a/qemu-char.c
> +++ b/qemu-char.c
> @@ -3276,7 +3276,6 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
> ChardevReturn *ret = NULL;
> const char *id = qemu_opts_id(opts);
> const char *bid = NULL;
> - char *filename = g_strdup(qemu_opt_get(opts, "backend"));
>
> if (qemu_opt_get_bool(opts, "mux", 0)) {
> bid = g_strdup_printf("%s-base", id);
> @@ -3309,7 +3308,9 @@ CharDriverState *qemu_chr_new_from_opts(QemuOpts *opts,
> }
>
> chr = qemu_chr_find(id);
> - chr->filename = filename;
> + if (!chr->filename) {
> + chr->filename = g_strdup(qemu_opt_get(opts, "backend"));
> + }
>
> qapi_out:
> qapi_free_ChardevBackend(backend);
> --
> 1.7.2.5
>
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2013-05-28 10:44 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-27 18:13 [Qemu-devel] [PATCH 0/3] Xen related fixes Stefano Stabellini
2013-05-27 18:13 ` Stefano Stabellini
2013-05-27 18:13 ` [Qemu-devel] [PATCH 1/3] qemu_chr_new_from_opts: do not overwrite existing chr->filename Stefano Stabellini
2013-05-27 18:13 ` Stefano Stabellini
2013-05-28 6:37 ` [Qemu-devel] " Gerd Hoffmann
2013-05-28 6:37 ` Gerd Hoffmann
2013-05-28 10:43 ` [Qemu-devel] " Stefano Stabellini
2013-05-28 10:43 ` Stefano Stabellini
2013-05-28 10:44 ` [Qemu-devel] " Stefano Stabellini
2013-05-28 10:44 ` Stefano Stabellini
2013-05-27 18:13 ` [Qemu-devel] [PATCH 2/3] xen: simplify xen_enabled Stefano Stabellini
2013-05-27 18:13 ` Stefano Stabellini
2013-05-27 18:13 ` [Qemu-devel] [PATCH 3/3] main_loop: do not set nonblocking if xen_enabled() Stefano Stabellini
2013-05-27 18:13 ` 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.