From: Julien Grall <julien.grall@arm.com>
To: Tamas K Lengyel <tamas.lengyel@zentific.com>,
Jan Beulich <JBeulich@suse.com>
Cc: "xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>,
Stefano Stabellini <sstabellini@kernel.org>
Subject: Re: [PATCH v8 4/6] arm/vm_event: get/set registers
Date: Wed, 6 Jul 2016 22:12:06 +0100 [thread overview]
Message-ID: <abfe2c77-87fb-0ca3-8efd-e924bcb8a74e@arm.com> (raw)
In-Reply-To: <CAErYnsh4ZXXZBFuyk49407j63Okh9BrxX_fWNet8bDeQrPbciw@mail.gmail.com>
On 06/07/2016 20:23, Tamas K Lengyel wrote:
> On Wed, Jul 6, 2016 at 1:43 AM, Jan Beulich <JBeulich@suse.com> wrote:
>>>>> On 05.07.16 at 20:37, <tamas.lengyel@zentific.com> wrote:
>>> +struct vm_event_regs_arm64 {
>>> + uint64_t x0;
>>> + uint64_t x1;
>>> + uint64_t x2;
>>> + uint64_t x3;
>>> + uint64_t x4;
>>> + uint64_t x5;
>>> + uint64_t x6;
>>> + uint64_t x7;
>>> + uint64_t x8;
>>> + uint64_t x9;
>>> + uint64_t x10;
>>> + uint64_t x11;
>>> + uint64_t x12;
>>> + uint64_t x13;
>>> + uint64_t x14;
>>> + uint64_t x15;
>>> + uint64_t x16;
>>> + uint64_t x17;
>>> + uint64_t x18;
>>> + uint64_t x19;
>>> + uint64_t x20;
>>> + uint64_t x21;
>>> + uint64_t x22;
>>> + uint64_t x23;
>>> + uint64_t x24;
>>> + uint64_t x25;
>>> + uint64_t x26;
>>> + uint64_t x27;
>>> + uint64_t x28;
>>> + uint64_t x29;
>>> + uint64_t x30;
>>> + uint64_t pc;
>>> +};
>>
>> Isn't the stack pointer a fully separate register in aarch64? Not
>> making available something as essential as that seems wrong to
>> me.
>>
>
> The register is available for access already, so unless there is an
> actual use-case that requires it to be transmitted through vm_event I
> don't see the point for transmitting it. So as I mentioned in my other
> response, I'm inclined to reduce this patch to the bare essentials my
> use-case requires at this point and leave the extensions up for the
> future when - and if - it will be of use. Since this patch is just an
> optimization, if transmitting such reduced set is not acceptable for
> some reason, I'll forgo this patch entirely.
Here we go with again the same argument: "this is not necessary for my
use-case". This data structure is part of the ABI between the hypervisor
and the vm-event app, i.e modifying this structure for adding ARM64/ARM
registers will result to an incompatibility with a previous version of
the hypervisor. Better to do it now than in a couple of years when
vm-event will have more users. I agree that it is time consuming to get
an ABI correct, but it will save users to recompile/ship another version
of their vm-event app because of this incompatibility.
As mentioned in a previous thread, the main use-case for trapping an SMC
is emulating the call, hence a vm-event app would want to have access to
the general-purpose registers. And yes, I know that your use-case is
different and does not require those registers, I already expressed my
concerns about it.
Now, if you drop this patch, how will you retrieve the vCPU register? I
guess via DOMCTL_getvcpucontext? If so, if the vCPU has not been paused,
you will get a context which is different compare to the time the
vm-event has occurred. And yes, I know that in your use-case the vCPU is
paused. This call will always be more expensive than passing the
registers with event.
Anyway, I really don't think we ask for something really difficult to
accomplish.
Regards,
--
Julien Grall
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2016-07-06 21:12 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-05 18:37 [PATCH v8 1/6] monitor: rename and relocate vm_event_monitor_traps Tamas K Lengyel
2016-07-05 18:37 ` [PATCH v8 2/6] arm: filter SMC exceptions with failed condition checks Tamas K Lengyel
2016-07-06 17:31 ` Julien Grall
2016-07-06 18:52 ` Tamas K Lengyel
2016-07-05 18:37 ` [PATCH v8 3/6] monitor: ARM SMC events Tamas K Lengyel
2016-07-05 18:37 ` [PATCH v8 4/6] arm/vm_event: get/set registers Tamas K Lengyel
2016-07-06 7:43 ` Jan Beulich
2016-07-06 7:59 ` Razvan Cojocaru
2016-07-06 17:39 ` Julien Grall
2016-07-06 19:23 ` Tamas K Lengyel
2016-07-06 21:12 ` Julien Grall [this message]
2016-07-06 22:01 ` Tamas K Lengyel
2016-07-06 18:04 ` Julien Grall
2016-07-06 19:12 ` Tamas K Lengyel
2016-07-07 8:23 ` Jan Beulich
2016-07-07 9:46 ` Julien Grall
2016-07-07 9:57 ` Jan Beulich
2016-07-07 10:09 ` Julien Grall
2016-07-07 15:53 ` Tamas K Lengyel
2016-07-05 18:37 ` [PATCH v8 5/6] tools/libxc: add xc_monitor_privileged_call Tamas K Lengyel
2016-07-05 18:37 ` [PATCH v8 6/6] tools/xen-access: add test-case for ARM SMC Tamas K Lengyel
2016-07-07 10:05 ` Julien Grall
2016-07-07 15:54 ` Tamas K Lengyel
2016-07-05 19:15 ` [PATCH v8 1/6] monitor: rename and relocate vm_event_monitor_traps Razvan Cojocaru
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=abfe2c77-87fb-0ca3-8efd-e924bcb8a74e@arm.com \
--to=julien.grall@arm.com \
--cc=JBeulich@suse.com \
--cc=sstabellini@kernel.org \
--cc=tamas.lengyel@zentific.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.