From: George Dunlap <george.dunlap@citrix.com>
To: "Roger Pau Monné" <roger.pau@citrix.com>
Cc: Lars Kurth <lars.kurth@citrix.com>,
Stefano Stabellini <sstabellini@kernel.org>,
Wei Liu <wei.liu2@citrix.com>,
Andrew Cooper <andrew.cooper3@citrix.com>,
Ian Jackson <ian.jackson@citrix.com>, Tim Deegan <tim@xen.org>,
Julien Grall <julien.grall@arm.com>,
Jan Beulich <jbeulich@suse.com>,
Tamas K Lengyel <tamas.lengyel@zentific.com>,
xen-devel@lists.xenproject.org
Subject: Re: [PATCH] hvm/altp2m: Clarify the proper way to extend the altp2m interface
Date: Tue, 10 Jul 2018 11:09:36 +0100 [thread overview]
Message-ID: <d5481c8c-2ac7-b6d5-f5be-4967fd02c5cc@citrix.com> (raw)
In-Reply-To: <20180710094309.ny46hu6g4cl63cpv@mac.bytemobile.com>
On 07/10/2018 10:43 AM, Roger Pau Monné wrote:
> On Tue, Jul 10, 2018 at 10:33:22AM +0100, George Dunlap wrote:
>> The altp2m functionality was originally envisioned to be used in
>> several different configurations, one of which was a single in-guest
>> agent that had full operational control of altp2m. This required the
>> single hypercall to be an HVMOP, which is the only type of hypercall
>> an HVM guest is allowed to make.
>
> That's not true. HVM guests can use a bunch of hypercalls, like
> GNTTABOP, XENMEM, PHYSDEVOP...
But it can't maken DOMCTLs, which would be the other natural fit. I'll
see if I can capture that accurately.
>
>> diff --git a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c
>> index e022f5ab0e..90a4be5e86 100644
>> --- a/xen/arch/x86/hvm/hvm.c
>> +++ b/xen/arch/x86/hvm/hvm.c
>> @@ -4460,6 +4460,34 @@ static int hvmop_get_param(
>> return rc;
>> }
>>
>> +/*
>> + * altp2m operations are envisioned as being used in several different
>> + * modes:
>> + *
>> + * - external: All control and decisions are made by an external agent
>> + * running domain 0.
>> + *
>> + * - internal: altp2m operations are used exclusively by an in-guest agent
>> + * to protect itself from the guest kernel and in-guest attackers.
>> + *
>> + * - coordinated: An in-guest agent handles #VE and VMFUNCs locally,
>> + * but makes requests of an external entity for bigger changes (such
>> + * as modifying altp2m entires).
>> + *
>> + * This corresponds to the three values for HVM_PARAM_ALTP2M
>> + * (external, mixed, limited). All three models have advantages and
>> + * disadvantages.
>
> Shouldn't you use the existing HVM_PARAM_ALTP2M values in the
> enumeration above instead of introducing a new nomenclature?
I did think about that. The problem is that 'mixed' is basically the
wrong label. Or rather, it covers two different use cases: A more fully
empowered guest agent coordinating with an external agent, and a solo
guest agent doing everything itself.
Replacing 'coordinated' with 'limited' might make sense though.
-George
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
next prev parent reply other threads:[~2018-07-10 10:09 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-10 9:33 [PATCH] hvm/altp2m: Clarify the proper way to extend the altp2m interface George Dunlap
2018-07-10 9:43 ` Roger Pau Monné
2018-07-10 10:09 ` George Dunlap [this message]
2018-07-10 9:54 ` Wei Liu
2018-07-10 10:26 ` Ian Jackson
2018-07-10 10:31 ` Wei Liu
2018-07-10 10:01 ` Jan Beulich
2018-07-10 10:30 ` George Dunlap
2018-07-10 10:32 ` Ian Jackson
2018-07-10 10:56 ` George Dunlap
2018-07-10 10:59 ` Ian Jackson
2018-07-10 11:07 ` George Dunlap
2018-07-10 11:58 ` Jan Beulich
2018-07-10 13:10 ` George Dunlap
2018-07-10 10:46 ` George Dunlap
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=d5481c8c-2ac7-b6d5-f5be-4967fd02c5cc@citrix.com \
--to=george.dunlap@citrix.com \
--cc=andrew.cooper3@citrix.com \
--cc=ian.jackson@citrix.com \
--cc=jbeulich@suse.com \
--cc=julien.grall@arm.com \
--cc=lars.kurth@citrix.com \
--cc=roger.pau@citrix.com \
--cc=sstabellini@kernel.org \
--cc=tamas.lengyel@zentific.com \
--cc=tim@xen.org \
--cc=wei.liu2@citrix.com \
--cc=xen-devel@lists.xenproject.org \
/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).