Re: [PATCH] crypto: jitter - add oversampling of noise source

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Freitag, 17. Dezember 2021, 13:06:07 CET schrieb Simo Sorce:

Hi Simo,

> >  static void jent_gen_entropy(struct rand_data *ec)
> >  {
> > 
> > -	unsigned int k = 0;
> > +	unsigned int k = 0, safety_factor = JENT_ENTROPY_SAFETY_FACTOR;
> > +
> > +	if (!jent_fips_enabled())
> > +		safety_factor = 0;
> 
> I would find this more readable if safety_factor is initialized to 0,
> and then in the code:
> 	if (jent_fips_enabled())
> 		safety_factor = JENT_ENTROPY_SAFETY_FACTOR;
> 
> However this is just readability for me, either option is perfectly
> identicaly IMO, so

Thank you, I will send an updated patch.

Ciao
Stephan





[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux