cxgb4: Simplify the return expression
authorWei Yongjun <weiyj.lk@gmail.com>
Sat, 20 Aug 2016 15:32:41 +0000 (15:32 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sun, 21 Aug 2016 22:23:27 +0000 (15:23 -0700)
Simplify the return expression.

Signed-off-by: Wei Yongjun <weiyj.lk@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c

index 85e30f19e97a1c7cf3ae049c185c7b4628f0ed87..0099a0cd53ea111e33a2177e04b35f0a9326cdfa 100644 (file)
@@ -2932,7 +2932,6 @@ EXPORT_SYMBOL(cxgb4_create_server_filter);
 int cxgb4_remove_server_filter(const struct net_device *dev, unsigned int stid,
                unsigned int queue, bool ipv6)
 {
-       int ret;
        struct filter_entry *f;
        struct adapter *adap;
 
@@ -2946,11 +2945,7 @@ int cxgb4_remove_server_filter(const struct net_device *dev, unsigned int stid,
        /* Unlock the filter */
        f->locked = 0;
 
-       ret = delete_filter(adap, stid);
-       if (ret)
-               return ret;
-
-       return 0;
+       return delete_filter(adap, stid);
 }
 EXPORT_SYMBOL(cxgb4_remove_server_filter);