From: Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>
To: Robert Elliott <elliott@hpe.com>, <herbert@gondor.apana.org.au>,
<davem@davemloft.net>, <jarod@redhat.com>,
<linux-crypto@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] crypto: tcrypt - fix return value for multiple subtests
Date: Fri, 30 Sep 2022 15:09:34 -0700 [thread overview]
Message-ID: <ab0d9840-07e3-ec49-a9b3-c4b65d7d61bc@intel.com> (raw)
In-Reply-To: <20220930214014.37194-1-elliott@hpe.com>
On 9/30/2022 2:40 PM, Robert Elliott wrote:
> 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.
I am assuming this is for the case when fips_enabled is true?
I agree that returning the cumulative sum or errors isn't particularly
useful, but how is returning the minimum error value useful? Wouldn't it
be more useful to return the first error return?
Ani
next prev parent reply other threads:[~2022-09-30 22:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-30 21:40 [PATCH] crypto: tcrypt - fix return value for multiple subtests Robert Elliott
2022-09-30 22:09 ` Anirudh Venkataramanan [this message]
2022-09-30 22:42 ` Elliott, Robert (Servers)
2022-09-30 23:30 ` Anirudh Venkataramanan
2022-10-21 11:35 ` Herbert Xu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ab0d9840-07e3-ec49-a9b3-c4b65d7d61bc@intel.com \
--to=anirudh.venkataramanan@intel.com \
--cc=davem@davemloft.net \
--cc=elliott@hpe.com \
--cc=herbert@gondor.apana.org.au \
--cc=jarod@redhat.com \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox