[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Ygyjib2FKY87S7/H@owl.dominikbrodowski.net>
Date: Wed, 16 Feb 2022 08:11:05 +0100
From: Dominik Brodowski <linux@...inikbrodowski.net>
To: "Jason A. Donenfeld" <Jason@...c4.com>
Cc: Toke Høiland-Jørgensen <toke@...e.dk>,
miaoqing@...eaurora.org, rsalvaterra@...il.com,
Jason Cooper <jason@...edaemon.net>,
"Sepehrdad, Pouyan" <pouyans@....qualcomm.com>,
ath9k-devel <ath9k-devel@....qualcomm.com>,
"linux-wireless@...r.kernel.org" <linux-wireless@...r.kernel.org>,
Kalle Valo <kvalo@...nel.org>,
Linux Crypto Mailing List <linux-crypto@...r.kernel.org>,
Herbert Xu <herbert@...dor.apana.org.au>,
LKML <linux-kernel@...r.kernel.org>,
Netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH] ath9k: use hw_random API instead of directly dumping
into random.c
Am Wed, Feb 16, 2022 at 12:52:15AM +0100 schrieb Jason A. Donenfeld:
> On 2/16/22, Toke Høiland-Jørgensen <toke@...e.dk> wrote:
> >> @@ -22,9 +22,6 @@
> >> #include "hw.h"
> >> #include "ar9003_phy.h"
> >>
> >> -#define ATH9K_RNG_BUF_SIZE 320
> >> -#define ATH9K_RNG_ENTROPY(x) (((x) * 8 * 10) >> 5) /* quality: 10/32 */
> >
> > So this comment says "quality: 10/32" but below you're setting "quality"
> > as 320. No idea what the units are supposed to be, but is this right?
>
> I think the unit is supposed to be how many entropic bits there are
> out of 1024 bits? These types of estimates are always BS, so keeping
> it on the lower end as before seemed right. Herbert can jump in here
> if he has a better idea; that's his jig.
10/32 = 320/1024, so that change is correct.
Dominik
Powered by blists - more mailing lists