aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2015-06-09 18:19:39 +0800
committerMister Oyster <oysterized@gmail.com>2017-04-11 10:59:06 +0200
commitde1b74fe67f7925bdc7b3a5c65653f6c166b1d03 (patch)
tree41231ed5de327c6d2e8e3bda06f25f5187a2d7f2 /scripts
parent8ee472b7d2c0f42bc7ee1b8ed86189f14d19d5ec (diff)
random: Add callback API for random pool readiness
The get_blocking_random_bytes API is broken because the wait can be arbitrarily long (potentially forever) so there is no safe way of calling it from within the kernel. This patch replaces it with a callback API instead. The callback is invoked potentially from interrupt context so the user needs to schedule their own work thread if necessary. In addition to adding callbacks, they can also be removed as otherwise this opens up a way for user-space to allocate kernel memory with no bound (by opening algif_rng descriptors and then closing them). Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions