drm/i915/skl: Fix up positive error code
authorTvrtko Ursulin <tvrtko.ursulin@intel.com>
Wed, 25 Mar 2015 10:15:26 +0000 (10:15 +0000)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 25 Mar 2015 17:23:43 +0000 (18:23 +0100)
It should have been negative since it is returned with ERR_PTR().

Introduced in new code commit:

   commit 50470bb011c4be278097670bea92462f4e8c8945
   Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
   Date:   Mon Mar 23 11:10:36 2015 +0000

    drm/i915/skl: Support secondary (rotated) frame buffer mapping

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem_gtt.c

index fc56c11..9903bb0 100644 (file)
@@ -2540,7 +2540,7 @@ intel_rotate_fb_obj_pages(struct i915_ggtt_view *ggtt_view,
        struct sg_table *st;
        unsigned int tile_pitch, tile_height;
        unsigned int width_pages, height_pages;
-       int ret = ENOMEM;
+       int ret = -ENOMEM;
 
        pages = obj->base.size / PAGE_SIZE;