<feed xmlns='http://www.w3.org/2005/Atom'>
<title>bwlp/qemu.git/include/hw/vfio, branch spice_video_codecs</title>
<subtitle>Experimental fork of QEMU with video encoding patches</subtitle>
<id>https://git.openslx.org/bwlp/qemu.git/atom/include/hw/vfio?h=spice_video_codecs</id>
<link rel='self' href='https://git.openslx.org/bwlp/qemu.git/atom/include/hw/vfio?h=spice_video_codecs'/>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/'/>
<updated>2022-05-06T15:06:51+00:00</updated>
<entry>
<title>vfio/common: Rename VFIOGuestIOMMU::iommu into ::iommu_mr</title>
<updated>2022-05-06T15:06:51+00:00</updated>
<author>
<name>Yi Liu</name>
</author>
<published>2022-05-02T09:42:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=44ee6aaae0c937abb631e57a9853c2cdef2bc9bb'/>
<id>urn:sha1:44ee6aaae0c937abb631e57a9853c2cdef2bc9bb</id>
<content type='text'>
Rename VFIOGuestIOMMU iommu field into iommu_mr. Then it becomes clearer
it is an IOMMU memory region.

no functional change intended

Signed-off-by: Yi Liu &lt;yi.l.liu@intel.com&gt;
Link: https://lore.kernel.org/r/20220502094223.36384-4-yi.l.liu@intel.com
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Query and store the maximum number of possible DMA mappings</title>
<updated>2021-07-08T19:54:45+00:00</updated>
<author>
<name>David Hildenbrand</name>
</author>
<published>2021-04-13T09:55:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=3eed155caf0a9a6db1e140c01bd8f0300ac475ce'/>
<id>urn:sha1:3eed155caf0a9a6db1e140c01bd8f0300ac475ce</id>
<content type='text'>
Let's query the maximum number of possible DMA mappings by querying the
available mappings when creating the container (before any mappings are
created). We'll use this informaton soon to perform some sanity checks
and warn the user.

Reviewed-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Acked-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Acked-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Cc: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Cc: "Michael S. Tsirkin" &lt;mst@redhat.com&gt;
Cc: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Cc: Dr. David Alan Gilbert &lt;dgilbert@redhat.com&gt;
Cc: Igor Mammedov &lt;imammedo@redhat.com&gt;
Cc: Pankaj Gupta &lt;pankaj.gupta.linux@gmail.com&gt;
Cc: Peter Xu &lt;peterx@redhat.com&gt;
Cc: Auger Eric &lt;eric.auger@redhat.com&gt;
Cc: Wei Yang &lt;richard.weiyang@linux.alibaba.com&gt;
Cc: teawater &lt;teawaterz@linux.alibaba.com&gt;
Cc: Marek Kedzierski &lt;mkedzier@redhat.com&gt;
Signed-off-by: David Hildenbrand &lt;david@redhat.com&gt;
Message-Id: &lt;20210413095531.25603-8-david@redhat.com&gt;
Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Support for RamDiscardManager in the !vIOMMU case</title>
<updated>2021-07-08T19:54:45+00:00</updated>
<author>
<name>David Hildenbrand</name>
</author>
<published>2021-04-13T09:55:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=5e3b981c330c58c4e97ab85e40c3bd2ee54b2fa7'/>
<id>urn:sha1:5e3b981c330c58c4e97ab85e40c3bd2ee54b2fa7</id>
<content type='text'>
Implement support for RamDiscardManager, to prepare for virtio-mem
support. Instead of mapping the whole memory section, we only map
"populated" parts and update the mapping when notified about
discarding/population of memory via the RamDiscardListener. Similarly, when
syncing the dirty bitmaps, sync only the actually mapped (populated) parts
by replaying via the notifier.

Using virtio-mem with vfio is still blocked via
ram_block_discard_disable()/ram_block_discard_require() after this patch.

Reviewed-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Acked-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Acked-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Cc: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Cc: "Michael S. Tsirkin" &lt;mst@redhat.com&gt;
Cc: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Cc: Dr. David Alan Gilbert &lt;dgilbert@redhat.com&gt;
Cc: Igor Mammedov &lt;imammedo@redhat.com&gt;
Cc: Pankaj Gupta &lt;pankaj.gupta.linux@gmail.com&gt;
Cc: Peter Xu &lt;peterx@redhat.com&gt;
Cc: Auger Eric &lt;eric.auger@redhat.com&gt;
Cc: Wei Yang &lt;richard.weiyang@linux.alibaba.com&gt;
Cc: teawater &lt;teawaterz@linux.alibaba.com&gt;
Cc: Marek Kedzierski &lt;mkedzier@redhat.com&gt;
Signed-off-by: David Hildenbrand &lt;david@redhat.com&gt;
Message-Id: &lt;20210413095531.25603-7-david@redhat.com&gt;
Signed-off-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Change default dirty pages tracking behavior during migration</title>
<updated>2020-11-23T17:05:58+00:00</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2020-11-23T14:23:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=bb0990d1740f6dced5b50a923677034c9399c213'/>
<id>urn:sha1:bb0990d1740f6dced5b50a923677034c9399c213</id>
<content type='text'>
By default dirty pages tracking is enabled during iterative phase
(pre-copy phase).
Added per device opt-out option 'x-pre-copy-dirty-page-tracking' to
disable dirty pages tracking during iterative phase. If the option
'x-pre-copy-dirty-page-tracking=off' is set for any VFIO device, dirty
pages tracking during iterative phase will be disabled.

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Make migration support experimental</title>
<updated>2020-11-23T15:29:29+00:00</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2020-11-09T18:56:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=cf254988a50d4164c86a356c80b8d3ae0ccaa005'/>
<id>urn:sha1:cf254988a50d4164c86a356c80b8d3ae0ccaa005</id>
<content type='text'>
Support for migration of vfio devices is still in flux.  Developers
are attempting to add support for new devices and new architectures,
but none are yet readily available for validation.  We have concerns
whether we're transferring device resources at the right point in the
migration, whether we're guaranteeing that updates during pre-copy are
migrated, and whether we can provide bit-stream compatibility should
any of this change.  Even the question of whether devices should
participate in dirty page tracking during pre-copy seems contentious.
In short, migration support has not had enough soak time and it feels
premature to mark it as supported.

Create an experimental option such that we can continue to develop.

[Retaining previous acks/reviews for a previously identical code
 change with different specifics in the commit log.]

Reviewed-by: Dr. David Alan Gilbert &lt;dgilbert@redhat.com&gt;
Acked-by: Cornelia Huck &lt;cohuck@redhat.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Add routine for finding VFIO_DEVICE_GET_INFO capabilities</title>
<updated>2020-11-01T19:30:52+00:00</updated>
<author>
<name>Matthew Rosato</name>
</author>
<published>2020-10-26T15:34:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=92fe289ace3e559e2d18d0c2e49cdfb4cbd5a59b'/>
<id>urn:sha1:92fe289ace3e559e2d18d0c2e49cdfb4cbd5a59b</id>
<content type='text'>
Now that VFIO_DEVICE_GET_INFO supports capability chains, add a helper
function to find specific capabilities in the chain.

Signed-off-by: Matthew Rosato &lt;mjrosato@linux.ibm.com&gt;
Reviewed-by: Cornelia Huck &lt;cohuck@redhat.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Find DMA available capability</title>
<updated>2020-11-01T19:30:51+00:00</updated>
<author>
<name>Matthew Rosato</name>
</author>
<published>2020-10-26T15:34:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=7486a62845b1e12011dd99973e4739f69d57cd38'/>
<id>urn:sha1:7486a62845b1e12011dd99973e4739f69d57cd38</id>
<content type='text'>
The underlying host may be limiting the number of outstanding DMA
requests for type 1 IOMMU.  Add helper functions to check for the
DMA available capability and retrieve the current number of DMA
mappings allowed.

