Re: [PATCH] random: mix all saved registers into entropy pool

From: H. Peter Anvin
Date: Mon May 19 2014 - 19:05:23 EST


On 05/19/2014 03:39 PM, JÃrn Engel wrote:
> On Mon, 19 May 2014 15:18:01 -0700, H. Peter Anvin wrote:
>>
>> I think this is likely to be particularly valuable during boot. I can
>> see it becoming substantially less valuable after that point, but during
>> boot is when the most critical.
>>
>> What I do see as an issue is that the value is probably impossible to
>> quantify, and so I feel more than a bit queasy about giving it
>> /dev/random credit. However, making sure the pool is well stirred
>> during boot is really way more important.
>
> I would feel fairly confident giving this .25 bits of entropy per
> event. With 40% unique hashes and assuming at most 1 bit of entropy
> for a unique hash, that is a fairly conservative underestimate.
>

Sure, but that is for a specific workload.

> What worries me is that much of those 5s may be spent inside the idle
> loop and have rather predictable register content and we may run
> tickless. I have no great solution for that case.
>
> We could change the ratelimiting to, say, 4 interrupts per jiffie.
> But that would still not help much in the worst case scenario above,
> so the benefits don't seem convincing.

Exactly.

-hpa

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/