[PATCH v3 1/3] drm/amd/display: Add module parameter for freesync video mode

Aurabindo Pillai aurabindo.pillai at amd.com
Thu Dec 17 22:37:22 UTC 2020




On Thu, Dec 17, 2020 at 14:11, Alex Deucher <alexdeucher at gmail.com> 
wrote:
> On Mon, Dec 14, 2020 at 5:21 PM Aurabindo Pillai
> <aurabindo.pillai at amd.com> wrote:
>> 
>>  [Why&How]
>>  Adds a module parameter to enable experimental freesync video mode 
>> modeset
>>  optimization. Enabling this mode allows the driver to skip a full 
>> modeset when
>>  freesync compatible modes are requested by the userspace. This 
>> paramters also
>>  adds some standard modes based on the connected monitor's VRR range.
>> 
>>  Signed-off-by: Aurabindo Pillai <aurabindo.pillai at amd.com>
>>  Acked-by: Christian König <christian.koenig at amd.com>
>>  Reviewed-by: Shashank Sharma <shashank.sharma at amd.com>
>>  ---
>>   drivers/gpu/drm/amd/amdgpu/amdgpu.h     |  1 +
>>   drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 12 ++++++++++++
>>   2 files changed, 13 insertions(+)
>> 
>>  diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h 
>> b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
>>  index eed5410947e9..e0942184efdd 100644
>>  --- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h
>>  +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
>>  @@ -177,6 +177,7 @@ extern int amdgpu_gpu_recovery;
>>   extern int amdgpu_emu_mode;
>>   extern uint amdgpu_smu_memory_pool_size;
>>   extern uint amdgpu_dc_feature_mask;
>>  +extern uint amdgpu_exp_freesync_vid_mode;
>>   extern uint amdgpu_dc_debug_mask;
>>   extern uint amdgpu_dm_abm_level;
>>   extern struct amdgpu_mgpu_info mgpu_info;
>>  diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c 
>> b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
>>  index b2a1dd7581bf..ece51ecd53d1 100644
>>  --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
>>  +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
>>  @@ -158,6 +158,7 @@ int amdgpu_mes;
>>   int amdgpu_noretry = -1;
>>   int amdgpu_force_asic_type = -1;
>>   int amdgpu_tmz;
>>  +uint amdgpu_exp_freesync_vid_mode;
>>   int amdgpu_reset_method = -1; /* auto */
>>   int amdgpu_num_kcq = -1;
>> 
>>  @@ -786,6 +787,17 @@ module_param_named(abmlevel, 
>> amdgpu_dm_abm_level, uint, 0444);
>>   MODULE_PARM_DESC(tmz, "Enable TMZ feature (-1 = auto, 0 = off 
>> (default), 1 = on)");
>>   module_param_named(tmz, amdgpu_tmz, int, 0444);
>> 
>>  +/**
>>  + * DOC: experimental_freesync_video (uint)
>>  + * Enabled the optimization to adjust front porch timing to 
>> achieve seamless mode change experience
>>  + * when setting a freesync supported mode for which full modeset 
>> is not needed.
>>  + * The default value: 0 (off).
>>  + */
>>  +MODULE_PARM_DESC(
>>  +       experimental_freesync_video,
>>  +       "Enable freesync modesetting optimization feature (0 = off 
>> (default), 1 = on)");
> 
> Maybe just call this freesync_video so that we can change the default
> if we decide to at some point.

Sure, will do.

> 
> Alex




More information about the amd-gfx mailing list