<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/vfio/vfio.c, branch linux-5.9.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.9.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.9.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2020-10-29T09:11:54Z</updated>
<entry>
<title>vfio: fix a missed vfio group put in vfio_pin_pages</title>
<updated>2020-10-29T09:11:54Z</updated>
<author>
<name>Yan Zhao</name>
</author>
<published>2020-09-16T02:29:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=cb924410c3a1629122f01d05552814891d96d337'/>
<id>urn:sha1:cb924410c3a1629122f01d05552814891d96d337</id>
<content type='text'>
[ Upstream commit 28b130244061863cf0437b7af1625fb45ec1a71e ]

When error occurs, need to put vfio group after a successful get.

Fixes: 95fc87b44104 ("vfio: Selective dirty page tracking if IOMMU backed device pins pages")
Signed-off-by: Yan Zhao &lt;yan.y.zhao@intel.com&gt;
Reviewed-by: Cornelia Huck &lt;cohuck@redhat.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>vfio: add a singleton check for vfio_group_pin_pages</title>
<updated>2020-10-29T09:11:53Z</updated>
<author>
<name>Yan Zhao</name>
</author>
<published>2020-09-16T02:28:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9a15e9921f9eb9137eb48bd96ae33497043fc82e'/>
<id>urn:sha1:9a15e9921f9eb9137eb48bd96ae33497043fc82e</id>
<content type='text'>
[ Upstream commit 7ef32e52368f62a4e041a4f0abefb4fb64e7fd4a ]

Page pinning is used both to translate and pin device mappings for DMA
purpose, as well as to indicate to the IOMMU backend to limit the dirty
page scope to those pages that have been pinned, in the case of an IOMMU
backed device.
To support this, the vfio_pin_pages() interface limits itself to only
singleton groups such that the IOMMU backend can consider dirty page
scope only at the group level.  Implement the same requirement for the
vfio_group_pin_pages() interface.

Fixes: 95fc87b44104 ("vfio: Selective dirty page tracking if IOMMU backed device pins pages")
Signed-off-by: Yan Zhao &lt;yan.y.zhao@intel.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>vfio: Cleanup allowed driver naming</title>
<updated>2020-07-27T19:43:36Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2020-07-27T19:43:36Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=26afdd98821bd36e4e1de88dd00a8c70d83accdf'/>
<id>urn:sha1:26afdd98821bd36e4e1de88dd00a8c70d83accdf</id>
<content type='text'>
No functional change, avoid non-inclusive naming schemes.

Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Selective dirty page tracking if IOMMU backed device pins pages</title>
<updated>2020-05-28T21:53:29Z</updated>
<author>
<name>Kirti Wankhede</name>
</author>
<published>2020-05-28T20:30:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=95fc87b44104d9a524ff3e975bbfbd7c1f1a2dd5'/>
<id>urn:sha1:95fc87b44104d9a524ff3e975bbfbd7c1f1a2dd5</id>
<content type='text'>
Added a check such that only singleton IOMMU groups can pin pages.
&gt;From the point when vendor driver pins any pages, consider IOMMU group
dirty page scope to be limited to pinned pages.

To optimize to avoid walking list often, added flag
pinned_page_dirty_scope to indicate if all of the vfio_groups for each
vfio_domain in the domain_list dirty page scope is limited to pinned
pages. This flag is updated on first pinned pages request for that IOMMU
group and on attaching/detaching group.

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>
<entry>
<title>Merge branches 'v5.7/vfio/alex-sriov-v3' and 'v5.7/vfio/yan-dma-rw-v4' into v5.7/vfio/next</title>
<updated>2020-03-24T15:32:41Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2020-03-24T15:32:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=48219795e7dbd3d4850f5bf47fa3e37c9c2a561b'/>
<id>urn:sha1:48219795e7dbd3d4850f5bf47fa3e37c9c2a561b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>vfio: Include optional device match in vfio_device_ops callbacks</title>
<updated>2020-03-24T15:28:25Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2020-03-24T15:28:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5f3874c2a2310d9bd6969ca6764961d27a843b9d'/>
<id>urn:sha1:5f3874c2a2310d9bd6969ca6764961d27a843b9d</id>
<content type='text'>
Allow bus drivers to provide their own callback to match a device to
the user provided string.

Reviewed-by: Cornelia Huck &lt;cohuck@redhat.com&gt;
Reviewed-by: Kevin Tian &lt;kevin.tian@intel.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: avoid inefficient operations on VFIO group in vfio_pin/unpin_pages</title>
<updated>2020-03-24T15:27:57Z</updated>
<author>
<name>Yan Zhao</name>
</author>
<published>2020-03-24T15:27:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=40280cf7e8ca7d31bb0a9d626f36f458fec32815'/>
<id>urn:sha1:40280cf7e8ca7d31bb0a9d626f36f458fec32815</id>
<content type='text'>
vfio_group_pin_pages() and vfio_group_unpin_pages() are introduced to
avoid inefficient search/check/ref/deref opertions associated with VFIO
group as those in each calling into vfio_pin_pages() and
vfio_unpin_pages().

VFIO group is taken as arg directly. The callers combine
search/check/ref/deref operations associated with VFIO group by calling
vfio_group_get_external_user()/vfio_group_get_external_user_from_dev()
beforehand, and vfio_group_put_external_user() afterwards.

Suggested-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Signed-off-by: Yan Zhao &lt;yan.y.zhao@intel.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: introduce vfio_dma_rw to read/write a range of IOVAs</title>
<updated>2020-03-24T15:27:57Z</updated>
<author>
<name>Yan Zhao</name>
</author>
<published>2020-03-24T15:27:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8d46c0cca5f4dc0538173d62cd36b1119b5105bc'/>
<id>urn:sha1:8d46c0cca5f4dc0538173d62cd36b1119b5105bc</id>
<content type='text'>
vfio_dma_rw will read/write a range of user space memory pointed to by
IOVA into/from a kernel buffer without enforcing pinning the user space
memory.

TODO: mark the IOVAs to user space memory dirty if they are written in
vfio_dma_rw().

Cc: Kevin Tian &lt;kevin.tian@intel.com&gt;
Signed-off-by: Yan Zhao &lt;yan.y.zhao@intel.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: allow external user to get vfio group from device</title>
<updated>2020-03-24T15:27:56Z</updated>
<author>
<name>Yan Zhao</name>
</author>
<published>2020-03-24T15:27:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c0560f51cf77472f4ed113539b0a02ca6cda7961'/>
<id>urn:sha1:c0560f51cf77472f4ed113539b0a02ca6cda7961</id>
<content type='text'>
external user calls vfio_group_get_external_user_from_dev() with a device
pointer to get the VFIO group associated with this device.
The VFIO group is checked to be vialbe and have IOMMU set. Then
container user counter is increased and VFIO group reference is hold
to prevent the VFIO group from disposal before external user exits.

when the external user finishes using of the VFIO group, it calls
vfio_group_put_external_user() to dereference the VFIO group and the
container user counter.

Suggested-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Signed-off-by: Yan Zhao &lt;yan.y.zhao@intel.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>compat_ioctl: move drivers to compat_ptr_ioctl</title>
<updated>2019-10-23T15:23:43Z</updated>
<author>
<name>Arnd Bergmann</name>
</author>
<published>2018-09-11T15:23:00Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=407e9ef72476e64937ebec44cc835e03a25fb408'/>
<id>urn:sha1:407e9ef72476e64937ebec44cc835e03a25fb408</id>
<content type='text'>
Each of these drivers has a copy of the same trivial helper function to
convert the pointer argument and then call the native ioctl handler.

We now have a generic implementation of that, so use it.

Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Acked-by: Michael S. Tsirkin &lt;mst@redhat.com&gt;
Acked-by: David S. Miller &lt;davem@davemloft.net&gt;
Acked-by: Jarkko Sakkinen &lt;jarkko.sakkinen@linux.intel.com&gt;
Reviewed-by: Jarkko Sakkinen &lt;jarkko.sakkinen@linux.intel.com&gt;
Reviewed-by: Jason Gunthorpe &lt;jgg@mellanox.com&gt;
Reviewed-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
Reviewed-by: Stefan Hajnoczi &lt;stefanha@redhat.com&gt;
Reviewed-by: Cornelia Huck &lt;cohuck@redhat.com&gt;
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
</content>
</entry>
</feed>
