Dolby: garbage images on screen when output 720 [1/1]
authoryao liu <yao.liu@amlogic.com>
Mon, 17 Jun 2019 13:50:30 +0000 (21:50 +0800)
committerNick Xie <nick@khadas.com>
Mon, 5 Aug 2019 07:12:13 +0000 (15:12 +0800)
PD#SWPL-9805

Problem:
dolby graphics core setting is marginal at 720@50 or 720@60

Solution:
Leave more margin in vertical potch for graphic core
Another modification: force update core2 and core3 reg
when dolby-vision on

Verify:
local build test on dolby tv 720@50/720@60/1080p24hz

Change-Id: I1019d2c1564230b0e42516fe1a7732ba25b2e8bf
Signed-off-by: yao liu <yao.liu@amlogic.com>
drivers/amlogic/media/enhancement/amdolby_vision/amdolby_vision.c

index cad59ee..08ad383 100644 (file)
@@ -2125,6 +2125,9 @@ static int dolby_core2_set(
        if (dolby_vision_flags & FLAG_CERTIFICAION)
                reset = true;
 
+       if (dolby_vision_on_count == 0)
+               reset = true;
+
        if (stb_core_setting_update_flag & FLAG_CHANGE_TC2)
                set_lut = true;
 
@@ -2252,6 +2255,9 @@ static int dolby_core3_set(
        if (!dolby_vision_on ||
                (dolby_vision_flags & FLAG_CERTIFICAION))
                reset = true;
+
+       if (dolby_vision_on_count == 0)
+               reset = true;
 #ifdef V2_4
        if (((cur_dv_mode == DOLBY_VISION_OUTPUT_MODE_IPT_TUNNEL)
                || (cur_dv_mode == DOLBY_VISION_OUTPUT_MODE_IPT))
@@ -2479,9 +2485,9 @@ static void apply_stb_core_settings(
                                (vinfo->field_height < 720))
                                g_vpotch = 0x60;
                        else
-                               g_vpotch = 0x8;
+                               g_vpotch = 0x20;
                } else
-                       g_vpotch = 0x8;
+                       g_vpotch = 0x20;
        }
 
        if (mask & 1) {
@@ -6517,9 +6523,9 @@ int register_dv_functions(const struct dolby_vision_func_s *func)
                                        (vinfo->field_height < 720))
                                        g_vpotch = 0x60;
                                else
-                                       g_vpotch = 0x8;
+                                       g_vpotch = 0x20;
                        } else
-                               g_vpotch = 0x8;
+                               g_vpotch = 0x20;
                } else
                        g_vpotch = 0x8;
        }