diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2013-08-10 15:49:33 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2013-08-10 15:49:33 +0100 |
commit | 467796acc80ced3440740d267c2e2a4f246d4b8a (patch) | |
tree | 0a8515b387709e1a41d468d2b0a6407b559869e7 /tests/gem_partial_pwrite_pread.c | |
parent | dbbf2e9b24d1488402269a803a230f341791d39a (diff) |
Expand gem_set_cacheing testing to handle the proposed DISPLAY domain
Diffstat (limited to 'tests/gem_partial_pwrite_pread.c')
-rw-r--r-- | tests/gem_partial_pwrite_pread.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/tests/gem_partial_pwrite_pread.c b/tests/gem_partial_pwrite_pread.c index eac27604..ee176b1d 100644 --- a/tests/gem_partial_pwrite_pread.c +++ b/tests/gem_partial_pwrite_pread.c @@ -257,8 +257,17 @@ static void do_tests(int cache_level, const char *suffix) { char name[80]; - if (cache_level != -1) - gem_set_cacheing(fd, scratch_bo->handle, cache_level); + if (cache_level != -1) { + switch (gem_set_cacheing(fd, scratch_bo->handle, cache_level)) { + case 0: break; + case -EINVAL: + case -ENOTTY: + return; + default: + assert(0); + return; + } + } snprintf(name, sizeof(name), "reads%s", suffix); if (drmtest_run_subtest(name)) @@ -299,6 +308,7 @@ int main(int argc, char **argv) /* Repeat the tests using different levels of snooping */ do_tests(0, "-uncached"); do_tests(1, "-snoop"); + do_tests(2, "-display"); drmtest_cleanup_aperture_trashers(); drm_intel_bufmgr_destroy(bufmgr); |