diff options
| author | Joerg Roedel <jroedel@suse.de> | 2019-04-26 09:48:52 -0400 |
|---|---|---|
| committer | Joerg Roedel <jroedel@suse.de> | 2019-04-26 09:48:52 -0400 |
| commit | 26ac2b6ee6c0902188316d16bc5ca9306d678f03 (patch) | |
| tree | 9664a3178d423866a37759ae33920ceeb9c377fe /include | |
| parent | 085b7755808aa11f78ab9377257e1dad2e6fa4bb (diff) | |
| parent | bc580b56cb7888d1f09fff8a50270228fb834ae8 (diff) | |
Merge branch 'for-joerg/arm-smmu/updates' of git://git.kernel.org/pub/scm/linux/kernel/git/will/linux into arm/smmu
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/iommu.h | 4 | ||||
| -rw-r--r-- | include/linux/pci.h | 31 |
2 files changed, 20 insertions, 15 deletions
diff --git a/include/linux/iommu.h b/include/linux/iommu.h index ffbbc7e39cee..6c1b4c900191 100644 --- a/include/linux/iommu.h +++ b/include/linux/iommu.h | |||
| @@ -392,10 +392,14 @@ struct iommu_fwspec { | |||
| 392 | const struct iommu_ops *ops; | 392 | const struct iommu_ops *ops; |
| 393 | struct fwnode_handle *iommu_fwnode; | 393 | struct fwnode_handle *iommu_fwnode; |
| 394 | void *iommu_priv; | 394 | void *iommu_priv; |
| 395 | u32 flags; | ||
| 395 | unsigned int num_ids; | 396 | unsigned int num_ids; |
| 396 | u32 ids[1]; | 397 | u32 ids[1]; |
| 397 | }; | 398 | }; |
| 398 | 399 | ||
| 400 | /* ATS is supported */ | ||
| 401 | #define IOMMU_FWSPEC_PCI_RC_ATS (1 << 0) | ||
| 402 | |||
| 399 | int iommu_fwspec_init(struct device *dev, struct fwnode_handle *iommu_fwnode, | 403 | int iommu_fwspec_init(struct device *dev, struct fwnode_handle *iommu_fwnode, |
| 400 | const struct iommu_ops *ops); | 404 | const struct iommu_ops *ops); |
| 401 | void iommu_fwspec_free(struct device *dev); | 405 | void iommu_fwspec_free(struct device *dev); |
diff --git a/include/linux/pci.h b/include/linux/pci.h index 77448215ef5b..61d7cd888bad 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
| @@ -1521,21 +1521,6 @@ static inline void pcie_ecrc_get_policy(char *str) { } | |||
| 1521 | 1521 | ||
| 1522 | bool pci_ats_disabled(void); | 1522 | bool pci_ats_disabled(void); |
| 1523 | 1523 | ||
| 1524 | #ifdef CONFIG_PCI_ATS | ||
| 1525 | /* Address Translation Service */ | ||
| 1526 | void pci_ats_init(struct pci_dev *dev); | ||
| 1527 | int pci_enable_ats(struct pci_dev *dev, int ps); | ||
| 1528 | void pci_disable_ats(struct pci_dev *dev); | ||
| 1529 | int pci_ats_queue_depth(struct pci_dev *dev); | ||
| 1530 | int pci_ats_page_aligned(struct pci_dev *dev); | ||
| 1531 | #else | ||
| 1532 | static inline void pci_ats_init(struct pci_dev *d) { } | ||
| 1533 | static inline int pci_enable_ats(struct pci_dev *d, int ps) { return -ENODEV; } | ||
| 1534 | static inline void pci_disable_ats(struct pci_dev *d) { } | ||
| 1535 | static inline int pci_ats_queue_depth(struct pci_dev *d) { return -ENODEV; } | ||
| 1536 | static inline int pci_ats_page_aligned(struct pci_dev *dev) { return 0; } | ||
| 1537 | #endif | ||
| 1538 | |||
| 1539 | #ifdef CONFIG_PCIE_PTM | 1524 | #ifdef CONFIG_PCIE_PTM |
| 1540 | int pci_enable_ptm(struct pci_dev *dev, u8 *granularity); | 1525 | int pci_enable_ptm(struct pci_dev *dev, u8 *granularity); |
| 1541 | #else | 1526 | #else |
| @@ -1728,8 +1713,24 @@ static inline int pci_irqd_intx_xlate(struct irq_domain *d, | |||
| 1728 | static inline const struct pci_device_id *pci_match_id(const struct pci_device_id *ids, | 1713 | static inline const struct pci_device_id *pci_match_id(const struct pci_device_id *ids, |
| 1729 | struct pci_dev *dev) | 1714 | struct pci_dev *dev) |
| 1730 | { return NULL; } | 1715 | { return NULL; } |
| 1716 | static inline bool pci_ats_disabled(void) { return true; } | ||
| 1731 | #endif /* CONFIG_PCI */ | 1717 | #endif /* CONFIG_PCI */ |
| 1732 | 1718 | ||
| 1719 | #ifdef CONFIG_PCI_ATS | ||
| 1720 | /* Address Translation Service */ | ||
| 1721 | void pci_ats_init(struct pci_dev *dev); | ||
| 1722 | int pci_enable_ats(struct pci_dev *dev, int ps); | ||
| 1723 | void pci_disable_ats(struct pci_dev *dev); | ||
| 1724 | int pci_ats_queue_depth(struct pci_dev *dev); | ||
| 1725 | int pci_ats_page_aligned(struct pci_dev *dev); | ||
| 1726 | #else | ||
| 1727 | static inline void pci_ats_init(struct pci_dev *d) { } | ||
| 1728 | static inline int pci_enable_ats(struct pci_dev *d, int ps) { return -ENODEV; } | ||
| 1729 | static inline void pci_disable_ats(struct pci_dev *d) { } | ||
| 1730 | static inline int pci_ats_queue_depth(struct pci_dev *d) { return -ENODEV; } | ||
| 1731 | static inline int pci_ats_page_aligned(struct pci_dev *dev) { return 0; } | ||
| 1732 | #endif | ||
| 1733 | |||
| 1733 | /* Include architecture-dependent settings and functions */ | 1734 | /* Include architecture-dependent settings and functions */ |
| 1734 | 1735 | ||
| 1735 | #include <asm/pci.h> | 1736 | #include <asm/pci.h> |
