]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
staging: drm/omap: Fix usage of IS_ERR_OR_NULL and PTR_ERR
authorAndy Gross <andy.gross@ti.com>
Fri, 16 Nov 2012 19:10:57 +0000 (13:10 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 16 Nov 2012 23:03:10 +0000 (15:03 -0800)
Return -ENOMEM if dmm_txn_init cannot allocate a refill engine.

v2: Fix typing issue seen with newer compilers

Signed-off-by: Andy Gross <andy.gross@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/omapdrm/omap_dmm_tiler.c

index 5c809c0568597e339cbf31dfc815e97394c223f5..59bf43899fc09d20ac5c01a0c1894f4b166bc189 100644 (file)
@@ -296,7 +296,7 @@ static int fill(struct tcm_area *area, struct page **pages,
 
        txn = dmm_txn_init(omap_dmm, area->tcm);
        if (IS_ERR_OR_NULL(txn))
-               return PTR_ERR(-ENOMEM);
+               return -ENOMEM;
 
        tcm_for_each_slice(slice, *area, area_s) {
                struct pat_area p_area = {