drm/amd/display: Add 120Hz support for freesync video mode
authorSolomon Chiu <solomon.chiu@amd.com>
Tue, 5 Oct 2021 12:52:42 +0000 (20:52 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 6 Oct 2021 19:53:43 +0000 (15:53 -0400)
[Why]
For those video format with 60 fps, the user space player could
ask for 120Hz for playback.

[How]
Add 120 in the table of common rates.

Signed-off-by: Solomon Chiu <solomon.chiu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c

index b567809..f35561b 100644 (file)
@@ -6018,7 +6018,7 @@ static void apply_dsc_policy_for_stream(struct amdgpu_dm_connector *aconnector,
  * - Cinema HFR (48 FPS)
  * - TV/PAL (50 FPS)
  * - Commonly used (60 FPS)
- * - Multiples of 24 (48,72,96 FPS)
+ * - Multiples of 24 (48,72,96,120 FPS)
  *
  * The list of standards video format is not huge and can be added to the
  * connector modeset list beforehand. With that, userspace can leverage
@@ -7980,19 +7980,19 @@ static uint add_fs_modes(struct amdgpu_dm_connector *aconnector)
 
        /* Standard FPS values
         *
-        * 23.976   - TV/NTSC
-        * 24       - Cinema
-        * 25       - TV/PAL
-        * 29.97    - TV/NTSC
-        * 30       - TV/NTSC
-        * 48       - Cinema HFR
-        * 50       - TV/PAL
-        * 60       - Commonly used
-        * 48,72,96 - Multiples of 24
+        * 23.976       - TV/NTSC
+        * 24           - Cinema
+        * 25           - TV/PAL
+        * 29.97        - TV/NTSC
+        * 30           - TV/NTSC
+        * 48           - Cinema HFR
+        * 50           - TV/PAL
+        * 60           - Commonly used
+        * 48,72,96,120 - Multiples of 24
         */
        static const uint32_t common_rates[] = {
                23976, 24000, 25000, 29970, 30000,
-               48000, 50000, 60000, 72000, 96000
+               48000, 50000, 60000, 72000, 96000, 120000
        };
 
        /*