amd-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: "Xu, Feifei" <Feifei.Xu@amd.com>
To: "Yang, Stanley" <Stanley.Yang@amd.com>,
	"amd-gfx@lists.freedesktop.org" <amd-gfx@lists.freedesktop.org>
Cc: "Yang, Stanley" <Stanley.Yang@amd.com>,
	"Clements, John" <John.Clements@amd.com>,
	"Li, Dennis" <Dennis.Li@amd.com>,
	"Zhang, Hawking" <Hawking.Zhang@amd.com>
Subject: RE: [PATCH Review 1/1] drm/amdgpu: optimize gfx ras features flag clean
Date: Wed, 21 Apr 2021 06:54:21 +0000	[thread overview]
Message-ID: <DM6PR12MB4603A380C3698E47C5CBD46CFE479@DM6PR12MB4603.namprd12.prod.outlook.com> (raw)
In-Reply-To: <20210419094421.24049-1-Stanley.Yang@amd.com>

[AMD Official Use Only - Internal Distribution Only]

Reviewed-by: Feifei Xu <Feifei.Xu@amd.com>

-----Original Message-----
From: Stanley.Yang <Stanley.Yang@amd.com>
Sent: Monday, April 19, 2021 5:44 PM
To: amd-gfx@lists.freedesktop.org
Cc: Zhang, Hawking <Hawking.Zhang@amd.com>; Clements, John <John.Clements@amd.com>; Li, Dennis <Dennis.Li@amd.com>; Xu, Feifei <Feifei.Xu@amd.com>; Yang, Stanley <Stanley.Yang@amd.com>
Subject: [PATCH Review 1/1] drm/amdgpu: optimize gfx ras features flag clean

Signed-off-by: Stanley.Yang <Stanley.Yang@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c
index ec3ebc33ee03..8fdf355d7de8 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c
@@ -657,11 +657,7 @@ static int __amdgpu_ras_feature_enable(struct amdgpu_device *adev,
 con->features |= BIT(head->block);
 } else {
 if (obj && amdgpu_ras_is_feature_enabled(adev, head)) {
-/* skip clean gfx ras context feature for VEGA20 Gaming.
- * will clean later
- */
-if (!(!adev->ras_features && con->features & BIT(AMDGPU_RAS_BLOCK__GFX)))
-con->features &= ~BIT(head->block);
+con->features &= ~BIT(head->block);
 put_obj(obj);
 }
 }
@@ -769,6 +765,10 @@ int amdgpu_ras_feature_enable_on_boot(struct amdgpu_device *adev,
 con->features |= BIT(head->block);

 ret = amdgpu_ras_feature_enable(adev, head, 0);
+
+/* clean gfx block ras features flag */
+if (adev->ras_features && head->block == AMDGPU_RAS_BLOCK__GFX)
+con->features &= ~BIT(head->block);
 }
 } else
 ret = amdgpu_ras_feature_enable(adev, head, enable);
--
2.17.1

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

      reply	other threads:[~2021-04-21  6:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-19  9:44 [PATCH Review 1/1] drm/amdgpu: optimize gfx ras features flag clean Stanley.Yang
2021-04-21  6:54 ` Xu, Feifei [this message]

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=DM6PR12MB4603A380C3698E47C5CBD46CFE479@DM6PR12MB4603.namprd12.prod.outlook.com \
    --to=feifei.xu@amd.com \
    --cc=Dennis.Li@amd.com \
    --cc=Hawking.Zhang@amd.com \
    --cc=John.Clements@amd.com \
    --cc=Stanley.Yang@amd.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;
as well as URLs for NNTP newsgroup(s).