Signed-off-by: Matthew Rosato &lt;mjrosato@linux.ibm.com&gt;
Reviewed-by: Cornelia Huck &lt;cohuck@redhat.com&gt;
[aw: vfio_get_info_dma_avail moved inside CONFIG_LINUX]
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>qapi: Add VFIO devices migration stats in Migration stats</title>
<updated>2020-11-01T19:30:51+00:00</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2020-10-26T09:36:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=3710586caa5d91a52c0cf247e1c829a50f2e7b98'/>
<id>urn:sha1:3710586caa5d91a52c0cf247e1c829a50f2e7b98</id>
<content type='text'>
Added amount of bytes transferred to the VM at destination by all VFIO
devices

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Reviewed-by: Dr. David Alan Gilbert &lt;dgilbert@redhat.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Get migration capability flags for container</title>
<updated>2020-11-01T19:30:50+00:00</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2020-10-26T09:36:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=87ea529c5020124440cd892a038dffe6057fd613'/>
<id>urn:sha1:87ea529c5020124440cd892a038dffe6057fd613</id>
<content type='text'>
Added helper functions to get IOMMU info capability chain.
Added function to get migration capability information from that
capability chain for IOMMU container.

Similar change was proposed earlier:
https://lists.gnu.org/archive/html/qemu-devel/2018-05/msg03759.html

Disable migration for devices if IOMMU module doesn't support migration
capability.

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Cc: Shameer Kolothum &lt;shameerali.kolothum.thodi@huawei.com&gt;
Cc: Eric Auger &lt;eric.auger@redhat.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Add save state functions to SaveVMHandlers</title>
<updated>2020-11-01T19:30:50+00:00</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2020-10-26T09:36:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=1bc3c535ffbe512126a02b9f588497d5f5b7075b'/>
<id>urn:sha1:1bc3c535ffbe512126a02b9f588497d5f5b7075b</id>
<content type='text'>
Added .save_live_pending, .save_live_iterate and .save_live_complete_precopy
functions. These functions handles pre-copy and stop-and-copy phase.

In _SAVING|_RUNNING device state or pre-copy phase:
- read pending_bytes. If pending_bytes &gt; 0, go through below steps.
- read data_offset - indicates kernel driver to write data to staging
  buffer.
- read data_size - amount of data in bytes written by vendor driver in
  migration region.
- read data_size bytes of data from data_offset in the migration region.
- Write data packet to file stream as below:
{VFIO_MIG_FLAG_DEV_DATA_STATE, data_size, actual data,
VFIO_MIG_FLAG_END_OF_STATE }

In _SAVING device state or stop-and-copy phase
a. read config space of device and save to migration file stream. This
   doesn't need to be from vendor driver. Any other special config state
   from driver can be saved as data in following iteration.
b. read pending_bytes. If pending_bytes &gt; 0, go through below steps.
c. read data_offset - indicates kernel driver to write data to staging
   buffer.
d. read data_size - amount of data in bytes written by vendor driver in
   migration region.
e. read data_size bytes of data from data_offset in the migration region.
f. Write data packet as below:
   {VFIO_MIG_FLAG_DEV_DATA_STATE, data_size, actual data}
g. iterate through steps b to f while (pending_bytes &gt; 0)
h. Write {VFIO_MIG_FLAG_END_OF_STATE}

When data region is mapped, its user's responsibility to read data from
data_offset of data_size before moving to next steps.

Added fix suggested by Artem Polyakov to reset pending_bytes in
vfio_save_iterate().
Added fix suggested by Zhi Wang to add 0 as data size in migration stream and
add END_OF_STATE delimiter to indicate phase complete.

Suggested-by: Artem Polyakov &lt;artemp@nvidia.com&gt;
Suggested-by: Zhi Wang &lt;zhi.wang.linux@gmail.com&gt;
Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Reviewed-by: Neo Jia &lt;cjia@nvidia.com&gt;
Reviewed-by: Yan Zhao &lt;yan.y.zhao@intel.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
</feed>
