Robert Elliott 65c92cbb3f crypto: tcrypt - fix return value for multiple subtests
When a test mode invokes multiple tests (e.g., mode 0 invokes modes
1 through 199, and mode 3 tests three block cipher modes with des),
don't keep accumulating the return values with ret += tcrypt_test(),
which results in a bogus value if more than one report a nonzero
value (e.g., two reporting -2 (-ENOENT) end up reporting -4 (-EINTR)).
Instead, keep track of the minimum return value reported by any
subtest.

Fixes: 4e033a6bc70f ("crypto: tcrypt - Do not exit on success in fips mode")
Signed-off-by: Robert Elliott <elliott@hpe.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2022-10-21 19:15:35 +08:00
..
2020-08-28 16:58:28 +10:00
2022-03-03 10:49:20 +12:00
2021-03-26 19:55:55 +11:00
2022-06-10 16:40:17 +08:00
2022-08-02 17:14:47 -06:00
2022-02-18 16:21:08 +11:00
2020-02-28 08:43:21 +08:00
2022-08-02 17:14:47 -06:00
2021-08-21 15:44:58 +08:00
2022-04-08 16:12:46 +08:00
2022-06-10 16:40:16 +08:00
2022-02-18 16:21:08 +11:00
2021-11-08 16:55:21 -08:00