]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: cavium/nitrox - fix for command corruption in queue full case with backlog...
authorSrikanth Jampala <Jampala.Srikanth@cavium.com>
Wed, 22 Aug 2018 07:10:52 +0000 (12:40 +0530)
committerHerbert Xu <herbert@gondor.apana.org.au>
Sat, 25 Aug 2018 11:50:44 +0000 (19:50 +0800)
commit5a8c78eae51838a92c1572eea8e341420abb3621
treededb0fda56b347d8bd3d7ca124ca17c68d36d0a2
parent8de2442a4286d257eef7dc1c91277b4a5b54baa1
crypto: cavium/nitrox - fix for command corruption in queue full case with backlog submissions.

Earlier used to post the current command without checking queue full
     after backlog submissions. So, post the current command only after
     confirming the space in queue after backlog submissions.

     Maintain host write index instead of reading device registers
     to get the next free slot to post the command.

     Return -ENOSPC in queue full case.

Signed-off-by: Srikanth Jampala <Jampala.Srikanth@cavium.com>
Reviewed-by: Gadam Sreerama <sgadam@cavium.com>
Tested-by: Jha, Chandan <Chandan.Jha@cavium.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/cavium/nitrox/nitrox_dev.h
drivers/crypto/cavium/nitrox/nitrox_lib.c
drivers/crypto/cavium/nitrox/nitrox_reqmgr.c