crypto: hisilicon/qm - stop qp by judging sq and cq tail
authorYang Shen <shenyang39@huawei.com>
Fri, 3 Apr 2020 08:16:42 +0000 (16:16 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 16 Apr 2020 06:49:21 +0000 (16:49 +1000)
commitf037fc5f93f4e3c973f8c3b7ebd6ccd123f0944b
treebba9af6c3a6284e8916ac1f11740969fc1b08ac7
parent141876c252a461818c39d45ca30ef1cb7c71953a
crypto: hisilicon/qm - stop qp by judging sq and cq tail

It is not working well to determine whether the queue is empty based on
whether the used count is 0. It is more stable to get if the queue is
stopping by checking if the tail pointer of the send queue and the
completion queue are equal.

Signed-off-by: Yang Shen <shenyang39@huawei.com>
Signed-off-by: Shukun Tan <tanshukun1@huawei.com>
Reviewed-by: Zhou Wang <wangzhou1@hisilicon.com>
Reviewed-by: Zaibo Xu <xuzaibo@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/hisilicon/qm.c