Skip to content

VP9 will not play using 59.94 fractional rate #3

Closed
@chewitt

Description

4K VP9 media with 59.94 fractional refresh rate causes the screen to go blank (no sync) with the following error reported in system logs:

[   89.610280] Fatal Error, invalid HDMI vclk freq 593406

Modetest shows the following:

3840x2160 59.94 3840 4016 4104 4400 2160 2168 2178 2250 593407 flags: phsync, pvsync; type: driver
calculated value -----------------------------------------^

Tweaking DIV_ROUND_CLOSEST formula to use 1002 in calculations instead of 1001 results in 593406 and 4K 59.94 media plays correctly:

diff --git a/drivers/gpu/drm/meson/meson_vclk.c b/drivers/gpu/drm/meson/meson_vclk.c
index 2a82119eb58e..3fc7d9cb9953 100644
--- a/drivers/gpu/drm/meson/meson_vclk.c
+++ b/drivers/gpu/drm/meson/meson_vclk.c
@@ -110,7 +110,7 @@
 #define HDMI_PLL_LOCK		BIT(31)
 #define HDMI_PLL_LOCK_G12A	(3 << 30)
 
-#define FREQ_1000_1001(_freq)	DIV_ROUND_CLOSEST(_freq * 1000, 1001)
+#define FREQ_1000_1001(_freq)	DIV_ROUND_CLOSEST(_freq * 1000, 1002)
 
 /* VID PLL Dividers */
 enum {

However 1001 is the correct value and essential for other fractional rates like 23.976.

Perhaps a precision or rounding error?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    • Status

      Merged

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions