public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Anuj Phogat <anuj.phogat@gmail.com>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH 4/5] Align YS tile base address to 64KB
Date: Mon, 30 Mar 2015 14:00:07 -0700	[thread overview]
Message-ID: <1427749208-8961-5-git-send-email-anuj.phogat@gmail.com> (raw)
In-Reply-To: <1427749208-8961-1-git-send-email-anuj.phogat@gmail.com>

Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
---
 intel/intel_bufmgr_gem.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/intel/intel_bufmgr_gem.c b/intel/intel_bufmgr_gem.c
index 7c50e26..775a9f9 100644
--- a/intel/intel_bufmgr_gem.c
+++ b/intel/intel_bufmgr_gem.c
@@ -289,8 +289,13 @@ drm_intel_gem_bo_tile_size(drm_intel_bufmgr_gem *bufmgr_gem, unsigned long size,
 	if (*tiling_mode == I915_TILING_NONE)
 		return size;
 
+	/* Tiled surface base addresses must be tile aligned (64KB aligned
+	 * for TileYS, 4KB aligned for all other tile modes).
+	 */
+	if (*tiling_mode == I915_TILING_YS)
+		return ROUND_UP_TO(size, 64 * 1024);
 	/* 965+ just need multiples of page size for tiling */
-	if (bufmgr_gem->gen >= 4)
+	else if (bufmgr_gem->gen >= 4)
 		return ROUND_UP_TO(size, 4096);
 
 	/* Older chips need powers of two, of at least 512k or 1M */
-- 
2.3.4

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

  parent reply	other threads:[~2015-03-30 21:01 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-30 21:00 [PATCH 0/5] i965/skl: Add YF/YS tiling support Anuj Phogat
2015-03-30 21:00 ` [PATCH 1/5] i965/skl: Add macros for Yf/Ys tiling formats Anuj Phogat
2015-03-31 13:17   ` Daniel Vetter
2015-03-31 22:16     ` Anuj Phogat
2015-03-30 21:00 ` [PATCH 2/5] i965/skl: Move tile_width computations out of drm_intel_gem_bo_tile_pitch Anuj Phogat
2015-03-30 21:00 ` [PATCH 3/5] i965/skl: Set tile width and height for YF/YS tiling Anuj Phogat
2015-03-31  8:36   ` Tvrtko Ursulin
2015-03-30 21:00 ` Anuj Phogat [this message]
2015-03-31 14:26   ` [PATCH 4/5] Align YS tile base address to 64KB Damien Lespiau
2015-03-31 17:49     ` Anuj Phogat
2015-03-31 17:57       ` Damien Lespiau
2015-04-01  6:11         ` Daniel Vetter
2015-04-01 16:31           ` Anuj Phogat
2015-03-30 21:00 ` [PATCH 5/5] build: Bump the version to 2.4.61 Anuj Phogat
2015-03-31 14:28   ` Damien Lespiau
2015-03-31 17:51     ` Anuj Phogat
2015-04-01  6:13       ` 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=1427749208-8961-5-git-send-email-anuj.phogat@gmail.com \
    --to=anuj.phogat@gmail.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox