]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
UBI: Fastmap: Remove else after return.
authorRichard Weinberger <richard@nod.at>
Wed, 29 Oct 2014 10:44:45 +0000 (11:44 +0100)
committerRichard Weinberger <richard@nod.at>
Thu, 26 Mar 2015 21:47:37 +0000 (22:47 +0100)
checkpatch.pl complains:
WARNING: else is not generally useful after a break or return

Signed-off-by: Richard Weinberger <richard@nod.at>
drivers/mtd/ubi/fastmap-wl.c

index c4717531b24c87a2e3908af93a3e70d13d522c11..7a72af2ec4ec0e3cde9670fcc1587a4597acbe01 100644 (file)
@@ -260,10 +260,10 @@ static struct ubi_wl_entry *get_peb_for_wl(struct ubi_device *ubi)
                        schedule_work(&ubi->fm_work);
                }
                return NULL;
-       } else {
-               pnum = pool->pebs[pool->used++];
-               return ubi->lookuptbl[pnum];
        }
+
+       pnum = pool->pebs[pool->used++];
+       return ubi->lookuptbl[pnum];
 }
 
 /**