Thomas Gleixner | d2912cb | 2019-06-04 10:11:33 +0200 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
Tony Lindgren | c8d35c8 | 2012-11-02 12:24:03 -0700 | [diff] [blame] | 2 | /* |
| 3 | * omap iommu: simple virtual address space management |
| 4 | * |
| 5 | * Copyright (C) 2008-2009 Nokia Corporation |
| 6 | * |
| 7 | * Written by Hiroshi DOYU <[email protected]> |
Tony Lindgren | c8d35c8 | 2012-11-02 12:24:03 -0700 | [diff] [blame] | 8 | */ |
| 9 | |
Laurent Pinchart | baaa7b5d | 2014-07-18 12:49:55 +0200 | [diff] [blame] | 10 | #ifndef _OMAP_IOMMU_H_ |
| 11 | #define _OMAP_IOMMU_H_ |
Tony Lindgren | c8d35c8 | 2012-11-02 12:24:03 -0700 | [diff] [blame] | 12 | |
Suman Anna | d9c4d8a6 | 2019-08-07 11:26:50 +0300 | [diff] [blame] | 13 | struct iommu_domain; |
| 14 | |
Mauro Carvalho Chehab | c7f1770 | 2018-04-05 10:54:14 -0400 | [diff] [blame] | 15 | #ifdef CONFIG_OMAP_IOMMU |
Tony Lindgren | c8d35c8 | 2012-11-02 12:24:03 -0700 | [diff] [blame] | 16 | extern void omap_iommu_save_ctx(struct device *dev); |
| 17 | extern void omap_iommu_restore_ctx(struct device *dev); |
Suman Anna | d9c4d8a6 | 2019-08-07 11:26:50 +0300 | [diff] [blame] | 18 | |
| 19 | int omap_iommu_domain_deactivate(struct iommu_domain *domain); |
| 20 | int omap_iommu_domain_activate(struct iommu_domain *domain); |
Mauro Carvalho Chehab | c7f1770 | 2018-04-05 10:54:14 -0400 | [diff] [blame] | 21 | #else |
| 22 | static inline void omap_iommu_save_ctx(struct device *dev) {} |
| 23 | static inline void omap_iommu_restore_ctx(struct device *dev) {} |
Suman Anna | d9c4d8a6 | 2019-08-07 11:26:50 +0300 | [diff] [blame] | 24 | |
Joerg Roedel | 73499ad | 2019-08-09 18:09:13 +0200 | [diff] [blame] | 25 | static inline int omap_iommu_domain_deactivate(struct iommu_domain *domain) |
| 26 | { |
| 27 | return -ENODEV; |
| 28 | } |
| 29 | |
| 30 | static inline int omap_iommu_domain_activate(struct iommu_domain *domain) |
| 31 | { |
| 32 | return -ENODEV; |
| 33 | } |
Mauro Carvalho Chehab | c7f1770 | 2018-04-05 10:54:14 -0400 | [diff] [blame] | 34 | #endif |
Tony Lindgren | c8d35c8 | 2012-11-02 12:24:03 -0700 | [diff] [blame] | 35 | |
| 36 | #endif |