diff options
author | weiping <zhangweiping@didichuxing.com> | 2017-08-08 13:15:55 +0800 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2017-08-10 19:55:35 -0400 |
commit | 3b8328e2e0fda49202b502154608dd6fb8e8ed37 (patch) | |
tree | 15cb5ff05ece0e7e4369357643a3c58c117e4189 /drivers/scsi/megaraid | |
parent | d60e9eec95d2e81253eaf3c39ac8baf4830d0472 (diff) | |
download | linux-exynos-3b8328e2e0fda49202b502154608dd6fb8e8ed37.tar.gz linux-exynos-3b8328e2e0fda49202b502154608dd6fb8e8ed37.tar.bz2 linux-exynos-3b8328e2e0fda49202b502154608dd6fb8e8ed37.zip |
scsi: megaraid_sas: fix allocate instance->pd_info twice
fix allocate instance->pd_info twice which was introduced by 96188a89cc6d.
Signed-off-by: weiping zhang <zhangweiping@didichuxing.com>
Acked-by: Sumit Saxena <sumit.saxena@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/megaraid')
-rw-r--r-- | drivers/scsi/megaraid/megaraid_sas_base.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c index 03693c438b67..5202c2fd72ac 100644 --- a/drivers/scsi/megaraid/megaraid_sas_base.c +++ b/drivers/scsi/megaraid/megaraid_sas_base.c @@ -6097,14 +6097,12 @@ static int megasas_probe_one(struct pci_dev *pdev, instance->pd_info = pci_alloc_consistent(pdev, sizeof(struct MR_PD_INFO), &instance->pd_info_h); - instance->pd_info = pci_alloc_consistent(pdev, - sizeof(struct MR_PD_INFO), &instance->pd_info_h); - instance->tgt_prop = pci_alloc_consistent(pdev, - sizeof(struct MR_TARGET_PROPERTIES), &instance->tgt_prop_h); - if (!instance->pd_info) dev_err(&instance->pdev->dev, "Failed to alloc mem for pd_info\n"); + instance->tgt_prop = pci_alloc_consistent(pdev, + sizeof(struct MR_TARGET_PROPERTIES), &instance->tgt_prop_h); + if (!instance->tgt_prop) dev_err(&instance->pdev->dev, "Failed to alloc mem for tgt_prop\n"); |