aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/message/fusion/mptsas.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/message/fusion/mptsas.c')
-rw-r--r--drivers/message/fusion/mptsas.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/drivers/message/fusion/mptsas.c b/drivers/message/fusion/mptsas.c
index 0e557a3a9d06..282fb5ebbadf 100644
--- a/drivers/message/fusion/mptsas.c
+++ b/drivers/message/fusion/mptsas.c
@@ -1134,13 +1134,15 @@ mptsas_probe(struct pci_dev *pdev, const struct pci_device_id *id)
1134 printk(MYIOC_s_WARN_FMT 1134 printk(MYIOC_s_WARN_FMT
1135 "Skipping because it's not operational!\n", 1135 "Skipping because it's not operational!\n",
1136 ioc->name); 1136 ioc->name);
1137 return -ENODEV; 1137 error = -ENODEV;
1138 goto out_mptsas_probe;
1138 } 1139 }
1139 1140
1140 if (!ioc->active) { 1141 if (!ioc->active) {
1141 printk(MYIOC_s_WARN_FMT "Skipping because it's disabled!\n", 1142 printk(MYIOC_s_WARN_FMT "Skipping because it's disabled!\n",
1142 ioc->name); 1143 ioc->name);
1143 return -ENODEV; 1144 error = -ENODEV;
1145 goto out_mptsas_probe;
1144 } 1146 }
1145 1147
1146 /* Sanity check - ensure at least 1 port is INITIATOR capable 1148 /* Sanity check - ensure at least 1 port is INITIATOR capable
@@ -1164,7 +1166,8 @@ mptsas_probe(struct pci_dev *pdev, const struct pci_device_id *id)
1164 printk(MYIOC_s_WARN_FMT 1166 printk(MYIOC_s_WARN_FMT
1165 "Unable to register controller with SCSI subsystem\n", 1167 "Unable to register controller with SCSI subsystem\n",
1166 ioc->name); 1168 ioc->name);
1167 return -1; 1169 error = -1;
1170 goto out_mptsas_probe;
1168 } 1171 }
1169 1172
1170 spin_lock_irqsave(&ioc->FreeQlock, flags); 1173 spin_lock_irqsave(&ioc->FreeQlock, flags);
@@ -1238,7 +1241,7 @@ mptsas_probe(struct pci_dev *pdev, const struct pci_device_id *id)
1238 mem = kmalloc(sz, GFP_ATOMIC); 1241 mem = kmalloc(sz, GFP_ATOMIC);
1239 if (mem == NULL) { 1242 if (mem == NULL) {
1240 error = -ENOMEM; 1243 error = -ENOMEM;
1241 goto mptsas_probe_failed; 1244 goto out_mptsas_probe;
1242 } 1245 }
1243 1246
1244 memset(mem, 0, sz); 1247 memset(mem, 0, sz);
@@ -1256,7 +1259,7 @@ mptsas_probe(struct pci_dev *pdev, const struct pci_device_id *id)
1256 mem = kmalloc(sz, GFP_ATOMIC); 1259 mem = kmalloc(sz, GFP_ATOMIC);
1257 if (mem == NULL) { 1260 if (mem == NULL) {
1258 error = -ENOMEM; 1261 error = -ENOMEM;
1259 goto mptsas_probe_failed; 1262 goto out_mptsas_probe;
1260 } 1263 }
1261 1264
1262 memset(mem, 0, sz); 1265 memset(mem, 0, sz);
@@ -1309,14 +1312,14 @@ mptsas_probe(struct pci_dev *pdev, const struct pci_device_id *id)
1309 if (error) { 1312 if (error) {
1310 dprintk((KERN_ERR MYNAM 1313 dprintk((KERN_ERR MYNAM
1311 "scsi_add_host failed\n")); 1314 "scsi_add_host failed\n"));
1312 goto mptsas_probe_failed; 1315 goto out_mptsas_probe;
1313 } 1316 }
1314 1317
1315 mptsas_scan_sas_topology(ioc); 1318 mptsas_scan_sas_topology(ioc);
1316 1319
1317 return 0; 1320 return 0;
1318 1321
1319mptsas_probe_failed: 1322out_mptsas_probe:
1320 1323
1321 mptscsih_remove(pdev); 1324 mptscsih_remove(pdev);
1322 return error; 1325 return error;