[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 10 Oct 2019 16:07:32 -0700
From: Kuppuswamy Sathyanarayanan
<sathyanarayanan.kuppuswamy@...ux.intel.com>
To: Bjorn Helgaas <helgaas@...nel.org>, linux-pci@...r.kernel.org
Cc: Ashok Raj <ashok.raj@...el.com>,
Keith Busch <keith.busch@...el.com>,
linux-kernel@...r.kernel.org,
David Woodhouse <dwmw2@...radead.org>,
Joerg Roedel <joro@...tes.org>,
iommu@...ts.linux-foundation.org,
Krzysztof Wilczynski <kw@...ux.com>,
Bjorn Helgaas <bhelgaas@...gle.com>
Subject: Re: [PATCH 1/3] PCI/ATS: Remove unused PRI and PASID stubs
On 10/9/19 3:53 PM, Bjorn Helgaas wrote:
> From: Bjorn Helgaas <bhelgaas@...gle.com>
>
> The following functions are only used by amd_iommu.c and intel-iommu.c
> (when CONFIG_INTEL_IOMMU_SVM is enabled). CONFIG_PCI_PRI and
> CONFIG_PCI_PASID are always defined in those cases, so there's no need for
> the stubs.
>
> pci_enable_pri()
> pci_disable_pri()
> pci_reset_pri()
> pci_prg_resp_pasid_required()
> pci_enable_pasid()
> pci_disable_pasid()
>
> Remove the unused stubs.
>
> Signed-off-by: Bjorn Helgaas <bhelgaas@...gle.com>
Looks good to me.
Reviewed-by: Kuppuswamy Sathyanarayanan
<sathyanarayanan.kuppuswamy@...ux.intel.com>
> ---
> include/linux/pci-ats.h | 10 ----------
> 1 file changed, 10 deletions(-)
>
> diff --git a/include/linux/pci-ats.h b/include/linux/pci-ats.h
> index 67de3a9499bb..963c11f7c56b 100644
> --- a/include/linux/pci-ats.h
> +++ b/include/linux/pci-ats.h
> @@ -27,14 +27,7 @@ void pci_restore_pri_state(struct pci_dev *pdev);
> int pci_reset_pri(struct pci_dev *pdev);
> int pci_prg_resp_pasid_required(struct pci_dev *pdev);
> #else /* CONFIG_PCI_PRI */
> -static inline int pci_enable_pri(struct pci_dev *pdev, u32 reqs)
> -{ return -ENODEV; }
> -static inline void pci_disable_pri(struct pci_dev *pdev) { }
> static inline void pci_restore_pri_state(struct pci_dev *pdev) { }
> -static inline int pci_reset_pri(struct pci_dev *pdev)
> -{ return -ENODEV; }
> -static inline int pci_prg_resp_pasid_required(struct pci_dev *pdev)
> -{ return 0; }
> #endif /* CONFIG_PCI_PRI */
>
> #ifdef CONFIG_PCI_PASID
> @@ -44,9 +37,6 @@ void pci_restore_pasid_state(struct pci_dev *pdev);
> int pci_pasid_features(struct pci_dev *pdev);
> int pci_max_pasids(struct pci_dev *pdev);
> #else /* CONFIG_PCI_PASID */
> -static inline int pci_enable_pasid(struct pci_dev *pdev, int features)
> -{ return -EINVAL; }
> -static inline void pci_disable_pasid(struct pci_dev *pdev) { }
> static inline void pci_restore_pasid_state(struct pci_dev *pdev) { }
> static inline int pci_pasid_features(struct pci_dev *pdev)
> { return -EINVAL; }
--
Sathyanarayanan Kuppuswamy
Linux kernel developer
Powered by blists - more mailing lists