Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp3878918imm; Tue, 11 Sep 2018 03:38:51 -0700 (PDT) X-Google-Smtp-Source: ANB0Vdb/StWo5ysgBm+wG33a9F1E/O8cq2Qd7npq6YD2UbEH5QLo+3k4Irm5ExK4xib8/gI4IL3r X-Received: by 2002:a17:902:d898:: with SMTP id b24-v6mr7053537plz.218.1536662331725; Tue, 11 Sep 2018 03:38:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536662331; cv=none; d=google.com; s=arc-20160816; b=JVQQ/yQJ1BstiGJgy5bsa839tRqZ1pGaypVoiQ/CAmDzN41+SQRH67iHwnhqH2hL36 +nGnxmGjk3YnyS5nbFuINYIaET0rKs1vjcDq+4csgRew0vv5SCm6JzYZ5v3o7F/uFUeW pna46HqL6rwHizAid74mmdj6EyCAA78xltmBx6J88rkoF0OaxG8W2we9Cf2G6ZpoNwha EOw79yrM/nMQ8j3aIN2Dp5UHVLcR9UDUvf7AzgpwCosq4nFu1LnIm2tuP4kGC+EftHs2 jNXWk0LCT9KXJvv/ZZN8/dMMXw248JmWKRHvBdJUvujpC4F7cw91vDhd2T23YgNI5ZfZ wKbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=4aQ+OdCPwM2ARuwW7P57BsN8jCo0Our5Pv2eUuulRSs=; b=hO8YgTBVfU8JrqohYxV2v+OtpwrwTK03hEbSR9Uohq7idec1Lx6u/lyZb/CgzXzFcX txf0V+XeDb7wPRlV1dy0nQaDb+JCx2FhI6e8PphHQozx5lZVKjNJt9GqvlptyHLVr7VH IoEiqP+zhyB/0ylMZjhdTWCkS8UMS1kkyXkUl2K/yuBdEu01VhKYKl+Gs+7gZzHbenNj BmJ2OYhvBcyfnUbyIP4+5AwBHOxIU+IqAZG0c9B43niCYuz7atzJtjR63UbsKPO6puLT jKcfiNskot5rtXBihgIeRikVcwCsQmAmBuBus8yC8//Y+n6jyjU0TixejJZR4D5sTeSg RsTA== 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 h14-v6si20948645pgl.289.2018.09.11.03.38.36; Tue, 11 Sep 2018 03:38:51 -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 S1726739AbeIKPhP (ORCPT + 99 others); Tue, 11 Sep 2018 11:37:15 -0400 Received: from mail.skyhub.de ([5.9.137.197]:37010 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726554AbeIKPhP (ORCPT ); Tue, 11 Sep 2018 11:37:15 -0400 X-Virus-Scanned: Nedap ESD1 at mail.skyhub.de Received: from mail.skyhub.de ([127.0.0.1]) by localhost (blast.alien8.de [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id E10vu8rR-EVZ; Tue, 11 Sep 2018 12:38:30 +0200 (CEST) Received: from zn.tnic (p200300EC2BC6F600329C23FFFEA6A903.dip0.t-ipconnect.de [IPv6:2003:ec:2bc6:f600:329c:23ff:fea6:a903]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id E06481EC0645; Tue, 11 Sep 2018 12:38:29 +0200 (CEST) Date: Tue, 11 Sep 2018 12:38:28 +0200 From: Borislav Petkov To: Pu Wen Cc: tglx@linutronix.de, mingo@redhat.com, hpa@zytor.com, x86@kernel.org, thomas.lendacky@amd.com, pbonzini@redhat.com, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org Subject: Re: [PATCH v6 09/16] x86/bugs: Add mitigation to spectre and no meltdown for Hygon Dhyana Message-ID: <20180911103828.GF12094@zn.tnic> References: <191ce6b53269e90fdc26ee49ef337b905bd7d99c.1536550550.git.puwen@hygon.cn> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <191ce6b53269e90fdc26ee49ef337b905bd7d99c.1536550550.git.puwen@hygon.cn> User-Agent: Mutt/1.9.5 (2018-04-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 10, 2018 at 09:17:40PM +0800, Pu Wen wrote: > The Hygon Dhyana CPU has the same speculative execution as AMD family > 17h, so share AMD spectre mitigation code for Hygon Dhyana. > > Also Hygon Dhyana is not affected by meltdown vulnerability as AMD, > so add the exception for Hygon Dhyana. > > Signed-off-by: Pu Wen > --- > arch/x86/kernel/cpu/bugs.c | 6 ++++-- > arch/x86/kernel/cpu/common.c | 1 + > 2 files changed, 5 insertions(+), 2 deletions(-) > > diff --git a/arch/x86/kernel/cpu/bugs.c b/arch/x86/kernel/cpu/bugs.c > index 40bdaea..726010d 100644 > --- a/arch/x86/kernel/cpu/bugs.c > +++ b/arch/x86/kernel/cpu/bugs.c > @@ -312,8 +312,9 @@ static enum spectre_v2_mitigation_cmd __init spectre_v2_parse_cmdline(void) > } > > if (cmd == SPECTRE_V2_CMD_RETPOLINE_AMD && > + boot_cpu_data.x86_vendor != X86_VENDOR_HYGON && > boot_cpu_data.x86_vendor != X86_VENDOR_AMD) { > - pr_err("retpoline,amd selected but CPU is not AMD. Switching to AUTO select\n"); > + pr_err("retpoline,amd selected but CPU is not AMD or Hygon. Switching to AUTO select\n"); Didn't we say, no user-visible changes pls? -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.