Re: [PATCH v1 0/5] Fix PF/VF dependency issues
From: Bjorn Helgaas
Date: Fri Apr 19 2019 - 14:29:18 EST
On Wed, Mar 06, 2019 at 02:11:13PM -0800, sathyanarayanan.kuppuswamy@xxxxxxxxxxxxxxx wrote:
> From: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@xxxxxxxxxxxxxxx>
>
> Current implementation of ATS, PASID, PRI does not handle the PF/VF
> dependencies as defined in PCIe spec r4.0. Following patches
> addresses this issue.
Some of these patches probably fix issues, like making PASID work
correctly on VFs. But that needs to be made explicit in the commit
logs.
The current commit logs read more like "make XYZ follow the spec",
and that's not really what we need to know. The commit log needs to
tell us why we need the change, not just what the spec says.
For example, maybe VFs can't use PASID because Linux incorrectly tries
to use the PASID capability on the VF when it should be using the
capability on the PF. The commit log should say that explicitly and
also say what the current behavior is, e.g., does it cause IOMMU
faults, does it cause data corruption, does some DMA mapping interface
called by the VF driver fail when it shouldn't, etc?
Bjorn
> Kuppuswamy Sathyanarayanan (5):
> PCI/IOV: Add support to verify PF/VF spec compliance
> PCI/ATS: Fix PRI PF/VF dependency issues
> PCI/ATS: Fix PASID PF/VF dependency issues
> PCI/ATS: For PF/VF skip ATS initalization if spec check failed
> PCI/ATS: Fix ATS PF/VF dependency issues
>
> .../admin-guide/kernel-parameters.txt | 2 +
> drivers/pci/ats.c | 129 ++++-
> drivers/pci/iov.c | 468 ++++++++++++++++++
> drivers/pci/pci.c | 2 +
> drivers/pci/pci.h | 6 +
> include/linux/pci.h | 33 +-
> include/uapi/linux/pci_regs.h | 15 +-
> 7 files changed, 639 insertions(+), 16 deletions(-)
>
> --
> 2.20.1
>