From 27ead0251388eaae682683cf20b9458dd492263d Mon Sep 17 00:00:00 2001 From: Pengcheng Chen Date: Thu, 5 Dec 2019 18:48:05 +0800 Subject: [PATCH] vpp: fix afbc mif setting error caused vd2 display abnormal [1/1] PD#SWPL-17687 Problem: afbc vd2 mif width size set error Solution: fix afbc vd2 mif setting error issue Verify: Verify on X301 Change-Id: I4e24b58ab581e2f15fae1becb7120b6bbc951175 Signed-off-by: Pengcheng Chen (cherry picked from commit 7f43e78548f34f26d9bcaae7995a5b6c6365b5d7) --- drivers/amlogic/media/video_sink/video_hw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/amlogic/media/video_sink/video_hw.c b/drivers/amlogic/media/video_sink/video_hw.c index 30caa9436f32..0a4c0e62f2d6 100644 --- a/drivers/amlogic/media/video_sink/video_hw.c +++ b/drivers/amlogic/media/video_sink/video_hw.c @@ -1715,7 +1715,7 @@ static s32 vd2_afbc_setting_tl1(struct mif_pos_s *setting) (setting->src_w - 1) + 1, 32); mif_blk_bgn_h = crop_left / 32; mif_blk_end_h = (crop_left + setting->end_x_lines - - setting->start_x_lines + 1) / 32; + setting->start_x_lines) / 32; pix_bgn_h = crop_left - mif_blk_bgn_h * 32; pix_end_h = pix_bgn_h + setting->end_x_lines - setting->start_x_lines; @@ -1741,7 +1741,7 @@ static s32 vd2_afbc_setting_tl1(struct mif_pos_s *setting) vsize_in = round_up((setting->src_h - 1) + 1, 4); mif_blk_bgn_v = crop_top / 4; mif_blk_end_v = (crop_top + setting->end_y_lines - - setting->start_y_lines + 1) / 4; + setting->start_y_lines) / 4; pix_bgn_v = crop_top - mif_blk_bgn_v * 4; pix_end_v = pix_bgn_v + setting->end_y_lines - setting->start_y_lines; -- 2.20.1