Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp1757794imm; Thu, 21 Jun 2018 01:44:38 -0700 (PDT) X-Google-Smtp-Source: ADUXVKIvcMhvknsGGQXzDB/Ib8ZxSVxmsX7S+6jcKzXkK87wsP1/SSXSWyGJ3izz3Z87ru4W8vPe X-Received: by 2002:a63:9611:: with SMTP id c17-v6mr21652684pge.361.1529570678779; Thu, 21 Jun 2018 01:44:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529570678; cv=none; d=google.com; s=arc-20160816; b=CpgsPhTx9Q6uGZ5LlGZmUj1isC239kT/r3ee4yvoZE7LCDmbncQ6nqNr3EDAHKamLJ JTHOlY5X+dmKcxz5TCXoDM/CoNLxPHgSDlZ22XoZvF28OozHVaG3mlSvzvxa3N6xr8+9 ctuPBNQj2KEV29xYbMfftgUYI01aCDsb6ph4e9SgqOB+fCH367g8pYdZZnA43sV1U4sl 4p/K0jSM7aMzfNBtFtZ835pXMEXCfePppJ27ejwNuBWxgh1YNDPgOPYup6BN6bfvv0HY cKyxNNc6+wLtk+p+sGv7k0FnUtpzEgYY0u3ZUaViQMWxJ0xLt10GbYDkkDY6e9SUJpcX m/Uw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=+BNN64jSgtHcAckuKNQeIx4wG0bA3bMkdEkNdOj1Fm4=; b=yQykU/ddtrlLCKuSlsSMI+xul8yCdseWB1r3lgYmBchFJvnM9899NGEGgc2CCyNo0q dRLn8UJbEJ37orPNvb8WRrSzVcxUylim99W0ufgeO9mtDdYAK+oHggZ3S0i3nfc/g35E dhNyU13ebqzapt1vHs6upUm5Eb9WUwFVgIS+sVlzxXnZc4K2fv91bqXVdzS5DfTAeA0n h+Z3ds7u1stUC29hjTUFDulFiURSwQumDnLK7FGRiKokBMHnpVynpE35iT+mIN8oqyOQ nj5oeR0Bxdkjt8Oo9Zx5lKYu+aqBasn7ehoFex2Hn6T13WTKU2g5RH5CBnlhOE1kUo21 zeqQ== 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 x15-v6si3700241pgq.619.2018.06.21.01.44.24; Thu, 21 Jun 2018 01:44:38 -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 S932828AbeFUInh (ORCPT + 99 others); Thu, 21 Jun 2018 04:43:37 -0400 Received: from mx2.suse.de ([195.135.220.15]:40749 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932459AbeFUInf (ORCPT ); Thu, 21 Jun 2018 04:43:35 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext-too.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 35472AFA9; Thu, 21 Jun 2018 08:43:34 +0000 (UTC) From: Juergen Gross To: linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org, x86@kernel.org Cc: boris.ostrovsky@oracle.com, hpa@zytor.com, tglx@linutronix.de, mingo@redhat.com, Juergen Gross , stable@vger.kernel.org Subject: [PATCH] x86/xen: add call of speculative_store_bypass_ht_init() to pv paths Date: Thu, 21 Jun 2018 10:43:31 +0200 Message-Id: <20180621084331.21228-1-jgross@suse.com> X-Mailer: git-send-email 2.13.7 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit 1f50ddb4f4189243c05926b842dc1a0332195f31 ("x86/speculation: Handle HT correctly on AMD") added speculative_store_bypass_ht_init() to the per-cpu initialization sequence. speculative_store_bypass_ht_init() needs to be called on each cpu for pv guests, too. Reported-by: Brian Woods Fixes: 1f50ddb4f4189243c05926b842dc1a0332195f31 ("x86/speculation: Handle HT correctly on AMD") Cc: Signed-off-by: Juergen Gross Tested-by: Brian Woods --- arch/x86/xen/smp_pv.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/x86/xen/smp_pv.c b/arch/x86/xen/smp_pv.c index 2e20ae2fa2d6..e3b18ad49889 100644 --- a/arch/x86/xen/smp_pv.c +++ b/arch/x86/xen/smp_pv.c @@ -32,6 +32,7 @@ #include #include +#include #include #include @@ -70,6 +71,8 @@ static void cpu_bringup(void) cpu_data(cpu).x86_max_cores = 1; set_cpu_sibling_map(cpu); + speculative_store_bypass_ht_init(); + xen_setup_cpu_clockevents(); notify_cpu_starting(cpu); @@ -250,6 +253,8 @@ static void __init xen_pv_smp_prepare_cpus(unsigned int max_cpus) } set_cpu_sibling_map(0); + speculative_store_bypass_ht_init(); + xen_pmu_init(0); if (xen_smp_intr_init(0) || xen_smp_intr_init_pv(0)) -- 2.13.7