Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: qemu/qemu
base: 5e8838524a74
Choose a base ref
...
head repository: qemu/qemu
compare: 477ab906d18c
Choose a head ref
  • 7 commits
  • 7 files changed
  • 7 contributors

Commits on Jun 30, 2023

  1. vdpa: mask _F_CTRL_GUEST_OFFLOADS for vhost vdpa devices

    QEMU does not emulate it so it must be disabled as long as the backend
    does not support it.
    
    Signed-off-by: Eugenio Pérez <eperezma@redhat.com>
    Message-Id: <20230602173328.1917385-1-eperezma@redhat.com>
    Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Acked-by: Jason Wang <jasowang@redhat.com>
    Tested-by: Lei Yang <leiyang@redhat.com>
    (cherry picked from commit 51e8424)
    Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
    eugpermar authored and Michael Tokarev committed Jun 30, 2023
    Copy the full SHA
    246b0cf View commit details
    Browse the repository at this point in the history
  2. vhost: fix vhost_dev_enable_notifiers() error case

    in vhost_dev_enable_notifiers(), if virtio_bus_set_host_notifier(true)
    fails, we call vhost_dev_disable_notifiers() that executes
    virtio_bus_set_host_notifier(false) on all queues, even on queues that
    have failed to be initialized.
    
    This triggers a core dump in memory_region_del_eventfd():
    
     virtio_bus_set_host_notifier: unable to init event notifier: Too many open files (-24)
     vhost VQ 1 notifier binding failed: 24
     .../softmmu/memory.c:2611: memory_region_del_eventfd: Assertion `i != mr->ioeventfd_nb' failed.
    
    Fix the problem by providing to vhost_dev_disable_notifiers() the
    number of queues to disable.
    
    Fixes: 8771589 ("vhost: simplify vhost_dev_enable_notifiers")
    Cc: longpeng2@huawei.com
    Signed-off-by: Laurent Vivier <lvivier@redhat.com>
    Message-Id: <20230602162735.3670785-1-lvivier@redhat.com>
    Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    (cherry picked from commit 92099aa)
    Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
    vivier authored and Michael Tokarev committed Jun 30, 2023
    Copy the full SHA
    ce63312 View commit details
    Browse the repository at this point in the history
  3. target/ppc: Fix decrementer time underflow and infinite timer loop

    It is possible to store a very large value to the decrementer that it
    does not raise the decrementer exception so the timer is scheduled, but
    the next time value wraps and is treated as in the past.
    
    This can occur if (u64)-1 is stored on a zero-triggered exception, or
    (u64)-1 is stored twice on an underflow-triggered exception, for
    example.
    
    If such a value is set in DECAR, it gets stored to the decrementer by
    the timer function, which then immediately causes another timer, which
    hangs QEMU.
    
    Clamp the decrementer to the implemented width, and use that as the
    value for the timer calculation, effectively preventing this overflow.
    
    Reported-by: sdicaro@DDCI.com
    Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
    Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
    Message-Id: <20230530131214.373524-1-npiggin@gmail.com>
    Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
    (cherry picked from commit 09d2db9)
    Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
    npiggin authored and Michael Tokarev committed Jun 30, 2023
    Copy the full SHA
    55ee115 View commit details
    Browse the repository at this point in the history
  4. vfio/pci: Fix a segfault in vfio_realize

    The kvm irqchip notifier is only registered if the device supports
    INTx, however it's unconditionally removed in vfio realize error
    path. If the assigned device does not support INTx, this will cause
    QEMU to crash when vfio realize fails. Change it to conditionally
    remove the notifier only if the notify hook is setup.
    
    Before fix:
    (qemu) device_add vfio-pci,host=81:11.1,id=vfio1,bus=root1,xres=1
    Connection closed by foreign host.
    
    After fix:
    (qemu) device_add vfio-pci,host=81:11.1,id=vfio1,bus=root1,xres=1
    Error: vfio 0000:81:11.1: xres and yres properties require display=on
    (qemu)
    
    Fixes: c5478fe ("vfio/pci: Respond to KVM irqchip change notifier")
    Signed-off-by: Zhenzhong Duan <zhenzhong.duan@intel.com>
    Reviewed-by: Cédric Le Goater <clg@redhat.com>
    Reviewed-by: Joao Martins <joao.m.martins@oracle.com>
    Signed-off-by: Cédric Le Goater <clg@redhat.com>
    (cherry picked from commit 357bd79)
    Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
    duanzhenzhong authored and Michael Tokarev committed Jun 30, 2023
    Copy the full SHA
    58b3e4f View commit details
    Browse the repository at this point in the history
  5. vfio/pci: Call vfio_prepare_kvm_msi_virq_batch() in MSI retry path

    When vfio_enable_vectors() returns with less than requested nr_vectors
    we retry with what kernel reported back. But the retry path doesn't
    call vfio_prepare_kvm_msi_virq_batch() and this results in,
    
    qemu-system-aarch64: vfio: Error: Failed to enable 4 MSI vectors, retry with 1
    qemu-system-aarch64: ../hw/vfio/pci.c:602: vfio_commit_kvm_msi_virq_batch: Assertion `vdev->defer_kvm_irq_routing' failed
    
    Fixes: dc580d5 ("vfio: defer to commit kvm irq routing when enable msi/msix")
    Reviewed-by: Longpeng <longpeng2@huawei.com>
    Signed-off-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
    Reviewed-by: Cédric Le Goater <clg@redhat.com>
    Signed-off-by: Cédric Le Goater <clg@redhat.com>
    (cherry picked from commit c174088)
    Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
    shamiali2008 authored and Michael Tokarev committed Jun 30, 2023
    Copy the full SHA
    383fb8c View commit details
    Browse the repository at this point in the history

Commits on Jul 1, 2023

  1. linux-user: Avoid mmap of the last byte of the reserved_va

    There is an overflow problem in mmap_find_vma_reserved:
    when reserved_va == UINT32_MAX, end may overflow to 0.
    Rather than a larger rewrite at this time, simply avoid
    the final byte of the VA, which avoids searching the
    final page, which avoids the overflow.
    
    Cc: qemu-stable@nongnu.org
    Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1741
    Fixes: 95059f9 ("include/exec: Change reserved_va semantics to last byte")
    Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
    Tested-by: Michael Tokarev <mjt@tls.msk.ru>
    Reviewed-by: Michael Tokarev <mjt@tls.msk.ru>
    Message-Id: <20230629080835.71371-1-richard.henderson@linaro.org>
    (cherry picked from commit 605a8b5)
    Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
    rth7680 authored and Michael Tokarev committed Jul 1, 2023
    Copy the full SHA
    df1e45c View commit details
    Browse the repository at this point in the history

Commits on Jul 2, 2023

  1. ui/gtk: set the area of the scanout texture correctly

    x and y offsets and width and height of the scanout texture
    is not correctly configured in case guest scanout frame is
    dmabuf.
    
    Cc: Gerd Hoffmann <kraxel@redhat.com>
    Cc: Marc-André Lureau <marcandre.lureau@redhat.com>
    Cc: Vivek Kasireddy <vivek.kasireddy@intel.com>
    Signed-off-by: Dongwon Kim <dongwon.kim@intel.com>
    Message-ID: <20230621213150.29573-1-dongwon.kim@intel.com>
    (cherry picked from commit 37802a2)
    Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
    downor authored and Michael Tokarev committed Jul 2, 2023
    Copy the full SHA
    477ab90 View commit details
    Browse the repository at this point in the history