From nobody Wed Jan 12 19:30:59 2022 X-Original-To: dev-commits-src-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 343991946859; Wed, 12 Jan 2022 19:31:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JYyN366p1z4qpR; Wed, 12 Jan 2022 19:30:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id B02F012E84; Wed, 12 Jan 2022 19:30:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 20CJUx2O054077; Wed, 12 Jan 2022 19:30:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 20CJUxM0054076; Wed, 12 Jan 2022 19:30:59 GMT (envelope-from git) Date: Wed, 12 Jan 2022 19:30:59 GMT Message-Id: <202201121930.20CJUxM0054076@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: d4724934f2e4 - stable/13 - vfs_mountroot: Skip 'Root mount waiting' < 1 s List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d4724934f2e41c850c0e714ebb89f888252b0ddd Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1642015859; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ejA8jAmmUxWx0BkzmJIL5VniP72ZVbNvDLXmSeb0p3o=; b=aNP/MGTF1DXwVEj5j8C2J1jZofiAo4F60QWrrNn1QXbwQJicMXGL1QsIycenvhg/7kCuEt QDjN2G0QfuPwMipMEbqYCEgKzTWBkO7/WVX4V19FZxY7RuG0hld+ttc1Eq/FZo4tmYS+Bq 7ZsUGXDU9RSSKSFMXaoZIDDdUlenftr/WCLStfvhMfuRWNpjGAvV9QLyl0Q62Sgb85lLrL DA+uHjoR18X0j88cozQGUfV9x9e8XJ9/MwnO95LAxBQXzcD5OyauPUL5YXlwVurTuSzSu2 kXYsgnJKUTiSzgD944ipGVD/VV/gCCXODS+OfP85wxEiskHPu+Ji6eG0R4x4wg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1642015859; a=rsa-sha256; cv=none; b=D2I3RnOd5r3e1/HfhMARNTxmdLrJYLCxGC77+BQilTKwxveBEAZKbjgn3aSkAWA/lxXWBr 98xzJnJTHvxH3PryAKD2Y6lv7eojOWNm/8M5xTOWGFKHMM4pvwtkjQhzuxZqGFhYrxk5Rt HLj13t5EBXbwfx4+WPIsNDzT+8S+BDDjmiszfvZbKioRVX+ujbmWMi49lFaZIffaZNrij1 v8CT7S/NMfYDCoNz27e49xPC1beLK2WSbVXNpbdzM/uoi0fiNou5fhyeeHgrfCi5aI7MhG zvHAFHUdFDRKKLgiJL1oqm4nq72vQeVzAwW7hvi3KGKaKmOb2FcXltE5WoXEtg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=d4724934f2e41c850c0e714ebb89f888252b0ddd commit d4724934f2e41c850c0e714ebb89f888252b0ddd Author: Colin Percival AuthorDate: 2021-12-20 15:17:25 +0000 Commit: Colin Percival CommitDate: 2022-01-12 19:29:37 +0000 vfs_mountroot: Skip 'Root mount waiting' < 1 s While the message is technically correct, it's not particularly helpful in the case where we're only waiting a few ms; this case occurs frequently on EC2 arm64 instances with CAM initialization racing to release its root hold before vfs_mountroot reaches this point. Only print the message if we end up waiting for more than one second. Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D33591 (cherry picked from commit e6db5eb9ec7ba9edfc564fd5ade5fb40df9acebb) --- sys/kern/vfs_mountroot.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/kern/vfs_mountroot.c b/sys/kern/vfs_mountroot.c index 9a3895b6f830..3ea9a7397d06 100644 --- a/sys/kern/vfs_mountroot.c +++ b/sys/kern/vfs_mountroot.c @@ -987,6 +987,7 @@ vfs_mountroot_wait(void) curfail = 0; lastfail.tv_sec = 0; + ppsratecheck(&lastfail, &curfail, 1); while (1) { g_waitidle(); mtx_lock(&root_holds_mtx);