[Intel-gfx] [PATCH 3/4] tests/gem_gtt_hog: Use XY_COLOR_BLT instead of COLOR_BLT.

2014-03-18 Thread Rodrigo Vivi
Signed-off-by: Rodrigo Vivi rodrigo.v...@gmail.com
---
 tests/gem_gtt_hog.c | 11 +--
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/tests/gem_gtt_hog.c b/tests/gem_gtt_hog.c
index 5f14109..d22e074 100644
--- a/tests/gem_gtt_hog.c
+++ b/tests/gem_gtt_hog.c
@@ -42,9 +42,6 @@
 #include i915_drm.h
 #include drmtest.h
 
-#define BLT_WRITE_ALPHA(121)
-#define BLT_WRITE_RGB  (120)
-
 static const uint32_t canary = 0xdeadbeef;
 
 static double elapsed(const struct timeval *start,
@@ -60,7 +57,7 @@ static void busy(int fd, uint32_t handle, int size, int loops)
struct drm_i915_gem_execbuffer2 execbuf;
struct drm_i915_gem_pwrite gem_pwrite;
struct drm_i915_gem_create create;
-   uint32_t buf[102], *b;
+   uint32_t buf[122], *b;
int i;
 
memset(reloc, 0, sizeof(reloc));
@@ -69,9 +66,11 @@ static void busy(int fd, uint32_t handle, int size, int 
loops)
 
b = buf;
for (i = 0; i  20; i++) {
-   *b++ = COLOR_BLT_CMD | BLT_WRITE_ALPHA | BLT_WRITE_RGB;
+   *b++ = XY_COLOR_BLT_CMD_NOLEN | 4 |
+   COLOR_BLT_WRITE_ALPHA | XY_COLOR_BLT_WRITE_RGB;
*b++ = 0xf0  16 | 1  25 | 1  24 | 4096;
-   *b++ = size  12  16 | 4096;
+   *b++ = 0;
+   *b++ = size  12  16 | 1024;
reloc[i].offset = (b - buf) * sizeof(uint32_t);
reloc[i].target_handle = handle;
reloc[i].read_domains = I915_GEM_DOMAIN_RENDER;
-- 
1.8.5.3

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


[Intel-gfx] [PATCH 3/4] tests/gem_gtt_hog: Use XY_COLOR_BLT instead of COLOR_BLT.

2014-02-06 Thread Rodrigo Vivi
Signed-off-by: Rodrigo Vivi rodrigo.v...@gmail.com
---
 tests/gem_gtt_hog.c | 11 +--
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/tests/gem_gtt_hog.c b/tests/gem_gtt_hog.c
index 53d7dd7..53cd7eb 100644
--- a/tests/gem_gtt_hog.c
+++ b/tests/gem_gtt_hog.c
@@ -42,9 +42,6 @@
 #include i915_drm.h
 #include drmtest.h
 
-#define BLT_WRITE_ALPHA(121)
-#define BLT_WRITE_RGB  (120)
-
 static const uint32_t canary = 0xdeadbeef;
 
 static double elapsed(const struct timeval *start,
@@ -60,7 +57,7 @@ static void busy(int fd, uint32_t handle, int size, int loops)
struct drm_i915_gem_execbuffer2 execbuf;
struct drm_i915_gem_pwrite gem_pwrite;
struct drm_i915_gem_create create;
-   uint32_t buf[102], *b;
+   uint32_t buf[122], *b;
int i;
 
memset(reloc, 0, sizeof(reloc));
@@ -69,9 +66,11 @@ static void busy(int fd, uint32_t handle, int size, int 
loops)
 
b = buf;
for (i = 0; i  20; i++) {
-   *b++ = COLOR_BLT_CMD | BLT_WRITE_ALPHA | BLT_WRITE_RGB;
+   *b++ = XY_COLOR_BLT_CMD_NOLEN | 4 |
+   COLOR_BLT_WRITE_ALPHA | XY_COLOR_BLT_WRITE_RGB;
*b++ = 0xf0  16 | 1  25 | 1  24 | 4096;
-   *b++ = size  12  16 | 4096;
+   *b++ = 0;
+   *b++ = size  12  16 | 1024;
reloc[i].offset = (b - buf) * sizeof(uint32_t);
reloc[i].target_handle = handle;
reloc[i].read_domains = I915_GEM_DOMAIN_RENDER;
-- 
1.8.3.1

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