drm/omap: remove null test before kfree
authorFabian Frederick <fabf@skynet.be>
Fri, 4 Jul 2014 19:17:15 +0000 (21:17 +0200)
committerDavid Herrmann <dh.herrmann@gmail.com>
Mon, 7 Jul 2014 22:34:19 +0000 (00:34 +0200)
Fix checkpatch warning:
WARNING: kfree(NULL) is safe this check is probably not required

Cc: David Airlie <airlied@linux.ie>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
drivers/gpu/drm/omapdrm/omap_gem.c

index 7c68c8a189399ba1780725037b33a398a4bce3a7..5c3670017a4a906563dd5274cd441fdad35db9e8 100644 (file)
@@ -1179,9 +1179,7 @@ int omap_gem_op_sync(struct drm_gem_object *obj, enum omap_gem_op op)
                        }
                }
                spin_unlock(&sync_lock);
-
-               if (waiter)
-                       kfree(waiter);
+               kfree(waiter);
        }
        return ret;
 }