Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp37583297rwd; Tue, 11 Jul 2023 16:55:52 -0700 (PDT) X-Google-Smtp-Source: APBJJlGa3DqmG/VgpzBwIL1Teu2EBKb3I1jO69LLr6dFhjRycWGxk8tB1xx7FAppj2+tMesUieZk X-Received: by 2002:a05:6402:350:b0:51d:f589:9c7a with SMTP id r16-20020a056402035000b0051df5899c7amr2840976edw.17.1689119752310; Tue, 11 Jul 2023 16:55:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689119752; cv=none; d=google.com; s=arc-20160816; b=wT6mAKjo3YPdIAbIm5XL6YnG4RB0hWv9cJ4O40bgwNkx5f0mhFbdnBG83o46un5Q9/ nwznEjHyZpcWd/EzNYNUaIH8b+8cJPJ9ASLHAqEvBumyL8Z2oxMHintm7at6iOeXDycE g1B/wdMQeMYlwZE/noRXijruECDZB99fYkrZ3XOygNxaXnaRjwy/jYIx4vn5CESWqdkk +x/0eEcmWqLBoR20fy6dyMzUSiQucRdWmqgsOwTpMF2uF4AXhAMJyLN9FrcyO1pAMhkH 00NFEdvC6GGayiieAtbA1vfzrT4ANkYLruB3Hw4kyAoNlbkvV9V3AcFvbSzf3QMYoe8j 4bpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:to:content-language:subject:user-agent:mime-version:date :message-id:dkim-signature; bh=Lrr621m3PEfOV+4L5pprIEQdmcfpacRL2Y9FyhiUSQk=; fh=LXZi7Tfpqr+u6JwZlhtQoHF68L1bX6pd0tjVprbQlq0=; b=Winzlov4uf0bPYdJ0B8/CnBrprSVZVqmhlnvf/u0WjngDBiXnKXYHOyIpzGzH0hAMv 7ITd4IcJu9JmFXaj3SzuPERDKqnAListt0zwmlsf0H7akUpuvuVPAXbqi7+usVPvBCIx n4VtZDvLzLwtPxtkKl8D9HBHXpPPv3zfGbAzFsEgrbO/vZS3orzTz7CsZymmSGQvta03 FaGrH+CbESdczMvd7T0Af/PiiM4N1WmOBe/KE3bBYhZ9OYNwZM+9JrOQzOtmIQ5q1oX5 RlHRaT6fhVwqFpC1Pbo1H8LgC3MQyZXgYoqsslhPLg7okiPp1Tu8gP5eSMk+KtjrJBKI tL7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=I4yBbWLL; 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=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b12-20020aa7c6cc000000b0051da08e2403si3018862eds.255.2023.07.11.16.55.23; Tue, 11 Jul 2023 16:55:52 -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=@intel.com header.s=Intel header.b=I4yBbWLL; 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=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229845AbjGKXIQ (ORCPT + 99 others); Tue, 11 Jul 2023 19:08:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47386 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230360AbjGKXH7 (ORCPT ); Tue, 11 Jul 2023 19:07:59 -0400 Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 706EACF for ; Tue, 11 Jul 2023 16:07:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1689116878; x=1720652878; h=message-id:date:mime-version:subject:to:references:from: in-reply-to:content-transfer-encoding; bh=fFtkcFDO8ixMyETrfbSOUsYJNuMITAkLOlhjZD0bGpk=; b=I4yBbWLLRH63Sc9b+orvAkMFN7HFimSf/UY6JbXpsf69YDo0UszqhWnh oRyIP+jPY4asnRBbFrHjFNj3ys9zFdY84dcNvhxYMU4CiyPZvtNrfBbn4 fANDTexiTULAugqnq6zKTQnvxgTryXNZuLZa9B8bAVe/1PRXsjoI2Ch2X +3H2aWfREYsl/y5cWu1flq+AInTuMsGFOC9PiXtSsuObax0sWE1oJGPxc Z95cxPL+dTd63SwF1jaqivE7RStU5Nl15xFTmfvQewGcUtQwLYMU3qJHk nK/UB9STppvrt3jurUkrYBbcGrXbAB9WgEWLVEA2q5YDGBpfBtHs7iBIY A==; X-IronPort-AV: E=McAfee;i="6600,9927,10768"; a="362224692" X-IronPort-AV: E=Sophos;i="6.01,197,1684825200"; d="scan'208";a="362224692" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Jul 2023 16:07:57 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10768"; a="834890058" X-IronPort-AV: E=Sophos;i="6.01,197,1684825200"; d="scan'208";a="834890058" Received: from ticela-or-054.amr.corp.intel.com (HELO [10.209.95.41]) ([10.209.95.41]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Jul 2023 16:07:57 -0700 Message-ID: <7422da56-a5a1-d6b2-a2a0-fd4ee5dde5e0@intel.com> Date: Tue, 11 Jul 2023 16:07:55 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: [PATCH] x86/platform/uv: Abort UV initialization when reduced nr_cpus requires it Content-Language: en-US To: Steve Wahl , Dimitri Sivanich , Russ Anderson , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H. Peter Anvin" , linux-kernel@vger.kernel.org References: <20230711202618.85562-1-steve.wahl@hpe.com> From: Dave Hansen In-Reply-To: <20230711202618.85562-1-steve.wahl@hpe.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED 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 On 7/11/23 13:26, Steve Wahl wrote: > When nr_cpus is set to a smaller number than actually present, there > is some node-to-socket mapping info we won't get access to in First of all, no "we's" in commit messages. > https://www.kernel.org/doc/html/next/process/maintainer-tip.html#changelog > build_socket_tables(). This could later result in using a -1 value > for some array indexing, and eventual kernel page faults. > > To avoid this, if any unfilled table entries are found, print a > warning message, and resume initializing, acting as if this is not a > UV system. UV features will be unavailable, but we will not cause > kernel dumps. > > This is a condition we expect only in platform debugging situations, > not in day-to-day operation. This seems like a hack. The real problem is that you've got an online Linux NUMA node with no CPUs. uv_system_init_hub() (probably) goes and does: > for_each_node(nodeid) > __uv_hub_info_list[nodeid] = uv_hub_info_list_blade[uv_node_to_blade_id(nodeid)]; But the node=>blade lookup uses socket numbers. No CPUs means no socket numbers. You _have_ the blade information _somewhere_. Is there really no other way to map it to a NUMA node than using the CPU apicid?