[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YufOdlXNA5cuUIiL@zx2c4.com>
Date: Mon, 1 Aug 2022 15:00:38 +0200
From: "Jason A. Donenfeld" <Jason@...c4.com>
To: linux-kernel@...r.kernel.org
Cc: linux-crypto@...r.kernel.org, x86@...nel.org,
Nadia Heninger <nadiah@...ucsd.edu>,
Thomas Ristenpart <ristenpart@...nell.edu>,
Theodore Ts'o <tytso@....edu>,
Vincenzo Frascino <vincenzo.frascino@....com>,
Adhemerval Zanella Netto <adhemerval.zanella@...aro.org>,
Florian Weimer <fweimer@...hat.com>,
Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: [PATCH RFC v2] random: implement getrandom() in vDSO
On Sun, Jul 31, 2022 at 03:31:25AM +0200, Jason A. Donenfeld wrote:
> + batch_len = min_t(size_t, sizeof(state->batch) - state->pos, len);
> + if (batch_len) {
> + memcpy_and_zero(buffer, state->batch, batch_len);
Should be state->batch + state->pos, of course.
> + state->pos += batch_len;
> + buffer += batch_len;
> + len -= batch_len;
> + }
Powered by blists - more mailing lists