Skip to contentSkip to conversation

FAILED: patch "[PATCH] crypto: qcom-rng - Remove crypto_rng interface" failed to apply to 6.12-stable tree

PATCH [email protected] 2 participants 2 messages Aug 31

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 6.12-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

To reproduce the conflict and resubmit, you may use the following commands:

git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.12.y
git checkout FETCH_HEAD
git cherry-pick -x 2ecdf5c9910e20f73639bc322f0518a3439d17c0
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026083146-squatted-debug-8f6e@gregkh' --subject-prefix 'PATCH 6.12.y' 'HEAD^..'

Possible dependencies:

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

From 2ecdf5c9910e20f73639bc322f0518a3439d17c0 Mon Sep 17 00:00:00 2001
From: Eric Biggers <[email protected]>
Date: Mon, 8 Jun 2026 17:58:47 +0000
Subject: [PATCH] crypto: qcom-rng - Remove crypto_rng interface

qcom-rng.c exposes the same hardware through two completely separate interfaces, crypto_rng and hwrng. However, the implementation of this is buggy because it permits generation operations from these interfaces to run concurrently with each other, accessing the same registers. That is, qcom_rng_generate() synchronizes with itself but not with qcom_hwrng_read(). This results in potential repetition of output from the RNG, output of non-random values, etc.

Fortunately, there's actually no point in hardware RNG drivers implementing the crypto_rng interface. It's not actually used by anything besides the "rng" algorithm type of AF_ALG, which in turn is not actually used in practice. Other crypto_rng hardware drivers are likewise being phased out, leaving just the hwrng support.

Thus, remove it to simplify the code and avoid conflict (and confusion) with the hwrng interface which is the one that actually matters.

Fixes f29cd5bb64c2 ("crypto: qcom-rng - Add hw_random interface support")
drivers/crypto/Kconfig +0 -1
index 216a00bad5d7..eb834d15d614 100644
@@ -641,7 +641,6 @@ config CRYPTO_DEV_QCOM_RNG
 	tristate "Qualcomm Random Number Generator Driver"
 	depends on ARCH_QCOM || COMPILE_TEST
 	depends on HW_RANDOM
-	select CRYPTO_RNG
 	help
 	  This driver provides support for the Random Number
 	  Generator hardware found on Qualcomm SoCs.
drivers/crypto/qcom-rng.c +19 -139

226 lines not on this page · raw message

#1 lore raw
Quoted 8 lines · On Mon, Aug 31, 2026 at 03:00:46PM +0200, [email protected] wrote:

The patch below does not apply to the 6.12-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

To reproduce the conflict and resubmit, you may use the following commands:

Quoted 8 lines

git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.12.y
git checkout FETCH_HEAD
git cherry-pick -x 2ecdf5c9910e20f73639bc322f0518a3439d17c0
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026083146-squatted-debug-8f6e@gregkh' --subject-prefix 'PATCH 6.12.y' 'HEAD^..'

Possible dependencies:

This seems to have been added to the stable queue anyway, despite the FAILED email. So it seems there's nothing more to do. Also, please Cc the subsystem mailing list.

- Eric