<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/vfio/vfio.c, branch linux-4.10.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.10.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.10.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2017-03-30T07:44:08Z</updated>
<entry>
<title>vfio: Rework group release notifier warning</title>
<updated>2017-03-30T07:44:08Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2017-03-21T19:19:09Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8b0219e35b43cb6ceb592a1fb35af5a9d5d91b5d'/>
<id>urn:sha1:8b0219e35b43cb6ceb592a1fb35af5a9d5d91b5d</id>
<content type='text'>
commit 65b1adebfe43c642dfe3b109edb5d992db5fbe72 upstream.

The intent of the original warning is make sure that the mdev vendor
driver has removed any group notifiers at the point where the group
is closed by the user.  Theoretically this would be through an
orderly shutdown where any devices are release prior to the group
release.  We can't always count on an orderly shutdown, the user can
close the group before the notifier can be removed or the user task
might be killed.  We'd like to add this sanity test when the group is
idle and the only references are from the devices within the group
themselves, but we don't have a good way to do that.  Instead check
both when the group itself is removed and when the group is opened.
A bit later than we'd prefer, but better than the current over
aggressive approach.

Fixes: ccd46dbae77d ("vfio: support notifier chain in vfio_group")
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Cc: Jike Song &lt;jike.song@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>vfio: support notifier chain in vfio_group</title>
<updated>2016-12-01T17:40:05Z</updated>
<author>
<name>Jike Song</name>
</author>
<published>2016-12-01T05:20:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ccd46dbae77dbf0d33f42e04b59536f108c395e8'/>
<id>urn:sha1:ccd46dbae77dbf0d33f42e04b59536f108c395e8</id>
<content type='text'>
Beyond vfio_iommu events, users might also be interested in
vfio_group events. For example, if a vfio_group is used along
with Qemu/KVM, whenever kvm pointer is set to/cleared from the
vfio_group, users could be notified.

Currently only VFIO_GROUP_NOTIFY_SET_KVM supported.

Cc: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Cc: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Cc: Xiao Guangrong &lt;guangrong.xiao@linux.intel.com&gt;
Signed-off-by: Jike Song &lt;jike.song@intel.com&gt;
[aw: remove use of new typedef]
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: vfio_register_notifier: classify iommu notifier</title>
<updated>2016-12-01T16:38:47Z</updated>
<author>
<name>Jike Song</name>
</author>
<published>2016-12-01T05:20:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=22195cbd3451a75abaf30651a61cf85c89061327'/>
<id>urn:sha1:22195cbd3451a75abaf30651a61cf85c89061327</id>
<content type='text'>
Currently vfio_register_notifier assumes that there is only one
notifier chain, which is in vfio_iommu. However, the user might
also be interested in events other than vfio_iommu, for example,
vfio_group. Refactor vfio_{un}register_notifier implementation
to make it feasible.

Cc: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Cc: Xiao Guangrong &lt;guangrong.xiao@linux.intel.com&gt;
Reviewed-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Signed-off-by: Jike Song &lt;jike.song@intel.com&gt;
[aw: merge with commit 816ca69ea9c7 ("vfio: Fix handling of error returned by 'vfio_group_get_from_dev()'"), remove typedef]
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Fix handling of error returned by 'vfio_group_get_from_dev()'</title>
<updated>2016-12-01T15:45:49Z</updated>
<author>
<name>Christophe JAILLET</name>
</author>
<published>2016-11-30T07:06:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d256459fae4dba66d50850f2d948306503818913'/>
<id>urn:sha1:d256459fae4dba66d50850f2d948306503818913</id>
<content type='text'>
'vfio_group_get_from_dev()' seems to return only NULL on error, not an
error pointer.

Fixes: 2169037dc322 ("vfio iommu: Added pin and unpin callback functions to vfio_iommu_driver_ops")
Fixes: c086de818dd8 ("vfio iommu: Add blocking notifier to notify DMA_UNMAP")
Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Reported-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: fix vfio_info_cap_add/shift</title>
<updated>2016-11-21T18:51:53Z</updated>
<author>
<name>Eric Auger</name>
</author>
<published>2016-11-21T06:21:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5ba6de98c78ac45166036516e34bec487887ba5d'/>
<id>urn:sha1:5ba6de98c78ac45166036516e34bec487887ba5d</id>
<content type='text'>
Capability header next field is an offset relative to the start of
the INFO buffer. tmp-&gt;next is assigned the proper value but iterations
implemented in vfio_info_cap_add and vfio_info_cap_shift use next
as an offset between the headers. When coping with multiple capabilities
this leads to an Oops.

