From patchwork Fri Jul 27 12:49:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juerg Haefliger X-Patchwork-Id: 950164 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41cTMJ2Rf4z9ryt; Fri, 27 Jul 2018 22:50:04 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1fj2Bw-0004bD-UQ; Fri, 27 Jul 2018 12:49:56 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.86_2) (envelope-from ) id 1fj2Bu-0004b6-Ud for kernel-team@lists.ubuntu.com; Fri, 27 Jul 2018 12:49:54 +0000 Received: from mail-ed1-f72.google.com ([209.85.208.72]) by youngberry.canonical.com with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.76) (envelope-from ) id 1fj2Bu-0000ua-N7 for kernel-team@lists.ubuntu.com; Fri, 27 Jul 2018 12:49:54 +0000 Received: by mail-ed1-f72.google.com with SMTP id d5-v6so2164654edq.3 for ; Fri, 27 Jul 2018 05:49:54 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=d8KhB5M8WcU68/Ok6gR7TtWKk9me3u/S5PaoUdt8qt4=; b=VjXAdsdX9H+Zg9luE1AocoTpzBS4OqIqlxvRi2XI/gxTeeE+VQSgBJ/KjUGwj2BGKd O8v/lN/+9vj0wqpNHOD3CC1cu0TTMrYrHYYHFIKnL7YDriJ1arQ/cnvMhYQLUccDDD0i c0YkwWWS8F02jwt7R45L+qwnp+UDIUg46F8yg1/9S+bGPQM2JV5mE14EVomcseu+ObJ5 UXcIHKVJy23bjWTPObAyDfZ/5KmNlUJAcgW/5DXo8DS+CaIesw9QZrGEZZG2Kt3jEsW1 Y7B4JPjBVf3NUKerBmMgMGTSz6bN4gqeSsp13rZUcjmPQjCY9JLemirUYnMc2aaQjfFK aUdA== X-Gm-Message-State: AOUpUlHtzi/Ts7dZ6oNO5O2M7yxRVmZF58BxJMUcm8pElsF3/mYb9acW hD//KS4MzXnYvjpgeeXFzvzH9X6UGPgHHBE3993dQuol7/+0WkjQvMMOuj2m7xytYkqfRbmzKTJ 8E3FQ7ZpzoACB9g7r3usrVhySTsiK8GQq3aBVzl0c7Q== X-Received: by 2002:a50:c01d:: with SMTP id r29-v6mr7134464edb.202.1532695794218; Fri, 27 Jul 2018 05:49:54 -0700 (PDT) X-Google-Smtp-Source: AAOMgpeZhWd4VwRmh58Q5J65/HqLa8j0ZSPrCalqyXUss3h9jTWV2JGkHxiCg0UrCvDNF9j2bB3/ZQ== X-Received: by 2002:a50:c01d:: with SMTP id r29-v6mr7134449edb.202.1532695794029; Fri, 27 Jul 2018 05:49:54 -0700 (PDT) Received: from gollum.fritz.box ([81.221.205.149]) by smtp.gmail.com with ESMTPSA id c7-v6sm1685583edi.79.2018.07.27.05.49.53 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 27 Jul 2018 05:49:53 -0700 (PDT) From: Juerg Haefliger X-Google-Original-From: Juerg Haefliger To: kernel-team@lists.ubuntu.com Subject: [SRU][Trusty][PATCH 1/1] UBUNTU: SAUCE: x86: Use barrier_nospec in arch/x86/um/asm/barrier.h Date: Fri, 27 Jul 2018 14:49:52 +0200 Message-Id: <20180727124952.30882-1-juergh@canonical.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <2dd022222443a00e54f58f0e2a0e5f9e78c0e6b7.1532593086.git.juergh@canonical.com> References: <2dd022222443a00e54f58f0e2a0e5f9e78c0e6b7.1532593086.git.juergh@canonical.com> X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: https://bugs.launchpad.net/bugs/1774181 Modify the duplicate rdtsc_barrier() in arch/x86/um/asm/barrier.h. Fixes: b3d7ad85b80b ("x86: Introduce barrier_nospec") Signed-off-by: Juerg Haefliger Acked-by: Stefan Bader Acked-by: Kleber Sacilotto de Souza --- arch/x86/um/asm/barrier.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/x86/um/asm/barrier.h b/arch/x86/um/asm/barrier.h index 7d01b8c56c00..f16760f3d848 100644 --- a/arch/x86/um/asm/barrier.h +++ b/arch/x86/um/asm/barrier.h @@ -68,8 +68,7 @@ */ static inline void rdtsc_barrier(void) { - alternative(ASM_NOP3, "mfence", X86_FEATURE_MFENCE_RDTSC); - alternative(ASM_NOP3, "lfence", X86_FEATURE_LFENCE_RDTSC); + barrier_nospec(); } #endif