<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/vfio/pci, branch linux-3.17.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.17.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.17.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2014-10-30T16:43:13Z</updated>
<entry>
<title>vfio-pci: Fix remove path locking</title>
<updated>2014-10-30T16:43:13Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2014-09-29T23:18:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b6975072a1b9a2f8c527f8f9043dc86cfb70fc6a'/>
<id>urn:sha1:b6975072a1b9a2f8c527f8f9043dc86cfb70fc6a</id>
<content type='text'>
commit 93899a679fd6b2534b5c297d9316bae039ebcbe1 upstream.

Locking both the remove() and release() path results in a deadlock
that should have been obvious.  To fix this we can get and hold the
vfio_device reference as we evaluate whether to do a bus/slot reset.
This will automatically block any remove() calls, allowing us to
remove the explict lock.  Fixes 61d792562b53.

Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>drivers/vfio: Enable VFIO if EEH is not supported</title>
<updated>2014-08-08T16:39:16Z</updated>
<author>
<name>Alexey Kardashevskiy</name>
</author>
<published>2014-08-08T16:39:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9b936c960f22954bfb89f2fefd8f96916bb42908'/>
<id>urn:sha1:9b936c960f22954bfb89f2fefd8f96916bb42908</id>
<content type='text'>
The existing vfio_pci_open() fails upon error returned from
vfio_spapr_pci_eeh_open(), which breaks POWER7's P5IOC2 PHB
support which this patch brings back.

The patch fixes the issue by dropping the return value of
vfio_spapr_pci_eeh_open().

Signed-off-by: Alexey Kardashevskiy &lt;aik@ozlabs.ru&gt;
Signed-off-by: Gavin Shan &lt;gwshan@linux.vnet.ibm.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio-pci: Attempt bus/slot reset on release</title>
<updated>2014-08-07T17:12:07Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2014-08-07T17:12:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bc4fba77124e2fe4eb14bcb52875c0b0228deace'/>
<id>urn:sha1:bc4fba77124e2fe4eb14bcb52875c0b0228deace</id>
<content type='text'>
Each time a device is released, mark whether a local reset was
successful or whether a bus/slot reset is needed.  If a reset is
needed and all of the affected devices are bound to vfio-pci and
unused, allow the reset.  This is most useful when the userspace
driver is killed and releases all the devices in an unclean state,
such as when a QEMU VM quits.

Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio-pci: Use mutex around open, release, and remove</title>
<updated>2014-08-07T17:12:04Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2014-08-07T17:12:04Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=61d792562b53c610f9fe917f2bbc22218aa39c22'/>
<id>urn:sha1:61d792562b53c610f9fe917f2bbc22218aa39c22</id>
<content type='text'>
Serializing open/release allows us to fix a refcnt error if we fail
to enable the device and lets us prevent devices from being unbound
or opened, giving us an opportunity to do bus resets on release.  No
restriction added to serialize binding devices to vfio-pci while the
mutex is held though.

Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio-pci: Release devices with BusMaster disabled</title>
<updated>2014-08-07T17:12:02Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2014-08-07T17:12:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9c22e660ce8105debb497933b9900eaeb40836d2'/>
<id>urn:sha1:9c22e660ce8105debb497933b9900eaeb40836d2</id>
<content type='text'>
Our current open/release path looks like this:

vfio_pci_open
  vfio_pci_enable
    pci_enable_device
    pci_save_state
    pci_store_saved_state

vfio_pci_release
  vfio_pci_disable
    pci_disable_device
    pci_restore_state

pci_enable_device() doesn't modify PCI_COMMAND_MASTER, so if a device
comes to us with it enabled, it persists through the open and gets
stored as part of the device saved state.  We then restore that saved
state when released, which can allow the device to attempt to continue
to do DMA.  When the group is disconnected from the domain, this will
get caught by the IOMMU, but if there are other devices in the group,
the device may continue running and interfere with the user.  Even in
the former case, IOMMUs don't necessarily behave well and a stream of
blocked DMA can result in unpleasant behavior on the host.

Explicitly disable Bus Master as we're enabling the device and
slightly re-work release to make sure that pci_disable_device() is
the last thing that touches the device.

Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>drivers/vfio: EEH support for VFIO PCI device</title>
<updated>2014-08-05T05:28:48Z</updated>
<author>
<name>Gavin Shan</name>
</author>
<published>2014-06-10T01:41:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1b69be5e8afc634f39ad695a6ab6aad0cf0975c7'/>
<id>urn:sha1:1b69be5e8afc634f39ad695a6ab6aad0cf0975c7</id>
<content type='text'>
The patch adds new IOCTL commands for sPAPR VFIO container device
to support EEH functionality for PCI devices, which have been passed
through from host to somebody else via VFIO.

Signed-off-by: Gavin Shan &lt;gwshan@linux.vnet.ibm.com&gt;
Acked-by: Alexander Graf &lt;agraf@suse.de&gt;
Acked-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
</content>
</entry>
<entry>
<title>drivers/vfio/pci: Fix wrong MSI interrupt count</title>
<updated>2014-05-30T17:35:54Z</updated>
<author>
<name>Gavin Shan</name>
</author>
<published>2014-05-30T17:35:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=fd49c81f080a997aad4b0e73541cd42772b6a772'/>
<id>urn:sha1:fd49c81f080a997aad4b0e73541cd42772b6a772</id>
<content type='text'>
According PCI local bus specification, the register of Message
Control for MSI (offset: 2, length: 2) has bit#0 to enable or
disable MSI logic and it shouldn't be part contributing to the
calculation of MSI interrupt count. The patch fixes the issue.

Signed-off-by: Gavin Shan &lt;gwshan@linux.vnet.ibm.com&gt;
Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio/pci: Fix unchecked return value</title>
<updated>2014-05-30T17:35:53Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2014-05-30T17:35:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=eb5685f0de4702e44a8b262f1acaea52ef99271a'/>
<id>urn:sha1:eb5685f0de4702e44a8b262f1acaea52ef99271a</id>
<content type='text'>
There's nothing we can do different if pci_load_and_free_saved_state()
fails, other than maybe print some log message, but the actual re-load
of the state is an unnecessary step here since we've only just saved
it.  We can cleanup a coverity warning and eliminate the unnecessary
step by freeing the state ourselves.

Detected by Coverity: CID 753101

Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio/pci: Fix sizing of DPA and THP express capabilities</title>
<updated>2014-05-30T16:50:31Z</updated>
<author>
<name>Alex Williamson</name>
</author>
<published>2014-05-30T16:50:31Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=afa63252b2ab85614929405971105c3b20d675ba'/>
<id>urn:sha1:afa63252b2ab85614929405971105c3b20d675ba</id>
<content type='text'>
When sizing the TPH capability we store the register containing the
table size into the 'dword' variable, but then use the uninitialized
'byte' variable to analyze the size.  The table size is also actually
reported as an N-1 value, so correct sizing to account for this.

The round_up() for both TPH and DPA is unnecessary, remove it.

Detected by Coverity: CID 714665 &amp; 715156

Signed-off-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;
</content>
</entry>
<entry>
<title>vfio: Use pci_enable_msi_range() and pci_enable_msix_range()</title>
<updated>2014-02-14T21:23:40Z</updated>
<author>
<name>Alexander Gordeev</name>
</author>
<published>2014-01-17T16:02:21Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=94cccde648d32abe61e2d0d1b18178f3027f1a78'/>
<id>urn:sha1:94cccde648d32abe61e2d0d1b18178f3027f1a78</id>
<content type='text'>
pci_enable_msix() and pci_enable_msi_block() have been deprecated; use
pci_enable_msix_range() and pci_enable_msi_range() instead.

[bhelgaas: changelog]
Signed-off-by: Alexander Gordeev &lt;agordeev@redhat.com&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Acked-by: Alex Williamson &lt;alex.williamson@redhat.com&gt;</content>
</entry>
</feed>
