staging: media: davinci_vpfe: Remove unnecessary else after return
authorBhaktipriya Shridhar <bhaktipriya96@gmail.com>
Thu, 10 Mar 2016 17:36:23 +0000 (23:06 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 12 Mar 2016 06:09:09 +0000 (22:09 -0800)
This patch fixes the checkpatch warning that else is not generally
useful after a break or return.

This was done using Coccinelle:
@@
expression e2;
statement s1;
@@
if(e2) { ... return ...; }
-else
         s1

Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/media/davinci_vpfe/dm365_ipipeif.c

index 6e4c87f..46fd2c7 100644 (file)
@@ -94,7 +94,7 @@ static int get_oneshot_mode(enum ipipeif_input_entity input)
 {
        if (input == IPIPEIF_INPUT_MEMORY)
                return IPIPEIF_MODE_ONE_SHOT;
-       else if (input == IPIPEIF_INPUT_ISIF)
+       if (input == IPIPEIF_INPUT_ISIF)
                return IPIPEIF_MODE_CONTINUOUS;
 
        return -EINVAL;