All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephan Mueller <smueller@chronox.de>
To: miaoqing@codeaurora.org
Cc: kvalo@qca.qualcomm.com, linux-wireless@vger.kernel.org,
	ath9k-devel@qca.qualcomm.com, linux-crypto@vger.kernel.org,
	jason@lakedaemon.net, pouyans@qti.qualcomm.com
Subject: Re: [PATCH 2/2] ath9k: disable RNG by default
Date: Tue, 09 Aug 2016 09:14:30 +0200	[thread overview]
Message-ID: <4627645.oz3l49ICL3@tauon.atsec.com> (raw)
In-Reply-To: <1470726147-30095-2-git-send-email-miaoqing@codeaurora.org>

Am Dienstag, 9. August 2016, 15:02:27 CEST schrieb miaoqing@codeaurora.org:

Hi Miaoqing,

> From: Miaoqing Pan <miaoqing@codeaurora.org>
> 
> ath9k RNG will dominates all the noise sources from the real HW
> RNG, disable it by default. But we strongly recommand to enable
> it if the system without HW RNG, especially on embedded systems.
> 
> Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>

As a short term solution:

Acked-by: Stephan Mueller <smueller@chronox.de>

But as Jason outlined, there should be nothing that prevents using this code 
with the HW Random framework. This framework also has logic to limit the rate 
of injection and allows the setting of the entropy threshold at runtime.

> ---
>  drivers/net/wireless/ath/ath9k/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/wireless/ath/ath9k/Kconfig
> b/drivers/net/wireless/ath/ath9k/Kconfig index f68cb00..8f231c6 100644
> --- a/drivers/net/wireless/ath/ath9k/Kconfig
> +++ b/drivers/net/wireless/ath/ath9k/Kconfig
> @@ -180,7 +180,7 @@ config ATH9K_HTC_DEBUGFS
>  config ATH9K_HWRNG
>  	bool "Random number generator support"
>  	depends on ATH9K && (HW_RANDOM = y || HW_RANDOM = ATH9K)
> -	default y
> +	default n
>  	---help---
>  	  This option incorporates the ADC register output as a source of
>  	  randomness into Linux entropy pool (/dev/urandom and /dev/random)



Ciao
Stephan

WARNING: multiple messages have this Message-ID (diff)
From: Stephan Mueller <smueller-T9tCv8IpfcWELgA04lAiVw@public.gmane.org>
To: miaoqing-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org
Cc: kvalo-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org,
	linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	ath9k-devel-A+ZNKFmMK5xy9aJCnZT0Uw@public.gmane.org,
	linux-crypto-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	jason-NLaQJdtUoK4Be96aLqz0jA@public.gmane.org,
	pouyans-Rm6X0d1/PG5y9aJCnZT0Uw@public.gmane.org
Subject: Re: [PATCH 2/2] ath9k: disable RNG by default
Date: Tue, 09 Aug 2016 09:14:30 +0200	[thread overview]
Message-ID: <4627645.oz3l49ICL3@tauon.atsec.com> (raw)
In-Reply-To: <1470726147-30095-2-git-send-email-miaoqing-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>

Am Dienstag, 9. August 2016, 15:02:27 CEST schrieb miaoqing-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org:

Hi Miaoqing,

> From: Miaoqing Pan <miaoqing-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
> 
> ath9k RNG will dominates all the noise sources from the real HW
> RNG, disable it by default. But we strongly recommand to enable
> it if the system without HW RNG, especially on embedded systems.
> 
> Signed-off-by: Miaoqing Pan <miaoqing-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>

As a short term solution:

Acked-by: Stephan Mueller <smueller-T9tCv8IpfcWELgA04lAiVw@public.gmane.org>

But as Jason outlined, there should be nothing that prevents using this code 
with the HW Random framework. This framework also has logic to limit the rate 
of injection and allows the setting of the entropy threshold at runtime.

