OpenCloudOS-Kernel/drivers/net/ethernet
Peter Senna Tschudin 0968a9d1c8 drivers/net/ethernet/sis/sis900.c: fix error return code
The function sis900_probe() return 0 for success and negative value
for most of its internal tests failures. There is one exception
that is error case going to err_out_cleardev:. Fore this error case,
the function abort its success execution path, but returns non negative
value, making it difficult for a caller function to notice the error.

This patch fixes the error case that do not return negative value.

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:10 -04:00
..
3com treewide: fix comment/printk/variable typos 2012-09-01 10:33:05 -07:00
8390 sections: fix section conflicts in drivers/net 2012-10-06 03:04:42 +09:00
adaptec sections: fix section conflicts in drivers/net 2012-10-06 03:04:42 +09:00
adi bfin: Fix build failure due to get_ts_info() changes. 2012-04-06 00:17:50 -04:00
aeroflex ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
alteon
amd lance: remove unnecessary setting of skb->dev 2012-07-10 23:24:56 -07:00
apple ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
atheros sections: fix section conflicts in drivers/net 2012-10-06 03:04:42 +09:00
broadcom bnx2x: fix ring size for 10G functions 2012-10-03 16:34:15 -04:00
brocade bna: Fix warning false positive. 2012-09-27 18:31:58 -04:00
cadence at91ether: return PTR_ERR if call to clk_get fails 2012-09-20 22:21:40 -04:00
calxeda net: remove skb recycling 2012-10-07 00:40:54 -04:00
chelsio cxgb4: Fix build error due to missing linux/vmalloc.h include. 2012-10-03 20:50:08 -04:00
cirrus cs89x0 : packet reception not working 2012-08-31 15:48:56 -04:00
cisco enic: remove unnecessary setting of skb->dev 2012-07-10 23:24:56 -07:00
davicom dm9000: some coldfire boards need this 2012-05-14 18:40:16 -04:00
dec drivers/net/ethernet/dec/tulip/dmfe.c: fix error return code 2012-10-07 14:37:04 -04:00
dlink sections: fix section conflicts in drivers/net 2012-10-06 03:04:42 +09:00
emulex Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2012-10-02 13:38:27 -07:00
faraday net: ftgmac100/ftmac100: dont pull too much data 2012-07-18 09:40:53 -07:00
freescale net: remove skb recycling 2012-10-07 00:40:54 -04:00
fujitsu drivers/net: delete all code/drivers depending on CONFIG_MCA 2012-05-17 16:37:41 -04:00
hp ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
i825xx net: Make ZNET driver config depend on X86. 2012-09-22 18:11:32 -04:00
ibm Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc 2012-10-06 03:16:12 +09:00
icplus
intel ixgbe: add support for X540-AT1 2012-10-03 08:38:30 -07:00
marvell net: remove skb recycling 2012-10-07 00:40:54 -04:00
mellanox First batch of InfiniBand/RDMA changes for the 3.7 merge window: 2012-10-02 17:20:40 -07:00
micrel ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
microchip
myricom myri10ge: Use PCI Express Capability accessors 2012-08-23 10:11:14 -06:00
natsemi drivers/net/ethernet/natsemi/natsemi.c: fix error return code 2012-10-07 14:37:04 -04:00
neterion Merge branch 'for-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq 2012-10-02 09:54:49 -07:00
nuvoton
nvidia forcedeth: prevent TX timeouts after reboot 2012-08-30 13:04:57 -04:00
nxp lpc_eth: remove obsolete ifdefs 2012-08-08 16:07:51 -07:00
octeon netdev: octeon: fix return value check in octeon_mgmt_init_phy() 2012-09-28 01:18:32 -04:00
oki-semi pch_gbe: Fix PTP dependencies. 2012-10-02 22:34:04 -04:00
packetengines yellowfin: stop using net_device.{base_addr, irq}. 2012-04-07 11:45:26 +02:00
pasemi netdev: pasemi: fix return value check in pasemi_mac_phy_init() 2012-09-27 13:20:50 -04:00
qlogic sections: fix section conflicts in drivers/net 2012-10-06 03:04:42 +09:00
racal
rdc r6040: use module_pci_driver macro 2012-07-09 14:42:30 -07:00
realtek sections: fix section conflicts in drivers/net 2012-10-06 03:04:42 +09:00
renesas net: sh_eth: Add eth support for R8A7779 device 2012-08-20 02:16:54 -07:00
seeq Merge branch 'cleanup/__iomem' into next/cleanup 2012-09-22 10:24:29 -07:00
sfc drivers/net/ethernet/sfc: use standard __{clear,set}_bit_le() functions 2012-10-06 03:04:54 +09:00
sgi Merge tty-next into 3.6-rc1 2012-08-06 09:48:31 -07:00
silan sc92031: stop using net_device.{base_addr, irq} 2012-04-07 11:45:27 +02:00
sis drivers/net/ethernet/sis/sis900.c: fix error return code 2012-10-07 14:37:10 -04:00
smsc ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
stmicro net: remove skb recycling 2012-10-07 00:40:54 -04:00
sun Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2012-10-02 13:38:27 -07:00
tehuti drivers/net/ethernet: Fix (nearly-)kernel-doc comments for various functions 2012-07-10 23:13:46 -07:00
ti net: ethernet: davinci_cpdma: decrease the desc count when cleaning up the remaining packets 2012-10-02 22:34:21 -04:00
tile tilegx net: use eth_hw_addr_random(), not eth_random_addr() 2012-07-18 15:07:45 -04:00
toshiba drivers/net/ethernet: Fix (nearly-)kernel-doc comments for various functions 2012-07-10 23:13:46 -07:00
tundra drivers/net/ethernet/tundra/tsi108_eth.c: delete double assignment 2012-08-30 13:08:37 -04:00
via ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
wiznet w5300: using eth_hw_addr_random() for random MAC and set device flag 2012-08-24 13:30:27 -04:00
xilinx ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
xircom
xscale ixp4xx_eth: fix ptp_ixp46x build failure 2012-08-06 13:30:01 -07:00
Kconfig net: mipsnet: Remove the MIPSsim Ethernet driver. 2012-09-24 16:47:23 -04:00
Makefile net: mipsnet: Remove the MIPSsim Ethernet driver. 2012-09-24 16:47:23 -04:00
dnet.c
dnet.h
ethoc.c ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
fealnx.c sections: fix section conflicts in drivers/net 2012-10-06 03:04:42 +09:00
jme.c jme: netpoll support 2012-07-18 09:40:54 -07:00
jme.h
korina.c
lantiq_etop.c ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
netx-eth.c ARM: netx: move platform_data definitions 2012-09-14 11:17:36 +02:00
s6gmac.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2012-05-22 19:22:50 -07:00