Signed-off-by: Eric Auger &lt;eric.auger@redhat.com&gt;
Reviewed-by: David Hildenbrand &lt;david@redhat.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Introduce vfio_set_irqs_validate_and_prepare()</title>
<updated>2016-11-17T15:33:20Z</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2016-11-16T20:46:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c747f08aea847c8c0704acf9375ca83c4800f6c1'/>
<id>urn:sha1:c747f08aea847c8c0704acf9375ca83c4800f6c1</id>
<content type='text'>
Vendor driver using mediated device framework would use same mechnism to
validate and prepare IRQs. Introducing this function to reduce code
replication in multiple drivers.

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Signed-off-by: Neo Jia &lt;cjia@nvidia.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Introduce common function to add capabilities</title>
<updated>2016-11-17T15:33:20Z</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2016-11-16T20:46:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b3c0a866f1692da2d1059dadd9c429ff5b364fc9'/>
<id>urn:sha1:b3c0a866f1692da2d1059dadd9c429ff5b364fc9</id>
<content type='text'>
Vendor driver using mediated device framework should use
vfio_info_add_capability() to add capabilities.
Introduced this function to reduce code duplication in vendor drivers.

vfio_info_cap_shift() manipulated a data buffer to add an offset to each
element in a chain. This data buffer is documented in a uapi header.
Changing vfio_info_cap_shift symbol to be available to all drivers.

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Signed-off-by: Neo Jia &lt;cjia@nvidia.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio iommu: Add blocking notifier to notify DMA_UNMAP</title>
<updated>2016-11-17T15:33:07Z</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2016-11-17T04:58:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c086de818dd81c3c2f7cecff23de6585b74340c0'/>
<id>urn:sha1:c086de818dd81c3c2f7cecff23de6585b74340c0</id>
<content type='text'>
Added blocking notifier to IOMMU TYPE1 driver to notify vendor drivers
about DMA_UNMAP.
Exported two APIs vfio_register_notifier() and vfio_unregister_notifier().
Notifier should be registered, if external user wants to use
vfio_pin_pages()/vfio_unpin_pages() APIs to pin/unpin pages.
Vendor driver should use VFIO_IOMMU_NOTIFY_DMA_UNMAP action to invalidate
mappings.

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Signed-off-by: Neo Jia &lt;cjia@nvidia.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio iommu: Added pin and unpin callback functions to vfio_iommu_driver_ops</title>
<updated>2016-11-17T15:24:58Z</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2016-11-16T20:46:17Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2169037dc322d8baa84d9bd4468995f818f25d82'/>
<id>urn:sha1:2169037dc322d8baa84d9bd4468995f818f25d82</id>
<content type='text'>
Added APIs for pining and unpining set of pages. These call back into
backend iommu module to actually pin and unpin pages.
Added two new callback functions to struct vfio_iommu_driver_ops. Backend
IOMMU module that supports pining and unpinning pages for mdev devices
should provide these functions.

Renamed static functions in vfio_type1_iommu.c to resolve conflicts

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Signed-off-by: Neo Jia &lt;cjia@nvidia.com&gt;
Reviewed-by: Dong Jia Shi &lt;bjsdjshi@linux.vnet.ibm.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Common function to increment container_users</title>
<updated>2016-11-17T15:24:55Z</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2016-11-16T20:46:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=32f55d835b23830bf9295d038a1693ce9fd41b56'/>
<id>urn:sha1:32f55d835b23830bf9295d038a1693ce9fd41b56</id>
<content type='text'>
This change rearrange functions to have common function to increment
container_users

Signed-off-by: Kirti Wankhede &lt;kwankhede@nvidia.com&gt;
Signed-off-by: Neo Jia &lt;cjia@nvidia.com&gt;
Reviewed-by: Jike Song &lt;jike.song@intel.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
</feed>
