aboutsummaryrefslogtreecommitdiff
path: root/drivers/staging/crystalhd
diff options
context:
space:
mode:
authorKulikov Vasiliy <segooon@gmail.com>2010-08-09 23:51:44 +0400
committerGreg Kroah-Hartman <gregkh@suse.de>2010-08-31 14:48:07 -0700
commit036b00e0917a867a018c583aa86aa66affb9321c (patch)
tree66c4742a381e5daee0514a09e38255f4f6f56328 /drivers/staging/crystalhd
parentb6cdc4056f642884d6819597c315753264e305a1 (diff)
downloadlinaro-lsk-036b00e0917a867a018c583aa86aa66affb9321c.tar.gz
staging: crystalhd: call disable_pci_device() if pci_probe() failed
Driver should call disable_pci_device() if it returns from pci_probe() with error. Signed-off-by: Kulikov Vasiliy <segooon@gmail.com> Acked-by: Jarod Wilson <jarod@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/crystalhd')
-rw-r--r--drivers/staging/crystalhd/crystalhd_lnx.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/crystalhd/crystalhd_lnx.c b/drivers/staging/crystalhd/crystalhd_lnx.c
index fbb80f09a3d..115e79b8b4e 100644
--- a/drivers/staging/crystalhd/crystalhd_lnx.c
+++ b/drivers/staging/crystalhd/crystalhd_lnx.c
@@ -570,6 +570,7 @@ static int __devinit chd_dec_pci_probe(struct pci_dev *pdev,
rc = chd_pci_reserve_mem(pinfo);
if (rc) {
BCMLOG_ERR("Failed to setup memory regions.\n");
+ pci_disable_device(pdev);
return -ENOMEM;
}