net:drivers/net: replace IS_ERR and PTR_ERR with PTR_ERR_OR_ZERO
authorDuan Jiong <duanj.fnst@cn.fujitsu.com>
Wed, 6 Nov 2013 07:58:13 +0000 (15:58 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 7 Nov 2013 08:01:59 +0000 (03:01 -0500)
This patch fixes coccinelle error regarding usage of IS_ERR and
PTR_ERR instead of PTR_ERR_OR_ZERO.

Signed-off-by: Duan Jiong <duanj.fnst@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/i825xx/82596.c

index a15877affc9bd6b5791e1df9fa0e8ec2c2905c0d..7ce6379fd1a362cfbad846f7881cdae0d03e6982 100644 (file)
@@ -1527,9 +1527,7 @@ int __init init_module(void)
        if (debug >= 0)
                i596_debug = debug;
        dev_82596 = i82596_probe(-1);
-       if (IS_ERR(dev_82596))
-               return PTR_ERR(dev_82596);
-       return 0;
+       return PTR_ERR_OR_ZERO(dev_82596);
 }
 
 void __exit cleanup_module(void)