mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bo YU <tsu.yubo@gmail.com>
To: alexander.deucher@amd.com, christian.koenig@amd.com,
	David1.Zhou@amd.com, airlied@linux.ie, daniel@ffwll.ch,
	Rex.Zhu@amd.com, andrey.grodzovsky@amd.com,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Cc: Bo Yu <tsu.yubo@gmail.com>, amd-gfx@lists.freedesktop.org
Subject: [PATCH] drm/amdgpu: Error handling issues about CHECKED_RETURN
Date: Wed, 13 Feb 2019 23:46:28 -0500	[thread overview]
Message-ID: <20190214044628.26759-1-tsu.yubo@gmail.com> (raw)

From: Bo Yu <tsu.yubo@gmail.com>

Calling "amdgpu_ring_test_helper" without checking return value

Signed-off-by: Bo Yu <tsu.yubo@gmail.com>
---
 drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c
index 57cb3a51bda7..48465a61516b 100644
--- a/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c
@@ -4728,7 +4728,9 @@ static int gfx_v8_0_cp_test_all_rings(struct amdgpu_device *adev)
 
 	for (i = 0; i < adev->gfx.num_compute_rings; i++) {
 		ring = &adev->gfx.compute_ring[i];
-		amdgpu_ring_test_helper(ring);
+		r = amdgpu_ring_test_helper(ring);
+		if (r)
+			return r;
 	}
 
 	return 0;
-- 
2.11.0


             reply	other threads:[~2019-02-14  4:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-14  4:46 Bo YU [this message]
2019-02-14  5:09 ` Zhou, David(ChunMing)

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=20190214044628.26759-1-tsu.yubo@gmail.com \
    --to=tsu.yubo@gmail.com \
    --cc=David1.Zhou@amd.com \
    --cc=Rex.Zhu@amd.com \
    --cc=airlied@linux.ie \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=andrey.grodzovsky@amd.com \
    --cc=christian.koenig@amd.com \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®