mbox

[PULL,v2,00/41] virtio,acpi: features, fixes, cleanups.

Message ID 20200704182750.1088103-1-mst@redhat.com
State New
Headers show

Pull-request

git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_upstream

Message

Michael S. Tsirkin July 4, 2020, 6:29 p.m. UTC
v2 of the pull, fixing non-Linux builds.


The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab:

  hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 21:16:10 +0100)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_upstream

for you to fetch changes up to f7d98068bf7a0913744dd4ac0a28e8c841df2af5:

  vhost-vdpa: introduce vhost-vdpa net client (2020-07-04 11:13:50 -0400)

----------------------------------------------------------------
virtio,acpi: features, fixes, cleanups.

vdpa support
virtio-mem support
a handy script for disassembling acpi tables
misc fixes and cleanups

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

----------------------------------------------------------------
Andrew Jones (1):
      tests/acpi: remove stale allowed tables

Cindy Lu (11):
      net: introduce qemu_get_peer
      vhost_net: use the function qemu_get_peer
      vhost: introduce new VhostOps vhost_dev_start
      vhost: implement vhost_dev_start method
      vhost: introduce new VhostOps vhost_vq_get_addr
      vhost: implement vhost_vq_get_addr method
      vhost: introduce new VhostOps vhost_force_iommu
      vhost: implement vhost_force_iommu method
      vhost_net: introduce set_config & get_config
      vhost-vdpa: introduce vhost-vdpa backend
      vhost-vdpa: introduce vhost-vdpa net client

David Hildenbrand (22):
      virtio-balloon: always indicate S_DONE when migration fails
      pc: Support coldplugging of virtio-pmem-pci devices on all buses
      exec: Introduce ram_block_discard_(disable|require)()
      vfio: Convert to ram_block_discard_disable()
      accel/kvm: Convert to ram_block_discard_disable()
      s390x/pv: Convert to ram_block_discard_disable()
      virtio-balloon: Rip out qemu_balloon_inhibit()
      target/i386: sev: Use ram_block_discard_disable()
      migration/rdma: Use ram_block_discard_disable()
      migration/colo: Use ram_block_discard_disable()
      virtio-mem: Paravirtualized memory hot(un)plug
      virtio-pci: Proxy for virtio-mem
      MAINTAINERS: Add myself as virtio-mem maintainer
      hmp: Handle virtio-mem when printing memory device info
      numa: Handle virtio-mem in NUMA stats
      pc: Support for virtio-mem-pci
      virtio-mem: Allow notifiers for size changes
      virtio-pci: Send qapi events when the virtio-mem size changes
      virtio-mem: Migration sanity checks
      virtio-mem: Add trace events
      virtio-mem: Exclude unplugged memory during migration
      numa: Auto-enable NUMA when any memory devices are possible

Jason Wang (3):
      virtio-bus: introduce queue_enabled method
      virtio-pci: implement queue_enabled method
      vhost: check the existence of vhost_set_iotlb_callback

Maxime Coquelin (1):
      docs: vhost-user: add Virtio status protocol feature

Michael S. Tsirkin (2):
      tests: disassemble-aml.sh: generate AML in readable format
      Revert "tests/migration: Reduce autoconverge initial bandwidth"

