* [Qemu-devel] [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version
@ 2010-02-15 15:13 Amit Shah
2010-02-15 15:13 ` [Qemu-devel] [PATCH v2 2/3] pc: Add backward compatibility options for virtio-serial Amit Shah
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Amit Shah @ 2010-02-15 15:13 UTC (permalink / raw)
To: qemu-devel; +Cc: Amit Shah, kraxel
The version 0.13 will be the new default and compatibility options will
be added to the 0.12 version.
Signed-off-by: Amit Shah <amit.shah@redhat.com>
---
v2: register the 0.12 version in this patch instead of the next one.
hw/pc.c | 10 +++++++++-
1 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/hw/pc.c b/hw/pc.c
index 6fbe98b..c27ad0f 100644
--- a/hw/pc.c
+++ b/hw/pc.c
@@ -1052,7 +1052,7 @@ void cmos_set_s3_resume(void)
}
static QEMUMachine pc_machine = {
- .name = "pc-0.12",
+ .name = "pc-0.13",
.alias = "pc",
.desc = "Standard PC",
.init = pc_init_pci,
@@ -1060,6 +1060,13 @@ static QEMUMachine pc_machine = {
.is_default = 1,
};
+static QEMUMachine pc_machine_v0_12 = {
+ .name = "pc-0.12",
+ .desc = "Standard PC",
+ .init = pc_init_pci,
+ .max_cpus = 255,
+};
+
static QEMUMachine pc_machine_v0_11 = {
.name = "pc-0.11",
.desc = "Standard PC, qemu 0.11",
@@ -1136,6 +1143,7 @@ static QEMUMachine isapc_machine = {
static void pc_machine_init(void)
{
qemu_register_machine(&pc_machine);
+ qemu_register_machine(&pc_machine_v0_12);
qemu_register_machine(&pc_machine_v0_11);
qemu_register_machine(&pc_machine_v0_10);
qemu_register_machine(&isapc_machine);
--
1.6.2.5
^ permalink raw reply related [flat|nested] 5+ messages in thread* [Qemu-devel] [PATCH v2 2/3] pc: Add backward compatibility options for virtio-serial 2010-02-15 15:13 [Qemu-devel] [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version Amit Shah @ 2010-02-15 15:13 ` Amit Shah 2010-02-15 15:13 ` [Qemu-devel] [PATCH v2 3/3] virtio-serial: don't set MULTIPORT for 1 port dev Amit Shah 2010-02-15 15:24 ` [Qemu-devel] Re: [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version Gerd Hoffmann 2010-02-19 21:48 ` [Qemu-devel] " Anthony Liguori 2 siblings, 1 reply; 5+ messages in thread From: Amit Shah @ 2010-02-15 15:13 UTC (permalink / raw) To: qemu-devel; +Cc: Amit Shah, kraxel virtio-serial-pci can support multiple ports in the current development version that will become 0.13. Add compatibility options for the 0.12 and 0.11 pc machine types. Signed-off-by: Amit Shah <amit.shah@redhat.com> --- hw/pc.c | 28 ++++++++++++++++++++++++++++ 1 files changed, 28 insertions(+), 0 deletions(-) diff --git a/hw/pc.c b/hw/pc.c index c27ad0f..49a95ba 100644 --- a/hw/pc.c +++ b/hw/pc.c @@ -1065,6 +1065,18 @@ static QEMUMachine pc_machine_v0_12 = { .desc = "Standard PC", .init = pc_init_pci, .max_cpus = 255, + .compat_props = (GlobalProperty[]) { + { + .driver = "virtio-serial-pci", + .property = "max_nr_ports", + .value = stringify(1), + },{ + .driver = "virtio-serial-pci", + .property = "vectors", + .value = stringify(0), + }, + { /* end of list */ } + } }; static QEMUMachine pc_machine_v0_11 = { @@ -1078,6 +1090,14 @@ static QEMUMachine pc_machine_v0_11 = { .property = "vectors", .value = stringify(0), },{ + .driver = "virtio-serial-pci", + .property = "max_nr_ports", + .value = stringify(1), + },{ + .driver = "virtio-serial-pci", + .property = "vectors", + .value = stringify(0), + },{ .driver = "ide-drive", .property = "ver", .value = "0.11", @@ -1109,6 +1129,14 @@ static QEMUMachine pc_machine_v0_10 = { .property = "class", .value = stringify(PCI_CLASS_DISPLAY_OTHER), },{ + .driver = "virtio-serial-pci", + .property = "max_nr_ports", + .value = stringify(1), + },{ + .driver = "virtio-serial-pci", + .property = "vectors", + .value = stringify(0), + },{ .driver = "virtio-net-pci", .property = "vectors", .value = stringify(0), -- 1.6.2.5 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Qemu-devel] [PATCH v2 3/3] virtio-serial: don't set MULTIPORT for 1 port dev 2010-02-15 15:13 ` [Qemu-devel] [PATCH v2 2/3] pc: Add backward compatibility options for virtio-serial Amit Shah @ 2010-02-15 15:13 ` Amit Shah 0 siblings, 0 replies; 5+ messages in thread From: Amit Shah @ 2010-02-15 15:13 UTC (permalink / raw) To: qemu-devel; +Cc: Amit Shah, kraxel, Michael S. Tsirkin From: Michael S. Tsirkin <mst@redhat.com> Since commit 98b19252cf1bd97c54bc4613f3537c5ec0aae263, all serial devices declare MULTIPORT feature. To allow 0.12 compatibility, we should clear this when max_nr_ports is 1. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Amit Shah <amit.shah@redhat.com> --- hw/virtio-serial-bus.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hw/virtio-serial-bus.c b/hw/virtio-serial-bus.c index ab456ea..d0e0219 100644 --- a/hw/virtio-serial-bus.c +++ b/hw/virtio-serial-bus.c @@ -335,8 +335,10 @@ static void handle_input(VirtIODevice *vdev, VirtQueue *vq) static uint32_t get_features(VirtIODevice *vdev, uint32_t features) { - features |= (1 << VIRTIO_CONSOLE_F_MULTIPORT); - + VirtIOSerial *vser = DO_UPCAST(VirtIOSerial, vdev, vdev); + if (vser->bus->max_nr_ports > 1) { + features |= (1 << VIRTIO_CONSOLE_F_MULTIPORT); + } return features; } -- 1.6.2.5 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Qemu-devel] Re: [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version 2010-02-15 15:13 [Qemu-devel] [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version Amit Shah 2010-02-15 15:13 ` [Qemu-devel] [PATCH v2 2/3] pc: Add backward compatibility options for virtio-serial Amit Shah @ 2010-02-15 15:24 ` Gerd Hoffmann 2010-02-19 21:48 ` [Qemu-devel] " Anthony Liguori 2 siblings, 0 replies; 5+ messages in thread From: Gerd Hoffmann @ 2010-02-15 15:24 UTC (permalink / raw) To: Amit Shah; +Cc: qemu-devel On 02/15/10 16:13, Amit Shah wrote: > The version 0.13 will be the new default and compatibility options will > be added to the 0.12 version. Whole series looks good now. Acked-by: Gerd Hoffmann <kraxel@redhat.com> cheers, Gerd ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version 2010-02-15 15:13 [Qemu-devel] [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version Amit Shah 2010-02-15 15:13 ` [Qemu-devel] [PATCH v2 2/3] pc: Add backward compatibility options for virtio-serial Amit Shah 2010-02-15 15:24 ` [Qemu-devel] Re: [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version Gerd Hoffmann @ 2010-02-19 21:48 ` Anthony Liguori 2 siblings, 0 replies; 5+ messages in thread From: Anthony Liguori @ 2010-02-19 21:48 UTC (permalink / raw) To: Amit Shah; +Cc: qemu-devel, kraxel On 02/15/2010 09:13 AM, Amit Shah wrote: > The version 0.13 will be the new default and compatibility options will > be added to the 0.12 version. > > Signed-off-by: Amit Shah<amit.shah@redhat.com> > Applied. Thanks. Regards, Anthony Liguori > --- > v2: register the 0.12 version in this patch instead of the next one. > > hw/pc.c | 10 +++++++++- > 1 files changed, 9 insertions(+), 1 deletions(-) > > diff --git a/hw/pc.c b/hw/pc.c > index 6fbe98b..c27ad0f 100644 > --- a/hw/pc.c > +++ b/hw/pc.c > @@ -1052,7 +1052,7 @@ void cmos_set_s3_resume(void) > } > > static QEMUMachine pc_machine = { > - .name = "pc-0.12", > + .name = "pc-0.13", > .alias = "pc", > .desc = "Standard PC", > .init = pc_init_pci, > @@ -1060,6 +1060,13 @@ static QEMUMachine pc_machine = { > .is_default = 1, > }; > > +static QEMUMachine pc_machine_v0_12 = { > + .name = "pc-0.12", > + .desc = "Standard PC", > + .init = pc_init_pci, > + .max_cpus = 255, > +}; > + > static QEMUMachine pc_machine_v0_11 = { > .name = "pc-0.11", > .desc = "Standard PC, qemu 0.11", > @@ -1136,6 +1143,7 @@ static QEMUMachine isapc_machine = { > static void pc_machine_init(void) > { > qemu_register_machine(&pc_machine); > + qemu_register_machine(&pc_machine_v0_12); > qemu_register_machine(&pc_machine_v0_11); > qemu_register_machine(&pc_machine_v0_10); > qemu_register_machine(&isapc_machine); > ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-02-19 21:48 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2010-02-15 15:13 [Qemu-devel] [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version Amit Shah 2010-02-15 15:13 ` [Qemu-devel] [PATCH v2 2/3] pc: Add backward compatibility options for virtio-serial Amit Shah 2010-02-15 15:13 ` [Qemu-devel] [PATCH v2 3/3] virtio-serial: don't set MULTIPORT for 1 port dev Amit Shah 2010-02-15 15:24 ` [Qemu-devel] Re: [PATCH v2 1/3] pc: Bump up pc version to 0.13 and add a 0.12 compat version Gerd Hoffmann 2010-02-19 21:48 ` [Qemu-devel] " Anthony Liguori
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.