From 6eebad0acfc99cfe22dcb330d3f83607f88f2306 Mon Sep 17 00:00:00 2001 From: Pengcheng Chen Date: Wed, 19 Jun 2019 17:47:20 +0800 Subject: [PATCH] video: black_threshold valid when vscale_skip=8 && hscale_skip=1 [1/1] PD#TV-6827 Problem: when input source is 4k and output axis's height <228, screen blank Solution: 1. need set echo 20 250 > /sys/class/video/black_threshold, when video scaler can't process, disable video 2. black_threshold valid when vscale_skip_count=8 && hscale_skip_count=1 Verify: t972 Change-Id: I4459c9989adf4c8acb6061756393384cee6f438f Signed-off-by: Pengcheng Chen --- drivers/amlogic/media/video_sink/video.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/amlogic/media/video_sink/video.c b/drivers/amlogic/media/video_sink/video.c index a5cacf3820c5..2b4d322fc575 100644 --- a/drivers/amlogic/media/video_sink/video.c +++ b/drivers/amlogic/media/video_sink/video.c @@ -6375,8 +6375,12 @@ static bool black_threshold_check(u8 id) return ret; if ((layer->layer_width <= black_threshold_width) - || (layer->layer_height <= black_threshold_height)) - ret = true; + || (layer->layer_height <= black_threshold_height)) { + if (cur_frame_par && + (cur_frame_par->vscale_skip_count == 8) && + (cur_frame_par->hscale_skip_count == 1)) + ret = true; + } return ret; }