diff options
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/hw/mthca/mthca_main.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_main.c b/drivers/infiniband/hw/mthca/mthca_main.c index 773145e29947..aa563e61de65 100644 --- a/drivers/infiniband/hw/mthca/mthca_main.c +++ b/drivers/infiniband/hw/mthca/mthca_main.c | |||
@@ -1250,12 +1250,14 @@ static void __mthca_remove_one(struct pci_dev *pdev) | |||
1250 | int __mthca_restart_one(struct pci_dev *pdev) | 1250 | int __mthca_restart_one(struct pci_dev *pdev) |
1251 | { | 1251 | { |
1252 | struct mthca_dev *mdev; | 1252 | struct mthca_dev *mdev; |
1253 | int hca_type; | ||
1253 | 1254 | ||
1254 | mdev = pci_get_drvdata(pdev); | 1255 | mdev = pci_get_drvdata(pdev); |
1255 | if (!mdev) | 1256 | if (!mdev) |
1256 | return -ENODEV; | 1257 | return -ENODEV; |
1258 | hca_type = mdev->hca_type; | ||
1257 | __mthca_remove_one(pdev); | 1259 | __mthca_remove_one(pdev); |
1258 | return __mthca_init_one(pdev, mdev->hca_type); | 1260 | return __mthca_init_one(pdev, hca_type); |
1259 | } | 1261 | } |
1260 | 1262 | ||
1261 | static int __devinit mthca_init_one(struct pci_dev *pdev, | 1263 | static int __devinit mthca_init_one(struct pci_dev *pdev, |