Files
android_kernel_samsung_sm86…/rotator/sde_rotator_smmu.h
Samantha Tran 13bb35435c disp: add changes to generate display dlkm in android
Add Android make files and Kbuild files to support dlkm
for display driver. Also resolve header and config issues
to allow successful compilation of display driver.

Change-Id: I04d6233864ea54c0a808b295fbdccb83058f1fd2
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
Signed-off-by: Prabhanjan Kandula <pkandula@codeaurora.org>
2021-01-15 00:32:42 -08:00

50 lines
1.1 KiB
C

/* SPDX-License-Identifier: GPL-2.0-only */
/*
* Copyright (c) 2015-2021, The Linux Foundation. All rights reserved.
*/
#ifndef SDE_ROTATOR_SMMU_H
#define SDE_ROTATOR_SMMU_H
#include <linux/types.h>
#include <linux/device.h>
#include <linux/dma-buf.h>
#include "sde_rotator_io_util.h"
enum sde_iommu_domain_type {
SDE_IOMMU_DOMAIN_ROT_UNSECURE,
SDE_IOMMU_DOMAIN_ROT_SECURE,
SDE_IOMMU_MAX_DOMAIN
};
int sde_smmu_init(struct device *dev);
static inline int sde_smmu_dma_data_direction(int dir)
{
return dir;
}
#ifdef CONFIG_MSM_SDE_ROTATOR
int sde_smmu_ctrl(int enable);
#else
static inline int sde_smmu_ctrl(int enable)
{
return 0;
}
#endif
struct dma_buf_attachment *sde_smmu_dma_buf_attach(
struct dma_buf *dma_buf, struct device *dev, int domain);
int sde_smmu_map_dma_buf(struct dma_buf *dma_buf,
struct sg_table *table, int domain, dma_addr_t *iova,
unsigned long *size, int dir);
void sde_smmu_unmap_dma_buf(struct sg_table *table, int domain,
int dir, struct dma_buf *dma_buf);
int sde_smmu_secure_ctrl(int enable);
#endif /* SDE_ROTATOR_SMMU_H */