Received: by 2002:a4a:311b:0:0:0:0:0 with SMTP id k27-v6csp4780384ooa; Tue, 14 Aug 2018 10:26:42 -0700 (PDT) X-Google-Smtp-Source: AA+uWPw3vwwOoFx0iNhp/IvKfIB+63CAcnylXJdVrPB+kmDphZEu0HY0aRh50577qhzWvF8Qi4W9 X-Received: by 2002:a62:a216:: with SMTP id m22-v6mr23889983pff.163.1534267602340; Tue, 14 Aug 2018 10:26:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1534267602; cv=none; d=google.com; s=arc-20160816; b=NhWdx3XFLxxv13NfxTvhZ7X01A7iRY4OL4pKbdA9ao3MsDbBsZTPFV1wMsBnJqFReS bLIRbkEkjsrxuznsh6+RTVvAo4UmaO0TVZUVks9bvKEUKM+JwCmPjWVFnK6RKkI0V/ta SvtWix6UT8QP5lRHmhb/ewMdHF5cIJh7aVFs4n4tOh5PdFhY4KTVpQd7NDUMcNkbX24N oiePKogMumk8y70teoU53CS2EJWv7hG6f1noDeYA08IJxpjfxyRQsa9xe4oPMUENlc9H Eg8N8solVYxJuzaAA27dWrqURcdZmsRxjqsUQrjg8efvsguBpKcJ+I+ipgb8yPhXkJxI hxaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=xyrAtNu8j6DUSB3naLqTevFCwwCjgzV07GLtX6ddrng=; b=hc/6eyEjLRxzbgEeXGXbguuB5dFX5xOsP9fykWuVaHwaZTctjGflHN31UvxQv6Fm0t gjuCAEz3R45c1XIE05PoVnnC5Bs7UkiR0Rwz8bL8C4ZJesevhdrcg8tj0ki55ZBS1vzW D3Zp/GB3VOkXWOkWFGCPbh1yJRWgTEVh9VnJu2dRxOMyyx87sdhOEUouW/iF+6cexBsv DsjEUd4ofdKd2dIZ9OV+F5zuQ3Nh46+KDzGtndicrdtJb5mKEJi6VBoA9BTpttaQVQH+ h4GEqF7IZhO5NwYZCGsBieUoDQ0JVyWYyfkwJShzfIm8BbegKnWLvMKHN6EwmHcgrF8j pvfw== 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 r14-v6si21408200pfa.44.2018.08.14.10.26.27; Tue, 14 Aug 2018 10:26:42 -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 S2388079AbeHNUND (ORCPT + 99 others); Tue, 14 Aug 2018 16:13:03 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:51500 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388054AbeHNUNC (ORCPT ); Tue, 14 Aug 2018 16:13:02 -0400 Received: from localhost (unknown [194.244.16.108]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id CEFB6C5C; Tue, 14 Aug 2018 17:24:56 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Thomas Gleixner , Konrad Rzeszutek Wilk , Ingo Molnar Subject: [PATCH 4.18 24/79] x86/cpu/intel: Evaluate smp_num_siblings early Date: Tue, 14 Aug 2018 19:16:43 +0200 Message-Id: <20180814171337.729301526@linuxfoundation.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180814171336.799314117@linuxfoundation.org> References: <20180814171336.799314117@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Thomas Gleixner Make use of the new early detection function to initialize smp_num_siblings on the boot cpu before the MP-Table or ACPI/MADT scan happens. That's required for force disabling SMT. Signed-off-by: Thomas Gleixner Reviewed-by: Konrad Rzeszutek Wilk Acked-by: Ingo Molnar Signed-off-by: Greg Kroah-Hartman --- arch/x86/kernel/cpu/intel.c | 7 +++++++ 1 file changed, 7 insertions(+) --- a/arch/x86/kernel/cpu/intel.c +++ b/arch/x86/kernel/cpu/intel.c @@ -301,6 +301,13 @@ static void early_init_intel(struct cpui } check_mpx_erratum(c); + + /* + * Get the number of SMT siblings early from the extended topology + * leaf, if available. Otherwise try the legacy SMT detection. + */ + if (detect_extended_topology_early(c) < 0) + detect_ht_early(c); } #ifdef CONFIG_X86_32