crypto: qat - detect PFVF collision after ACK
authorGiovanni Cabiddu <giovanni.cabiddu@intel.com>
Tue, 28 Sep 2021 11:44:29 +0000 (12:44 +0100)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 8 Oct 2021 12:02:38 +0000 (20:02 +0800)
commit9b768e8a3909ac1ab39ed44a3933716da7761a6f
tree71d8146d8335538b3e13b004d22faf44c3f4bd52
parentcfd6fb45cfaf46fa9547421d8da387dc9c7997d4
crypto: qat - detect PFVF collision after ACK

Detect a PFVF collision between the local and the remote function by
checking if the message on the PFVF CSR has been overwritten.
This is done after the remote function confirms that the message has
been received, by clearing the interrupt bit, or the maximum number of
attempts (ADF_IOV_MSG_ACK_MAX_RETRY) to check the CSR has been exceeded.

Fixes: ed8ccaef52fa ("crypto: qat - Add support for SRIOV")
Signed-off-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Co-developed-by: Marco Chiappero <marco.chiappero@intel.com>
Signed-off-by: Marco Chiappero <marco.chiappero@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/qat/qat_common/adf_pf2vf_msg.c