Files
linux-stable-mirror/drivers
Everest K.C db74e48b49 crypto: cavium - Fix the if condition to exit loop after timeout
[ Upstream commit 53d91ca76b ]

The while loop breaks in the first run because of incorrect
if condition. It also causes the statements after the if to
appear dead.
Fix this by changing the condition from if(timeout--) to
if(!timeout--).

This bug was reported by Coverity Scan.
Report:
CID 1600859: (#1 of 1): Logically dead code (DEADCODE)
dead_error_line: Execution cannot reach this statement: udelay(30UL);

Fixes: 9e2c7d9994 ("crypto: cavium - Add Support for Octeon-tx CPT Engine")
Signed-off-by: Everest K.C. <everestkc@everestkc.com.np>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-12-09 10:31:48 +01:00
..
2024-10-17 15:24:14 +02:00
2024-11-08 16:28:26 +01:00
2024-10-04 16:29:14 +02:00