Signed-off-by: Tomas Henzl <[email protected]>
---
drivers/scsi/hpsa.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c
index 909562c09f..7fdc4d2a91 100644
--- a/drivers/scsi/hpsa.c
+++ b/drivers/scsi/hpsa.c
@@ -7069,13 +7069,12 @@ static void hpsa_free_device_info(struct ctlr_info *h)
static void hpsa_remove_one(struct pci_dev *pdev)
{
- struct ctlr_info *h;
+ struct ctlr_info *h = pci_get_drvdata(pdev);
- if (pci_get_drvdata(pdev) == NULL) {
+ if (!h) {
dev_err(&pdev->dev, "unable to remove device\n");
return;
}
- h = pci_get_drvdata(pdev);
/* Get rid of any controller monitoring work items */
h->remove_in_progress = 1;
--
1.9.3
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html