From e32b084701f160be0b6d558d9cbdd8bd3a86a8bc Mon Sep 17 00:00:00 2001 From: Alex Waterman Date: Tue, 10 Jun 2014 11:17:50 -0700 Subject: video: tegra: nvmap: Move nvmap init code Move the nvmap init code to nvmap's directory and remove the board code. This is in preparation for using the device tree to specify the carveout structures that nvmap ends up creating. Bug 200008319 Change-Id: Ia593714f2fd4cc1c7143df0b3c931cf01e0d611f Signed-off-by: Alex Waterman Reviewed-on: http://git-master/r/421887 Reviewed-by: Krishna Reddy --- include/linux/nvmap.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'include/linux') diff --git a/include/linux/nvmap.h b/include/linux/nvmap.h index 3bfb365b2..cb889f110 100644 --- a/include/linux/nvmap.h +++ b/include/linux/nvmap.h @@ -58,12 +58,26 @@ #if defined(__KERNEL__) +struct platform_device; + +struct platform_device *nvmap_get_platform_dev(void); + struct dma_buf *nvmap_alloc_dmabuf(size_t size, size_t align, unsigned int flags, unsigned int heap_mask); int nvmap_get_dmabuf_param(struct dma_buf *dmabuf, u32 param, u64 *result); +#ifdef CONFIG_TEGRA_NVMAP +int __init nvmap_init(void); +#else +/* MODS does not enable nvmap. */ +__attribute__((unused)) static int nvmap_init(void) +{ + return 0; +} +#endif + #ifdef CONFIG_NVMAP_PAGE_POOLS ulong nvmap_page_pool_get_unused_pages(void); ulong nvmap_page_pool_get_pool_size(void); -- cgit v1.2.2