deinterlace: fix kasan bug in di_task_handle [1/1]

PD#173820

Problem:
kasan bug in di_task_handle

Solution:
delete cma_mutex because it has no effect

Verify:
P321

Change-Id: Ie6ca7973576e7350870c5466b54b38b490dff65e
Signed-off-by: Jihong Sui <jihong.sui@amlogic.com>
This commit is contained in:
Jihong Sui
2018-09-21 10:03:15 +08:00
committed by Dongjin Kim
parent 4f42e959ad
commit bc113c055b
2 changed files with 4 additions and 4 deletions

View File

@@ -6322,7 +6322,7 @@ static int di_task_handle(void *data)
di_pre_stru.reg_req_flag_irq = 0;
}
#ifdef CONFIG_CMA
mutex_lock(&de_devp->cma_mutex);
/* mutex_lock(&de_devp->cma_mutex);*/
if (di_pre_stru.cma_release_req) {
atomic_set(&devp->mem_flag, 0);
di_cma_release(devp);
@@ -6337,7 +6337,7 @@ static int di_task_handle(void *data)
di_pre_stru.cma_alloc_req = 0;
di_pre_stru.cma_alloc_done = 1;
}
mutex_unlock(&de_devp->cma_mutex);
/* mutex_unlock(&de_devp->cma_mutex); */
#endif
}
if (de_devp->flags & DI_VPU_CLKB_SET) {
@@ -7451,7 +7451,7 @@ static int di_probe(struct platform_device *pdev)
} else {
atomic_set(&di_devp->mem_flag, 1);
}
mutex_init(&di_devp->cma_mutex);
/* mutex_init(&di_devp->cma_mutex); */
INIT_LIST_HEAD(&di_devp->pq_table_list);
atomic_set(&di_devp->pq_flag, 0);

View File

@@ -235,7 +235,7 @@ struct di_dev_s {
unsigned int post_wr_support;
unsigned int nrds_enable;
unsigned int pps_enable;
struct mutex cma_mutex;
/*struct mutex cma_mutex;*/
unsigned int flag_cma;
struct page *total_pages;
atomic_t mem_flag;