Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp650925ybt; Mon, 6 Jul 2020 19:23:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw827oWUjlgLjY1pdhQTV5wzneZGl/XBFYfR9FlzLY0jfz00boLsKpMWCfeSBuOGONDN80w X-Received: by 2002:a17:906:5949:: with SMTP id g9mr44740772ejr.305.1594088585390; Mon, 06 Jul 2020 19:23:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594088585; cv=none; d=google.com; s=arc-20160816; b=AA9sFyr3CCS8tKdf64PAq1J6oasiKLtukYGRUP9rYKGUaBc6hjSEAY1YkscO1dOIG4 rs03xoepyJLzknARDmbcMQk/S05GDQ540vk91iYxfjunethtRFw04ytLgVr+Z7U5pIzM 2sd1KhtXU/+BEouEbNzcVkwZneq4fsCpiS16Mm1mk5aVK9Dlp+SMnW7QkpqLP650Fu5x 10hrnodqn879n8oGYfRBBO1PfAFxxl64eG7O83dTIIDIKw9b4hxfBRoQq2rx6UBp0juX 09LFqFQyGMOYi/KNGtAct3k4uwvH4wH5yCme3I+I5ibI2XEB0l+tKRhCHo2LpT0o0hCD rhnw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:ironport-sdr:ironport-sdr; bh=cSYbYxRXIx51aDrdE0NbmgS31YtiL5FJEzxMkALPlCk=; b=sg5TarXMdXmnqcO4FzrtvetkHa6t9G3vPe6iVakqCnewlRwJFAbMHK2cj5JEG5aaoD haeDctjbUVozfq9o7K3LlZMQ66vAeF6P/o2isRTxELazzWT69W1SJiw43DjVL1KuKYbc 8Kh7hxpLclUfn0Hm6uqlZdrlUSKjA5cQzE+hDldLZkB4EcPJqzaNxzZ0+mvzn4JzrHT9 i4nht6iSaq2HPiym7e+bOyyDbR3s+vn/Crhh7sPO0i5WDXy0kxGygluBayZaaRMSze/c XBKNd+INb3YWdYGMgHPMCUULjGdPUYM2ssK0kN8rD7Nrp/MYJk6oVvvdxzDggr6isAqs aajg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dm19si16650002ejc.17.2020.07.06.19.22.42; Mon, 06 Jul 2020 19:23:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727949AbgGGCV4 (ORCPT + 99 others); Mon, 6 Jul 2020 22:21:56 -0400 Received: from mga18.intel.com ([134.134.136.126]:13713 "EHLO mga18.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727818AbgGGCVz (ORCPT ); Mon, 6 Jul 2020 22:21:55 -0400 IronPort-SDR: tSs4+it+xlFegJ8Clg8UmX9AcGM+HN0X8SUFL3sb5z6zy/wbCLc3PJCjw9X+F2OLyvQ33IfVKp eAuLLovijd1Q== X-IronPort-AV: E=McAfee;i="6000,8403,9674"; a="134993942" X-IronPort-AV: E=Sophos;i="5.75,321,1589266800"; d="scan'208";a="134993942" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Jul 2020 19:21:54 -0700 IronPort-SDR: 4L7jp6Ec8oc9PkdA+d+RkKO6oUvD2KyiLlJFH9MBjmSwDfIBhgIZfh93p2XjS2wxnOdgMAWskK pnt57yVk0C8A== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.75,321,1589266800"; d="scan'208";a="357633737" Received: from unknown (HELO localhost.localdomain.bj.intel.com) ([10.238.156.127]) by orsmga001.jf.intel.com with ESMTP; 06 Jul 2020 19:21:49 -0700 From: Cathy Zhang To: kvm@vger.kernel.org, linux-kernel@vger.kernel.org, x86@kernel.org Cc: pbonzini@redhat.com, sean.j.christopherson@intel.com, vkuznets@redhat.com, wanpengli@tencent.com, jmattson@google.com, joro@8bytes.org, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, hpa@zytor.com, ricardo.neri-calderon@linux.intel.com, kyung.min.park@intel.com, jpoimboe@redhat.com, gregkh@linuxfoundation.org, ak@linux.intel.com, dave.hansen@intel.com, tony.luck@intel.com, ravi.v.shankar@intel.com, Cathy Zhang Subject: [PATCH v2 2/4] x86/cpufeatures: Enumerate TSX suspend load address tracking instructions Date: Tue, 7 Jul 2020 10:16:21 +0800 Message-Id: <1594088183-7187-3-git-send-email-cathy.zhang@intel.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1594088183-7187-1-git-send-email-cathy.zhang@intel.com> References: <1594088183-7187-1-git-send-email-cathy.zhang@intel.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Intel TSX suspend load tracking instructions aim to give a way to choose which memory accesses do not need to be tracked in the TSX read set. Add TSX suspend load tracking CPUID feature flag TSXLDTRK for enumeration. A processor supports Intel TSX suspend load address tracking if CPUID.0x07.0x0:EDX[16] is present. Two instructions XSUSLDTRK, XRESLDTRK are available when this feature is present. The CPU feature flag is shown as "tsxldtrk" in /proc/cpuinfo. Detailed information on the instructions and CPUID feature flag TSXLDTRK can be found in the latest Intel Architecture Instruction Set Extensions and Future Features Programming Reference and Intel 64 and IA-32 Architectures Software Developer's Manual. Signed-off-by: Kyung Min Park Signed-off-by: Cathy Zhang --- arch/x86/include/asm/cpufeatures.h | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/x86/include/asm/cpufeatures.h b/arch/x86/include/asm/cpufeatures.h index adf45cf..34b66d7 100644 --- a/arch/x86/include/asm/cpufeatures.h +++ b/arch/x86/include/asm/cpufeatures.h @@ -366,6 +366,7 @@ #define X86_FEATURE_MD_CLEAR (18*32+10) /* VERW clears CPU buffers */ #define X86_FEATURE_TSX_FORCE_ABORT (18*32+13) /* "" TSX_FORCE_ABORT */ #define X86_FEATURE_SERIALIZE (18*32+14) /* SERIALIZE instruction */ +#define X86_FEATURE_TSX_LDTRK (18*32+16) /* TSX Suspend Load Address Tracking */ #define X86_FEATURE_PCONFIG (18*32+18) /* Intel PCONFIG */ #define X86_FEATURE_SPEC_CTRL (18*32+26) /* "" Speculation Control (IBRS + IBPB) */ #define X86_FEATURE_INTEL_STIBP (18*32+27) /* "" Single Thread Indirect Branch Predictors */ -- 1.8.3.1