qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 0/2] msi support for virtfs
@ 2010-11-11 11:59 Gerd Hoffmann
  2010-11-11 11:59 ` [Qemu-devel] [PATCH 1/2] pc: add 0.13 pc machine type Gerd Hoffmann
                   ` (5 more replies)
  0 siblings, 6 replies; 8+ messages in thread
From: Gerd Hoffmann @ 2010-11-11 11:59 UTC (permalink / raw)
  To: qemu-devel; +Cc: Gerd Hoffmann

  Hi,

This tiny patch series adds msi support for virtfs.  It's two patches
only because we need a compat property to stay compatible with -stable
and we don't have a pc-0.14 machine type yet, so this is added first.

please apply,
  Gerd

Gerd Hoffmann (2):
  pc: add 0.13 pc machine type
  virtfs: enable MSI-X

 hw/pc_piix.c    |   18 +++++++++++++++++-
 hw/virtio-pci.c |    5 ++++-
 2 files changed, 21 insertions(+), 2 deletions(-)

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

* [Qemu-devel] [PATCH 1/2] pc: add 0.13 pc machine type
  2010-11-11 11:59 [Qemu-devel] [PATCH 0/2] msi support for virtfs Gerd Hoffmann
@ 2010-11-11 11:59 ` Gerd Hoffmann
  2010-11-11 11:59 ` [Qemu-devel] [PATCH 2/2] virtfs: enable MSI-X Gerd Hoffmann
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Gerd Hoffmann @ 2010-11-11 11:59 UTC (permalink / raw)
  To: qemu-devel; +Cc: Gerd Hoffmann

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 hw/pc_piix.c |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/hw/pc_piix.c b/hw/pc_piix.c
index e82bfd1..af01cfb 100644
--- a/hw/pc_piix.c
+++ b/hw/pc_piix.c
@@ -213,7 +213,7 @@ static void pc_init_isa(ram_addr_t ram_size,
 }
 
 static QEMUMachine pc_machine = {
-    .name = "pc-0.13",
+    .name = "pc-0.14",
     .alias = "pc",
     .desc = "Standard PC",
     .init = pc_init_pci,
@@ -221,6 +221,13 @@ static QEMUMachine pc_machine = {
     .is_default = 1,
 };
 
+static QEMUMachine pc_machine_v0_13 = {
+    .name = "pc-0.13",
+    .desc = "Standard PC",
+    .init = pc_init_pci,
+    .max_cpus = 255,
+};
+
 static QEMUMachine pc_machine_v0_12 = {
     .name = "pc-0.12",
     .desc = "Standard PC",
@@ -386,6 +393,7 @@ static QEMUMachine pc_machine_rhel600 = {
 static void pc_machine_init(void)
 {
     qemu_register_machine(&pc_machine);
+    qemu_register_machine(&pc_machine_v0_13);
     qemu_register_machine(&pc_machine_v0_12);
     qemu_register_machine(&pc_machine_v0_11);
     qemu_register_machine(&pc_machine_v0_10);
-- 
1.7.1

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

* [Qemu-devel] [PATCH 2/2] virtfs: enable MSI-X
  2010-11-11 11:59 [Qemu-devel] [PATCH 0/2] msi support for virtfs Gerd Hoffmann
  2010-11-11 11:59 ` [Qemu-devel] [PATCH 1/2] pc: add 0.13 pc machine type Gerd Hoffmann
@ 2010-11-11 11:59 ` Gerd Hoffmann
  2010-11-11 15:36 ` [Qemu-devel] [PATCH 0/2] msi support for virtfs Aneesh Kumar K. V
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Gerd Hoffmann @ 2010-11-11 11:59 UTC (permalink / raw)
  To: qemu-devel; +Cc: Gerd Hoffmann

This patch enables MSI-X for virtfs-9p-pci.  It also adds a
compat property to pc-0.13 which turns it of there to stay
compatible to 0.13-stable.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 hw/pc_piix.c    |    8 ++++++++
 hw/virtio-pci.c |    5 ++++-
 2 files changed, 12 insertions(+), 1 deletions(-)

diff --git a/hw/pc_piix.c b/hw/pc_piix.c
index af01cfb..e9752db 100644
--- a/hw/pc_piix.c
+++ b/hw/pc_piix.c
@@ -226,6 +226,14 @@ static QEMUMachine pc_machine_v0_13 = {
     .desc = "Standard PC",
     .init = pc_init_pci,
     .max_cpus = 255,
+    .compat_props = (GlobalProperty[]) {
+        {
+            .driver   = "virtio-9p-pci",
+            .property = "vectors",
+            .value    = stringify(0),
+        },
+        { /* end of list */ }
+    },
 };
 
 static QEMUMachine pc_machine_v0_12 = {
diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c
index 729917d..3610d7e 100644
--- a/hw/virtio-pci.c
+++ b/hw/virtio-pci.c
@@ -684,12 +684,14 @@ static int virtio_9p_init_pci(PCIDevice *pci_dev)
     VirtIODevice *vdev;
 
     vdev = virtio_9p_init(&pci_dev->qdev, &proxy->fsconf);
+    vdev->nvectors = proxy->nvectors;
     virtio_init_pci(proxy, vdev,
                     PCI_VENDOR_ID_REDHAT_QUMRANET,
                     0x1009,
                     0x2,
                     0x00);
-
+    /* make the actual value visible */
+    proxy->nvectors = vdev->nvectors;
     return 0;
 }
 #endif
@@ -758,6 +760,7 @@ static PCIDeviceInfo virtio_info[] = {
         .qdev.size = sizeof(VirtIOPCIProxy),
         .init      = virtio_9p_init_pci,
         .qdev.props = (Property[]) {
+            DEFINE_PROP_UINT32("vectors", VirtIOPCIProxy, nvectors, 2),
             DEFINE_VIRTIO_COMMON_FEATURES(VirtIOPCIProxy, host_features),
             DEFINE_PROP_STRING("mount_tag", VirtIOPCIProxy, fsconf.tag),
             DEFINE_PROP_STRING("fsdev", VirtIOPCIProxy, fsconf.fsdev_id),
-- 
1.7.1

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

* Re: [Qemu-devel] [PATCH 0/2] msi support for virtfs
  2010-11-11 11:59 [Qemu-devel] [PATCH 0/2] msi support for virtfs Gerd Hoffmann
  2010-11-11 11:59 ` [Qemu-devel] [PATCH 1/2] pc: add 0.13 pc machine type Gerd Hoffmann
  2010-11-11 11:59 ` [Qemu-devel] [PATCH 2/2] virtfs: enable MSI-X Gerd Hoffmann
@ 2010-11-11 15:36 ` Aneesh Kumar K. V
  2010-11-11 15:37 ` Aneesh Kumar K. V
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Aneesh Kumar K. V @ 2010-11-11 15:36 UTC (permalink / raw)
  To: Gerd Hoffmann, qemu-devel

On Thu, 11 Nov 2010 12:59:24 +0100, Gerd Hoffmann <kraxel@redhat.com> wrote:
>   Hi,
> 
> This tiny patch series adds msi support for virtfs.  It's two patches
> only because we need a compat property to stay compatible with -stable
> and we don't have a pc-0.14 machine type yet, so this is added first.
> 

Sorry for being dump. But what does the above change help to achieve.

-aneesh

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

* Re: [Qemu-devel] [PATCH 0/2] msi support for virtfs
  2010-11-11 11:59 [Qemu-devel] [PATCH 0/2] msi support for virtfs Gerd Hoffmann
                   ` (2 preceding siblings ...)
  2010-11-11 15:36 ` [Qemu-devel] [PATCH 0/2] msi support for virtfs Aneesh Kumar K. V
@ 2010-11-11 15:37 ` Aneesh Kumar K. V
  2010-11-11 18:47   ` Gerd Hoffmann
  2010-11-16 17:56 ` [Qemu-devel] " Michael S. Tsirkin
  2010-11-21 15:19 ` [Qemu-devel] " Anthony Liguori
  5 siblings, 1 reply; 8+ messages in thread
From: Aneesh Kumar K. V @ 2010-11-11 15:37 UTC (permalink / raw)
  To: Gerd Hoffmann, qemu-devel

On Thu, 11 Nov 2010 12:59:24 +0100, Gerd Hoffmann <kraxel@redhat.com> wrote:
>   Hi,
> 
> This tiny patch series adds msi support for virtfs.  It's two patches
> only because we need a compat property to stay compatible with -stable
> and we don't have a pc-0.14 machine type yet, so this is added first.
> 

Sorry for being dumb. But what does the above change help to achieve.

-aneesh

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

* Re: [Qemu-devel] [PATCH 0/2] msi support for virtfs
  2010-11-11 15:37 ` Aneesh Kumar K. V
@ 2010-11-11 18:47   ` Gerd Hoffmann
  0 siblings, 0 replies; 8+ messages in thread
From: Gerd Hoffmann @ 2010-11-11 18:47 UTC (permalink / raw)
  To: Aneesh Kumar K. V; +Cc: qemu-devel

On 11/11/10 16:37, Aneesh Kumar K. V wrote:
> On Thu, 11 Nov 2010 12:59:24 +0100, Gerd Hoffmann<kraxel@redhat.com>  wrote:
>>    Hi,
>>
>> This tiny patch series adds msi support for virtfs.  It's two patches
>> only because we need a compat property to stay compatible with -stable
>> and we don't have a pc-0.14 machine type yet, so this is added first.
>>
>
> Sorry for being dumb. But what does the above change help to achieve.

msi support makes the IRQ handling more efficient (no IRQ sharing, no 
need to ack the IRQ to the ioapic).  Look at /proc/interupts with and 
without the patch ...

The compat property is for migration compatibility:  qemu 0.14 should be 
able to migrate to 0.13 with -M pc-0.13.  To archive that we have to 
disable new stuff which affects the savevm format (msi support does).

HTH
   Gerd

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

* [Qemu-devel] Re: [PATCH 0/2] msi support for virtfs
  2010-11-11 11:59 [Qemu-devel] [PATCH 0/2] msi support for virtfs Gerd Hoffmann
                   ` (3 preceding siblings ...)
  2010-11-11 15:37 ` Aneesh Kumar K. V
@ 2010-11-16 17:56 ` Michael S. Tsirkin
  2010-11-21 15:19 ` [Qemu-devel] " Anthony Liguori
  5 siblings, 0 replies; 8+ messages in thread
From: Michael S. Tsirkin @ 2010-11-16 17:56 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: qemu-devel

On Thu, Nov 11, 2010 at 12:59:24PM +0100, Gerd Hoffmann wrote:
>   Hi,
> 
> This tiny patch series adds msi support for virtfs.  It's two patches
> only because we need a compat property to stay compatible with -stable
> and we don't have a pc-0.14 machine type yet, so this is added first.

Scared me ... you really mean msix.

Acked-by: Michael S. Tsirkin <mst@redhat.com>

> please apply,
>   Gerd
> 
> Gerd Hoffmann (2):
>   pc: add 0.13 pc machine type
>   virtfs: enable MSI-X
> 
>  hw/pc_piix.c    |   18 +++++++++++++++++-
>  hw/virtio-pci.c |    5 ++++-
>  2 files changed, 21 insertions(+), 2 deletions(-)
> 

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

* Re: [Qemu-devel] [PATCH 0/2] msi support for virtfs
  2010-11-11 11:59 [Qemu-devel] [PATCH 0/2] msi support for virtfs Gerd Hoffmann
                   ` (4 preceding siblings ...)
  2010-11-16 17:56 ` [Qemu-devel] " Michael S. Tsirkin
@ 2010-11-21 15:19 ` Anthony Liguori
  5 siblings, 0 replies; 8+ messages in thread
From: Anthony Liguori @ 2010-11-21 15:19 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: qemu-devel

On 11/11/2010 05:59 AM, Gerd Hoffmann wrote:
>    Hi,
>
> This tiny patch series adds msi support for virtfs.  It's two patches
> only because we need a compat property to stay compatible with -stable
> and we don't have a pc-0.14 machine type yet, so this is added first.
>    

Applied all.  Thanks.

Regards,

Anthony Liguori

> please apply,
>    Gerd
>
> Gerd Hoffmann (2):
>    pc: add 0.13 pc machine type
>    virtfs: enable MSI-X
>
>   hw/pc_piix.c    |   18 +++++++++++++++++-
>   hw/virtio-pci.c |    5 ++++-
>   2 files changed, 21 insertions(+), 2 deletions(-)
>
>
>
>    

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

end of thread, other threads:[~2010-11-21 15:19 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-11 11:59 [Qemu-devel] [PATCH 0/2] msi support for virtfs Gerd Hoffmann
2010-11-11 11:59 ` [Qemu-devel] [PATCH 1/2] pc: add 0.13 pc machine type Gerd Hoffmann
2010-11-11 11:59 ` [Qemu-devel] [PATCH 2/2] virtfs: enable MSI-X Gerd Hoffmann
2010-11-11 15:36 ` [Qemu-devel] [PATCH 0/2] msi support for virtfs Aneesh Kumar K. V
2010-11-11 15:37 ` Aneesh Kumar K. V
2010-11-11 18:47   ` Gerd Hoffmann
2010-11-16 17:56 ` [Qemu-devel] " Michael S. Tsirkin
2010-11-21 15:19 ` [Qemu-devel] " Anthony Liguori

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