AMD-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Luben Tuikov <luben.tuikov@amd.com>
To: Alex Deucher <alexdeucher@gmail.com>, amd-gfx@lists.freedesktop.org
Cc: Alex Deucher <alexander.deucher@amd.com>
Subject: Re: [PATCH 2/2] drm/amdgpu: add an auto setting to the noretry parameter
Date: Wed, 23 Sep 2020 10:48:02 -0400	[thread overview]
Message-ID: <3ec1aff1-9ca9-6a71-7871-5359d004566f@amd.com> (raw)
In-Reply-To: <20200923140858.1193427-2-alexander.deucher@amd.com>

Series is Reviewed-by: Luben Tuikov <luben.tuikov@amd.com>

This is a good change!

Regards,
Luben

On 2020-09-23 10:08, Alex Deucher wrote:
> This allows us to set different defaults on a per asic basis.  This
> way we can enable noretry on dGPUs where it can increase performance
> in certain cases and disable it on chips where it can be problematic.
> 
> For now the default is 0 for all asics, but we may want to try and
> enable it again for newer dGPUs.
> 
> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c |  9 +++++++--
>  drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 26 ++++++++++++++++++++++++-
>  2 files changed, 32 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
> index a4b518211b1f..f3e2fbcfadfb 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
> @@ -147,7 +147,7 @@ int amdgpu_async_gfx_ring = 1;
>  int amdgpu_mcbp = 0;
>  int amdgpu_discovery = -1;
>  int amdgpu_mes = 0;
> -int amdgpu_noretry;
> +int amdgpu_noretry = -1;
>  int amdgpu_force_asic_type = -1;
>  int amdgpu_tmz = 0;
>  int amdgpu_reset_method = -1; /* auto */
> @@ -596,8 +596,13 @@ MODULE_PARM_DESC(mes,
>  	"Enable Micro Engine Scheduler (0 = disabled (default), 1 = enabled)");
>  module_param_named(mes, amdgpu_mes, int, 0444);
>  
> +/**
> + * DOC: noretry (int)
> + * Disable retry faults in the GPU memory controller.
> + * (0 = retry enabled, 1 = retry disabled, -1 auto (default))
> + */
>  MODULE_PARM_DESC(noretry,
> -	"Disable retry faults (0 = retry enabled (default), 1 = retry disabled)");
> +	"Disable retry faults (0 = retry enabled, 1 = retry disabled, -1 auto (default))");
>  module_param_named(noretry, amdgpu_noretry, int, 0644);
>  
>  /**
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
> index 3572629fef0a..36604d751d62 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
> @@ -424,7 +424,31 @@ void amdgpu_gmc_noretry_set(struct amdgpu_device *adev)
>  {
>  	struct amdgpu_gmc *gmc = &adev->gmc;
>  
> -	gmc->noretry = amdgpu_noretry;
> +	switch (adev->asic_type) {
> +	case CHIP_RAVEN:
> +		/* Raven currently has issues with noretry
> +		 * regardless of what we decide for other
> +		 * asics, we should leave raven with
> +		 * noretry = 0 until we root cause the
> +		 * issues.
> +		 */
> +		if (amdgpu_noretry == -1)
> +			gmc->noretry = 0;
> +		else
> +			gmc->noretry = amdgpu_noretry;
> +		break;
> +	default:
> +		/* default this to 0 for now, but we may want
> +		 * to change this in the future for certain
> +		 * GPUs as it can increase performance in
> +		 * certain cases.
> +		 */
> +		if (amdgpu_noretry == -1)
> +			gmc->noretry = 0;
> +		else
> +			gmc->noretry = amdgpu_noretry;
> +		break;
> +	}
>  }
>  
>  void amdgpu_gmc_set_vm_fault_masks(struct amdgpu_device *adev, int hub_type,
> 

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

  reply	other threads:[~2020-09-23 14:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-23 14:08 [PATCH 1/2] drm/amdgpu: store noretry parameter per driver instance Alex Deucher
2020-09-23 14:08 ` [PATCH 2/2] drm/amdgpu: add an auto setting to the noretry parameter Alex Deucher
2020-09-23 14:48   ` Luben Tuikov [this message]
2020-09-24  6:37 ` [PATCH 1/2] drm/amdgpu: store noretry parameter per driver instance Christian König

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=3ec1aff1-9ca9-6a71-7871-5359d004566f@amd.com \
    --to=luben.tuikov@amd.com \
    --cc=alexander.deucher@amd.com \
    --cc=alexdeucher@gmail.com \
    --cc=amd-gfx@lists.freedesktop.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox