mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Jason A. Donenfeld" <Jason@zx2c4.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org
Subject: [GIT PULL] random number generator fixes for 5.19-rc2
Date: Sat, 11 Jun 2022 17:36:11 +0200	[thread overview]
Message-ID: <20220611153611.828415-1-Jason@zx2c4.com> (raw)

Hi Linus,

Please pull the following random number generator fixes for 5.19-rc2:

- A fix for a 5.19 regression for a case in which early device tree
  initializes the RNG, which flips a static branch. On most plaforms, jump
  labels aren't initialized until much later, so this caused splats. On a few
  mailing list threads, we cooked up easy fixes for arm64, arm32, and risc-v.
  But then things looked slightly more involved for xtensa, powerpc, arc, and
  mips. And at that point, when we're patching 7 architectures in a place
  before the console is even available, it seems like the cost/risk just
  wasn't worth it. So random.c works around it now by checking the already
  exported `static_key_initialized` boolean, as though somebody already ran
  into this issue in the past. I'm not super jazzed about that; it'd be
  prettier to not have to complicate downstream code. But I suppose it's
  practical.

- A few small code nits and adding a missing __init annotation.

- A change to the default config values to use the cpu and bootloader's seeds
  for initializing the RNG earlier. This brings them into line with what all
  the distros do (Fedora/RHEL, Debian, Ubuntu, Gentoo, Arch, NixOS, Alpine,
  SUSE, and Void... at least), and moreover will now give us test coverage in
  various test beds that might have caught the above device tree bug earlier.

- A change to WireGuard CI's configuration to increase test coverage around
  the RNG.

- A documentation comment fix to unrelated maintainerless CRC code that I was
  asked to take, I guess because it has to do with polynomials (which the RNG
  thankfully no longer uses).

Thanks,
Jason

The following changes since commit e71e60cd74df9386c3f684c54888f2367050b831:

  Merge tag 'dma-mapping-5.19-2022-06-06' of git://git.infradead.org/users/hch/dma-mapping (2022-06-06 17:56:18 -0700)

are available in the Git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/crng/random.git tags/random-5.19-rc2-for-linus

for you to fetch changes up to 17b0128a136d43e5f8f268631f48bc267373ebff:

  wireguard: selftests: use maximum cpu features and allow rng seeding (2022-06-11 15:38:08 +0200)

----------------------------------------------------------------
Random number generator fixes for Linux 5.19-rc2.
----------------------------------------------------------------

Jason A. Donenfeld (7):
      random: avoid checking crng_ready() twice in random_init()
      random: mark bootloader randomness code as __init
      random: account for arch randomness in bits
      random: do not use jump labels before they are initialized
      random: credit cpu and bootloader seeds by default
      random: remove rng_has_arch_random()
      wireguard: selftests: use maximum cpu features and allow rng seeding

Roger Knecht (1):
      crc-itu-t: fix typo in CRC ITU-T polynomial comment

 drivers/char/Kconfig                               | 50 ++++++++++++++--------
 drivers/char/random.c                              | 39 ++++++++---------
 include/linux/crc-itu-t.h                          |  2 +-
 include/linux/random.h                             |  3 +-
 lib/crc-itu-t.c                                    |  2 +-
 lib/vsprintf.c                                     |  3 +-
 tools/testing/selftests/wireguard/qemu/Makefile    | 28 ++++++------
 tools/testing/selftests/wireguard/qemu/init.c      |  3 ++
 .../testing/selftests/wireguard/qemu/kernel.config |  3 ++
 9 files changed, 71 insertions(+), 62 deletions(-)

             reply	other threads:[~2022-06-11 15:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-11 15:36 Jason A. Donenfeld [this message]
2022-06-12 18:40 ` pr-tracker-bot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220611153611.828415-1-Jason@zx2c4.com \
    --to=jason@zx2c4.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®