Peter Xu (1):
      MAINTAINERS: add VT-d entry

 configure                                   |  21 +
 qapi/misc.json                              |  64 +-
 qapi/net.json                               |  28 +-
 hw/virtio/virtio-mem-pci.h                  |  34 ++
 include/exec/memory.h                       |  41 ++
 include/hw/boards.h                         |   1 +
 include/hw/pci/pci.h                        |   1 +
 include/hw/vfio/vfio-common.h               |   4 +-
 include/hw/virtio/vhost-backend.h           |  19 +-
 include/hw/virtio/vhost-vdpa.h              |  26 +
 include/hw/virtio/vhost.h                   |   7 +
 include/hw/virtio/virtio-bus.h              |   4 +
 include/hw/virtio/virtio-mem.h              |  86 +++
 include/migration/colo.h                    |   2 +-
 include/migration/misc.h                    |   2 +
 include/net/net.h                           |   1 +
 include/net/vhost-vdpa.h                    |  22 +
 include/net/vhost_net.h                     |   5 +
 include/sysemu/balloon.h                    |   2 -
 net/clients.h                               |   2 +
 tests/qtest/bios-tables-test-allowed-diff.h |  18 -
 accel/kvm/kvm-all.c                         |   4 +-
 balloon.c                                   |  17 -
 exec.c                                      |  52 ++
 hw/arm/virt.c                               |   2 +
 hw/core/numa.c                              |  17 +-
 hw/i386/microvm.c                           |   1 +
 hw/i386/pc.c                                |  66 ++-
 hw/i386/pc_piix.c                           |   1 +
 hw/i386/pc_q35.c                            |   1 +
 hw/net/vhost_net-stub.c                     |  11 +
 hw/net/vhost_net.c                          |  44 +-
 hw/net/virtio-net.c                         |  19 +
 hw/s390x/s390-virtio-ccw.c                  |  22 +-
 hw/vfio/ap.c                                |   8 +-
 hw/vfio/ccw.c                               |  11 +-
 hw/vfio/common.c                            |  53 +-
 hw/vfio/pci.c                               |   6 +-
 hw/virtio/vhost-backend.c                   |   6 +
 hw/virtio/vhost-vdpa.c                      | 475 +++++++++++++++
 hw/virtio/vhost.c                           |  52 +-
 hw/virtio/virtio-balloon.c                  |  36 +-
 hw/virtio/virtio-mem-pci.c                  | 157 +++++
 hw/virtio/virtio-mem.c                      | 873 ++++++++++++++++++++++++++++
 hw/virtio/virtio-pci.c                      |  13 +
 hw/virtio/virtio.c                          |   6 +
 migration/migration.c                       |  15 +-
 migration/postcopy-ram.c                    |  23 -
 migration/rdma.c                            |  18 +-
 migration/savevm.c                          |  11 +-
 monitor/hmp-cmds.c                          |  16 +
 monitor/monitor.c                           |   1 +
 net/net.c                                   |  10 +
 net/vhost-vdpa.c                            | 228 ++++++++
 target/i386/sev.c                           |   7 +
 tests/qtest/migration-test.c                |   2 +-
 MAINTAINERS                                 |  18 +
 docs/interop/index.rst                      |   1 +
 docs/interop/vhost-user.rst                 |  24 +
 docs/interop/vhost-vdpa.rst                 |  17 +
 hw/i386/Kconfig                             |   1 +
 hw/virtio/Kconfig                           |  11 +
 hw/virtio/Makefile.objs                     |   3 +
 hw/virtio/trace-events                      |  10 +
 net/Makefile.objs                           |   2 +-
 qemu-options.hx                             |  12 +
 tests/data/acpi/disassemle-aml.sh           |  52 ++
 tests/data/acpi/rebuild-expected-aml.sh     |   1 +
 68 files changed, 2639 insertions(+), 187 deletions(-)
 create mode 100644 hw/virtio/virtio-mem-pci.h
 create mode 100644 include/hw/virtio/vhost-vdpa.h
 create mode 100644 include/hw/virtio/virtio-mem.h
 create mode 100644 include/net/vhost-vdpa.h
 create mode 100644 hw/virtio/vhost-vdpa.c
 create mode 100644 hw/virtio/virtio-mem-pci.c
 create mode 100644 hw/virtio/virtio-mem.c
 create mode 100644 net/vhost-vdpa.c
 create mode 100644 docs/interop/vhost-vdpa.rst
 create mode 100755 tests/data/acpi/disassemle-aml.sh

Comments

Peter Maydell July 7, 2020, 11:40 a.m. UTC | #1
On Sat, 4 Jul 2020 at 19:29, Michael S. Tsirkin <mst@redhat.com> wrote:
>
>
> v2 of the pull, fixing non-Linux builds.
>
>
> The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab:
>
>   hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 21:16:10 +0100)
>
> are available in the Git repository at:
>
>   git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_upstream
>
> for you to fetch changes up to f7d98068bf7a0913744dd4ac0a28e8c841df2af5:
>
>   vhost-vdpa: introduce vhost-vdpa net client (2020-07-04 11:13:50 -0400)
>
> ----------------------------------------------------------------
> virtio,acpi: features, fixes, cleanups.
>
> vdpa support
> virtio-mem support
> a handy script for disassembling acpi tables
> misc fixes and cleanups
>
> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
>
> ----------------------------------------------------------------

Hi; I'm afraid this fails to build on 32-bit:

/home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c: In function
'vhost_vdpa_dma_map':
/home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c:48:23: error: cast
from pointer to integer of different size
[-Werror=pointer-to-int-cast]
     msg.iotlb.uaddr = (uint64_t)vaddr;
                       ^

This should probably be "= (uintptr_t)vaddr".

