From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.1 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E1827C5ACAE for ; Wed, 11 Sep 2019 17:00:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B4A9521479 for ; Wed, 11 Sep 2019 17:00:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1568221240; bh=3w6xF3foq1hxXmdkkCHS1s5w3xVpNEx7uKE/4HZvrkY=; h=References:In-Reply-To:From:Date:Subject:To:Cc:List-ID:From; b=SiV5nVnyGDJVD2eveBdW2+7rOvpDjAf6XR6Dlq53oD5kTLWxffmby0vnSHlmW3EZC hZI+MQbXGmqwRLQNeyW7mLmTQBu+IsTRFu788/491Gwn4NjAKn4hJ8+m59I84E5ehO ZGR1rMT3j8aAcczTgwtq5K4Onh8tH4/BMgVIAeN0= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729002AbfIKRAk (ORCPT ); Wed, 11 Sep 2019 13:00:40 -0400 Received: from mail-lj1-f193.google.com ([209.85.208.193]:33359 "EHLO mail-lj1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728825AbfIKRAk (ORCPT ); Wed, 11 Sep 2019 13:00:40 -0400 Received: by mail-lj1-f193.google.com with SMTP id a22so20738782ljd.0 for ; Wed, 11 Sep 2019 10:00:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=hI3EB/9BDPeGlAj5JSZDGYA2f1JCFRdoSzkNrQAXirE=; b=CGKf9ffZA0sDKRiYz4VTL4pJ6O/i9q/3SuKL2cMKY0lYCwrIgBzzQc9qpL02hJUCVf zhRFfXilE/dIFAK6zLlsU05aZBlAW8SlX2gIrBCON7ulaV9IINxTNXZGi6/Lfghu5RUo Ttenh548bV73virB1och/bEQUdMXAWdJlPKp4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=hI3EB/9BDPeGlAj5JSZDGYA2f1JCFRdoSzkNrQAXirE=; b=VTzcB6Fli2i7mfwurvf6geOBzBDDuzWg0gtsrtJIpWSjYzLMOgBJ+OxlFR53TL8Ng+ JicnOb5Ps4dUDfuBQbrZYFafSuAmvT5wu91rlexT5vzy8YNxV2w12U+c+fSyNQrlm4Pw guRV34Mng+gad9hW/Ok997qlGokhRyC3wL/qc4aiWP7uMFbqcoyRjb8Ij2VpYZ8l9+kk wHiBNCktUE7YiJ37YgCKzTfyK3ZPmGjxsw+dk8+EEReqPs7+H94U5UxUlw2oUoNjGPZ7 G9vttlqTyPsGQ+70PM3e+og821m/oNo8RqEdo2hsEhTUR+l23ZojvtAj0MDVTuEYG+oV 49Nw== X-Gm-Message-State: APjAAAWyhAu581n66FrmfvTVIvrgSBgJYgUG4AlSVDgGDWYehG0TeAwj iguUzwpIXgSb8nfnWOnCP5DY5cn+M9SqXg== X-Google-Smtp-Source: APXvYqyQKDD0VXDh6jRytqK4x81Vx3r3/ESmbL+t00hNLDqcSfuD9e8fAa0E6QtaVRVkxfcetYPyIw== X-Received: by 2002:a2e:654a:: with SMTP id z71mr24080001ljb.37.1568221237193; Wed, 11 Sep 2019 10:00:37 -0700 (PDT) Received: from mail-lj1-f173.google.com (mail-lj1-f173.google.com. [209.85.208.173]) by smtp.gmail.com with ESMTPSA id f15sm5244872lfc.30.2019.09.11.10.00.36 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 11 Sep 2019 10:00:36 -0700 (PDT) Received: by mail-lj1-f173.google.com with SMTP id q22so16125409ljj.2 for ; Wed, 11 Sep 2019 10:00:36 -0700 (PDT) X-Received: by 2002:a05:651c:1108:: with SMTP id d8mr16107533ljo.180.1568221235850; Wed, 11 Sep 2019 10:00:35 -0700 (PDT) MIME-Version: 1.0 References: <20190910042107.GA1517@darwi-home-pc> <20190910173243.GA3992@darwi-home-pc> <20190911160729.GF2740@mit.edu> In-Reply-To: From: Linus Torvalds Date: Wed, 11 Sep 2019 18:00:19 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Linux 5.3-rc8 To: "Theodore Y. Ts'o" Cc: "Ahmed S. Darwish" , Andreas Dilger , Jan Kara , Ray Strode , William Jon McCann , zhangjs , linux-ext4@vger.kernel.org, lkml Content-Type: text/plain; charset="UTF-8" Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org Archived-At: List-Archive: List-Post: On Wed, Sep 11, 2019 at 5:45 PM Linus Torvalds wrote: > > So I'd be inclined to either lower the limit regardless - and perhaps > make the "user space asked for randomness much too early" be a big > *warning* instead of being a basically fatal hung machine? Hmm. Just testing - normally I run my laptop with TRUST_CPU enabled, so I never see this any more, but warning (rather than waiting) is what we still do for the kernel. And I see [ 0.231255] random: get_random_bytes called from start_kernel+0x323/0x4f5 with crng_init=0 and that's this code: add_latent_entropy(); add_device_randomness(command_line, strlen(command_line)); boot_init_stack_canary(); in particular, it's the boot_init_stack_canary() thing that asks for a random number for the canary. I don't actually see the 'crng init done' until much much later: [ 21.741125] random: crng init done but part of that may be that my early boot is slow due to having an encrypted disk and so the bootup ends up waiting for me to type the passphrase. But this does show that (a) we have the same issue in the kernel, and we don't block there (b) initializing the crng really can be a timing problem The interrupt thing is only going to get worse as disks turn into ssd's and some of them end up using polling rather than interrupts.. So we're likely to see _fewer_ interrupts in the future, not more. Linus