All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Kazlauskas, Nicholas" <Nicholas.Kazlauskas-5C7GfCeVMHo@public.gmane.org>
To: Alex Deucher
	<alexdeucher-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	"amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org"
	<amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org>
Cc: "Deucher, Alexander" <Alexander.Deucher-5C7GfCeVMHo@public.gmane.org>
Subject: Re: [PATCH 4/4] drm/amdgpu/display: add flag for multi-display mclk switching
Date: Thu, 22 Aug 2019 19:40:36 +0000	[thread overview]
Message-ID: <fc06d6b3-4135-3969-c4a0-0dc17eef9d72@amd.com> (raw)
In-Reply-To: <20190822193050.3107-5-alexander.deucher-5C7GfCeVMHo@public.gmane.org>

On 8/22/19 3:30 PM, Alex Deucher wrote:
> Add a dcfeaturemask flag for mclk switching.  Disable by default;
> enable once the feature has seen more testing.
> 
> Set amdgpu.dcfeaturemask=2 on the kernel command line in grub
> to enable this.
> 
> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

Patches 3 and 4 are

Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>

> ---
>   drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 +++
>   drivers/gpu/drm/amd/display/dc/calcs/dce_calcs.c  | 5 ++++-
>   drivers/gpu/drm/amd/display/dc/dc.h               | 2 +-
>   drivers/gpu/drm/amd/include/amd_shared.h          | 1 +
>   4 files changed, 9 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> index 45298269744d..cb86ccf48bd9 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> @@ -694,6 +694,9 @@ static int amdgpu_dm_init(struct amdgpu_device *adev)
>   	if (amdgpu_dc_feature_mask & DC_FBC_MASK)
>   		init_data.flags.fbc_support = true;
>   
> +	if (amdgpu_dc_feature_mask & DC_MULTI_MON_PP_MCLK_SWITCH_MASK)
> +		init_data.flags.multi_mon_pp_mclk_switch = true;
> +
>   	init_data.flags.power_down_display_on_boot = true;
>   
>   #ifdef CONFIG_DRM_AMD_DC_DCN2_0
> diff --git a/drivers/gpu/drm/amd/display/dc/calcs/dce_calcs.c b/drivers/gpu/drm/amd/display/dc/calcs/dce_calcs.c
> index eca681d9d7f5..a1d49256fab7 100644
> --- a/drivers/gpu/drm/amd/display/dc/calcs/dce_calcs.c
> +++ b/drivers/gpu/drm/amd/display/dc/calcs/dce_calcs.c
> @@ -3025,7 +3025,10 @@ bool bw_calcs(struct dc_context *ctx,
>   
>   	populate_initial_data(pipe, pipe_count, data);
>   
> -	calcs_output->all_displays_in_sync = all_displays_in_sync(pipe, pipe_count);
> +	if (ctx->dc->config.multi_mon_pp_mclk_switch)
> +		calcs_output->all_displays_in_sync = all_displays_in_sync(pipe, pipe_count);
> +	else
> +		calcs_output->all_displays_in_sync = false;
>   
>   	if (data->number_of_displays != 0) {
>   		uint8_t yclk_lvl, sclk_lvl;
> diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h
> index 3ef269f82478..5d4a2a9228f0 100644
> --- a/drivers/gpu/drm/amd/display/dc/dc.h
> +++ b/drivers/gpu/drm/amd/display/dc/dc.h
> @@ -220,7 +220,7 @@ struct dc_config {
>   	bool power_down_display_on_boot;
>   	bool edp_not_connected;
>   	bool forced_clocks;
> -
> +	bool multi_mon_pp_mclk_switch;
>   };
>   
>   enum visual_confirm {
> diff --git a/drivers/gpu/drm/amd/include/amd_shared.h b/drivers/gpu/drm/amd/include/amd_shared.h
> index a0a7211438f2..8889aaceec60 100644
> --- a/drivers/gpu/drm/amd/include/amd_shared.h
> +++ b/drivers/gpu/drm/amd/include/amd_shared.h
> @@ -142,6 +142,7 @@ enum PP_FEATURE_MASK {
>   
>   enum DC_FEATURE_MASK {
>   	DC_FBC_MASK = 0x1,
> +	DC_MULTI_MON_PP_MCLK_SWITCH_MASK = 0x2,
>   };
>   
>   enum amd_dpm_forced_level;
> 

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  parent reply	other threads:[~2019-08-22 19:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-22 19:30 [PATCH 0/4] Support mclk switching when monitors are in sync (v2) Alex Deucher
     [not found] ` <20190822193050.3107-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org>
2019-08-22 19:30   ` [PATCH 1/4] drm/amdgpu/powerplay/smu7: enable mclk switching if monitors are synced Alex Deucher
2019-08-22 19:30   ` [PATCH 2/4] drm/amdgpu/powerplay/vega10: " Alex Deucher
2019-08-22 19:30   ` [PATCH 3/4] drm/amd/display: update bw_calcs to take pipe sync into account (v3) Alex Deucher
2019-08-22 19:30   ` [PATCH 4/4] drm/amdgpu/display: add flag for multi-display mclk switching Alex Deucher
     [not found]     ` <20190822193050.3107-5-alexander.deucher-5C7GfCeVMHo@public.gmane.org>
2019-08-22 19:40       ` Kazlauskas, Nicholas [this message]
2019-08-23  3:42       ` Quan, Evan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fc06d6b3-4135-3969-c4a0-0dc17eef9d72@amd.com \
    --to=nicholas.kazlauskas-5c7gfcevmho@public.gmane.org \
    --cc=Alexander.Deucher-5C7GfCeVMHo@public.gmane.org \
    --cc=alexdeucher-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.