tests/gem_lut_handle: Limit testing LUT interface to recent kernels
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 17 Jan 2013 15:07:50 +0000 (15:07 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 17 Jan 2013 15:10:29 +0000 (15:10 +0000)
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
tests/gem_exec_lut_handle.c
tests/gem_lut_handle.c

index 218e8ca..4f544ad 100644 (file)
@@ -143,7 +143,8 @@ int main(int argc, char **argv)
        gem_exec[n].handle =  gem_create(fd, 4096);
        gem_write(fd, gem_exec[n].handle, 0, batch, sizeof(batch));
 
-       do_or_die(exec(fd, MAX_NUM_EXEC, 0, USE_LUT));
+       if (exec(fd, 1, 0, USE_LUT))
+               return 77;
 
        for (p = pass; p->name != NULL; p++) {
                for (n = 1; n <= MAX_NUM_EXEC; n *= 2) {
index 6b58538..a051003 100644 (file)
@@ -185,9 +185,12 @@ int main(int argc, char **argv)
        gem_write(fd, handle, 0, batch, sizeof(batch));
 
        do_or_die(exec(fd, handle, NORMAL));
-       do_or_die(exec(fd, handle, USE_LUT));
-
        fail(exec(fd, handle, BROKEN));
+
+       if (exec(fd, handle, USE_LUT))
+               return 77;
+
+       do_or_die(exec(fd, handle, USE_LUT));
        fail(exec(fd, handle, USE_LUT | BROKEN));
 
        for (i = 2; i <= 65536; i *= 2) {