]> git.baikalelectronics.ru Git - kernel.git/commit
crypto:hisilicon/sec2 - update busy processing logic
authorKai Ye <yekai13@huawei.com>
Tue, 7 Jul 2020 01:15:38 +0000 (09:15 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 16 Jul 2020 11:49:00 +0000 (21:49 +1000)
commit69ee52e2680d5919a2b20f1f2e52d784b78c6c83
tree8022ae6bcdadc9c4ca643a5c4120accca9124c75
parentbbe57dc2a8d518a14d5ed85dacd4c7f62abd6ac4
crypto:hisilicon/sec2 - update busy processing logic

As before, if a SEC queue is at the 'fake busy' status,
the request with a 'fake busy' flag will be sent into hardware
and the sending function returns busy. After the request is
finished, SEC driver's call back will identify the 'fake busy' flag,
and notifies the user that hardware is not busy now by calling
user's call back function.

Now, a request sent into busy hardware will be cached in the
SEC queue's backlog, return '-EBUSY' to user.
After the request being finished, the cached requests will
be processed in the call back function. to notify the
corresponding user that SEC queue can process more requests.

Signed-off-by: Kai Ye <yekai13@huawei.com>
Reviewed-by: Longfang Liu <liulongfang@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/hisilicon/sec2/sec.h
drivers/crypto/hisilicon/sec2/sec_crypto.c
drivers/crypto/hisilicon/sec2/sec_main.c