From: jsg Date: Mon, 5 Sep 2022 14:11:02 +0000 (+0000) Subject: drm/amd/display: Fix HDMI VSIF V3 incorrect issue X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=60287b987346c8cbde9b71a72396310a24bb8c32;p=openbsd drm/amd/display: Fix HDMI VSIF V3 incorrect issue From Leo Ma 2cddd3d0b049a5e0666f93ea8c0d6ba6cc4bbec4 in linux 5.15.y/5.15.65 0591183699fceeafb4c4141072d47775de83ecfb in mainline linux --- diff --git a/sys/dev/pci/drm/amd/display/modules/freesync/freesync.c b/sys/dev/pci/drm/amd/display/modules/freesync/freesync.c index 1e1aab35a53..b32db8be6e4 100644 --- a/sys/dev/pci/drm/amd/display/modules/freesync/freesync.c +++ b/sys/dev/pci/drm/amd/display/modules/freesync/freesync.c @@ -567,10 +567,6 @@ static void build_vrr_infopacket_data_v1(const struct mod_vrr_params *vrr, * Note: We should never go above the field rate of the mode timing set. */ infopacket->sb[8] = (unsigned char)((vrr->max_refresh_in_uhz + 500000) / 1000000); - - /* FreeSync HDR */ - infopacket->sb[9] = 0; - infopacket->sb[10] = 0; } static void build_vrr_infopacket_data_v3(const struct mod_vrr_params *vrr, @@ -638,10 +634,6 @@ static void build_vrr_infopacket_data_v3(const struct mod_vrr_params *vrr, /* PB16 : Reserved bits 7:1, FixedRate bit 0 */ infopacket->sb[16] = (vrr->state == VRR_STATE_ACTIVE_FIXED) ? 1 : 0; - - //FreeSync HDR - infopacket->sb[9] = 0; - infopacket->sb[10] = 0; } static void build_vrr_infopacket_fs2_data(enum color_transfer_func app_tf, @@ -726,8 +718,7 @@ static void build_vrr_infopacket_header_v2(enum amd_signal_type signal, /* HB2 = [Bits 7:5 = 0] [Bits 4:0 = Length = 0x09] */ infopacket->hb2 = 0x09; - *payload_size = 0x0A; - + *payload_size = 0x09; } else if (dc_is_dp_signal(signal)) { /* HEADER */ @@ -776,9 +767,9 @@ static void build_vrr_infopacket_header_v3(enum amd_signal_type signal, infopacket->hb1 = version; /* HB2 = [Bits 7:5 = 0] [Bits 4:0 = Length] */ - *payload_size = 0x10; - infopacket->hb2 = *payload_size - 1; //-1 for checksum + infopacket->hb2 = 0x10; + *payload_size = 0x10; } else if (dc_is_dp_signal(signal)) { /* HEADER */