lkml.org 
[lkml]   [2020]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    SubjectRe: [PATCH] random: Document add_hwgenerator_randomness() with other input functions
    From
    Date
    On 4/24/20 5:39 AM, Mark Brown wrote:
    > The section at the top of random.c which documents the input functions
    > available does not document add_hwgenerator_randomness() which might lead
    > a reader to overlook it. Add a brief note about it.
    >
    > Signed-off-by: Mark Brown <broonie@kernel.org>
    > ---
    > drivers/char/random.c | 8 ++++++++
    > 1 file changed, 8 insertions(+)
    >
    > diff --git a/drivers/char/random.c b/drivers/char/random.c
    > index 0d10e31fd342..ba2dc45bf718 100644
    > --- a/drivers/char/random.c
    > +++ b/drivers/char/random.c
    > @@ -228,6 +228,14 @@
    > * particular randomness source. They do this by keeping track of the
    > * first and second order deltas of the event timings.
    > *
    > + * There is also an interface for true hardware RNGs:
    > + *
    > + * void add_hwgenerator_randomness(const char *buffer, size_t count,
    > + * size_t entropy);
    > + *
    > + * This will credit entropy as specified by the caller, if the entropy

    Use a ';' or '.' instead of ','. (and "If" if a period is used)

    > + * pool is full it will block until more entropy is needed.
    > + *
    > * Ensuring unpredictability at system startup
    > * ============================================
    > *
    >

    Otherwise looks good. Thanks.

    --
    ~Randy

    \
     
     \ /
      Last update: 2020-04-24 18:04    [W:8.679 / U:0.052 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site