Message ID | 1450876907-3913-1-git-send-email-thenzl@redhat.com (mailing list archive) |
---|---|
State | Accepted, archived |
Headers | show |
>>>>> "Tomas" == Tomas Henzl <thenzl@redhat.com> writes:
Tomas> It might happen that we try to free an already freed pointer.
Tomas> Tomas
Applied to 4.5/scsi-queue.
diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c index d4f1dcdb83..3b09b3d09f 100644 --- a/drivers/scsi/mpt3sas/mpt3sas_base.c +++ b/drivers/scsi/mpt3sas/mpt3sas_base.c @@ -1827,8 +1827,10 @@ mpt3sas_base_unmap_resources(struct MPT3SAS_ADAPTER *ioc) _base_free_irq(ioc); _base_disable_msix(ioc); - if (ioc->msix96_vector) + if (ioc->msix96_vector) { kfree(ioc->replyPostRegisterIndex); + ioc->replyPostRegisterIndex = NULL; + } if (ioc->chip_phys) { iounmap(ioc->chip);
It might happen that we try to free an already freed pointer. Tomas Reported-by: Maurizio Lombardi <mlombard@redhat.com> Signed-off-by: Tomas Henzl <thenzl@redhat.com> --- drivers/scsi/mpt3sas/mpt3sas_base.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)