All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Wilson <chris@chris-wilson.co.uk>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH 8/9] drm/i915: Rename ring->virtual_start as ring->vaddr
Date: Wed, 20 Jul 2016 10:00:01 +0100	[thread overview]
Message-ID: <1469005202-9659-9-git-send-email-chris@chris-wilson.co.uk> (raw)
In-Reply-To: <1469005202-9659-1-git-send-email-chris@chris-wilson.co.uk>

Just a different colour to better match virtual addresses elsewhere.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 drivers/gpu/drm/i915/i915_irq.c         |  2 +-
 drivers/gpu/drm/i915/intel_ringbuffer.c | 11 +++++------
 drivers/gpu/drm/i915/intel_ringbuffer.h |  4 ++--
 3 files changed, 8 insertions(+), 9 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c
index 38d9ae90b613..0fef5cda4aca 100644
--- a/drivers/gpu/drm/i915/i915_irq.c
+++ b/drivers/gpu/drm/i915/i915_irq.c
@@ -2899,7 +2899,7 @@ semaphore_waits_for(struct intel_engine_cs *engine, u32 *seqno)
 	 */
 	head = I915_READ_HEAD(engine) & HEAD_ADDR;
 	backwards = (INTEL_GEN(dev_priv) >= 8) ? 5 : 4;
-	vaddr = (void __iomem *) engine->buffer->virtual_start;
+	vaddr = (void __iomem *) engine->buffer->vaddr;
 
 	for (i = backwards; i; --i) {
 		/*
diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c b/drivers/gpu/drm/i915/intel_ringbuffer.c
index afed24abb596..b9638e19d304 100644
--- a/drivers/gpu/drm/i915/intel_ringbuffer.c
+++ b/drivers/gpu/drm/i915/intel_ringbuffer.c
@@ -1972,14 +1972,14 @@ static int init_phys_status_page(struct intel_engine_cs *engine)
 
 void intel_unpin_ringbuffer_obj(struct intel_ringbuffer *ringbuf)
 {
-	GEM_BUG_ON(ringbuf->vma == NULL);
-	GEM_BUG_ON(ringbuf->virtual_start == NULL);
+	GEM_BUG_ON(!ringbuf->vma);
+	GEM_BUG_ON(!ringbuf->vaddr);
 
 	if (HAS_LLC(ringbuf->obj->base.dev) && !ringbuf->obj->stolen)
 		i915_gem_object_unpin_map(ringbuf->obj);
 	else
 		i915_vma_unpin_iomap(ringbuf->vma);
-	ringbuf->virtual_start = NULL;
+	ringbuf->vaddr = NULL;
 
 	i915_gem_object_ggtt_unpin(ringbuf->obj);
 	ringbuf->vma = NULL;
@@ -2029,7 +2029,7 @@ int intel_pin_and_map_ringbuffer_obj(struct drm_i915_private *dev_priv,
 		}
 	}
 
-	ringbuf->virtual_start = addr;
+	ringbuf->vaddr = addr;
 	ringbuf->vma = i915_gem_obj_to_ggtt(obj);
 	return 0;
 
@@ -2391,8 +2391,7 @@ int intel_ring_begin(struct drm_i915_gem_request *req, int num_dwords)
 		GEM_BUG_ON(ringbuf->tail + remain_actual > ringbuf->size);
 
 		/* Fill the tail with MI_NOOP */
-		memset(ringbuf->virtual_start + ringbuf->tail,
-		       0, remain_actual);
+		memset(ringbuf->vaddr + ringbuf->tail, 0, remain_actual);
 		ringbuf->tail = 0;
 		ringbuf->space -= remain_actual;
 	}
diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.h b/drivers/gpu/drm/i915/intel_ringbuffer.h
index d1b2d9bd89eb..05bab8bda63d 100644
--- a/drivers/gpu/drm/i915/intel_ringbuffer.h
+++ b/drivers/gpu/drm/i915/intel_ringbuffer.h
@@ -84,7 +84,7 @@ struct intel_ring_hangcheck {
 
 struct intel_ringbuffer {
 	struct drm_i915_gem_object *obj;
-	void *virtual_start;
+	void *vaddr;
 	struct i915_vma *vma;
 
 	struct intel_engine_cs *engine;
@@ -457,7 +457,7 @@ int __must_check intel_ring_cacheline_align(struct drm_i915_gem_request *req);
 static inline void __intel_ringbuffer_emit(struct intel_ringbuffer *rb,
 					   u32 data)
 {
-	*(uint32_t *)(rb->virtual_start + rb->tail) = data;
+	*(uint32_t *)(rb->vaddr + rb->tail) = data;
 	rb->tail += 4;
 }
 
-- 
2.8.1

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

  parent reply	other threads:[~2016-07-20  9:00 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-20  8:59 A simple batch of churn to make reference handling look consistent Chris Wilson
2016-07-20  8:59 ` [PATCH 1/9] drm/i915: Rename request reference/unreference to get/put Chris Wilson
2016-07-20  8:59 ` [PATCH 2/9] drm/i915: Rename i915_gem_context_reference/unreference() Chris Wilson
2016-07-20  8:59 ` [PATCH 3/9] drm/i915: Wrap drm_gem_object_lookup in i915_gem_object_lookup Chris Wilson
2016-07-20 11:28   ` Dave Gordon
2016-07-20 11:38     ` Chris Wilson
2016-07-20 11:38   ` Joonas Lahtinen
2016-07-20 12:03     ` Chris Wilson
2016-07-20  8:59 ` [PATCH 4/9] drm/i915: Wrap drm_gem_object_reference in i915_gem_object_get Chris Wilson
2016-07-20 11:38   ` Dave Gordon
2016-07-20 11:45     ` Chris Wilson
2016-07-20 11:45   ` Joonas Lahtinen
2016-07-20  8:59 ` [PATCH 5/9] drm/i915: Rename drm_gem_object_unreference in preparation for lockless free Chris Wilson
2016-07-20 11:43   ` Joonas Lahtinen
2016-07-20 11:51     ` Dave Gordon
2016-07-20 12:11       ` Chris Wilson
2016-07-21 16:58   ` [PATCH] drm/i915: use i915_gem_object_put_unlocked() after releasing mutex Dave Gordon
2016-07-21 17:25     ` Chris Wilson
2016-07-20  8:59 ` [PATCH 6/9] drm/i915: Rename drm_gem_object_unreference_unlocked in preparation for lockless free Chris Wilson
2016-07-20 12:04   ` Joonas Lahtinen
2016-07-20  9:00 ` [PATCH 7/9] drm/i915: Treat ringbuffer writes as write to normal memory Chris Wilson
2016-07-20  9:00 ` Chris Wilson [this message]
2016-07-20 11:54   ` [PATCH 8/9] drm/i915: Rename ring->virtual_start as ring->vaddr Dave Gordon
2016-07-20 12:07   ` Joonas Lahtinen
2016-07-20  9:00 ` [PATCH 9/9] drm/i915: Convert i915_semaphores_is_enabled over to early sanitize Chris Wilson
2016-07-20 12:18   ` Joonas Lahtinen
2016-07-20  9:38 ` ✗ Ro.CI.BAT: failure for series starting with [1/9] drm/i915: Rename request reference/unreference to get/put Patchwork
2016-07-22  5:28 ` ✗ Ro.CI.BAT: failure for series starting with [1/9] drm/i915: Rename request reference/unreference to get/put (rev2) 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=1469005202-9659-9-git-send-email-chris@chris-wilson.co.uk \
    --to=chris@chris-wilson.co.uk \
    --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.