Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp6133929iog; Thu, 23 Jun 2022 12:03:51 -0700 (PDT) X-Google-Smtp-Source: AGRyM1vvVsu9ICji2gW/ctr54U+pVr7Q6Z0WTAIhWlZlB1Uya8bLe0nvFBft5wpYtlnSlyxQ9sRm X-Received: by 2002:aa7:dac2:0:b0:435:76a2:4ebe with SMTP id x2-20020aa7dac2000000b0043576a24ebemr12383459eds.196.1656011031074; Thu, 23 Jun 2022 12:03:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656011031; cv=none; d=google.com; s=arc-20160816; b=yJ3R4oNE6LMlItKiaRUg4mEjp0ZabgnL+tJY0/j4XJfKsoo7JY/jh3pGxmMFCKMJKt Zv1vcy9ze+YmuMvjntTMVKkz6ziODZi9UUs5raz3z/BONMzUrktkYkd///OLa97QHXiA gH07yyI6BpumAzsu42SHHMPiozonzHUuem8z3JCJm5FFeMRSI/WxWYnoHCQdQ9XWwFVG V5PKLHN3IYxrgMHISCMls3UXOn2Vuh+iYv5PRx1Z3Xs28qs4EwuDuGJrtznNQdRSTdJn EKm38yMhAvPqnBJ8eV9RTlKhapSAgO/RA/Xb7FWPdwBacKVTI9Q0tKAfuUQ3voo7LVec YvbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=1d7DsCpUWkm1pPD4SKpmPNyXRmIdmNOZVBMJXWWtgeY=; b=AA2GnoNJhmYteuFRfzxmjPSLqn9BBJltZ8+izbJC0EZhL5Msb4L+XSSdAbkEFUxS/1 4XtnR4DXa/sAQ5t/KrBbs7/AWKklIgZ+BY0Jx60fkSLfJcjGnQ13nMksPTqSmW9D85O8 SjJ/spbKtEvQso6Vk5pJyJIAO4BbqPxx0W63wt0aKJQbQbYmd8tXJyeGZ9Tp4sOy7TCs B2t7KlF5hv9GH4gyCyGS7dqAcj3RMtJbv0EHl+JCZ2qXmawrYPS0uiVGUzOIYiA1BNyZ A/Ipr/40dOzwxb5CmTM1ws4StRU2tZ9BJFN4D13ysG+Q25wOxymVUljEbyckUrUwHrTy c//A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Z115MAB7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a22-20020aa7cf16000000b0042df0646ba2si401927edy.30.2022.06.23.12.03.25; Thu, 23 Jun 2022 12:03:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Z115MAB7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233184AbiFWSKJ (ORCPT + 99 others); Thu, 23 Jun 2022 14:10:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48322 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230212AbiFWSGG (ORCPT ); Thu, 23 Jun 2022 14:06:06 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B5AE648314; Thu, 23 Jun 2022 10:18:07 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 4CDC061E07; Thu, 23 Jun 2022 17:18:07 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8FC5EC3411B; Thu, 23 Jun 2022 17:18:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1656004686; bh=LxfPCWUpPkoJx7CMdmDWuUIIaCKudlIu6rNxc9EV36E=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Z115MAB7IvXXmm/ma2qZSqX0r+JKIVV5T8fj9F//QBb1PYvy9Mu5oeI4olM3++LVW ZQQOo+Er1X6ueN+MjJ8WWc1SWC30hYS/gBGZaV604Y1GUqhH2oyedEQ/Fh3GkwEd4o F/Fr7Mbi8CBpXj3McblU8lVC1V/al40UhvuhXfgA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Theodore Tso , Dominik Brodowski , "Jason A. Donenfeld" Subject: [PATCH 4.19 116/234] random: give sysctl_random_min_urandom_seed a more sensible value Date: Thu, 23 Jun 2022 18:43:03 +0200 Message-Id: <20220623164346.341146891@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220623164343.042598055@linuxfoundation.org> References: <20220623164343.042598055@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: "Jason A. Donenfeld" commit d0efdf35a6a71d307a250199af6fce122a7c7e11 upstream. This isn't used by anything or anywhere, but we can't delete it due to compatibility. So at least give it the correct value of what it's supposed to be instead of a garbage one. Cc: Theodore Ts'o Reviewed-by: Dominik Brodowski Signed-off-by: Jason A. Donenfeld Signed-off-by: Greg Kroah-Hartman --- drivers/char/random.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/char/random.c +++ b/drivers/char/random.c @@ -1612,7 +1612,7 @@ const struct file_operations urandom_fop * to avoid breaking old userspaces, but writing to it does not * change any behavior of the RNG. * - * - urandom_min_reseed_secs - fixed to the meaningless value "60". + * - urandom_min_reseed_secs - fixed to the value CRNG_RESEED_INTERVAL. * It is writable to avoid breaking old userspaces, but writing * to it does not change any behavior of the RNG. * @@ -1622,7 +1622,7 @@ const struct file_operations urandom_fop #include -static int sysctl_random_min_urandom_seed = 60; +static int sysctl_random_min_urandom_seed = CRNG_RESEED_INTERVAL / HZ; static int sysctl_random_write_wakeup_bits = POOL_MIN_BITS; static int sysctl_poolsize = POOL_BITS; static u8 sysctl_bootid[UUID_SIZE];