From patchwork Thu Nov 16 17:19:38 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Woods, Brian" X-Patchwork-Id: 10061565 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 61FBE604D3 for ; Thu, 16 Nov 2017 17:22:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1CE782A6FB for ; Thu, 16 Nov 2017 17:22:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1192D2ABD7; Thu, 16 Nov 2017 17:22:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 97C062A6FB for ; Thu, 16 Nov 2017 17:22:25 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eFNpS-0003SM-IL; Thu, 16 Nov 2017 17:19:54 +0000 Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eFNpR-0003S9-6w for xen-devel@lists.xen.org; Thu, 16 Nov 2017 17:19:53 +0000 Received: from [85.158.137.68] by server-5.bemta-3.messagelabs.com id 7B/FB-15737-8B8CD0A5; Thu, 16 Nov 2017 17:19:52 +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amd.com X-Msg-Ref: server-11.tower-31.messagelabs.com!1510852787!84419345!2 X-Originating-IP: [104.47.34.86] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 9.4.45; banners=-,-,- X-VirusChecked: Checked Received: (qmail 24935 invoked from network); 16 Nov 2017 17:19:49 -0000 Received: from mail-by2nam01on0086.outbound.protection.outlook.com (HELO NAM01-BY2-obe.outbound.protection.outlook.com) (104.47.34.86) by server-11.tower-31.messagelabs.com with AES256-SHA256 encrypted SMTP; 16 Nov 2017 17:19:49 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=ndwqyxhMaGpwGV+EMwwoJ1aT4pRUO0OiTTT1VpzfMRY=; b=fzTGndlsPl4RVceVXDtWI3urI9ouGR9OyQw5Jmpc+TELqAJBkMO0u7ixx2+4FCRxlo8wCDWBaV6gM+6k1sD8hpXgbetRNZo6Bbn49Az/SPKrE2UurhUtmRALj3ybPNllKmfLNwFQUaKEBxwD8f3j8h3lsUYkRdw54CEqyc/pgBA= Received: from nikka.amd.com (165.204.78.1) by CY4PR12MB1830.namprd12.prod.outlook.com (10.175.81.148) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.239.5; Thu, 16 Nov 2017 17:19:46 +0000 From: Brian Woods To: xen-devel@lists.xen.org Date: Thu, 16 Nov 2017 11:19:38 -0600 Message-Id: <20171116171939.6853-2-brian.woods@amd.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20171116171939.6853-1-brian.woods@amd.com> References: <20171116171939.6853-1-brian.woods@amd.com> MIME-Version: 1.0 X-Originating-IP: [165.204.78.1] X-ClientProxiedBy: CO1PR15CA0062.namprd15.prod.outlook.com (10.175.176.30) To CY4PR12MB1830.namprd12.prod.outlook.com (10.175.81.148) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 00159b3b-3fb7-4f0b-c2cb-08d52d163ca0 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(48565401081)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(2017052603199); SRVR:CY4PR12MB1830; X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1830; 3:bJg0Qgg6HBqSuL5RZFT5zmJ2YaAxdjnFpC9neGLXQQDnkmGFg14pZrxx8f6WPjydL4RKRdwgvxeLCLQNS5Gqcea8wYvcGr34qt2dmijPIWqnLu11sKFGQe3ocq2y9gQ7dPxwpyy+y6v43a8M46UX/t3fHNyrAT5qFrL31m1YLa7i6cMATsGYRo69S2WzAwHlAzMe6krPcAtX44l8AtiOLShIzekGOMFPZuJN34ZJnifnkUhDerhZIoJHEh/AygUU; 25:JkFv/LeKWllhSxpHJg29Bmv7PcrFs9haFNG4MCvO/9eky5KOGbeao4adJk49MDIOlZWUvUl8PCIWsVNjc81lWIeT0uecbNvfKMRvrNIoudPBsSxS4zEc3rH1F9H8vJKZMxe51HPauND/Oecgz2OxzpIvxiHfwx/Sa2hvGHr/mTLcc0MMLM9u00oC6gU0rMCGHnxPVuWbzVJW0imTz4D8XkaDqnBUpAZuPzQhuiSr13Q4BJM/nw/uo8crCHhQhzSdPAJNWifZRHEKiRK7bphGg8qU0FYVPhvo6YuouZXakWF7rLMs1E35G8Bw5xJd8oUnLp9oyhMpIig4XOD+vHYp/Q==; 31:+lNMzB0a1x3HXBpX94vpJklyKnRK6R6VYkBV7JaDEqbFUZ2TT+KmCKKAV5foe2NLt0zSQCJdDAi+qjoGp7VEs+2d3nSwWrZ1Qe8myvqKFyKeX7Oqto9iAwyouTAM9mwkJMZBa9gykBCAvWhpPdRWHg4kbE27+hvu7Ma7H/L3YKMIhTEx98K6fjZrap6coGNatNDySauIAy6L0y+41GmZ7Sz9orC/wRQT/cfnG34MVGg= X-MS-TrafficTypeDiagnostic: CY4PR12MB1830: X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1830; 20:6pbWRinTMXywzZcTedL6uXENvqU26KzJIY6O/51swbmnwWzxyuVZsq5Woc9mu2zB+m9H0ZvvaW1nC8rGIENMgMPRsHJ6+366Azo/rpKpN42TcPU4c2EAU21cbX1N/UwoievOGGoJgbdnk7j8SHowEBAL1PNcWo0KvdyWmAm2hawWG9nIRYBjHO9Vqgcq0KglPY20T1/sO1Nu3q6OQMjJ0aogcHAhXcF3FaggFmCuxJGgHWK2R+7A3YUvhae9MgGt2vs2beBfsG1YoUt9miiSoOQ3WinIE5fka6yQWRLIVHlHS4qa+zmhn9qcUkXj9Lx5omrDClOBMCjYlk53qJtU9cjk+vFy/fjyJJvaX+xTnUcFGF7Y8KyMEMfHb+JpQp1hg13y4PLC6KZ4JNhd9KM0AoN/pbZiRJP3/+Jj6aLAs68l9GfACYxJ2S4uGVLirtcWEaOj28QfsBsPo7QiBU+/w+IRMYyJP46f2IWg1jJk+6tXmTiOvTrnrvwKM9l4hLsT; 4:XTLkc1bw3bI9BdvMP7xBhXYjIcFqWpjh4ZfQEuQjJ5StYcCBWWWK+xYjUH0pL+11SSz3a2izGArpOf/bWxyCSSWq4LcaKIF9CW6gdErgvnn3zSQY720zRnPV5Y2sVRmY/qPT99AX14W5HcVBCaCmVF1G+j6yaPtcWvZq6F9al4ZO/JHdT/l0lIuPfPFsUQYrkMa3KBlxnDCpWpbN+2pdvQyWIdmu+spJ4HdN5/ekATJhqUfh68Jzvr3AORBuynLLVduo+7lDyxsAGsA6KWoXRcxrdcwgBJS1cLeYGZ8sE0SHA3weXDgvZZ2cEC954wSE X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(5005006)(8121501046)(3231022)(3002001)(10201501046)(93006095)(93001095)(100000703101)(100105400095)(6055026)(6041248)(20161123560025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123564025)(20161123555025)(20161123562025)(20161123558100)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:CY4PR12MB1830; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:CY4PR12MB1830; X-Forefront-PRVS: 0493852DA9 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(39860400002)(346002)(376002)(189002)(199003)(6486002)(8936002)(53416004)(72206003)(3846002)(2906002)(53936002)(6116002)(76176999)(50986999)(1076002)(25786009)(101416001)(36756003)(5660300001)(6666003)(2950100002)(478600001)(6916009)(4326008)(8676002)(50466002)(189998001)(47776003)(8666007)(66066001)(48376002)(54906003)(16586007)(305945005)(16526018)(81166006)(81156014)(97736004)(316002)(50226002)(105586002)(7736002)(2361001)(5003940100001)(575784001)(106356001)(33646002)(68736007)(2351001)(86362001); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR12MB1830; H:nikka.amd.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY4PR12MB1830; 23:NRxJZAG8TXwqayTCa0yq93CjulqGsAttXzBL30BHL?= =?us-ascii?Q?5XLa+JZ9HRhMgVYYph2V4+iLKcBo4XW6jn7n28HA9RyuHr0BksRb5z5memft?= =?us-ascii?Q?WuSNLnyL8QGd1iXngzQ94IBIjQdC5NA3UrNPchuhECR70WnthK7PJDNCE8ev?= =?us-ascii?Q?f3+sOQSOmkOBBUZ/QdPEmCMNaVWJMENXt3c08hqP2X8AsJgTOCyOLXtyJN6p?= =?us-ascii?Q?+EP0lOKEtTVQvTUrtisXz8ulWJkJ71Ecv8Zeq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BIVkPnVyJ74FuBKrQaVSWmJVopDlGONr0rdOHgRrADznarr9?= =?us-ascii?Q?9SXMqdQQA/kvf6Dq50pZUvqOczDmIaC6MYm?= X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1830; 6:f3VnKQYK6Wtj7XP8Hcw3MwPv1BrrJinExelzpUSFiguyoB+n7EK91ddvv2IaEZjgTWiqXh+zdrX1D/Zh9O4K8njJVm00vuEXhVRANTEa143bbBkO+hlSL9RyyxiRaAEWL+MAUFFKXPNmUeVakXPVeItg9WNqg2Ty/iDJQVvrFQadWL+68MdMwucjXTTSv1XWKxp31oumTQSm4a0VXcs4hnatx20XmDmW0XzlhWaM0kQmtUhMo3351JAbZmVd9O7yvMujhGPaJjoUMWQ76OGEYfcUtqQcqu9GO3nPxupuufRoaLsc7MikPV7w+AtJtrWFs19NfqhjC0jaC/W66vrMtLwIdG8byjyt2MyfemAriEQ=; 5:21AiBcO5g2sMh8fB7gqBT4/pa/IxjD67VI0xvqIb3ebkXXU9/DwY/Gr7DHTMh5DLBEa/VAsXux+DgXuCbHb1NRyDaomWD4hodgOg/FG0U3N7IE/4MZfP8RvRILIJ0QdMmJZCL3tjkV3N7DwNrnQtEnmkdnzIzXBmlx1H7GA0q2g=; 24:ApR+yby0bv0mguazm1tQ40btqIqwY46mQnRx9KxttC3cCdHflgTdmc0qht2qjj7cIbREaH51gN9xe2n+ppos7Sdgski/AMfl+8janxGxPx0=; 7:QgSFSMVTnPWVDzbeG4TCeZ0kf/fZWRVJ8g4wU5p/xMJjI2e9XetiUfzBSqg+cCB9N8QEuH8MJz8s4UuFXqstFpigRzQpI3y1PG5LuS6ZQqgxR/wciTf5Lvinw0qhCwMLCO5XoeY66OkVV7+1JoyPeJSbito/QDT4c+0JYNLLkSs46JL277Rad9G1R2poJsYRMF4uydGaCTj4nG7TOrot0v1/MrwKv0mo76dj71S6o5PwbM77A7vMcwBZQMZvjDqz SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1830; 20:NiCAxeAH4zsRnobx51Tvdzrj1WIh+j7o0/cen70oft3kQdvHB5n4gFikzdKJJtTBKekdk7qrt21C4ptiaXd+yeQqUAYHug5HaofLlsSThgl8J/Ks8urx5x/tSemgvAa3V0DJDFRVXOylirHqnMo7HRLuR/0JMRWZ24ZbmHkZMtV+LDnUrMOH/MK6jJOgm6vmjyaal+fKRWNPZg4Zr+9BclJgHKrTg7HPQgJjxoo1Ia6N5a94uPeC0uX/Z7ONWudJ X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Nov 2017 17:19:46.4367 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 00159b3b-3fb7-4f0b-c2cb-08d52d163ca0 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR12MB1830 Cc: Andrew Cooper , Boris Ostrovsky , Brian Woods , Jan Beulich , Suravee Suthikulpanit Subject: [Xen-devel] [PATCH v2 1/2] x86/svm: Add virtual GIF feature definition X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP Add support for enabling the virtual GIF feature. Signed-off-by: Brian Woods --- xen/include/asm-x86/hvm/svm/svm.h | 2 ++ xen/include/asm-x86/hvm/svm/vmcb.h | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/xen/include/asm-x86/hvm/svm/svm.h b/xen/include/asm-x86/hvm/svm/svm.h index 0956f860ef..ec1eda6a3e 100644 --- a/xen/include/asm-x86/hvm/svm/svm.h +++ b/xen/include/asm-x86/hvm/svm/svm.h @@ -64,6 +64,7 @@ extern u32 svm_feature_flags; #define SVM_FEATURE_FLUSHBYASID 6 /* TLB flush by ASID support */ #define SVM_FEATURE_DECODEASSISTS 7 /* Decode assists support */ #define SVM_FEATURE_PAUSEFILTER 10 /* Pause intercept filter support */ +#define SVM_FEATURE_VGIF 16 /* Virtual GIF */ #define cpu_has_svm_feature(f) test_bit(f, &svm_feature_flags) #define cpu_has_svm_npt cpu_has_svm_feature(SVM_FEATURE_NPT) @@ -72,6 +73,7 @@ extern u32 svm_feature_flags; #define cpu_has_svm_nrips cpu_has_svm_feature(SVM_FEATURE_NRIPS) #define cpu_has_svm_cleanbits cpu_has_svm_feature(SVM_FEATURE_VMCBCLEAN) #define cpu_has_svm_decode cpu_has_svm_feature(SVM_FEATURE_DECODEASSISTS) +#define cpu_has_svm_vgif cpu_has_svm_feature(SVM_FEATURE_VGIF) #define cpu_has_pause_filter cpu_has_svm_feature(SVM_FEATURE_PAUSEFILTER) #define cpu_has_tsc_ratio cpu_has_svm_feature(SVM_FEATURE_TSCRATEMSR) diff --git a/xen/include/asm-x86/hvm/svm/vmcb.h b/xen/include/asm-x86/hvm/svm/vmcb.h index 01ce20b0bd..595cfcf57b 100644 --- a/xen/include/asm-x86/hvm/svm/vmcb.h +++ b/xen/include/asm-x86/hvm/svm/vmcb.h @@ -325,12 +325,14 @@ typedef union { u64 tpr: 8; u64 irq: 1; - u64 rsvd0: 7; + u64 vgif: 1; + u64 rsvd0: 6; u64 prio: 4; u64 ign_tpr: 1; u64 rsvd1: 3; u64 intr_masking: 1; - u64 rsvd2: 7; + u64 vgif_enable: 1; + u64 rsvd2: 6; u64 vector: 8; u64 rsvd3: 24; } fields;