summaryrefslogtreecommitdiff
path: root/drivers/net/caif
diff options
context:
space:
mode:
authorSjur Brændeland <sjur.brandeland@stericsson.com>2012-06-24 11:01:38 +0000
committerDavid S. Miller <davem@davemloft.net>2012-06-25 16:07:23 -0700
commit1fdc7630b2cba4a5aeb5fc3834c7189716fdbcb0 (patch)
tree344bd04d4786eaeb33cb544e0980f8c5e1c24682 /drivers/net/caif
parent3935600a7f341c00b0def2ed8870669ab2c05493 (diff)
caif-hsi: Add missing return in error path
Fix a missing return, causing access to freed memory. Signed-off-by: Sjur Brændeland <sjur.brandeland@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/caif')
-rw-r--r--drivers/net/caif/caif_hsi.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/caif/caif_hsi.c b/drivers/net/caif/caif_hsi.c
index 1f52ff3076b4..4a27adb7ae67 100644
--- a/drivers/net/caif/caif_hsi.c
+++ b/drivers/net/caif/caif_hsi.c
@@ -1178,6 +1178,7 @@ int cfhsi_probe(struct platform_device *pdev)
dev_err(&ndev->dev, "%s: Registration error: %d.\n",
__func__, res);
free_netdev(ndev);
+ return -ENODEV;
}
/* Add CAIF HSI device to list. */
spin_lock(&cfhsi_list_lock);