[RFC 3/3] random: disable interrupt random source

Johannes Berg johannes at sipsolutions.net
Thu Nov 19 05:19:14 PST 2026


From: Benjamin Berg <benjamin.berg at intel.com>

Interrupts in our UML environment are signals, which can be delivered at
somewhat random times depending on host scheduling. Disable these as a
source to make the random reproducible between runs.

Signed-off-by: Benjamin Berg <benjamin.berg at intel.com>
Signed-off-by: Johannes Berg <johannes.berg at intel.com>
---
 drivers/char/random.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/char/random.c b/drivers/char/random.c
index 64d0cfc99ac4..be9f744f3e72 100644
--- a/drivers/char/random.c
+++ b/drivers/char/random.c
@@ -1104,6 +1104,9 @@ void add_interrupt_randomness(int irq)
 	struct pt_regs *regs = get_irq_regs();
 	unsigned int new_count;
 
+	/* UML seems to not always get the signals entirely at the same time */
+	return;
+
 	fast_mix(fast_pool->pool, entropy,
 		 (regs ? instruction_pointer(regs) : _RET_IP_) ^ swab(irq));
 	new_count = ++fast_pool->count;
-- 
2.56.1




More information about the linux-um mailing list