All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel.vetter@ffwll.ch>
To: Intel Graphics Development <intel-gfx@lists.freedesktop.org>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Subject: [PATCH 02/14] drm/i915: set ring->size in common ring setup code
Date: Wed, 11 Apr 2012 22:12:47 +0200	[thread overview]
Message-ID: <1334175179-1514-3-git-send-email-daniel.vetter@ffwll.ch> (raw)
In-Reply-To: <1334175179-1514-1-git-send-email-daniel.vetter@ffwll.ch>

Eventually we want to scale the ring size depending upon available
gtt space. For now just consolidate this instead of replicating it
over all ringbuffer templates.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 drivers/gpu/drm/i915/intel_ringbuffer.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c b/drivers/gpu/drm/i915/intel_ringbuffer.c
index 54595cd..8131c40 100644
--- a/drivers/gpu/drm/i915/intel_ringbuffer.c
+++ b/drivers/gpu/drm/i915/intel_ringbuffer.c
@@ -989,6 +989,7 @@ int intel_init_ring_buffer(struct drm_device *dev,
 	INIT_LIST_HEAD(&ring->active_list);
 	INIT_LIST_HEAD(&ring->request_list);
 	INIT_LIST_HEAD(&ring->gpu_write_list);
+	ring->size = 32 * PAGE_SIZE;
 
 	init_waitqueue_head(&ring->irq_queue);
 	spin_lock_init(&ring->irq_lock);
@@ -1262,7 +1263,6 @@ static const struct intel_ring_buffer render_ring = {
 	.name			= "render ring",
 	.id			= RCS,
 	.mmio_base		= RENDER_RING_BASE,
-	.size			= 32 * PAGE_SIZE,
 	.init			= init_render_ring,
 	.write_tail		= ring_write_tail,
 	.flush			= render_ring_flush,
@@ -1285,7 +1285,6 @@ static const struct intel_ring_buffer bsd_ring = {
 	.name                   = "bsd ring",
 	.id			= VCS,
 	.mmio_base		= BSD_RING_BASE,
-	.size			= 32 * PAGE_SIZE,
 	.init			= init_ring_common,
 	.write_tail		= ring_write_tail,
 	.flush			= bsd_ring_flush,
@@ -1363,7 +1362,6 @@ static const struct intel_ring_buffer gen6_bsd_ring = {
 	.name			= "gen6 bsd ring",
 	.id			= VCS,
 	.mmio_base		= GEN6_BSD_RING_BASE,
-	.size			= 32 * PAGE_SIZE,
 	.init			= init_ring_common,
 	.write_tail		= gen6_bsd_ring_write_tail,
 	.flush			= gen6_ring_flush,
@@ -1407,7 +1405,6 @@ static const struct intel_ring_buffer gen6_blt_ring = {
 	.name			= "blt ring",
 	.id			= BCS,
 	.mmio_base		= BLT_RING_BASE,
-	.size			= 32 * PAGE_SIZE,
 	.init			= init_ring_common,
 	.write_tail		= ring_write_tail,
 	.flush			= blt_ring_flush,
-- 
1.7.7.5

  parent reply	other threads:[~2012-04-11 19:58 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-11 20:12 [PATCH 00/14] intel_ringbuffer.c reorg + cleanups Daniel Vetter
2012-04-11 20:12 ` [PATCH 01/14] drm/i915: rip out ring->irq_mask Daniel Vetter
2012-04-11 20:12 ` Daniel Vetter [this message]
2012-04-12 19:23   ` [PATCH 02/14] drm/i915: set ring->size in common ring setup code Ben Widawsky
2012-04-12 20:17     ` Daniel Vetter
2012-04-11 20:12 ` [PATCH 03/14] drm/i915: dynamically set up the render ring functions and params Daniel Vetter
2012-04-11 20:12 ` [PATCH 04/14] drm/i915: dynamically set up bsd " Daniel Vetter
2012-04-11 20:12 ` [PATCH 05/14] drm/i915: dynamically set up blt ring functions and parameters Daniel Vetter
2012-04-11 20:12 ` [PATCH 06/14] drm/i915: don't set up rings on gen6+ for non-kms Daniel Vetter
2012-04-11 20:12 ` [PATCH 07/14] drm/i915: consolidate ring->sync-to functions Daniel Vetter
2012-04-11 20:12 ` [PATCH 08/14] drm/i915: abstract away ring-specific irq_get/put Daniel Vetter
2012-04-11 20:12 ` [PATCH 09/14] drm/i915: split out the gen5 ring irq get/put functions Daniel Vetter
2012-04-11 20:12 ` [PATCH 10/14] drm/i915: don't enable the gen6 bsd ring tail write enable on gen7 Daniel Vetter
2012-04-11 20:12 ` [PATCH 11/14] drm/i915: split up ring->dispatch_execbuffer functions Daniel Vetter
2012-04-11 20:12 ` [PATCH 12/14] drm/i915: consolidate ring->flush a bit Daniel Vetter
2012-04-13  0:54   ` Ben Widawsky
2012-04-13  9:03     ` Daniel Vetter
2012-04-11 20:12 ` [PATCH 13/14] drm/i915: don't set up gem ring functions on gen5 for !kms Daniel Vetter
2012-04-13  1:05   ` Ben Widawsky
2012-04-13  9:07     ` Daniel Vetter
2012-04-11 20:12 ` [PATCH 14/14] drm/i915: inline enable/disable_irq into ring->get/put_irq Daniel Vetter
2012-04-13  1:03   ` Ben Widawsky
2012-04-13  9:13     ` Daniel Vetter
2012-04-13  9:17       ` Chris Wilson
2012-04-11 20:49 ` [PATCH 00/14] intel_ringbuffer.c reorg + cleanups Chris Wilson
2012-04-11 23:42 ` Eric Anholt
2012-04-13 10:56   ` Daniel Vetter

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=1334175179-1514-3-git-send-email-daniel.vetter@ffwll.ch \
    --to=daniel.vetter@ffwll.ch \
    --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.