ath9k-devel.lists.ath9k.org archive mirror
 help / color / mirror / Atom feed
* [ath9k-devel] [RFC][PATCH] RANDOM: ATH9K RNG delivers zero bits of entropy
@ 2016-08-05 15:18 Stephan Mueller
  2016-08-06 20:02 ` Jason Cooper
  2016-08-07  9:36 ` [ath9k-devel] [PATCH v2] " Stephan Mueller
  0 siblings, 2 replies; 17+ messages in thread
From: Stephan Mueller @ 2016-08-05 15:18 UTC (permalink / raw)
  To: ath9k-devel

Hi Ted, Herbert,

I sent a question to the ATH9K RNG some time ago to the developers.
See https://www.mail-archive.com/linux-crypto at vger.kernel.org/msg19115.html

I have not yet received a word and I think this issue should be resolved.

Thanks
Stephan

---8<---

The ATH9K driver implements an RNG which is completely bypassing the
standard Linux HW generator logic.

The RNG may or may not deliver entropy. Considering the conservative
approach in treating entropy with respect to non-auditable sources, this
patch changes the delivered entropy value to zero. The RNG still feeds
data into the input_pool but it is assumed to have no entropy.

When the ATH9K RNG changes to use the HW RNG framework, it may re-enable
the entropy estimation considering that a user can change that value at
boot and runtime.

Signed-off-by: Stephan Mueller <smueller@chronox.de>
---
 drivers/net/wireless/ath/ath9k/rng.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/net/wireless/ath/ath9k/rng.c b/drivers/net/wireless/ath/ath9k/rng.c
index d38e50f..d63dc48 100644
--- a/drivers/net/wireless/ath/ath9k/rng.c
+++ b/drivers/net/wireless/ath/ath9k/rng.c
@@ -92,8 +92,7 @@ static int ath9k_rng_kthread(void *data)
 		fail_stats = 0;
 
 		/* sleep until entropy bits under write_wakeup_threshold */
-		add_hwgenerator_randomness((void *)rng_buf, bytes_read,
-					   ATH9K_RNG_ENTROPY(bytes_read));
+		add_hwgenerator_randomness((void *)rng_buf, bytes_read, 0);
 	}
 
 	kfree(rng_buf);
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2016-09-27 15:23 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-05 15:18 [ath9k-devel] [RFC][PATCH] RANDOM: ATH9K RNG delivers zero bits of entropy Stephan Mueller
2016-08-06 20:02 ` Jason Cooper
2016-08-06 20:04   ` Stephan Mueller
2016-08-06 20:32     ` Jason Cooper
2016-08-07  9:36 ` [ath9k-devel] [PATCH v2] " Stephan Mueller
2016-08-08  2:10   ` Pan, Miaoqing
2016-08-08  6:41     ` Stephan Mueller
2016-08-08 17:46       ` Jason Cooper
2016-08-08 22:05         ` Jason Cooper
2016-08-09  6:30         ` Pan, Miaoqing
2016-08-09 12:14           ` Theodore Ts'o
2016-08-09 14:04             ` Jason Cooper
2016-08-10 23:44               ` Theodore Ts'o
2016-08-14 18:11                 ` Jason Cooper
2016-08-15 11:01     ` Kalle Valo
2016-09-27 14:44   ` [ath9k-devel] [v2] " Kalle Valo
2016-09-27 15:23     ` Stephan Mueller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).