bridge: cleanup: remove unneed check
authorDan Carpenter <error27@gmail.com>
Sat, 6 Mar 2010 01:14:09 +0000 (01:14 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sun, 7 Mar 2010 23:25:49 +0000 (15:25 -0800)
We dereference "port" on the lines immediately before and immediately
after the test so port should hopefully never be null here.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/bridge/br_multicast.c

index 2559fb5..8b25887 100644 (file)
@@ -627,8 +627,8 @@ static void br_multicast_port_query_expired(unsigned long data)
        struct net_bridge *br = port->br;
 
        spin_lock(&br->multicast_lock);
-       if (port && (port->state == BR_STATE_DISABLED ||
-                    port->state == BR_STATE_BLOCKING))
+       if (port->state == BR_STATE_DISABLED ||
+           port->state == BR_STATE_BLOCKING)
                goto out;
 
        if (port->multicast_startup_queries_sent <