From owner-svn-src-all@freebsd.org Tue Dec 15 15:04:07 2020 Return-Path: Delivered-To: svn-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id DEAA44B9104; Tue, 15 Dec 2020 15:04:07 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: from mail-qt1-x82a.google.com (mail-qt1-x82a.google.com [IPv6:2607:f8b0:4864:20::82a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CwM3W5mDMz4SX9; Tue, 15 Dec 2020 15:04:07 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: by mail-qt1-x82a.google.com with SMTP id z9so14748070qtn.4; Tue, 15 Dec 2020 07:04:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=8bgmmcFyaMUkmk84gpJqLR1XgwAslkAlmtfM3Cn8B84=; b=Z0x6ZOiPARKpeaIZZ6WeWPzhK0eG3p+leEmPZjnyzJyWGbcPqSY9nebocSScX/LuXz RF0mlHmq0OpU0qU1TIciMF8QCawZf4qYttUueCQyFNk6Tp3JksP0Ik2b2bn4WToIacZf 2ZiSW71CKSZFAwLZEaEhmX3J4mKnau8J5YqoCOpVfIDnekBKeUFWWSsU9S5aAivpo4+0 HZxn5JFdF/cbomoQZCyVartYFZjUYwtkPT8bcolgmXNNngdbT4wZrGJVcWz11L8lyOQx Lgkf0l2QMpw6AaMFt4/R1Kdkk2PvC/B2UBwM7gs87x7dF4xPyByj2He4PpVd6mci7Lx4 +9TQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to; bh=8bgmmcFyaMUkmk84gpJqLR1XgwAslkAlmtfM3Cn8B84=; b=bGkjLclxFGA+yFPCTPMyLSMkRfMLiDH2pMagTLr80l/ARvzc38MUlhTpWhAusnElky UHzXerzPjJz6uRWNItCxwunhfP+Mey1IuSY2IQepOz9hqNn505+l3upGeK/LtdwoPpSb MAdxIEN7LDefEZX/pMZDit2iIH/hInekpjj9M1r03F8LFMyyhHCn7aSrRBT/04C2kgF5 CxtbOdYTRQ2JadkLA2/E/lf+SnbGbpVDeA40sqzPcxUcZmIl7AvvwddmBAEtcioiaPsd J5FMcvBvKdGqoEWM8JrqBNTVh7wVYBxjt64u5+hrtYUE2eTgkeHyrqGS6IMGFa1ZeqP0 FCew== X-Gm-Message-State: AOAM533SprXHmIqbibYIrzh8X8xNM+v+sqlej90qg+qYDjpiAtq+TyBq xk/cA6Y+yQ37Mk8Qv/kozydUiHLkxyA= X-Google-Smtp-Source: ABdhPJyz+FEwk0bizssd8wZBPeVXFTDkQh7jdFzdtU1Tsze9ddHsRRus3+n9SZxpSeNjprxsg8yQhQ== X-Received: by 2002:ac8:71c7:: with SMTP id i7mr35884480qtp.47.1608044646878; Tue, 15 Dec 2020 07:04:06 -0800 (PST) Received: from raichu ([142.126.164.150]) by smtp.gmail.com with ESMTPSA id l191sm16118169qke.7.2020.12.15.07.04.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Dec 2020 07:04:06 -0800 (PST) Sender: Mark Johnston Date: Tue, 15 Dec 2020 10:04:03 -0500 From: Mark Johnston To: Hans Petter Selasky Cc: Bryan Drewery , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r368523 - head/sys/vm Message-ID: References: <202012102044.0BAKiTHh011767@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Rspamd-Queue-Id: 4CwM3W5mDMz4SX9 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 Dec 2020 15:04:07 -0000 On Tue, Dec 15, 2020 at 03:33:09PM +0100, Hans Petter Selasky wrote: > On 12/15/20 3:27 PM, Mark Johnston wrote: > >> I'm seeing the following panic: > >> > >> panic("vm_wait in early boot") > >> vm_wait_domain() > >> kmem_alloc_contig_pages() > >> kmem_alloc_contig_domainset() > >> kmem_alloc_contig() > >> contigmalloc() > >> x86bios_alloc() > >> vesa_configure() > >> vesa_mod_event() > >> vesa_module_register_init() > >> mi_startup() > > Is it on a NUMA system? I see that the new logic won't work properly if > > there are empty domains, so this suggests that we really do need a > > special contig iterator as discussed in the review. > > Yes, this is a numa system. > > I just noticed, that before r368523 "flags" was updated by > _vm_domainset_iter_policy_init() to always contain M_NOWAIT and that > avoids the wait logic, but I think x86bios_alloc() doesn't get its > memory then. Yes, but note that vm_domainset_iter_policy() will also call vm_wait_doms() if a M_NOWAIT allocation from each domain fails. x86bios_alloc() requests memory from the first 1MB of physical memory, but because contigmalloc() uses a round-robin iterator initialized from per-thread state it may try from the "wrong" domain first. So really a different solution to the original problem is needed. > I'm not sure if x86bios_alloc() needs to be attached a bit later anyway? > > --HPS