From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9DB57C2D0DB for ; Thu, 23 Jan 2020 15:45:29 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7C4FC21734 for ; Thu, 23 Jan 2020 15:45:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728900AbgAWPp2 (ORCPT ); Thu, 23 Jan 2020 10:45:28 -0500 Received: from mga04.intel.com ([192.55.52.120]:29414 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726231AbgAWPp2 (ORCPT ); Thu, 23 Jan 2020 10:45:28 -0500 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 23 Jan 2020 07:45:27 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,354,1574150400"; d="scan'208";a="222375221" Received: from sjchrist-coffee.jf.intel.com (HELO linux.intel.com) ([10.54.74.202]) by fmsmga008.fm.intel.com with ESMTP; 23 Jan 2020 07:45:27 -0800 Date: Thu, 23 Jan 2020 07:45:27 -0800 From: Sean Christopherson To: Tao Xu , Jingqi Liu , Paolo Bonzini Cc: kvm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND] Atomic switch of MSR_IA32_UMWAIT_CONTROL Message-ID: <20200123154526.GC13178@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org cc'ing KVM and LKML this time... Why does KVM use the atomic load/store lists to load MSR_IA32_UMWAIT_CONTROL on VM-Enter/VM-Exit? Unless the host kernel is doing UWMAIT, which it really shouldn't and AFAICT doesn't, isn't it better to use the shared MSR mechanism to load the host value only when returning to userspace, and reload the guest value on demand?