提交 105900d5 编写于 作者: S Sumit.Saxena@lsi.com 提交者: James Bottomley

[SCSI] megaraid_sas: Free event detail memory without device ID check

Free event detail memory from more common place, instead of doing it for
limited device types.
Signed-off-by: NSumit Saxena <sumit.saxena@lsi.com>
Signed-off-by: NAdam Radford <aradford@gmail.com>
Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
上级 70b47b88
......@@ -4599,10 +4599,6 @@ static void megasas_detach_one(struct pci_dev *pdev)
break;
default:
megasas_release_mfi(instance);
pci_free_consistent(pdev,
sizeof(struct megasas_evt_detail),
instance->evt_detail,
instance->evt_detail_h);
pci_free_consistent(pdev, sizeof(u32),
instance->producer,
instance->producer_h);
......@@ -4612,6 +4608,9 @@ static void megasas_detach_one(struct pci_dev *pdev)
break;
}
if (instance->evt_detail)
pci_free_consistent(pdev, sizeof(struct megasas_evt_detail),
instance->evt_detail, instance->evt_detail_h);
scsi_host_put(host);
pci_set_drvdata(pdev, NULL);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册