]> git.sur5r.net Git - u-boot/commitdiff
net: macb: remove superfluous logical constraint
authorHeinrich Schuchardt <xypron.glpk@gmx.de>
Sun, 18 Mar 2018 10:32:53 +0000 (11:32 +0100)
committerJoe Hershberger <joe.hershberger@ni.com>
Thu, 22 Mar 2018 20:05:32 +0000 (15:05 -0500)
In

if (a > =0) {...}
else (a < 0) {...}

the second logical constraint is superfluous.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
drivers/net/macb.c

index e62aefcd0d6cadf257dd56807983c5a5b830f9e4..fe370bf728975321d7cdb09a943d9290977fb044 100644 (file)
@@ -915,7 +915,7 @@ static int macb_recv(struct eth_device *netdev)
                if (length >= 0) {
                        net_process_received_packet(packet, length);
                        reclaim_rx_buffers(macb, macb->next_rx_tail);
-               } else if (length < 0) {
+               } else {
                        return length;
                }
        }