running = atomic_read(&rga_service.total_running);\r
printk("rga total_running %d\n", running);\r
\r
+ return;\r
+\r
/* Dump waiting list info */\r
if (!list_empty(&rga_service.waiting))\r
{ \r
pr_alert("power off when %d task running!!\n", total_running); \r
mdelay(50);\r
pr_alert("delay 50 ms for running task\n"); \r
- //rga_dump();\r
+ rga_dump();\r
}\r
\r
clk_disable(aclk_rga);\r
INIT_LIST_HEAD(®->status_link);\r
\r
memcpy(®->req, req, sizeof(struct rga_req));\r
+\r
+ reg->MMU_base = NULL;\r
\r
if (req->mmu_info.mmu_en)\r
{\r
}\r
\r
\r
-#if 1//RGA_TEST \r
+#if RGA_TEST \r
static void print_info(struct rga_req *req)\r
{ \r
printk("src.yrgb_addr = %.8x, src.uv_addr = %.8x, src.v_addr = %.8x\n", \r
}\r
\r
\r
-static rga_mem_addr_sel(struct rga_req *req)\r
+static void rga_mem_addr_sel(struct rga_req *req)\r
{\r
switch(req->src.format)\r
{\r
case RK_FORMAT_YCbCr_422_P :\r
break;\r
case RK_FORMAT_YCbCr_420_SP :\r
+ if((req->src.yrgb_addr > 0xc0000000) && (req->src.uv_addr > 0xc0000000)\r
+ && (req->dst.yrgb_addr > 0xc0000000))\r
+ {\r
+ req->src.yrgb_addr = req->src.yrgb_addr - 0x60000000;\r
+ req->src.uv_addr = req->src.uv_addr - 0x60000000;\r
+ req->dst.yrgb_addr = req->dst.yrgb_addr - 0x60000000;\r
+ req->mmu_info.mmu_en = 0;\r
+ req->mmu_info.mmu_flag &= 0xfffe;\r
+ }\r
break;\r
case RK_FORMAT_YCbCr_420_P :\r
break;\r
-\r
case RK_FORMAT_YCrCb_422_SP :\r
break;\r
case RK_FORMAT_YCrCb_422_P :\r
printk("req argument is inval\n");\r
break;\r
}\r
+\r
+ if(req->render_mode == bitblt_mode)\r
+ {\r
+ rga_mem_addr_sel(req); \r
+ }\r
\r
reg = rga_reg_init(session, req);\r
if(reg == NULL) {\r
\r
static irqreturn_t rga_irq(int irq, void *dev_id)\r
{\r
- //struct rga_reg *reg;\r
- uint32_t flag;\r
- uint32_t i = 0;\r
- //int int_enable = 0;\r
+ unsigned long flag;\r
\r
#if RGA_TEST\r
printk("rga_irq is valid\n");\r
{\r
spin_unlock_irqrestore(&rga_service.lock, flag);\r
}\r
- \r
- /* add cmd to cmd buf */\r
- /*\r
- while((!list_empty(next)) && ((int_enable) == 0) && (num <= 0xf))\r
- { \r
- num += 1;\r
- reg = list_entry(next->next, struct rga_reg, status_link);\r
- int_enable = atomic_read(®->int_enable); \r
- next = next->next;\r
- } \r
- */\r
- \r
+ \r
return IRQ_HANDLED;\r
}\r
\r