hc
2023-11-20 2e7bd41e4e8ab3d1efdabd9e263a2f7fe79bff8c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
From 484f74bf8beca2a3744b9bac602d2844b32b3cd5 Mon Sep 17 00:00:00 2001
From: Frank Liu <frank.liu@rock-chips.com>
Date: Fri, 10 Apr 2020 16:52:18 +0800
Subject: [PATCH 20/20] Disable rkmpp_dec rga mmu if rv1108 packet.
 
Signed-off-by: Frank Liu <frank.liu@rock-chips.com>
---
 libavcodec/rkmppdec.c | 4 ++++
 1 file changed, 4 insertions(+)
 
diff --git a/libavcodec/rkmppdec.c b/libavcodec/rkmppdec.c
index 08ea774..dbe9795 100644
--- a/libavcodec/rkmppdec.c
+++ b/libavcodec/rkmppdec.c
@@ -110,7 +110,9 @@ static int rkmpp_write_nv12(MppBuffer mpp_buffer, int mpp_vir_width,
     }
 
     src_info.fd = mpp_buffer_get_fd(mpp_buffer);
+#ifndef CONFIG_ION
     src_info.mmuFlag = 1;
+#endif
     // mpp decoder always return nv12(yuv420sp)
     rga_set_rect(&src_info.rect, 0, 0, width, height,
                  mpp_vir_width, mpp_vir_height, RK_FORMAT_YCbCr_420_SP);
@@ -118,7 +120,9 @@ static int rkmpp_write_nv12(MppBuffer mpp_buffer, int mpp_vir_width,
     dst_info.fd = -1;
     // dst_frame data[*] must be continuous
     dst_info.virAddr = dst_frame->data[0];
+#ifndef CONFIG_ION
     dst_info.mmuFlag = 1;
+#endif
     rga_set_rect(&dst_info.rect, dst_frame->crop_left, dst_frame->crop_top,
                  width, height, dst_frame->linesize[0], possible_height,
                  rga_format);
-- 
2.17.1