int ret = -1;\r
\r
#if RGA2_TEST_MSG\r
- if (req->src.format >= 0x10) {\r
+ if (1) {//req->src.format >= 0x10) {\r
print_info(req);\r
rga2_flag = 1;\r
printk("*** rga_blit_async proc ***\n");\r
int ret_timeout = 0;\r
\r
#if RGA2_TEST_MSG\r
- if (req->bitblt_mode == 0x2) {\r
+ if (1) {//req->bitblt_mode == 0x2) {\r
print_info(req);\r
rga2_flag = 1;\r
printk("*** rga2_blit_sync proc ***\n");\r
int ret = 0;\r
rga2_session *session;\r
\r
+ memset(&req, 0x0, sizeof(req));\r
+\r
mutex_lock(&rga2_service.mutex);\r
\r
session = (rga2_session *)file->private_data;\r
}\r
\r
\r
-long rga_ioctl_kernel(struct rga_req *req)\r
+long rga_ioctl_kernel(struct rga_req *req_rga)\r
{\r
int ret = 0;\r
rga2_session *session;\r
- struct rga2_req req_rga2;\r
+ struct rga2_req req;\r
+\r
+ memset(&req, 0x0, sizeof(req));\r
\r
mutex_lock(&rga2_service.mutex);\r
\r
return -EINVAL;\r
}\r
\r
- RGA_MSG_2_RGA2_MSG(req, &req_rga2);\r
- ret = rga2_blit_sync(session, &req_rga2);\r
+ RGA_MSG_2_RGA2_MSG(req_rga, &req);\r
+ ret = rga2_blit_sync(session, &req);\r
\r
mutex_unlock(&rga2_service.mutex);\r
\r
extern void rk_direct_fb_show(struct fb_info * fbi);\r
EXPORT_SYMBOL(rk_direct_fb_show);\r
\r
-//unsigned int src_buf[1920*1080];\r
-//unsigned int dst_buf[1920*1080];\r
+//unsigned int src_buf[4096*2304*3/2];\r
+//unsigned int dst_buf[3840*2304*3/2];\r
//unsigned int tmp_buf[1920*1080 * 2];\r
\r
void rga2_test_0(void)\r
//fb = rk_get_fb(0);\r
\r
memset(&req, 0, sizeof(struct rga2_req));\r
- src = kmalloc(800*480*4, GFP_KERNEL);\r
- dst = kmalloc(800*480*4, GFP_KERNEL);\r
+ src = kmalloc(4096*2304*3/2, GFP_KERNEL);\r
+ dst = kmalloc(3840*2160*3/2, GFP_KERNEL);\r
\r
- memset(src, 0x80, 800*480*4);\r
+ //memset(src, 0x80, 4096*2304*4);\r
\r
- dmac_flush_range(&src, &src[800*480*4]);\r
- outer_flush_range(virt_to_phys(&src),virt_to_phys(&src[800*480*4]));\r
+ //dmac_flush_range(&src, &src[800*480*4]);\r
+ //outer_flush_range(virt_to_phys(&src),virt_to_phys(&src[800*480*4]));\r
\r
\r
#if 0\r
printk("************ RGA2_TEST ************\n");\r
printk("********************************\n\n");\r
\r
- req.src.act_w = 320;\r
- req.src.act_h = 240;\r
+ req.src.act_w = 4096;\r
+ req.src.act_h = 2304;\r
\r
- req.src.vir_w = 320;\r
- req.src.vir_h = 240;\r
- req.src.yrgb_addr = (uint32_t)virt_to_phys(src);\r
- req.src.uv_addr = (uint32_t)(req.src.yrgb_addr + 800*480);\r
- req.src.v_addr = (uint32_t)virt_to_phys(src);\r
- req.src.format = RGA2_FORMAT_RGBA_8888;\r
+ req.src.vir_w = 4096;\r
+ req.src.vir_h = 2304;\r
+ req.src.yrgb_addr = (uint32_t)0;//virt_to_phys(src);\r
+ req.src.uv_addr = (uint32_t)virt_to_phys(src);\r
+ req.src.v_addr = 0;\r
+ req.src.format = RGA2_FORMAT_YCbCr_420_SP;\r
\r
- req.dst.act_w = 320;\r
- req.dst.act_h = 240;\r
+ req.dst.act_w = 3840;\r
+ req.dst.act_h = 2160;\r
req.dst.x_offset = 0;\r
req.dst.y_offset = 0;\r
\r
- req.dst.vir_w = 320;\r
- req.dst.vir_h = 240;\r
+ req.dst.vir_w = 3840;\r
+ req.dst.vir_h = 2160;\r
\r
- req.dst.yrgb_addr = ((uint32_t)virt_to_phys(dst));\r
- req.dst.format = RGA2_FORMAT_RGBA_8888;\r
+ req.dst.yrgb_addr = 0;//((uint32_t)virt_to_phys(dst));\r
+ req.dst.uv_addr = ((uint32_t)virt_to_phys(dst));\r
+ req.dst.format = RGA2_FORMAT_YCbCr_420_SP;\r
\r
//dst = dst0;\r
\r
//req.render_mode = color_fill_mode;\r
//req.fg_color = 0x80ffffff;\r
\r
- req.rotate_mode = 1;\r
+ req.rotate_mode = 0;\r
req.scale_bicu_mode = 2;\r
\r
//req.alpha_rop_flag = 0;\r
//req.alpha_rop_mode = 0x19;\r
//req.PD_mode = 3;\r
\r
- req.rotate_mode = 0;\r
-\r
//req.mmu_info.mmu_flag = 0x21;\r
//req.mmu_info.mmu_en = 1;\r
\r