crypto: qat - fix double free during reset
authorSvyatoslav Pankratov <svyatoslav.pankratov@intel.com>
Mon, 9 Oct 2023 12:27:19 +0000 (13:27 +0100)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 20 Oct 2023 05:39:25 +0000 (13:39 +0800)
commit01aed663e6c421aeafc9c330bda630976b50a764
treed618a0c98fd25d3a2a0f41102d4f1db189ec42c7
parentfdcac2ddc759752cb4886138d89a8c06bf5086a7
crypto: qat - fix double free during reset

There is no need to free the reset_data structure if the recovery is
unsuccessful and the reset is synchronous. The function
adf_dev_aer_schedule_reset() handles the cleanup properly. Only
asynchronous resets require such structure to be freed inside the reset
worker.

Fixes: d8cba25d2c68 ("crypto: qat - Intel(R) QAT driver framework")
Signed-off-by: Svyatoslav Pankratov <svyatoslav.pankratov@intel.com>
Signed-off-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/intel/qat/qat_common/adf_aer.c