summaryrefslogtreecommitdiff
path: root/drivers/scsi/mpt3sas/mpt3sas_base.c
diff options
context:
space:
mode:
authorSuganath prabu Subramani <suganath-prabu.subramani@avagotech.com>2016-02-18 11:39:45 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2016-02-24 05:27:02 +0300
commit8ff045c92708a595b7e39d68bdc0bd7edc08a073 (patch)
treee59275d79fdb53b97ae04ea37a001f916dd2d780 /drivers/scsi/mpt3sas/mpt3sas_base.c
parent0872774d8a319676dea7416e0cf85bec63eea0d0 (diff)
downloadlinux-8ff045c92708a595b7e39d68bdc0bd7edc08a073.tar.xz
mpt3sas: Free memory pools before retrying to allocate with different value.
Deallocate resources before reallocating of the same in retry_allocation path of _base_allocate_memory_pools() Signed-off-by: Suganath prabu Subramani <suganath-prabu.subramani@avagotech.com> Signed-off-by: Chaitra P B <chaitra.basappa@broadcom.com> Reviewed-by: Tomas Henzl <thenzl@redhat.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/mpt3sas/mpt3sas_base.c')
-rw-r--r--drivers/scsi/mpt3sas/mpt3sas_base.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c
index afdb13acd3a2..5bbbbf26d2f9 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_base.c
+++ b/drivers/scsi/mpt3sas/mpt3sas_base.c
@@ -3414,6 +3414,7 @@ _base_allocate_memory_pools(struct MPT3SAS_ADAPTER *ioc, int sleep_flag)
goto out;
retry_sz = 64;
ioc->hba_queue_depth -= retry_sz;
+ _base_release_memory_pools(ioc);
goto retry_allocation;
}