From: Thorsten Blum <thorsten.blum@linux.dev>
To: Stephan Mueller <smueller@chronox.de>,
Herbert Xu <herbert@gondor.apana.org.au>,
"David S. Miller" <davem@davemloft.net>
Cc: Thorsten Blum <thorsten.blum@linux.dev>,
linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 1/2] crypto: jitterentropy - drop redundant delta check in jent_entropy_init
Date: Mon, 4 May 2026 10:28:50 +0200 [thread overview]
Message-ID: <20260504082848.7194-4-thorsten.blum@linux.dev> (raw)
Since start_time = end_time - delta, start_time can only equal end_time
when delta is 0, making the explicit end_time == start_time check
redundant. Remove it.
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
crypto/jitterentropy.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/crypto/jitterentropy.c b/crypto/jitterentropy.c
index d5832caa8ab3..6ac0257e8e0a 100644
--- a/crypto/jitterentropy.c
+++ b/crypto/jitterentropy.c
@@ -775,7 +775,7 @@ int jent_entropy_init(unsigned int osr, unsigned int flags,
* delta even when called shortly after each other -- this
* implies that we also have a high resolution timer
*/
- if (!delta || (end_time == start_time)) {
+ if (!delta) {
ret = JENT_ECOARSETIME;
goto out;
}
next reply other threads:[~2026-05-04 8:29 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-04 8:28 Thorsten Blum [this message]
2026-05-04 8:28 ` [PATCH 2/2] crypto: jitterentropy - fix URL Thorsten Blum
2026-05-04 11:47 ` Stephan Müller
2026-05-04 11:47 ` [PATCH 1/2] crypto: jitterentropy - drop redundant delta check in jent_entropy_init Stephan Müller
2026-05-15 10:13 ` 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=20260504082848.7194-4-thorsten.blum@linux.dev \
--to=thorsten.blum@linux.dev \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=smueller@chronox.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.