Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp5713232ybi; Tue, 28 May 2019 18:27:54 -0700 (PDT) X-Google-Smtp-Source: APXvYqzrqYMR7j/1A8V1nmNQydKusUBRnli0xoa8XYcZ7oTXvjkE2qAaQlq6fcUxAdT5glPyPksp X-Received: by 2002:a17:902:2c43:: with SMTP id m61mr29845011plb.315.1559093274068; Tue, 28 May 2019 18:27:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559093274; cv=none; d=google.com; s=arc-20160816; b=Dq7WVPnuMCGJlSQ53BhZU3oszLo6Ja83h7ZXYr/5JDS0TVgVW65yogN7NjZzbo485x L7o2a2AO8m2RJi1RIAfWr4Kn3j0gUc+Er30DbLuYfpi8eAk4SM1o8bRvVeyUchr1YLCv bvhdCCq0Y7NIwHRSzI1PwEF4bYc0QU0Gjl7wUbdk8qIDLENCJeF5d2ONW14332Y51v2y x2hfod0N57efYufWloTZc/LCj67eO5clj3nL3VPLAsb6FhKUze1wiqr95ciL8LXVOang r7jGT0m3PdYkGknJ/pGzES8r53z9cpOrchIIr72xG2glFTS3rygNdgnF9noI4tjkPu9C UXdg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=rqj4DN+mKFOFN2ElIEBtWrUBDtgBpL5CxV4R4XTM10o=; b=umb7QWpOnAl+miUcDnOSWFBG24K5+nlej5UFOdbnTPFWr88cjkP4ytkaBpfQ0aDG+1 li34HCu2AY8vngERls8baNtHw+HaBSIckLW3I2tIKanzkRrY7xXkumWv5qIxPKerMriE vTQyzaWxcYazFHM0N7wtld52wPPfDJ8DQmRWHa4u1JNyJiVgC5wvx+MlDfQdbcram6qf bXKkXROjmV+yzDBToS/8ZyiZMeVA0gMKKGuPis5clFVbQ8dy75+0hFvnMSpvKFtBzevY 1+G7qcD1m/z9UMf/vnjEAM2/wOGC9ywrhe2kJ8s8fl7ir4Povg8IIgWrSheHnmkc6fSx UuYQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id cp14si25778651plb.183.2019.05.28.18.27.38; Tue, 28 May 2019 18:27:54 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725856AbfE2BZn (ORCPT + 99 others); Tue, 28 May 2019 21:25:43 -0400 Received: from mail-wr1-f67.google.com ([209.85.221.67]:36163 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725832AbfE2BZm (ORCPT ); Tue, 28 May 2019 21:25:42 -0400 Received: by mail-wr1-f67.google.com with SMTP id s17so464724wru.3 for ; Tue, 28 May 2019 18:25:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=rqj4DN+mKFOFN2ElIEBtWrUBDtgBpL5CxV4R4XTM10o=; b=RVx8hscCWqB6dFtYupixvrhbnbdxExxVQKAjrRfZQAw1TdPI7q/PkhLp0wd1ygxCot o/x4xNuwm1O8gx18DNvjxn9ZUDJ0Xk8sHtkRd1UPGSS4Z+ai7wR/gBHhpYArLC82Q96X XFgb4/iDoMiQXAQ9f9rbNmWYKcivHRwxJlWxjM/VI8YkeZMnP3irLJTI78RVDTDvy7lj xPITznJEYclHXsfmrzu8ppSs+VCbKeXKAiANbzIivdyHBrEe5myE4iEIe9mOSJNDPPtn EC19hL84R2w7UlqaQ9XyuYyh4NHSMqEJy87aE/hQCoTgkRWC2GfBJ9F0iU5UibI3m3pk Cftg== X-Gm-Message-State: APjAAAWSpxcT5qMCRBa9LBRW5jc070oJeGT5MNukUOl4LAOPII2jwMuw 2PjBnp9sjh4dl4CXRYF7R2MdAA== X-Received: by 2002:a5d:5189:: with SMTP id k9mr14487648wrv.329.1559093141154; Tue, 28 May 2019 18:25:41 -0700 (PDT) Received: from [192.168.10.150] ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id s15sm10845265wrn.68.2019.05.28.18.25.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 28 May 2019 18:25:40 -0700 (PDT) Subject: Re: [PATCH v2 1/3] KVM: x86: add support for user wait instructions To: Peter Zijlstra , Tao Xu Cc: rkrcmar@redhat.com, corbet@lwn.net, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, hpa@zytor.com, sean.j.christopherson@intel.com, x86@kernel.org, kvm@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, jingqi.liu@intel.com References: <20190524075637.29496-1-tao3.xu@intel.com> <20190524075637.29496-2-tao3.xu@intel.com> <20190527103003.GX2623@hirez.programming.kicks-ass.net> From: Paolo Bonzini Message-ID: Date: Wed, 29 May 2019 03:25:39 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <20190527103003.GX2623@hirez.programming.kicks-ass.net> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 27/05/19 12:30, Peter Zijlstra wrote: >> This patch adds support for UMONITOR, UMWAIT and TPAUSE instructions >> in kvm, and by default dont't expose it to kvm and provide a capability >> to enable it. > > I'm thinking this should be conditional on the guest being a 1:1 guest, > and I also seem to remember we have bits for that already -- they were > used to disable paravirt spinlocks for example. This should be userspace's choice. It would indeed be silly to enable this while overcommitted, but KVM doesn't really care. Paolo