drm/vmwgfx: Return -ENOENT when a framebuffer can't be found
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Thu, 17 Oct 2013 10:35:06 +0000 (13:35 +0300)
committerDave Airlie <airlied@redhat.com>
Wed, 6 Nov 2013 03:25:22 +0000 (13:25 +1000)
Let's be a bit more consistent with our error values.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/vmwgfx/vmwgfx_ioctl.c

index c509d40c4897ad9e1bdf8fd37d6618c9ccb44be0..a51f48e3e917e0d3f5d4c73202be335df6f6919b 100644 (file)
@@ -168,7 +168,7 @@ int vmw_present_ioctl(struct drm_device *dev, void *data,
        fb = drm_framebuffer_lookup(dev, arg->fb_id);
        if (!fb) {
                DRM_ERROR("Invalid framebuffer id.\n");
-               ret = -EINVAL;
+               ret = -ENOENT;
                goto out_no_fb;
        }
        vfb = vmw_framebuffer_to_vfb(fb);
@@ -252,7 +252,7 @@ int vmw_present_readback_ioctl(struct drm_device *dev, void *data,
        fb = drm_framebuffer_lookup(dev, arg->fb_id);
        if (!fb) {
                DRM_ERROR("Invalid framebuffer id.\n");
-               ret = -EINVAL;
+               ret = -ENOENT;
                goto out_no_fb;
        }
 
This page took 0.026406 seconds and 5 git commands to generate.