Received: by 10.192.165.148 with SMTP id m20csp288149imm; Tue, 1 May 2018 23:40:08 -0700 (PDT) X-Google-Smtp-Source: AB8JxZq0tNjRxIGtfEsawbQmrA73QFOribVbCik6YmwltmWsLN7x7pAeUeEiP+5z3rngOKLiX2U4 X-Received: by 2002:a17:902:3f83:: with SMTP id a3-v6mr18974154pld.279.1525243208076; Tue, 01 May 2018 23:40:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525243208; cv=none; d=google.com; s=arc-20160816; b=jUCF6KL2JruveeZjphmE/R+qW/TnfyoSHTLObuSqUvfPvMvF3ht24Em3/n7o4J8zbe 0RVzxVw7OM8JoHEs9j+lGUcaCC9cGjRN4xRt4MOCy06g/Kz/CfPr2whwS+FJWPFs5Aby JuSIVrT7qFgRCLv2eNjxS7TW3DZNAynTlN3rnvfhHd3GkXsDGobt3QBB3Daw5je0fOgV ItOX7mlPkic1pgVCcdwp6rLTugThoSbYpHRZZ+jeuZs4kdCSQQ1K9amRVpbJ9MBzqeCT oFKWeRv9DMx/hGVEn7MqxuCYW6Dxl81f3Onro7URyvrwgBnhUhBJo8+syqzvT8IW00rf yWwg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:mime-version:in-reply-to:references :subject:cc:to:from:date:message-id:arc-authentication-results; bh=8BELWmkkNn5XQXTCgVOKHxm4q3L79wUaII/8htrUo1g=; b=QYT25CHgB9sjncbCNvvKLU4Ws3zCq40KSTxM6KpXm8yn8vxh297EiQy6lno3dpDEuv 15MtiEtK4Gi5OKfmdux1oZTGj3x6M05D/MVOnXJZtT0963jOnToFNmKwQjEWayc5q1eF 3ZrrSVc25BR6zyFbjAKsf2x+s3ePwmcEE41KT5Rl15VoY0aIujeCZ+WjZJn6Gh0PQLMJ DeEOy1epLpvWNt5Va0pM/D6O0rhWMWmNz4JHOfVem6Lm2gLUxSf16vz1KByQ9XD5QRCr wm8hU58iCrLLG+c65Gym8igtx+QJLsDQD7ji4klTJXs/9y9ELDFq+04ErJKqOzZu5WdU RpDQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i190-v6si9281936pge.408.2018.05.01.23.39.53; Tue, 01 May 2018 23:40:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751026AbeEBGjf convert rfc822-to-8bit (ORCPT + 99 others); Wed, 2 May 2018 02:39:35 -0400 Received: from prv1-mh.provo.novell.com ([137.65.248.33]:55241 "EHLO prv1-mh.provo.novell.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750907AbeEBGjc (ORCPT ); Wed, 2 May 2018 02:39:32 -0400 Received: from INET-PRV1-MTA by prv1-mh.provo.novell.com with Novell_GroupWise; Wed, 02 May 2018 00:39:31 -0600 Message-Id: <5AE95D2002000078001BFEC4@prv1-mh.provo.novell.com> X-Mailer: Novell GroupWise Internet Agent 18.0.0 Date: Wed, 02 May 2018 00:39:28 -0600 From: "Jan Beulich" To: Cc: , Subject: Re: recent patch "x86/acpi: Prevent X2APIC id 0xffffffff from being accounted" References: <5AE2CF8802000078001BF017@prv1-mh.provo.novell.com> <12fd36d0-1678-ed57-fec3-c94b430bd23f@cn.fujitsu.com> <5AE3130702000078001BF180@prv1-mh.provo.novell.com> <769e14c9-298d-3049-4001-2a8fe903d21e@cn.fujitsu.com> In-Reply-To: <769e14c9-298d-3049-4001-2a8fe903d21e@cn.fujitsu.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 8BIT Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org >>> On 02.05.18 at 03:56, wrote: > At 04/27/2018 08:09 PM, Jan Beulich wrote: >> I'm afraid I don't understand: Limiting the number of disabled CPUs is >> certainly desirable when those can never be used, but why would you >> want to do this when they might later get hotplugged? I'm not aware > > Let's see the workflow of CPU hotplug: > > 1) get the CPU device info from ACPI namespace > - it contains logical processor id > > 2) through the logical processor id, get the LACPI entry in MADT. > > 3) generate the CPU for kernel(will create a CPU id, can see by lscpu) > > Normally, there are no valid CPU devices in 1) which are mapped to > the LACPI entries(0xff or 0xffffffff). > > The actually number of hotplugged CPUs depends on CPU devices/processors > in ACPI namespace. The number calculated from MADT is the maximum > situation which can be cut and doesn't affect CPU hotplug. Don't worry > about it. > > Now, in ACPI-based system, Linux gets the number of possible CPUs by > MADT, We are going to use the ACPI namespace to make the number > accurate. But it is so hard, because it's so late to initialize the ACPI > namespace. So are you envisioning a model when the number of disabled CPUs can be increased once the ACPI interpreter has been enabled? Otherwise the maximum recorded during early boot may be too low with the changes in question. (And FTR, I agree this number may also be way too large without them, but it being too large is a resource efficiency problem, while it being too low is a functionality one.) Also, for background, besides wanting to clarify the correctness of these two changes, I'm also trying to understand whether we want to mirror them into the Xen hypervisor, which relies on the Dom0 kernel's ACPI interpreter (i.e. it can and does parse MADT, but can't and doesn't parse the ACPI name space). Hence late adjustment of the number of hotpluggable CPUs would be even more problematic in that environment. Jan