Skip to content

Commit

Permalink
ibmveth: Return -EINVAL on all ->probe errors
Browse files Browse the repository at this point in the history
We had a few cases where we returned success on error.

Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Santiago Leon <santil@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Santiago Leon authored and David S. Miller committed Sep 7, 2010
1 parent f148f61 commit be35ae9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/ibmveth.c
Original file line number Diff line number Diff line change
Expand Up @@ -1392,15 +1392,15 @@ static int __devinit ibmveth_probe(struct vio_dev *dev,
NULL);
if (!mac_addr_p) {
dev_err(&dev->dev, "Can't find VETH_MAC_ADDR attribute\n");
return 0;
return -EINVAL;
}

mcastFilterSize_p = (unsigned int *)vio_get_attribute(dev,
VETH_MCAST_FILTER_SIZE, NULL);
if (!mcastFilterSize_p) {
dev_err(&dev->dev, "Can't find VETH_MCAST_FILTER_SIZE "
"attribute\n");
return 0;
return -EINVAL;
}

netdev = alloc_etherdev(sizeof(struct ibmveth_adapter));
Expand Down

0 comments on commit be35ae9

Please sign in to comment.