All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ben Widawsky <ben@bwidawsk.net>
To: Intel GFX <intel-gfx@lists.freedesktop.org>
Cc: Ben Widawsky <ben@bwidawsk.net>
Subject: [PATCH] drm/i915: Don't try to deref an unbound VMA
Date: Wed, 17 Jul 2013 19:32:33 -0700	[thread overview]
Message-ID: <1374114753-871-1-git-send-email-ben@bwidawsk.net> (raw)
In-Reply-To: <20130718001217.GE6210@cantiga.alporthouse.com>

This was actually correct in the original series, and is also fixed
later in the patch series, but was broken in this middle state.

I'm not really certain how I didn't hit it sooner.

This patch should be squashed into:
commit 8f588cfc349bbbd8ae62a13679b9efba41645064
Author: Ben Widawsky <ben@bwidawsk.net>
Date:   Wed Jul 17 12:19:03 2013 -0700

    drm/i915: Create VMAs

CC: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
---
 drivers/gpu/drm/i915/i915_gem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index a9fa2bb..c9487bb 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -3314,7 +3314,7 @@ int i915_gem_object_set_cache_level(struct drm_i915_gem_object *obj,
 		return -EBUSY;
 	}
 
-	if (!i915_gem_valid_gtt_space(dev, &vma->node, cache_level)) {
+	if (vma && !i915_gem_valid_gtt_space(dev, &vma->node, cache_level)) {
 		ret = i915_gem_object_unbind(obj);
 		if (ret)
 			return ret;
-- 
1.8.3.3

  parent reply	other threads:[~2013-07-18  2:32 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-16 23:50 [PATCH 1/5] [v3] drm/i915: Move gtt and ppgtt under address space umbrella Ben Widawsky
2013-07-16 23:50 ` [PATCH 2/5] [v2] drm/i915: Put the mm in the parent address space Ben Widawsky
2013-07-16 23:50 ` [PATCH 3/5] [v2] drm/i915: Create a global list of vms Ben Widawsky
2013-07-16 23:50 ` [PATCH 4/5] [v2] drm/i915: Move active/inactive lists to new mm Ben Widawsky
2013-07-16 23:50 ` [PATCH 5/5] [v5] drm/i915: Create VMAs Ben Widawsky
2013-07-17 14:43   ` Imre Deak
2013-07-17 19:19   ` [PATCH 5/6] drm/i915: Free stolen node on failed preallocation Ben Widawsky
2013-07-17 19:19     ` [PATCH 6/6] drm/i915: Create VMAs Ben Widawsky
2013-07-17 20:27       ` Daniel Vetter
2013-07-18  0:12       ` Chris Wilson
2013-07-18  2:31         ` Ben Widawsky
2013-07-18  8:19           ` Chris Wilson
2013-07-18  2:32         ` Ben Widawsky [this message]
2013-07-18  6:47           ` [PATCH] drm/i915: Don't try to deref an unbound VMA Daniel Vetter
2013-07-18 12:08       ` [PATCH 6/6] drm/i915: Create VMAs Imre Deak

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=1374114753-871-1-git-send-email-ben@bwidawsk.net \
    --to=ben@bwidawsk.net \
    --cc=intel-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 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.