Commit 46acbf13 authored by Dave Airlie's avatar Dave Airlie
Browse files

drm: fixup i915 error codes



Frederik Deweerdt <deweerdt@free.fr> pointed this out, I fixed a missing
DRM error wrapper also.
Signed-off-by: default avatarDave Airlie <airlied@linux.ie>
parent b15ec368
...@@ -260,7 +260,7 @@ static int i915_dma_init(DRM_IOCTL_ARGS) ...@@ -260,7 +260,7 @@ static int i915_dma_init(DRM_IOCTL_ARGS)
retcode = i915_dma_resume(dev); retcode = i915_dma_resume(dev);
break; break;
default: default:
retcode = -EINVAL; retcode = DRM_ERR(EINVAL);
break; break;
} }
...@@ -391,7 +391,7 @@ static int i915_emit_box(drm_device_t * dev, ...@@ -391,7 +391,7 @@ static int i915_emit_box(drm_device_t * dev,
RING_LOCALS; RING_LOCALS;
if (DRM_COPY_FROM_USER_UNCHECKED(&box, &boxes[i], sizeof(box))) { if (DRM_COPY_FROM_USER_UNCHECKED(&box, &boxes[i], sizeof(box))) {
return EFAULT; return DRM_ERR(EFAULT);
} }
if (box.y2 <= box.y1 || box.x2 <= box.x1 || box.y2 <= 0 || box.x2 <= 0) { if (box.y2 <= box.y1 || box.x2 <= box.x1 || box.y2 <= 0 || box.x2 <= 0) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment