From: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
To: Andi Shyti <andi.shyti@linux.intel.com>
Cc: Intel-gfx@lists.freedesktop.org,
Dan Carpenter <dan.carpenter@linaro.org>,
dri-devel@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH] drm/i915/selftests: Add some missing error propagation
Date: Tue, 6 Jun 2023 10:44:50 +0100 [thread overview]
Message-ID: <e2f3a990-0fb9-74a2-3b1c-7a30fefda84b@linux.intel.com> (raw)
In-Reply-To: <ZH3ncqduEdlMRh98@ashyti-mobl2.lan>
On 05/06/2023 14:47, Andi Shyti wrote:
> Hi Tvrtko,
>
>> Add some missing error propagation in live_parallel_switch.
>>
>> To avoid needlessly burdening the various backport processes, note I am
>> not marking it as a fix against any patches and not copying stable since
>> it is debug/selftests only code.
>
> which I did :/
>
> But I guess you are right and it's not necessary.
>
>> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
>> Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
>> Cc: Andi Shyti <andi.shyti@linux.intel.com>
>> ---
>> .../gpu/drm/i915/gem/selftests/i915_gem_context.c | 14 ++++++++++----
>> 1 file changed, 10 insertions(+), 4 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c b/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
>> index ad6a3b2fb387..7021b6e9b219 100644
>> --- a/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
>> +++ b/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
>> @@ -348,8 +348,10 @@ static int live_parallel_switch(void *arg)
>> continue;
>>
>> ce = intel_context_create(data[m].ce[0]->engine);
>> - if (IS_ERR(ce))
>> + if (IS_ERR(ce)) {
>> + err = PTR_ERR(ce);
>> goto out;
>> + }
>>
>> err = intel_context_pin(ce);
>> if (err) {
>> @@ -369,8 +371,10 @@ static int live_parallel_switch(void *arg)
>>
>> worker = kthread_create_worker(0, "igt/parallel:%s",
>> data[n].ce[0]->engine->name);
>> - if (IS_ERR(worker))
>> + if (IS_ERR(worker)) {
>> + err = PTR_ERR(worker);
>> goto out;
>> + }
>>
>> data[n].worker = worker;
>> }
>> @@ -399,8 +403,10 @@ static int live_parallel_switch(void *arg)
>> }
>> }
>>
>> - if (igt_live_test_end(&t))
>> - err = -EIO;
>> + if (igt_live_test_end(&t)) {
>> + err = err ?: -EIO;
>
> Nice catch!
>
> Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com>
Thanks, pushed! (with Fixes tags added)
Regards,
Tvrtko
next prev parent reply other threads:[~2023-06-06 9:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-05 13:11 [Intel-gfx] [PATCH] drm/i915/selftests: Add some missing error propagation Tvrtko Ursulin
2023-06-05 13:43 ` Dan Carpenter
2023-06-05 14:54 ` Tvrtko Ursulin
2023-06-05 13:47 ` Andi Shyti
2023-06-06 9:44 ` Tvrtko Ursulin [this message]
2023-06-05 15:18 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
2023-06-05 15:32 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-06-06 11:21 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
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=e2f3a990-0fb9-74a2-3b1c-7a30fefda84b@linux.intel.com \
--to=tvrtko.ursulin@linux.intel.com \
--cc=Intel-gfx@lists.freedesktop.org \
--cc=andi.shyti@linux.intel.com \
--cc=dan.carpenter@linaro.org \
--cc=dri-devel@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