thanks
-- PMM
Michael S. Tsirkin July 7, 2020, 12:03 p.m. UTC | #2
On Tue, Jul 07, 2020 at 12:40:38PM +0100, Peter Maydell wrote:
> On Sat, 4 Jul 2020 at 19:29, Michael S. Tsirkin <mst@redhat.com> wrote:
> >
> >
> > v2 of the pull, fixing non-Linux builds.
> >
> >
> > The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab:
> >
> >   hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 21:16:10 +0100)
> >
> > are available in the Git repository at:
> >
> >   git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_upstream
> >
> > for you to fetch changes up to f7d98068bf7a0913744dd4ac0a28e8c841df2af5:
> >
> >   vhost-vdpa: introduce vhost-vdpa net client (2020-07-04 11:13:50 -0400)
> >
> > ----------------------------------------------------------------
> > virtio,acpi: features, fixes, cleanups.
> >
> > vdpa support
> > virtio-mem support
> > a handy script for disassembling acpi tables
> > misc fixes and cleanups
> >
> > Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
> >
> > ----------------------------------------------------------------
> 
> Hi; I'm afraid this fails to build on 32-bit:
> 
> /home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c: In function
> 'vhost_vdpa_dma_map':
> /home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c:48:23: error: cast
> from pointer to integer of different size
> [-Werror=pointer-to-int-cast]
>      msg.iotlb.uaddr = (uint64_t)vaddr;
>                        ^
> 
> This should probably be "= (uintptr_t)vaddr".
> 
> thanks
> -- PMM

Precisely. Sorry about missing this.
I made this change and pushed to the same tag - don't want to spam
the list for a small thing like this. Can you pick this up pls?
Commit 849c48004df0e123b53fe9888770cb4f6eb5e8ab now
Peter Maydell July 7, 2020, 5:50 p.m. UTC | #3
On Tue, 7 Jul 2020 at 13:04, Michael S. Tsirkin <mst@redhat.com> wrote:
>
> On Tue, Jul 07, 2020 at 12:40:38PM +0100, Peter Maydell wrote:
> > On Sat, 4 Jul 2020 at 19:29, Michael S. Tsirkin <mst@redhat.com> wrote:
> > >
> > >
> > > v2 of the pull, fixing non-Linux builds.
> > >
> > >
> > > The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab:
> > >
> > >   hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 21:16:10 +0100)
> > >
> > > are available in the Git repository at:
> > >
> > >   git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_upstream
> > >
> > > for you to fetch changes up to f7d98068bf7a0913744dd4ac0a28e8c841df2af5:
> > >
> > >   vhost-vdpa: introduce vhost-vdpa net client (2020-07-04 11:13:50 -0400)
> > >
> > > ----------------------------------------------------------------
> > > virtio,acpi: features, fixes, cleanups.
> > >
> > > vdpa support
> > > virtio-mem support
> > > a handy script for disassembling acpi tables
> > > misc fixes and cleanups
> > >
> > > Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
> > >
> > > ----------------------------------------------------------------
> >
> > Hi; I'm afraid this fails to build on 32-bit:
> >
> > /home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c: In function
> > 'vhost_vdpa_dma_map':
> > /home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c:48:23: error: cast
> > from pointer to integer of different size
> > [-Werror=pointer-to-int-cast]
> >      msg.iotlb.uaddr = (uint64_t)vaddr;
> >                        ^
> >
> > This should probably be "= (uintptr_t)vaddr".
> >
> > thanks
> > -- PMM
>
> Precisely. Sorry about missing this.
> I made this change and pushed to the same tag - don't want to spam
> the list for a small thing like this. Can you pick this up pls?
> Commit 849c48004df0e123b53fe9888770cb4f6eb5e8ab now

Sure. (You can always just resend a new v2 cover letter without
all the patches; that's what most people do for minor respins.)

Applied, thanks.

Please update the changelog at https://wiki.qemu.org/ChangeLog/5.1
for any user-visible changes.

-- PMM
Michael S. Tsirkin July 8, 2020, 6:45 a.m. UTC | #4
On Tue, Jul 07, 2020 at 06:50:55PM +0100, Peter Maydell wrote:
> On Tue, 7 Jul 2020 at 13:04, Michael S. Tsirkin <mst@redhat.com> wrote:
> >
> > On Tue, Jul 07, 2020 at 12:40:38PM +0100, Peter Maydell wrote:
> > > On Sat, 4 Jul 2020 at 19:29, Michael S. Tsirkin <mst@redhat.com> wrote:
> > > >
> > > >
> > > > v2 of the pull, fixing non-Linux builds.
> > > >
> > > >
> > > > The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab:
> > > >
> > > >   hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 21:16:10 +0100)
> > > >
> > > > are available in the Git repository at:
> > > >
> > > >   git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_upstream
> > > >
> > > > for you to fetch changes up to f7d98068bf7a0913744dd4ac0a28e8c841df2af5:
> > > >
> > > >   vhost-vdpa: introduce vhost-vdpa net client (2020-07-04 11:13:50 -0400)
> > > >
> > > > ----------------------------------------------------------------
> > > > virtio,acpi: features, fixes, cleanups.
> > > >
> > > > vdpa support
> > > > virtio-mem support
> > > > a handy script for disassembling acpi tables
> > > > misc fixes and cleanups
> > > >
> > > > Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
> > > >
> > > > ----------------------------------------------------------------
> > >
> > > Hi; I'm afraid this fails to build on 32-bit:
> > >
> > > /home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c: In function
> > > 'vhost_vdpa_dma_map':
> > > /home/peter.maydell/qemu/hw/virtio/vhost-vdpa.c:48:23: error: cast
> > > from pointer to integer of different size
> > > [-Werror=pointer-to-int-cast]
> > >      msg.iotlb.uaddr = (uint64_t)vaddr;
> > >                        ^
> > >
> > > This should probably be "= (uintptr_t)vaddr".
> > >
> > > thanks
> > > -- PMM
> >
> > Precisely. Sorry about missing this.
> > I made this change and pushed to the same tag - don't want to spam
> > the list for a small thing like this. Can you pick this up pls?
> > Commit 849c48004df0e123b53fe9888770cb4f6eb5e8ab now
> 
> Sure. (You can always just resend a new v2 cover letter without
> all the patches; that's what most people do for minor respins.)

As a reply-to or as a new thread?

> Applied, thanks.
> 
> Please update the changelog at https://wiki.qemu.org/ChangeLog/5.1
> for any user-visible changes.
> 
> -- PMM
Peter Maydell July 8, 2020, 10:19 a.m. UTC | #5
On Wed, 8 Jul 2020 at 07:45, Michael S. Tsirkin <mst@redhat.com> wrote:
>
> On Tue, Jul 07, 2020 at 06:50:55PM +0100, Peter Maydell wrote:
> > Sure. (You can always just resend a new v2 cover letter without
> > all the patches; that's what most people do for minor respins.)
>
> As a reply-to or as a new thread?

New thread. Just like sending a complete new pullreq, only you
only send the cover letter to the list, not all the patch mails.
Some people send "cover letter plus the mail for the patch
that changed" if they feel the changes were significant.

-- PMM
Peter Maydell July 9, 2020, 10:32 a.m. UTC | #6
On Tue, 7 Jul 2020 at 18:50, Peter Maydell <peter.maydell@linaro.org> wrote:
>
> On Tue, 7 Jul 2020 at 13:04, Michael S. Tsirkin <mst@redhat.com> wrote:
> > Precisely. Sorry about missing this.
> > I made this change and pushed to the same tag - don't want to spam
> > the list for a small thing like this. Can you pick this up pls?
> > Commit 849c48004df0e123b53fe9888770cb4f6eb5e8ab now
>
> Sure. (You can always just resend a new v2 cover letter without
> all the patches; that's what most people do for minor respins.)
>
> Applied, thanks.

I've just noticed that the commit that got merged was not the
one you quote but 1e0a84ea49b68b7cf60e -- can you check whether
anything was missed or the wrong version ?

thanks
-- PMM
Michael S. Tsirkin July 9, 2020, 5:46 p.m. UTC | #7
On Thu, Jul 09, 2020 at 11:32:05AM +0100, Peter Maydell wrote:
> On Tue, 7 Jul 2020 at 18:50, Peter Maydell <peter.maydell@linaro.org> wrote:
> >
> > On Tue, 7 Jul 2020 at 13:04, Michael S. Tsirkin <mst@redhat.com> wrote:
> > > Precisely. Sorry about missing this.
> > > I made this change and pushed to the same tag - don't want to spam
> > > the list for a small thing like this. Can you pick this up pls?
> > > Commit 849c48004df0e123b53fe9888770cb4f6eb5e8ab now
> >
> > Sure. (You can always just resend a new v2 cover letter without
> > all the patches; that's what most people do for minor respins.)
> >
> > Applied, thanks.
> 
> I've just noticed that the commit that got merged was not the
> one you quote but 1e0a84ea49b68b7cf60e -- can you check whether
> anything was missed or the wrong version ?
> 
> thanks
> -- PMM

Yea not a big deal:

diff --git a/hw/virtio/vhost-vdpa.c b/hw/virtio/vhost-vdpa.c
index fb7de972f3..a3d17fe0f9 100644
--- a/hw/virtio/vhost-vdpa.c
+++ b/hw/virtio/vhost-vdpa.c
@@ -45,7 +45,7 @@ static int vhost_vdpa_dma_map(struct vhost_vdpa *v, hwaddr iova, hwaddr size,
     msg.type = v->msg_type;
     msg.iotlb.iova = iova;
     msg.iotlb.size = size;
-    msg.iotlb.uaddr = (uintptr_t)vaddr;
+    msg.iotlb.uaddr = (uint64_t)(uintptr_t)vaddr;
     msg.iotlb.perm = readonly ? VHOST_ACCESS_RO : VHOST_ACCESS_RW;
     msg.iotlb.type = VHOST_IOTLB_UPDATE;

I guess I forgot to push or something. Sorry.