qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] a7b438: bios-tables-test: tell people how to


From: Peter Maydell
Subject: [Qemu-commits] [qemu/qemu] a7b438: bios-tables-test: tell people how to update
Date: Thu, 27 Feb 2020 12:00:15 -0800

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: a7b4384fefbd1cbe05c8fd10fe06de8c4fdc2792
      
https://github.com/qemu/qemu/commit/a7b4384fefbd1cbe05c8fd10fe06de8c4fdc2792
  Author: Michael S. Tsirkin <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M tests/qtest/bios-tables-test.c

  Log Message:
  -----------
  bios-tables-test: tell people how to update

For now just a pointer to the source file.

Signed-off-by: Michael S. Tsirkin <address@hidden>
Reviewed-by: Laurent Vivier <address@hidden>
Reviewed-by: Thomas Huth <address@hidden>


  Commit: c01e905f3a34088346833f3a5518cb0efeb24e27
      
https://github.com/qemu/qemu/commit/c01e905f3a34088346833f3a5518cb0efeb24e27
  Author: Michael S. Tsirkin <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M tests/qtest/bios-tables-test.c

  Log Message:
  -----------
  bios-tables-test: fix up DIFF generation

Turns out it goes to stdout which is suppressed even with V=1.
Force DIFF output to stderr to make it visible.

Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 34b1429ca92eae5bb2a532d5596f6150ea17150a
      
https://github.com/qemu/qemu/commit/34b1429ca92eae5bb2a532d5596f6150ea17150a
  Author: Michael S. Tsirkin <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M tests/qtest/bios-tables-test.c

  Log Message:
  -----------
  bios-tables-test: default diff command

Most people probably just want diff -u. So let's use that
as the default.

Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 6ab425d8a10226098c29971f74b5fa954d5498d6
      
https://github.com/qemu/qemu/commit/6ab425d8a10226098c29971f74b5fa954d5498d6
  Author: Michael S. Tsirkin <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M tests/data/acpi/rebuild-expected-aml.sh

  Log Message:
  -----------
  rebuild-expected-aml.sh: remind about the process

Remind users of rebuild-expected-aml.sh about the process
to follow. Suppress the warning if allowed file list exists -
that's a big hint user is already aware of the process.

Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: ba07cf5d3f58be697700b67d24e6277a7822b629
      
https://github.com/qemu/qemu/commit/ba07cf5d3f58be697700b67d24e6277a7822b629
  Author: Pan Nengyuan <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M hw/virtio/vhost-user-fs.c

  Log Message:
  -----------
  vhost-user-fs: do delete virtio_queues in unrealize

