Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1817918ybb; Thu, 2 Apr 2020 07:56:28 -0700 (PDT) X-Google-Smtp-Source: APiQypJF+6g+lw0gCKuDYoDS19/7Y7zY+U6N8l60JK48lmukQTLQvOKHW8i0DuoUWYNmH8UPVQKM X-Received: by 2002:aca:2b01:: with SMTP id i1mr2596745oik.162.1585839387939; Thu, 02 Apr 2020 07:56:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585839387; cv=none; d=google.com; s=arc-20160816; b=IpjmiQoiGsmIkSP7C5je4XaRVjm5d2bpSEKyPq6ImdZRFbvJFWMuR+ozeu2khGeldl 54s21HD++bgMjt17WCuwCYuYSQZaAvpXgPMj2ypJhWGCMdu/VkmQwRFucPp1PanUgu/r ZlUKB4dLvtY0v/tUckNwzodT22/iFsTbM+A3U9xWTxj4YVaz2PNevije3JuHyrSCer7W Wjvfok2VssuOfox/+rZ/lFvh9afnvhdZ9nuHXboZl3P9SgAYgxODt44H4RC0aRUh0kF2 ppjNmR0MZJU+iK590S7W+YDzIXLJMA7QJ5psmP1ugaAk3QVUeAcC13VRdTWE6n7xus4x mH8w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=4K01eNVB2V0D8O1PQ1rFTVzI9KCVoKt5jjRKfRfO3qs=; b=cj0O+3MI7PfgBkEOvUgEfl88n7RUd96841tcWHKPJbX1hhS/K42dEb/5YUOJBELH6z Taan+cxES2dWaaNpiFofdwlDVq/Z6vSy/OxNnkOuXLFVc0GRf+UNpmISNPcikL4fLs2d FVCTO7BGpRvQm8pfVx6+V4UH0yRYM13ryNiDtpDcyl4sM+5ElBIJjIcjXBof2ghhml08 fajuTt2Yr2SW8lux0zz4Rd72GZCSnhZiEWAl4iimhSvKIG8rIYumwvQZrOVuHKFtgvYp 0TiyxrhGBwE1irTkAzIYtvGUWqRK/26git82PXyQ2dvjLQRHx1XfCPwL/5KLrw8kPxxP kWcQ== 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 m2si2400300oof.17.2020.04.02.07.56.15; Thu, 02 Apr 2020 07:56:27 -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 S2388839AbgDBOyg (ORCPT + 99 others); Thu, 2 Apr 2020 10:54:36 -0400 Received: from foss.arm.com ([217.140.110.172]:43852 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388811AbgDBOyg (ORCPT ); Thu, 2 Apr 2020 10:54:36 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 864DB31B; Thu, 2 Apr 2020 07:54:35 -0700 (PDT) Received: from [192.168.122.166] (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 287C03F71E; Thu, 2 Apr 2020 07:54:35 -0700 (PDT) Subject: Re: [PATCH] ACPI: PPTT: Inform user that table offset used for Physical processor node ID To: John Garry , rjw@rjwysocki.net, lenb@kernel.org Cc: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, sudeep.holla@arm.com, linuxarm@huawei.com, wanghuiqiang@huawei.com References: <1585830145-208714-1-git-send-email-john.garry@huawei.com> <89f68a3c-264a-5d1b-e63a-d1147ea07320@arm.com> <0244dcc3-6006-2a67-e861-d2bcce4360f6@huawei.com> From: Jeremy Linton Message-ID: Date: Thu, 2 Apr 2020 09:54:25 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.6.0 MIME-Version: 1.0 In-Reply-To: <0244dcc3-6006-2a67-e861-d2bcce4360f6@huawei.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 4/2/20 9:51 AM, John Garry wrote: > On 02/04/2020 14:55, Jeremy Linton wrote: >> Hi, >> >> On 4/2/20 7:22 AM, John Garry wrote: >>> If the the Processor ID valid is not set for a Physical Processor >>> Package >>> node, then the node table offset is used as a substitute. As such, we >>> may get info like this from sysfs: >>> >>> root@(none)$ pwd >>> /sys/devices/system/cpu/cpu0/topology >>> root@(none)$ more physical_package_id >>> 56 >>> >>> Inform the user of this in the bootlog, as it is much less than >>> ideal, and >>> they can remedy this in their FW. >>> >>> This topic was originally discussed in: >>> https://lore.kernel.org/linux-acpi/c325cfe2-7dbf-e341-7f0f-081b6545e890@huawei.com/T/#m0ec18637d8586f832084a8a6af22580e6174669a >>> >>> >>> Signed-off-by: John Garry >>> >>> diff --git a/drivers/acpi/pptt.c b/drivers/acpi/pptt.c >>> index 4ae93350b70d..b4ed3c818e00 100644 >>> --- a/drivers/acpi/pptt.c >>> +++ b/drivers/acpi/pptt.c >>> @@ -515,6 +515,8 @@ static int topology_get_acpi_cpu_tag(struct >>> acpi_table_header *table, >>>           if (level == 0 || >>>               cpu_node->flags & ACPI_PPTT_ACPI_PROCESSOR_ID_VALID) >>>               return cpu_node->acpi_processor_id; >>> +        if (level == PPTT_ABORT_PACKAGE) >>> +            pr_notice_once("Physical package node Processor ID valid >>> not set, will use table offset as substitute\n"); > > Hi Jeremy, > >> >> What happens in the find_acpi_cpu_topology_hetro_id() case, if the >> last IDENTICAL node isn't a socket/etc. Are we expecting to warn of a >> missing processor container there as well? > > ok, I could just use this then: > > if (flags & ACPI_PPTT_PHYSCIAL_PACKAGE) >     pr_notice_once("Physical package node Processor ID ...") I think that is a better plan. > > As I recall, this tag for hetro id is not exposed to userspace (yet). Correct.