summaryrefslogtreecommitdiff
path: root/include/drm
diff options
context:
space:
mode:
authorThomas Hellstrom <thellstrom@vmware.com>2013-10-24 01:24:54 -0700
committerThomas Hellstrom <thellstrom@vmware.com>2013-11-06 03:55:52 -0800
commit7aeb7448d8d02868ef30a6d08e856b2220319273 (patch)
tree2b12ced2a7607b6305ff6a41d933d5b0b55c23a0 /include/drm
parent4695b03970df378dcb93fe3e7158381f1e980fa2 (diff)
downloadlinux-stable-7aeb7448d8d02868ef30a6d08e856b2220319273.tar.gz
linux-stable-7aeb7448d8d02868ef30a6d08e856b2220319273.tar.bz2
linux-stable-7aeb7448d8d02868ef30a6d08e856b2220319273.zip
drm/ttm: Enable the dma page pool also for intel IOMMUs
Used by the vmwgfx driver Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com> Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/ttm/ttm_page_alloc.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/include/drm/ttm/ttm_page_alloc.h b/include/drm/ttm/ttm_page_alloc.h
index 706b962c6467..d1f61bfe0ebe 100644
--- a/include/drm/ttm/ttm_page_alloc.h
+++ b/include/drm/ttm/ttm_page_alloc.h
@@ -62,7 +62,7 @@ extern void ttm_pool_unpopulate(struct ttm_tt *ttm);
extern int ttm_page_alloc_debugfs(struct seq_file *m, void *data);
-#ifdef CONFIG_SWIOTLB
+#if defined(CONFIG_SWIOTLB) || defined(CONFIG_INTEL_IOMMU)
/**
* Initialize pool allocator.
*/
@@ -94,6 +94,15 @@ static inline int ttm_dma_page_alloc_debugfs(struct seq_file *m, void *data)
{
return 0;
}
+static inline int ttm_dma_populate(struct ttm_dma_tt *ttm_dma,
+ struct device *dev)
+{
+ return -ENOMEM;
+}
+static inline void ttm_dma_unpopulate(struct ttm_dma_tt *ttm_dma,
+ struct device *dev)
+{
+}
#endif
#endif