diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2010-04-08 11:56:57 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2010-04-08 12:17:31 +0100 |
commit | 95374225e865da3a30153f73e8bb536700d15459 (patch) | |
tree | ab8797a6f255a0d76e5d8e7439b8fe4a9b34ca90 /tests/gem_ringfill.c | |
parent | cd64e193299be4b9733a5e804cedd99e2072830f (diff) |
Enable compilation on non-Intel, non-DRM systems.
A few of the tools can be performed post-mortem from a different system,
so it is useful to be able to compile those tools on those foreign
systems. Obviously, any program to interact with the PCI device or talk
to GEM will fail on a non-Intel system.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'tests/gem_ringfill.c')
-rw-r--r-- | tests/gem_ringfill.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/gem_ringfill.c b/tests/gem_ringfill.c index d245f1fe..c9860aa6 100644 --- a/tests/gem_ringfill.c +++ b/tests/gem_ringfill.c @@ -55,11 +55,12 @@ static const int size = 1024 * 1024; int main(int argc, char **argv) { int fd; + uint32_t devid; int i; drm_intel_bo *src_bo, *dst_bo; fd = drm_open_any(); - intel_get_drm_devid(fd); + devid = intel_get_drm_devid(fd); bufmgr = drm_intel_bufmgr_gem_init(fd, 4096); drm_intel_bufmgr_gem_enable_reuse(bufmgr); @@ -84,7 +85,7 @@ int main(int argc, char **argv) * doing this, we aren't likely to with this test. */ for (i = 0; i < 128 * 1024 / (8 * 4) * 1.25; i++) { - intel_copy_bo(batch, dst_bo, src_bo, width, height); + intel_copy_bo(batch, dst_bo, src_bo, width, height, devid); intel_batchbuffer_flush(batch); } |