All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: maarten.lankhorst@linux.intel.com
Cc: intel-gfx@lists.freedesktop.org
Subject: [Intel-gfx] [bug report] drm/i915: Use ww pinning for intel_context_create_request()
Date: Thu, 10 Sep 2020 11:43:59 +0300	[thread overview]
Message-ID: <20200910084359.GA65053@mwanda> (raw)

Hello Maarten Lankhorst,

The patch 8a929c9eb1c2: "drm/i915: Use ww pinning for
intel_context_create_request()" from Aug 19, 2020, leads to the
following static checker warning:

	drivers/gpu/drm/i915/gt/intel_context.c:481 intel_context_create_request()
	error: uninitialized symbol 'rq'.

drivers/gpu/drm/i915/gt/intel_context.c
   459  struct i915_request *intel_context_create_request(struct intel_context *ce)
   460  {
   461          struct i915_gem_ww_ctx ww;
   462          struct i915_request *rq;
   463          int err;
   464  
   465          i915_gem_ww_ctx_init(&ww, true);
   466  retry:
   467          err = intel_context_pin_ww(ce, &ww);
   468          if (!err) {
   469                  rq = i915_request_create(ce);
   470                  intel_context_unpin(ce);
   471          } else if (err == -EDEADLK) {
   472                  err = i915_gem_ww_ctx_backoff(&ww);
   473                  if (!err)
   474                          goto retry;

"rq" not initialized on the -EDEADLK path.

   475          } else {
   476                  rq = ERR_PTR(err);
   477          }
   478  
   479          i915_gem_ww_ctx_fini(&ww);
   480  
   481          if (IS_ERR(rq))
                           ^^

   482                  return rq;
   483  

regards,
dan carpenter
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

                 reply	other threads:[~2020-09-10  8:46 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20200910084359.GA65053@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=maarten.lankhorst@linux.intel.com \
    /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.