Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp5717918ybe; Tue, 10 Sep 2019 07:51:21 -0700 (PDT) X-Google-Smtp-Source: APXvYqz2RnQvgJF+N7Zj1iD7o0VN0XUb9PR8Qsz0Zvoi1si8JLzzcAUG6Wr/cUuNwyzQtpwuT3+9 X-Received: by 2002:aa7:df81:: with SMTP id b1mr30755801edy.281.1568127080920; Tue, 10 Sep 2019 07:51:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568127080; cv=none; d=google.com; s=arc-20160816; b=g9EVG9ZaSNOQIcFJUBBuPlnGRtDB7Fz/FnmFhpeohIwrazJ7xAJDGBbXfLBmVV7UDP 9HHOwZLH79kQsNXM/UkVfh1Nm7LUI3u2hg5T/lcSPM+hs+gACw32HoPuPx9qKAlEmRCd dg5vf3wFze2nZDSgRntzbVHNoMtlgC+McCiiCi09ElE6LTGpa7D6gZfj7r4HXDqFxDZf Lfkex437xZhQ4Bs+Pnyv1Z1t5dfTMd4S5qTyNhtz789yAmlj1Gi9ZxFTUY2cLAkaKQ84 CKzdXKydcYhTLhRZZLWO/o1W1sge+YuTj2EUjcusVfs1qUye9LdUT6lP8wF53IChkgyw mh0Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition:subject:cc:to:from :date:user-agent:references:message-id; bh=YoOnd81oReHE3SU+qJN2dtEgCzBK7iR6vOcPGkBRUEM=; b=IHgj4Svpn+1SPUjH1CqMkGG6N2Ec7DGMwRZVi+gF2ruqpjYO0cpfBDSPe6zAXUs4cP OHrC75xuEdpIQV1bysBrS2CoM/fHNVOsBSj4QOEf4oeDv5HuhY/A3+yZQ9fIXBOsbrpJ 6tXeJ5Oh3/kvmL6/teyWD/Gd8fUUxOn5+U8BxmOtEDUwFflaqqPYoxwaNhKcLPuPBjKN qunclWcD0RxpCxITRdClcOYbKwtz3Pj4DP/UZ7d6H0sid/W9HRYPIbzKKfqJC4/zay/F nHxFs/5QT/bxzbGx/H1WTB8eWO8CWItH3m92hn24qbZut9hRx4AEnQTJzf6UrKsAatAh /mew== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=hpe.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z16si11320734edb.420.2019.09.10.07.50.55; Tue, 10 Sep 2019 07:51:20 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=hpe.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2393454AbfIJOqg (ORCPT + 99 others); Tue, 10 Sep 2019 10:46:36 -0400 Received: from mx0b-002e3701.pphosted.com ([148.163.143.35]:13162 "EHLO mx0b-002e3701.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726066AbfIJOqf (ORCPT ); Tue, 10 Sep 2019 10:46:35 -0400 Received: from pps.filterd (m0150245.ppops.net [127.0.0.1]) by mx0b-002e3701.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id x8AEfanc010707; Tue, 10 Sep 2019 14:46:23 GMT Received: from g2t2353.austin.hpe.com (g2t2353.austin.hpe.com [15.233.44.26]) by mx0b-002e3701.pphosted.com with ESMTP id 2ux1w0r7fe-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 10 Sep 2019 14:46:23 +0000 Received: from stormcage.eag.rdlabs.hpecorp.net (stormcage.eag.rdlabs.hpecorp.net [128.162.236.70]) by g2t2353.austin.hpe.com (Postfix) with ESMTP id 27A8A9B; Tue, 10 Sep 2019 14:46:22 +0000 (UTC) Received: by stormcage.eag.rdlabs.hpecorp.net (Postfix, from userid 5508) id 64D7B201FCF26; Tue, 10 Sep 2019 09:46:21 -0500 (CDT) Message-Id: <20190910144610.632763542@stormcage.eag.rdlabs.hpecorp.net> References: <20190910144609.909602978@stormcage.eag.rdlabs.hpecorp.net> User-Agent: quilt/0.46-1 Date: Tue, 10 Sep 2019 09:46:15 -0500 From: Mike Travis To: Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Andrew Morton , Borislav Petkov , Christoph Hellwig Cc: Dimitri Sivanich , Russ Anderson , Hedi Berriche , Steve Wahl , Justin Ernst , x86@kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH V2 6/8] x86/platform/uv: Decode UVsystab Info Content-Disposition: inline; filename=decode-hubless-uvst X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.70,1.0.8 definitions=2019-09-10_10:2019-09-10,2019-09-10 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=999 mlxscore=0 malwarescore=0 suspectscore=0 bulkscore=0 clxscore=1015 impostorscore=0 phishscore=0 spamscore=0 priorityscore=1501 adultscore=0 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-1906280000 definitions=main-1909100142 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Decode the hubless UVsystab passed from BIOS to the kernel saving pertinent info in a similar manner that hubbed UVsystabs are decoded. Signed-off-by: Mike Travis Reviewed-by: Steve Wahl Reviewed-by: Dimitri Sivanich --- V2: Removed redundant error message after call to uv_bios_init. Removed redundant error message after call to decode_uv_systab. Clarify selection of UV4 and higher when checking for extended UVsystab in decode_uv_systab(). --- arch/x86/kernel/apic/x2apic_uv_x.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) --- linux.orig/arch/x86/kernel/apic/x2apic_uv_x.c +++ linux/arch/x86/kernel/apic/x2apic_uv_x.c @@ -1303,7 +1303,8 @@ static int __init decode_uv_systab(void) struct uv_systab *st; int i; - if (uv_hub_info->hub_revision < UV4_HUB_REVISION_BASE) + /* If system is uv3 or lower, there is no extended UVsystab */ + if (is_uv_hubbed(0xfffffe) < uv(4) && is_uv_hubless(0xfffffe) < uv(4)) return 0; /* No extended UVsystab required */ st = uv_systab; @@ -1554,8 +1555,15 @@ static __init int uv_system_init_hubless /* Init kernel/BIOS interface */ rc = uv_bios_init(); + if (rc < 0) + return rc; - /* Create user access node if UVsystab available */ + /* Process UVsystab */ + rc = decode_uv_systab(); + if (rc < 0) + return rc; + + /* Create user access node */ if (rc >= 0) uv_setup_proc_files(1); --