mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-09 04:10:18 +09:00
video: rockchip: rga3: fix compile errors on stable-4.19-rv1126
Update driver version to 1.2.26 Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com> Change-Id: I048c44201f34af5d4391b2ce097ba592b5f0b5c1
This commit is contained in:
@@ -87,7 +87,7 @@
|
||||
|
||||
#define DRIVER_MAJOR_VERISON 1
|
||||
#define DRIVER_MINOR_VERSION 2
|
||||
#define DRIVER_REVISION_VERSION 25
|
||||
#define DRIVER_REVISION_VERSION 26
|
||||
#define DRIVER_PATCH_VERSION
|
||||
|
||||
#define DRIVER_VERSION (STR(DRIVER_MAJOR_VERISON) "." STR(DRIVER_MINOR_VERSION) \
|
||||
|
||||
@@ -2068,7 +2068,7 @@ static void rga2_soft_reset(struct rga_scheduler_t *scheduler)
|
||||
{
|
||||
u32 i;
|
||||
u32 reg;
|
||||
u32 iommu_dte_addr;
|
||||
u32 iommu_dte_addr = 0;
|
||||
|
||||
if (scheduler->data->mmu == RGA_IOMMU)
|
||||
iommu_dte_addr = rga_read(RGA_IOMMU_DTE_ADDR, scheduler);
|
||||
|
||||
@@ -1626,7 +1626,7 @@ static void rga_cmd_to_rga3_cmd(struct rga_req *req_rga, struct rga3_req *req)
|
||||
static void rga3_soft_reset(struct rga_scheduler_t *scheduler)
|
||||
{
|
||||
u32 i;
|
||||
u32 iommu_dte_addr;
|
||||
u32 iommu_dte_addr = 0;
|
||||
|
||||
if (scheduler->data->mmu == RGA_IOMMU)
|
||||
iommu_dte_addr = rga_read(RGA_IOMMU_DTE_ADDR, scheduler);
|
||||
|
||||
@@ -206,9 +206,6 @@ static dma_addr_t rga_iommu_dma_alloc_iova(struct iommu_domain *domain,
|
||||
struct rga_iommu_dma_cookie *cookie = domain->iova_cookie;
|
||||
struct iova_domain *iovad = &cookie->iovad;
|
||||
unsigned long shift, iova_len, iova = 0;
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 4, 0))
|
||||
dma_addr_t limit;
|
||||
#endif
|
||||
|
||||
shift = iova_shift(iovad);
|
||||
iova_len = size >> shift;
|
||||
@@ -231,12 +228,13 @@ static dma_addr_t rga_iommu_dma_alloc_iova(struct iommu_domain *domain,
|
||||
if (domain->geometry.force_aperture)
|
||||
dma_limit = min(dma_limit, (u64)domain->geometry.aperture_end);
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 4, 0))
|
||||
iova = alloc_iova_fast(iovad, iova_len, dma_limit >> shift, true);
|
||||
#if (LINUX_VERSION_CODE > KERNEL_VERSION(4, 19, 111) && \
|
||||
LINUX_VERSION_CODE < KERNEL_VERSION(5, 4, 0))
|
||||
iova = alloc_iova_fast(iovad, iova_len,
|
||||
min_t(dma_addr_t, dma_limit >> shift, iovad->end_pfn),
|
||||
true);
|
||||
#else
|
||||
limit = min_t(dma_addr_t, dma_limit >> shift, iovad->end_pfn);
|
||||
|
||||
iova = alloc_iova_fast(iovad, iova_len, limit, true);
|
||||
iova = alloc_iova_fast(iovad, iova_len, dma_limit >> shift, true);
|
||||
#endif
|
||||
|
||||
return (dma_addr_t)iova << shift;
|
||||
|
||||
Reference in New Issue
Block a user