Fix GEM execbuf ioctl argument.
authorEric Anholt <eric@anholt.net>
Sat, 3 May 2008 01:24:13 +0000 (18:24 -0700)
committerEric Anholt <eric@anholt.net>
Sat, 3 May 2008 01:24:13 +0000 (18:24 -0700)
src/mesa/drivers/dri/intel/intel_ioctl.c

index b84cb64633cf5ce7e835755759878cca4d46ec2f..317ff2c440ff79a2113ed896b5ec29cff8b6dca3 100644 (file)
@@ -30,6 +30,8 @@
 #include <unistd.h>
 #include <errno.h>
 #include <sched.h>
+#include <sys/types.h>
+#include <sys/ioctl.h>
 
 #include "mtypes.h"
 #include "context.h"
@@ -170,8 +172,7 @@ intel_exec_ioctl(struct intel_context *intel,
                   (((GLuint) intel->drawY) << 16));
 
    do {
-      ret = drmCommandWriteRead(intel->driFd, DRM_I915_GEM_EXECBUFFER, &execbuf,
-                               sizeof(execbuf));
+      ret = ioctl(intel->driFd, DRM_IOCTL_I915_GEM_EXECBUFFER, execbuf);
    } while (ret == -EAGAIN);
 
    if (ret != 0) {