Similar to other virtio device(https://patchwork.kernel.org/patch/11399237/), 
virtio queues forgot to delete in unrealize, and aslo error path in realize, 
this patch fix these memleaks, the leak stack is as follow:
Direct leak of 57344 byte(s) in 1 object(s) allocated from:
    #0 0x7f15784fb970 in __interceptor_calloc (/lib64/libasan.so.5+0xef970)
    #1 0x7f157790849d in g_malloc0 (/lib64/libglib-2.0.so.0+0x5249d)
    #2 0x55587a1bf859 in virtio_add_queue 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/virtio/virtio.c:2333
    #3 0x55587a2071d5 in vuf_device_realize 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/virtio/vhost-user-fs.c:212
    #4 0x55587a1ae360 in virtio_device_realize 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/virtio/virtio.c:3531
    #5 0x55587a63fb7b in device_set_realized 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/core/qdev.c:891
    #6 0x55587acf03f5 in property_set_bool 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/object.c:2238
    #7 0x55587acfce0d in object_property_set_qobject 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/qom-qobject.c:26
    #8 0x55587acf5c8c in object_property_set_bool 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/object.c:1390
    #9 0x55587a8e22a2 in pci_qdev_realize 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/pci/pci.c:2095
    #10 0x55587a63fb7b in device_set_realized 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/core/qdev.c:891
    #11 0x55587acf03f5 in property_set_bool 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/object.c:2238
    #12 0x55587acfce0d in object_property_set_qobject 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/qom-qobject.c:26
    #13 0x55587acf5c8c in object_property_set_bool 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/object.c:1390
    #14 0x55587a496d65 in qdev_device_add 
/mnt/sdb/qemu-new/qemu_test/qemu/qdev-monitor.c:679

Reported-by: Euler Robot <address@hidden>
Signed-off-by: Pan Nengyuan <address@hidden>
Cc: "Dr. David Alan Gilbert" <address@hidden>
Cc: Stefan Hajnoczi <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 2e5bc65935ddf8ee152c1317a3d3bb4bb73e727d
      
https://github.com/qemu/qemu/commit/2e5bc65935ddf8ee152c1317a3d3bb4bb73e727d
  Author: Pan Nengyuan <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M hw/virtio/vhost-user-fs.c
    M include/hw/virtio/vhost-user-fs.h

  Log Message:
  -----------
  vhost-user-fs: convert to the new virtio_delete_queue function

use the new virtio_delete_queue function to cleanup.

Signed-off-by: Pan Nengyuan <address@hidden>
Cc: "Dr. David Alan Gilbert" <address@hidden>
Cc: Stefan Hajnoczi <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 9861546e1dae05c5152de7d3bd14e341ecadc972
      
https://github.com/qemu/qemu/commit/9861546e1dae05c5152de7d3bd14e341ecadc972
  Author: Pan Nengyuan <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M hw/virtio/virtio-pmem.c

  Log Message:
  -----------
  virtio-pmem: do delete rq_vq in virtio_pmem_unrealize

Similar to other virtio-devices, rq_vq forgot to delete in
virtio_pmem_unrealize, this patch fix it.  This device has already
maintained a vq pointer, thus we use the new virtio_delete_queue
function directly to do the cleanup.

Reported-by: Euler Robot <address@hidden>
Signed-off-by: Pan Nengyuan <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: d56e1c8256cb37e68f9b5d98c6cc4e6ca463f1fd
      
https://github.com/qemu/qemu/commit/d56e1c8256cb37e68f9b5d98c6cc4e6ca463f1fd
  Author: Pan Nengyuan <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M hw/virtio/virtio-crypto.c

  Log Message:
  -----------
  virtio-crypto: do delete ctrl_vq in virtio_crypto_device_unrealize

Similar to other virtio-deivces, ctrl_vq forgot to delete in 
virtio_crypto_device_unrealize, this patch fix it.
This device has aleardy maintained vq pointers. Thus, we use the new 
virtio_delete_queue function directly to do the cleanup.

The leak stack:
Direct leak of 10752 byte(s) in 3 object(s) allocated from:
    #0 0x7f4c024b1970 in __interceptor_calloc (/lib64/libasan.so.5+0xef970)
    #1 0x7f4c018be49d in g_malloc0 (/lib64/libglib-2.0.so.0+0x5249d)
    #2 0x55a2f8017279 in virtio_add_queue 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/virtio/virtio.c:2333
    #3 0x55a2f8057035 in virtio_crypto_device_realize 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/virtio/virtio-crypto.c:814
    #4 0x55a2f8005d80 in virtio_device_realize 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/virtio/virtio.c:3531
    #5 0x55a2f8497d1b in device_set_realized 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/core/qdev.c:891
    #6 0x55a2f8b48595 in property_set_bool 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/object.c:2238
    #7 0x55a2f8b54fad in object_property_set_qobject 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/qom-qobject.c:26
    #8 0x55a2f8b4de2c in object_property_set_bool 
/mnt/sdb/qemu-new/qemu_test/qemu/qom/object.c:1390
    #9 0x55a2f80609c9 in virtio_crypto_pci_realize 
/mnt/sdb/qemu-new/qemu_test/qemu/hw/virtio/virtio-crypto-pci.c:58

Reported-by: Euler Robot <address@hidden>
Signed-off-by: Pan Nengyuan <address@hidden>
Cc: "Gonglei (Arei)" <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 13e5468127111bf44c5dc314d1dd2ec5a65dfec4
      
https://github.com/qemu/qemu/commit/13e5468127111bf44c5dc314d1dd2ec5a65dfec4
  Author: Pan Nengyuan <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M hw/block/vhost-user-blk.c

  Log Message:
  -----------
  vhost-user-blk: delete virtioqueues in unrealize to fix memleaks

virtio queues forgot to delete in unrealize, and aslo error path in
realize, this patch fix these memleaks, the leak stack is as follow:

Direct leak of 114688 byte(s) in 16 object(s) allocated from:
    #0 0x7f24024fdbf0 in calloc (/lib64/libasan.so.3+0xcabf0)
    #1 0x7f2401642015 in g_malloc0 (/lib64/libglib-2.0.so.0+0x50015)
    #2 0x55ad175a6447 in virtio_add_queue /mnt/sdb/qemu/hw/virtio/virtio.c:2327
    #3 0x55ad17570cf9 in vhost_user_blk_device_realize 
/mnt/sdb/qemu/hw/block/vhost-user-blk.c:419
    #4 0x55ad175a3707 in virtio_device_realize 
/mnt/sdb/qemu/hw/virtio/virtio.c:3509
    #5 0x55ad176ad0d1 in device_set_realized /mnt/sdb/qemu/hw/core/qdev.c:876
    #6 0x55ad1781ff9d in property_set_bool /mnt/sdb/qemu/qom/object.c:2080
    #7 0x55ad178245ae in object_property_set_qobject 
/mnt/sdb/qemu/qom/qom-qobject.c:26
    #8 0x55ad17821eb4 in object_property_set_bool 
/mnt/sdb/qemu/qom/object.c:1338
    #9 0x55ad177aeed7 in virtio_pci_realize 
/mnt/sdb/qemu/hw/virtio/virtio-pci.c:1801

Reported-by: Euler Robot <address@hidden>
Signed-off-by: Pan Nengyuan <address@hidden>
Reviewed-by: Stefan Hajnoczi <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Stefan Hajnoczi <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 38e245a42ca81c47d477314c3cfabfcb3d3cec11
      
https://github.com/qemu/qemu/commit/38e245a42ca81c47d477314c3cfabfcb3d3cec11
  Author: Pan Nengyuan <address@hidden>
  Date:   2020-02-25 (Tue, 25 Feb 2020)

  Changed paths:
    M hw/block/vhost-user-blk.c
    M include/hw/virtio/vhost-user-blk.h

  Log Message:
  -----------
  vhost-user-blk: convert to new virtio_delete_queue

use the new virtio_delete_queue function to cleanup.

Signed-off-by: Pan Nengyuan <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Stefan Hajnoczi <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: abdd16f4681cc4d6bf84990227b5c9b98e869ccd
      
https://github.com/qemu/qemu/commit/abdd16f4681cc4d6bf84990227b5c9b98e869ccd
  Author: Stefan Hajnoczi <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/virtio.c

  Log Message:
  -----------
  virtio: gracefully handle invalid region caches

The virtqueue code sets up MemoryRegionCaches to access the virtqueue
guest RAM data structures.  The code currently assumes that
VRingMemoryRegionCaches is initialized before device emulation code
accesses the virtqueue.  An assertion will fail in
vring_get_region_caches() when this is not true.  Device fuzzing found a
case where this assumption is false (see below).

Virtqueue guest RAM addresses can also be changed from a vCPU thread
while an IOThread is accessing the virtqueue.  This breaks the same
assumption but this time the caches could become invalid partway through
the virtqueue code.  The code fetches the caches RCU pointer multiple
times so we will need to validate the pointer every time it is fetched.

Add checks each time we call vring_get_region_caches() and treat invalid
caches as a nop: memory stores are ignored and memory reads return 0.

The fuzz test failure is as follows:

  $ qemu -M pc -device virtio-blk-pci,id=drv0,drive=drive0,addr=4.0 \
         -drive if=none,id=drive0,file=null-co://,format=raw,auto-read-only=off 
\
         -drive 
if=none,id=drive1,file=null-co://,file.read-zeroes=on,format=raw \
         -display none \
         -qtest stdio
  endianness
  outl 0xcf8 0x80002020
  outl 0xcfc 0xe0000000
  outl 0xcf8 0x80002004
  outw 0xcfc 0x7
  write 0xe0000000 0x24 
0x00ffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffab5cffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffabffffffab0000000001
  inb 0x4
  writew 0xe000001c 0x1
  write 0xe0000014 0x1 0x0d

The following error message is produced:

  qemu-system-x86_64: /home/stefanha/qemu/hw/virtio/virtio.c:286: 
vring_get_region_caches: Assertion `caches != NULL' failed.

The backtrace looks like this:

  #0  0x00007ffff5520625 in raise () at /lib64/libc.so.6
  #1  0x00007ffff55098d9 in abort () at /lib64/libc.so.6
  #2  0x00007ffff55097a9 in _nl_load_domain.cold () at /lib64/libc.so.6
  #3  0x00007ffff5518a66 in annobin_assert.c_end () at /lib64/libc.so.6
  #4  0x00005555559073da in vring_get_region_caches (vq=<optimized out>) at 
qemu/hw/virtio/virtio.c:286
  #5  vring_get_region_caches (vq=<optimized out>) at 
qemu/hw/virtio/virtio.c:283
  #6  0x000055555590818d in vring_used_flags_set_bit (mask=1, 
vq=0x5555575ceea0) at qemu/hw/virtio/virtio.c:398
  #7  virtio_queue_split_set_notification (enable=0, vq=0x5555575ceea0) at 
qemu/hw/virtio/virtio.c:398
  #8  virtio_queue_set_notification (vq=vq@entry=0x5555575ceea0, 
enable=enable@entry=0) at qemu/hw/virtio/virtio.c:451
  #9  0x0000555555908512 in virtio_queue_set_notification 
(vq=vq@entry=0x5555575ceea0, enable=enable@entry=0) at 
qemu/hw/virtio/virtio.c:444
  #10 0x00005555558c697a in virtio_blk_handle_vq (s=0x5555575c57e0, 
vq=0x5555575ceea0) at qemu/hw/block/virtio-blk.c:775
  #11 0x0000555555907836 in virtio_queue_notify_aio_vq (vq=0x5555575ceea0) at 
qemu/hw/virtio/virtio.c:2244
  #12 0x0000555555cb5dd7 in aio_dispatch_handlers 
(ctx=ctx@entry=0x55555671a420) at util/aio-posix.c:429
  #13 0x0000555555cb67a8 in aio_dispatch (ctx=0x55555671a420) at 
util/aio-posix.c:460
  #14 0x0000555555cb307e in aio_ctx_dispatch (source=<optimized out>, 
callback=<optimized out>, user_data=<optimized out>) at util/async.c:260
  #15 0x00007ffff7bbc510 in g_main_context_dispatch () at 
/lib64/libglib-2.0.so.0
  #16 0x0000555555cb5848 in glib_pollfds_poll () at util/main-loop.c:219
  #17 os_host_main_loop_wait (timeout=<optimized out>) at util/main-loop.c:242
  #18 main_loop_wait (nonblocking=<optimized out>) at util/main-loop.c:518
  #19 0x00005555559b20c9 in main_loop () at vl.c:1683
  #20 0x0000555555838115 in main (argc=<optimized out>, argv=<optimized out>, 
envp=<optimized out>) at vl.c:4441

Reported-by: Alexander Bulekov <address@hidden>
Cc: Michael Tsirkin <address@hidden>
Cc: Cornelia Huck <address@hidden>
Cc: Paolo Bonzini <address@hidden>
Cc: address@hidden
Signed-off-by: Stefan Hajnoczi <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 22c37a10f3e1de1b19aa8281bc368d8cea960f4c
      
https://github.com/qemu/qemu/commit/22c37a10f3e1de1b19aa8281bc368d8cea960f4c
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/Kconfig
    M hw/virtio/Makefile.objs
    M hw/virtio/trace-events
    A hw/virtio/virtio-iommu.c
    A include/hw/virtio/virtio-iommu.h

  Log Message:
  -----------
  virtio-iommu: Add skeleton

This patchs adds the skeleton for the virtio-iommu device.

Signed-off-by: Eric Auger <address@hidden>
Reviewed-by: Peter Xu <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 5442b854eaf921588e24d5711640ab71e59cb1b8
      
https://github.com/qemu/qemu/commit/5442b854eaf921588e24d5711640ab71e59cb1b8
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/trace-events
    M hw/virtio/virtio-iommu.c

  Log Message:
  -----------
  virtio-iommu: Decode the command payload

This patch adds the command payload decoding and
introduces the functions that will do the actual
command handling. Those functions are not yet implemented.

Signed-off-by: Eric Auger <address@hidden>
Reviewed-by: Jean-Philippe Brucker <address@hidden>
Reviewed-by: Peter Xu <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: cfb42188b24d5904f82cd609185847a1168226e3
      
https://github.com/qemu/qemu/commit/cfb42188b24d5904f82cd609185847a1168226e3
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/trace-events
    M hw/virtio/virtio-iommu.c
    M include/hw/virtio/virtio-iommu.h

  Log Message:
  -----------
  virtio-iommu: Implement attach/detach command

This patch implements the endpoint attach/detach to/from
a domain.

Domain and endpoint internal datatypes are introduced.
Both are stored in RB trees. The domain owns a list of
endpoints attached to it. Also helpers to get/put
end points and domains are introduced.

As for the IOMMU memory regions, a callback is called on
PCI bus enumeration that initializes for a given device
on the bus hierarchy an IOMMU memory region. The PCI bus
hierarchy is stored locally in IOMMUPciBus and IOMMUDevice
objects.

At the time of the enumeration, the bus number may not be
computed yet.

So operations that will need to retrieve the IOMMUdevice
and its IOMMU memory region from the bus number and devfn,
once the bus number is garanteed to be frozen, use an array
of IOMMUPciBus, lazily populated.

Signed-off-by: Eric Auger <address@hidden>
Reviewed-by: Peter Xu <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: fe2cacae2438930eaafe8dd31b3bea1947ee0087
      
https://github.com/qemu/qemu/commit/fe2cacae2438930eaafe8dd31b3bea1947ee0087
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/trace-events
    M hw/virtio/virtio-iommu.c

  Log Message:
  -----------
  virtio-iommu: Implement map/unmap

This patch implements virtio_iommu_map/unmap.

Signed-off-by: Eric Auger <address@hidden>
Reviewed-by: Peter Xu <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: ed8449b30b29f9da10746d3e5672248f3e4b675b
      
https://github.com/qemu/qemu/commit/ed8449b30b29f9da10746d3e5672248f3e4b675b
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/trace-events
    M hw/virtio/virtio-iommu.c

  Log Message:
  -----------
  virtio-iommu: Implement translate

This patch implements the translate callback

Signed-off-by: Eric Auger <address@hidden>
Reviewed-by: Jean-Philippe Brucker <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: a7c1da8adc4553854433d749c69319daa670ce69
      
https://github.com/qemu/qemu/commit/a7c1da8adc4553854433d749c69319daa670ce69
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/trace-events
    M hw/virtio/virtio-iommu.c

  Log Message:
  -----------
  virtio-iommu: Implement fault reporting

The event queue allows to report asynchronous errors.
The translate function now injects faults when relevant.

Signed-off-by: Eric Auger <address@hidden>
Reviewed-by: Peter Xu <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: bd0ab8702fa272d39644bbefa1d3f4b42fc594ff
      
https://github.com/qemu/qemu/commit/bd0ab8702fa272d39644bbefa1d3f4b42fc594ff
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/virtio-iommu.c

  Log Message:
  -----------
  virtio-iommu: Support migration

Add Migration support. We rely on recently added gtree and qlist
migration. We only migrate the domain gtree. The endpoint gtree
is re-constructed in a post-load operation.

Signed-off-by: Eric Auger <address@hidden>
Acked-by: Peter Xu <address@hidden>
Reviewed-by: Juan Quintela <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 8b4eb09e32456ebd769fe09a1aa338d6a3536376
      
https://github.com/qemu/qemu/commit/8b4eb09e32456ebd769fe09a1aa338d6a3536376
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/Makefile.objs
    A hw/virtio/virtio-iommu-pci.c
    M include/hw/pci/pci.h
    M include/hw/virtio/virtio-iommu.h
    M qdev-monitor.c

  Log Message:
  -----------
  virtio-iommu-pci: Add virtio iommu pci support

This patch adds virtio-iommu-pci, which is the pci proxy for
the virtio-iommu device.

Currently non DT integration is not yet supported by the kernel.
So the machine must implement a hotplug handler for the
virtio-iommu-pci device that creates the device tree iommu-map
bindings as documented in kernel documentation:

Documentation/devicetree/bindings/virtio/iommu.txt

Signed-off-by: Eric Auger <address@hidden>
Reviewed-by: Jean-Philippe Brucker <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 70e89132c9e67473b7cbb507dd13c96aab598517
      
https://github.com/qemu/qemu/commit/70e89132c9e67473b7cbb507dd13c96aab598517
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/arm/virt.c
    M include/hw/arm/virt.h

  Log Message:
  -----------
  hw/arm/virt: Add the virtio-iommu device tree mappings

Adds the "virtio,pci-iommu" node in the host bridge node and
the RID mapping, excluding the IOMMU RID.

This is done in the virtio-iommu-pci hotplug handler which
gets called only if no firmware is loaded or if -no-acpi is
passed on the command line. As non DT integration is
not yet supported by the kernel we must make sure we
are in DT mode. This limitation will be removed as soon
as the topology description feature gets supported.

Signed-off-by: Eric Auger <address@hidden>

Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
Reviewed-by: Peter Maydell <address@hidden>


  Commit: c1dee918799391980dbde12ee60fbd0189f367f8
      
https://github.com/qemu/qemu/commit/c1dee918799391980dbde12ee60fbd0189f367f8
  Author: Eric Auger <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M MAINTAINERS

  Log Message:
  -----------
  MAINTAINERS: add virtio-iommu related files

Add a new "virtio-iommu" section with the new files
related to this device.

Signed-off-by: Eric Auger <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
Reviewed-by: Peter Maydell <address@hidden>


  Commit: 8899d60142e790debe1604a89d0028ba1740d8e9
      
https://github.com/qemu/qemu/commit/8899d60142e790debe1604a89d0028ba1740d8e9
  Author: Johannes Berg <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M contrib/libvhost-user/libvhost-user.c

  Log Message:
  -----------
  libvhost-user: implement VHOST_USER_PROTOCOL_F_REPLY_ACK

This is really simple, since we know whether a response is
already requested or not, so we can just send a (successful)
response when there isn't one already.

Given that, it's not all _that_ useful but the master can at
least be sure the message was processed, and we can exercise
more code paths using the example code.

Reviewed-by: Stefan Hajnoczi <address@hidden>
Signed-off-by: Johannes Berg <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: a7290a79fa262124916dab2bb75188cfd07faad6
      
https://github.com/qemu/qemu/commit/a7290a79fa262124916dab2bb75188cfd07faad6
  Author: Johannes Berg <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M contrib/libvhost-user/libvhost-user-glib.c
    M contrib/libvhost-user/libvhost-user-glib.h
    M contrib/vhost-user-input/main.c

  Log Message:
  -----------
  libvhost-user-glib: fix VugDev main fd cleanup

If you try to make a device implementation that can handle multiple
connections and allow disconnections (which requires overriding the
VHOST_USER_NONE handling), then glib will warn that we remove a src
while it's still on the mainloop, and will poll() an FD that doesn't
exist anymore.

Fix this by making vug_source_new() require pairing with the new
vug_source_destroy() so we can keep the GSource referenced in the
meantime.

Note that this requires calling the new API in vhost-user-input.
vhost-user-gpu also uses vug_source_new(), but never seems to free
the result at all, so I haven't changed anything there.

Fixes: 8bb7ddb78a1c ("libvhost-user: add glib source helper")
Reviewed-by: Marc-André Lureau <address@hidden>
Signed-off-by: Johannes Berg <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: a00fdc9c9d3e7f2c3c21d14ba8fd04451ec423a2
      
https://github.com/qemu/qemu/commit/a00fdc9c9d3e7f2c3c21d14ba8fd04451ec423a2
  Author: Johannes Berg <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M contrib/libvhost-user/libvhost-user-glib.c

  Log Message:
  -----------
  libvhost-user-glib: use g_main_context_get_thread_default()

If we use NULL, we just get the main program default mainloop
here. Using g_main_context_get_thread_default() has basically
the same effect, but it lets us start different devices in
different threads with different mainloops, which can be useful.

Reviewed-by: Stefan Hajnoczi <address@hidden>
Reviewed-by: Marc-André Lureau <address@hidden>
Signed-off-by: Johannes Berg <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: d5f99fc578d5f4f2ab731ec692f34ce875d870fe
      
https://github.com/qemu/qemu/commit/d5f99fc578d5f4f2ab731ec692f34ce875d870fe
  Author: Johannes Berg <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M contrib/libvhost-user/libvhost-user.c

  Log Message:
  -----------
  libvhost-user: handle NOFD flag in call/kick/err better

The code here is odd, for example will it print out invalid
file descriptor numbers that were never sent in the message.

Clean that up a bit so it's actually possible to implement
a device that uses polling.

Signed-off-by: Johannes Berg <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 3348e7e34ff945340dbcf310d29d4feb5de20ef6
      
https://github.com/qemu/qemu/commit/3348e7e34ff945340dbcf310d29d4feb5de20ef6
  Author: Johannes Berg <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M docs/interop/vhost-user.rst

  Log Message:
  -----------
  docs: vhost-user: add in-band kick/call messages

For good reason, vhost-user is currently built asynchronously, that
way better performance can be obtained. However, for certain use
cases such as simulation, this is problematic.

Consider an event-based simulation in which both the device and CPU
have scheduled according to a simulation "calendar". Now, consider
the CPU sending I/O to the device, over a vring in the vhost-user
protocol. In this case, the CPU must wait for the vring interrupt
to have been processed by the device, so that the device is able to
put an entry onto the simulation calendar to obtain time to handle
the interrupt. Note that this doesn't mean the I/O is actually done
at this time, it just means that the handling of it is scheduled
before the CPU can continue running.

This cannot be done with the asynchronous eventfd based vring kick
and call design.

Extend the protocol slightly, so that a message can be used for kick
and call instead, if VHOST_USER_PROTOCOL_F_INBAND_NOTIFICATIONS is
negotiated. This in itself doesn't guarantee synchronisation, but both
sides can also negotiate VHOST_USER_PROTOCOL_F_REPLY_ACK and thus get
a reply to this message by setting the need_reply flag, and ensure
synchronisation this way.

To really use it in both directions, VHOST_USER_PROTOCOL_F_SLAVE_REQ
is also needed.

Since it is used for simulation purposes and too many messages on
the socket can lock up the virtual machine, document that this should
only be used together with the mentioned features.

Signed-off-by: Johannes Berg <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: ff1320050a3a7af8b094020c5e4bb6ad736421a8
      
https://github.com/qemu/qemu/commit/ff1320050a3a7af8b094020c5e4bb6ad736421a8
  Author: Johannes Berg <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M contrib/libvhost-user/libvhost-user.c
    M contrib/libvhost-user/libvhost-user.h

  Log Message:
  -----------
  libvhost-user: implement in-band notifications

Add support for VHOST_USER_PROTOCOL_F_IN_BAND_NOTIFICATIONS, but
as it's not desired by default, don't enable it unless the device
implementation opts in by returning it from its protocol features
callback.

Note that I updated vu_set_vring_err_exec(), but didn't add any
sending of the VHOST_USER_SLAVE_VRING_ERR message as there's no
write to the err_fd today either.

This also adds vu_queue_notify_sync() which can be used to force
a synchronous notification if inband notifications are supported.
Previously, I had left out the slave->master direction handling
of F_REPLY_ACK, this now adds some code to support it as well.

Signed-off-by: Johannes Berg <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: fd9b0830b0be0ea89cf30ad846a232e0c442a18a
      
https://github.com/qemu/qemu/commit/fd9b0830b0be0ea89cf30ad846a232e0c442a18a
  Author: Igor Mammedov <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M docs/specs/acpi_cpu_hotplug.txt

  Log Message:
  -----------
  acpi: cpuhp: document CPHP_GET_CPU_ID_CMD command

Commit 3a61c8db9d25 introduced CPHP_GET_CPU_ID_CMD command but
did not sufficiently describe it. Fix it by adding missing command
documentation.

Fixes: 3a61c8db9d25 ("acpi: cpuhp: add CPHP_GET_CPU_ID_CMD command")
Signed-off-by: Igor Mammedov <address@hidden>
Reviewed-by: Laszlo Ersek <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 67b3965e89f8466fc6a61caa2142dd2c89257383
      
https://github.com/qemu/qemu/commit/67b3965e89f8466fc6a61caa2142dd2c89257383
  Author: Adrian Moreno <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/vhost-user.c

  Log Message:
  -----------
  vhost-user: only set slave channel for first vq

When multiqueue is enabled, a vhost_dev is created for each queue
pair. However, only one slave channel is needed.

Fixes: 4bbeeba023f2 (vhost-user: add slave-req-fd support)
Cc: address@hidden
Signed-off-by: Adrian Moreno <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: b844a4c77b618acfba6b3f4ce12d2ad709f99279
      
https://github.com/qemu/qemu/commit/b844a4c77b618acfba6b3f4ce12d2ad709f99279
  Author: Raphael Norwitz <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M hw/virtio/vhost-user.c

  Log Message:
  -----------
  Fixed assert in vhost_user_set_mem_table_postcopy

The current vhost_user_set_mem_table_postcopy() implementation
populates each region of the VHOST_USER_SET_MEM_TABLE message without
first checking if there are more than VHOST_MEMORY_MAX_NREGIONS already
populated. This can cause memory corruption if too many regions are
added to the message during the postcopy step.

This change moves an existing assert up such that attempting to
construct a VHOST_USER_SET_MEM_TABLE message with too many memory
regions will gracefully bring down qemu instead of corrupting memory.

Signed-off-by: Raphael Norwitz <address@hidden>
Signed-off-by: Peter Turschmid <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>


  Commit: 8b6b68e05b43f976714ca1d2afe01a64e1d82cba
      
https://github.com/qemu/qemu/commit/8b6b68e05b43f976714ca1d2afe01a64e1d82cba
  Author: Peter Maydell <address@hidden>
  Date:   2020-02-27 (Thu, 27 Feb 2020)

  Changed paths:
    M MAINTAINERS
    M contrib/libvhost-user/libvhost-user-glib.c
    M contrib/libvhost-user/libvhost-user-glib.h
    M contrib/libvhost-user/libvhost-user.c
    M contrib/libvhost-user/libvhost-user.h
    M contrib/vhost-user-input/main.c
    M docs/interop/vhost-user.rst
    M docs/specs/acpi_cpu_hotplug.txt
    M hw/arm/virt.c
    M hw/block/vhost-user-blk.c
    M hw/virtio/Kconfig
    M hw/virtio/Makefile.objs
    M hw/virtio/trace-events
    M hw/virtio/vhost-user-fs.c
    M hw/virtio/vhost-user.c
    M hw/virtio/virtio-crypto.c
    A hw/virtio/virtio-iommu-pci.c
    A hw/virtio/virtio-iommu.c
    M hw/virtio/virtio-pmem.c
    M hw/virtio/virtio.c
    M include/hw/arm/virt.h
    M include/hw/pci/pci.h
    M include/hw/virtio/vhost-user-blk.h
    M include/hw/virtio/vhost-user-fs.h
    A include/hw/virtio/virtio-iommu.h
    M qdev-monitor.c
    M tests/data/acpi/rebuild-expected-aml.sh
    M tests/qtest/bios-tables-test.c

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging

virtio, pc: fixes, features

New virtio iommu.
Unrealize memory leaks.
In-band kick/call support.
Bugfixes, documentation all over the place.

Signed-off-by: Michael S. Tsirkin <address@hidden>

# gpg: Signature made Thu 27 Feb 2020 08:46:33 GMT
# gpg:                using RSA key 5D09FD0871C8F85B94CA8A0D281F0DB8D28D5469
# gpg:                issuer "address@hidden"
# gpg: Good signature from "Michael S. Tsirkin <address@hidden>" [full]
# gpg:                 aka "Michael S. Tsirkin <address@hidden>" [full]
# Primary key fingerprint: 0270 606B 6F3C DF3D 0B17  0970 C350 3912 AFBE 8E67
#      Subkey fingerprint: 5D09 FD08 71C8 F85B 94CA  8A0D 281F 0DB8 D28D 5469

* remotes/mst/tags/for_upstream: (30 commits)
  Fixed assert in vhost_user_set_mem_table_postcopy
  vhost-user: only set slave channel for first vq
  acpi: cpuhp: document CPHP_GET_CPU_ID_CMD command
  libvhost-user: implement in-band notifications
  docs: vhost-user: add in-band kick/call messages
  libvhost-user: handle NOFD flag in call/kick/err better
  libvhost-user-glib: use g_main_context_get_thread_default()
  libvhost-user-glib: fix VugDev main fd cleanup
  libvhost-user: implement VHOST_USER_PROTOCOL_F_REPLY_ACK
  MAINTAINERS: add virtio-iommu related files
  hw/arm/virt: Add the virtio-iommu device tree mappings
  virtio-iommu-pci: Add virtio iommu pci support
  virtio-iommu: Support migration
  virtio-iommu: Implement fault reporting
  virtio-iommu: Implement translate
  virtio-iommu: Implement map/unmap
  virtio-iommu: Implement attach/detach command
  virtio-iommu: Decode the command payload
  virtio-iommu: Add skeleton
  virtio: gracefully handle invalid region caches
  ...

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/a7cfd219d5b9...8b6b68e05b43



reply via email to

[Prev in Thread] Current Thread [Next in Thread]