From: Tvrtko Ursulin Date: Wed, 25 Mar 2015 10:15:26 +0000 (+0000) Subject: drm/i915/skl: Fix up positive error code X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=1d00dad56b15ed5dab5802143df2bf61d51b6b55;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git drm/i915/skl: Fix up positive error code It should have been negative since it is returned with ERR_PTR(). Introduced in new code commit: commit 50470bb011c4be278097670bea92462f4e8c8945 Author: Tvrtko Ursulin Date: Mon Mar 23 11:10:36 2015 +0000 drm/i915/skl: Support secondary (rotated) frame buffer mapping Signed-off-by: Tvrtko Ursulin Reported-by: Dan Carpenter Signed-off-by: Daniel Vetter --- diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c index fc56c112a7de..9903bb0097a6 100644 --- a/drivers/gpu/drm/i915/i915_gem_gtt.c +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c @@ -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;