> ---
>  drivers/net/wireless/ath/ath9k/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/wireless/ath/ath9k/Kconfig
> b/drivers/net/wireless/ath/ath9k/Kconfig index f68cb00..8f231c6 100644
> --- a/drivers/net/wireless/ath/ath9k/Kconfig
> +++ b/drivers/net/wireless/ath/ath9k/Kconfig
> @@ -180,7 +180,7 @@ config ATH9K_HTC_DEBUGFS
>  config ATH9K_HWRNG
>  	bool "Random number generator support"
>  	depends on ATH9K && (HW_RANDOM = y || HW_RANDOM = ATH9K)
> -	default y
> +	default n
>  	---help---
>  	  This option incorporates the ADC register output as a source of
>  	  randomness into Linux entropy pool (/dev/urandom and /dev/random)



Ciao
Stephan
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2016-08-09  7:14 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-09  7:02 [PATCH 1/2] ath9k: change entropy formula for easier understanding miaoqing
2016-08-09  7:02 ` [PATCH 2/2] ath9k: disable RNG by default miaoqing
2016-08-09  7:14   ` Stephan Mueller [this message]
2016-08-09  7:14     ` Stephan Mueller
2016-08-09  7:35     ` Pan, Miaoqing
2016-08-09  8:07       ` Stephan Mueller
2016-08-09  8:58         ` Herbert Xu
2016-08-09  9:02           ` Stephan Mueller
2016-08-09  9:17             ` Herbert Xu
2016-08-09  9:17               ` Herbert Xu
2016-08-09  9:37               ` Stephan Mueller
2016-08-09  9:37                 ` Stephan Mueller
2016-08-09  9:46                 ` Herbert Xu
2016-08-09  9:56                   ` Stephan Mueller
2016-08-09  9:56                     ` Herbert Xu
2016-08-09 10:06                       ` Stephan Mueller
2016-08-09 10:24                         ` Henrique de Moraes Holschuh
2016-08-09 10:24                           ` Henrique de Moraes Holschuh
2016-08-09 17:51                           ` Jason Cooper
2016-08-10  2:35                 ` Pan, Miaoqing
2016-08-10  2:35                   ` Pan, Miaoqing
2016-08-10  5:29                   ` Stephan Mueller
2016-08-10  5:29                     ` Stephan Mueller
2016-08-10  6:04                     ` Pan, Miaoqing
2016-08-10  6:04                       ` Pan, Miaoqing
2016-08-10  6:25                       ` Stephan Mueller
2016-08-10  6:46                         ` Pan, Miaoqing
2016-08-10  6:46                           ` Pan, Miaoqing
2016-08-10  6:51                           ` Stephan Mueller
2016-08-10  7:15                             ` Pan, Miaoqing
2016-08-10  7:27                               ` Stephan Mueller
2016-08-10  7:27                                 ` Stephan Mueller
2016-08-10  7:40                                 ` Pan, Miaoqing
2016-08-10  7:40                                   ` Pan, Miaoqing
2016-08-10  7:43                                   ` Pan, Miaoqing
2016-08-10  7:43                                     ` Pan, Miaoqing
2016-08-10 13:24                                     ` Jason Cooper
2016-08-10 13:24                                       ` Jason Cooper
2016-08-11  2:54                                       ` miaoqing
2016-08-11 13:14                                         ` Jason Cooper
2016-08-11 13:14                                           ` Jason Cooper
2016-08-09 17:48   ` Jason Cooper
2016-08-09 17:48     ` Jason Cooper
2016-09-28 10:00   ` [2/2] " Kalle Valo
2016-09-27 14:53 ` [1/2] ath9k: change entropy formula for easier understanding Kalle Valo
2016-09-27 14:53   ` Kalle Valo
2016-10-13 14:23 ` Kalle Valo
2016-10-13 14:23   ` Kalle Valo

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=4627645.oz3l49ICL3@tauon.atsec.com \
    --to=smueller@chronox.de \
    --cc=ath9k-devel@qca.qualcomm.com \
    --cc=jason@lakedaemon.net \
    --cc=kvalo@qca.qualcomm.com \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=miaoqing@codeaurora.org \
    --cc=pouyans@qti.qualcomm.com \
    /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.