kernel-fxtec-pro1x/drivers/net/ethernet/amd
Peter Senna Tschudin 691299201b drivers/net/ethernet/amd/au1000_eth.c: fix error return code
The function au1000_probe() return 0 for success and negative value
for most of its internal tests failures. There are exceptions
that are error cases going to err_out:. For this cases, the
function abort its success execution path, but returns non negative
value, making it dificult for a caller function to notice the error.

This patch fixes the error cases that do not return negative values.

This was found by Coccinelle, but the code change was made by hand.
This patch is not robot generated.

A simplified version of the semantic match that finds this problem is
as follows: (http://coccinelle.lip6.fr/)

// <smpl>
(
if@p1 (\(ret < 0\|ret != 0\))
 { ... return ret; }
|
ret@p1 = 0
)
... when != ret = e1
    when != &ret
*if(...)
{
  ... when != ret = e2
      when forall
 return ret;
}
// </smpl>

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-10-07 14:37:11 -04:00
..
7990.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00
7990.h
a2065.c netdev: ethernet dev_alloc_skb to netdev_alloc_skb 2012-02-06 11:41:20 -05:00
a2065.h
am79c961a.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00
am79c961a.h drivers/net: fix up stale paths from driver reorg 2012-01-30 12:54:40 -05:00
amd8111e.c drivers/net/ethernet/amd/amd8111e.c: fix error return code 2012-10-07 14:37:11 -04:00
amd8111e.h module_param: make bool parameters really bool (net & drivers/net) 2011-12-19 22:27:29 -05:00
ariadne.c net/ariadne: Improve debug prints 2012-04-22 20:16:49 +02:00
ariadne.h
atarilance.c m68k/atari: Change VME irq numbers from unsigned long to unsigned int 2012-04-22 20:16:49 +02:00
au1000_eth.c drivers/net/ethernet/amd/au1000_eth.c: fix error return code 2012-10-07 14:37:11 -04:00
au1000_eth.h
declance.c ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
depca.c drivers/net: delete all code/drivers depending on CONFIG_MCA 2012-05-17 16:37:41 -04:00
depca.h
hplance.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00
hplance.h
Kconfig drivers/net: fix up stale paths from driver reorg 2012-01-30 12:54:40 -05:00
lance.c lance: remove unnecessary setting of skb->dev 2012-07-10 23:24:56 -07:00
Makefile
mvme147.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00
ni65.c netdev: ethernet dev_alloc_skb to netdev_alloc_skb 2012-02-06 11:41:20 -05:00
ni65.h
nmclan_cs.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00
pcnet32.c netdev: ethernet dev_alloc_skb to netdev_alloc_skb 2012-02-06 11:41:20 -05:00
sun3lance.c netdev: ethernet dev_alloc_skb to netdev_alloc_skb 2012-02-06 11:41:20 -05:00
sunlance.c Remove all #inclusions of asm/system.h 2012-03-28 18:30:03 +01:00