linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Chang S. Bae" <chang.seok.bae@intel.com>
To: Dave Hansen <dave.hansen@intel.com>, <len.brown@intel.com>,
	<tony.luck@intel.com>, <rafael.j.wysocki@intel.com>,
	<reinette.chatre@intel.com>, <dan.j.williams@intel.com>
Cc: <corbet@lwn.net>, <pbonzini@redhat.com>, <kvm@vger.kernel.org>,
	<linux-doc@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 2/2] Documentation/x86: Explain guest XSTATE permission control
Date: Tue, 23 Aug 2022 16:34:26 -0700	[thread overview]
Message-ID: <86cbe556-3084-95ef-381f-1490da7590cd@intel.com> (raw)
In-Reply-To: <ec95b28f-51a1-a9cf-7d72-a3a865797c7d@intel.com>

On 6/23/2022 4:55 PM, Chang S. Bae wrote:
> On 6/16/2022 3:49 PM, Dave Hansen wrote:
>>
>> This touches on the "what", but not the "why".  Could you explain in
>> here both why this is needed and why an app might want to use it?
> 
> [ while studying on this a bit further, found a few things here ]
> 
> They (ARCH_{REQ|GET}_XCOMP_GUEST_PERM) provide a userspace VMM to 
> request & check guest permission.
> 
> In general, KVM looks to have an API as a set of ioctls [1]. A guest VMM 
> uses KVM_GET_DEVICE_ATTR::KVM_X86_XCOMP_GUEST_SUPP to query the 
> available features [2][3]. ARCH_GET_XCOMP_SUPP is not usable here 
> because KVM wants to control those exposed features [4] (via 
> KVM_SUPPORTED_XCR0).
> 
> But oddly this mask does not appear to be actively referenced by those 
> two arch_prctl options. I can see this ioctl attribute is currently 
> disconnected from these arch_prctl options.
> 
> Also I failed to find the documentation about this 
> KVM_X86_XCOMP_GUEST_SUPP interface:
> 
>      $ git grep KVM_X86_XCOMP_GUEST_SUPP ./Documentation/
>      $
> 
> I guess people will be confused with having these two options only. I 
> think documenting this has to come along with these missing pieces (and 
> potential fix). So I'm inclined to drop this one at the moment.

Posted this series as following up this:

https://lore.kernel.org/lkml/20220823231402.7839-1-chang.seok.bae@intel.com/

Thanks,
Chang

      reply	other threads:[~2022-08-23 23:34 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-16 21:22 [PATCH 0/2] Documentation/x86: Update the dynamic XSTATE doc Chang S. Bae
2022-06-16 21:22 ` [PATCH 1/2] Documentation/x86: Add the AMX enabling example Chang S. Bae
2022-06-16 22:45   ` Dave Hansen
2022-06-17 21:35     ` Chang S. Bae
2022-08-24  4:33   ` Bagas Sanjaya
2022-06-16 21:22 ` [PATCH 2/2] Documentation/x86: Explain guest XSTATE permission control Chang S. Bae
2022-06-16 22:49   ` Dave Hansen
2022-06-23 23:55     ` Chang S. Bae
2022-08-23 23:34       ` Chang S. Bae [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86cbe556-3084-95ef-381f-1490da7590cd@intel.com \
    --to=chang.seok.bae@intel.com \
    --cc=corbet@lwn.net \
    --cc=dan.j.williams@intel.com \
    --cc=dave.hansen@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=len.brown@intel.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pbonzini@redhat.com \
    --cc=rafael.j.wysocki@intel.com \
    --cc=reinette.chatre@intel.com \
    --cc=tony.luck@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).