From 2b09d01896a7ea120adfaeca7141a08ffa2681da Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Fri, 5 Apr 2019 01:04:14 +0000 Subject: [PATCH] qla2x00t-32gbit: Only free 'entries' after its last use git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8153 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- qla2x00t-32gbit/qla_isr.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/qla2x00t-32gbit/qla_isr.c b/qla2x00t-32gbit/qla_isr.c index 701355954..ad0d46b49 100644 --- a/qla2x00t-32gbit/qla_isr.c +++ b/qla2x00t-32gbit/qla_isr.c @@ -3550,10 +3550,6 @@ msix_failed: &desc); #endif -#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0) - kfree(entries); -#endif - if (ret < 0) { ql_log(ql_log_fatal, vha, 0x00c7, "MSI-X: Failed to enable support, " @@ -3680,6 +3676,9 @@ msix_register_fail: ha->mqiobase, ha->max_rsp_queues, ha->max_req_queues); msix_out: +#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0) + kfree(entries); +#endif return ret; }