* update_va_mapping_otherdomain
@ 2007-09-08 1:29 Michael R. Hines
2007-09-08 9:00 ` update_va_mapping_otherdomain Keir Fraser
0 siblings, 1 reply; 6+ messages in thread
From: Michael R. Hines @ 2007-09-08 1:29 UTC (permalink / raw)
To: xen-devel
[-- Attachment #1.1: Type: text/plain, Size: 1045 bytes --]
Greetings,
I have a technical question about update_va_mapping_otherdomain.......
I have two components: a C program linked against libxc
and a kernel module which performs the following simple
sequence of events from domain zero:
1. Pause guest (unprivileged)
2. Grabs the PTE associated with a random (but present) page
within the guest's kernel's address space
(using a modified xc_translate_foreign_address)
3. Flips the present bit to zero
4. Calls HYPERVISOR_update_va_mapping otherdomain (from the kernel module)
5. Re-performs xc_translate_foreign_address on the same PTE
6. Verifies the the present bit was indeed changed to zero
Upon successful return from update_va_mapping (i.e. return code == zero),
my problem involves the last step mentioned above. The present bit still
remains unchanged (is still one), although update_va_mapping return true.
What might cause such a strange problem to occur?
--
/*
Michael R. Hines
http://www.cs.binghamton.edu/~mhines/
Live long and prosper...
*/
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: update_va_mapping_otherdomain
2007-09-08 1:29 update_va_mapping_otherdomain Michael R. Hines
@ 2007-09-08 9:00 ` Keir Fraser
2007-09-08 15:17 ` update_va_mapping_otherdomain Michael R. Hines
0 siblings, 1 reply; 6+ messages in thread
From: Keir Fraser @ 2007-09-08 9:00 UTC (permalink / raw)
To: mhines, xen-devel
On 8/9/07 02:29, "Michael R. Hines" <mhines@cs.binghamton.edu> wrote:
> Upon successful return from update_va_mapping (i.e. return code == zero),
> my problem involves the last step mentioned above. The present bit still
> remains unchanged (is still one), although update_va_mapping return true.
>
> What might cause such a strange problem to occur?
That hypercall allows you to update a *local* va mapping to map *another*
domain's memory page. So you've mapped the guest's page somewhere random in
your own address space.
-- Keir
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: update_va_mapping_otherdomain
2007-09-08 9:00 ` update_va_mapping_otherdomain Keir Fraser
@ 2007-09-08 15:17 ` Michael R. Hines
2007-09-08 18:27 ` update_va_mapping_otherdomain Michael R. Hines
0 siblings, 1 reply; 6+ messages in thread
From: Michael R. Hines @ 2007-09-08 15:17 UTC (permalink / raw)
To: Keir Fraser; +Cc: xen-devel
[-- Attachment #1.1: Type: text/plain, Size: 953 bytes --]
ooooh, ok. I understand now.
Thank you very much for your response. =)
- Michael
Keir Fraser wrote:
> On 8/9/07 02:29, "Michael R. Hines" <mhines@cs.binghamton.edu> wrote:
>
>> Upon successful return from update_va_mapping (i.e. return code == zero),
>> my problem involves the last step mentioned above. The present bit still
>> remains unchanged (is still one), although update_va_mapping return true.
>>
>> What might cause such a strange problem to occur?
>
> That hypercall allows you to update a *local* va mapping to map *another*
> domain's memory page. So you've mapped the guest's page somewhere random in
> your own address space.
>
> -- Keir
>
>
>
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel
>
--
/*
Michael R. Hines
http://www.cs.binghamton.edu/~mhines/
Live long and prosper...
*/
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: update_va_mapping_otherdomain
2007-09-08 15:17 ` update_va_mapping_otherdomain Michael R. Hines
@ 2007-09-08 18:27 ` Michael R. Hines
2007-09-09 8:17 ` update_va_mapping_otherdomain Keir Fraser
0 siblings, 1 reply; 6+ messages in thread
From: Michael R. Hines @ 2007-09-08 18:27 UTC (permalink / raw)
To: mhines; +Cc: xen-devel
[-- Attachment #1.1: Type: text/plain, Size: 1535 bytes --]
So, if I would like to use dom0 to modify a specific L1 PTE belonging
to another unprivileged domain, what's the best way to go about it?
Grant references? (on L1 page tables?)
Might I be able to get a quick pointer on the right sequence of hypercalls?
Much appreciated,
- Michael
Michael R. Hines wrote:
> ooooh, ok. I understand now.
>
> Thank you very much for your response. =)
>
> - Michael
>
> Keir Fraser wrote:
>> On 8/9/07 02:29, "Michael R. Hines" <mhines@cs.binghamton.edu> wrote:
>>
>>> Upon successful return from update_va_mapping (i.e. return code == zero),
>>> my problem involves the last step mentioned above. The present bit still
>>> remains unchanged (is still one), although update_va_mapping return true.
>>>
>>> What might cause such a strange problem to occur?
>> That hypercall allows you to update a *local* va mapping to map *another*
>> domain's memory page. So you've mapped the guest's page somewhere random in
>> your own address space.
>>
>> -- Keir
>>
>>
>>
>>
>> _______________________________________________
>> Xen-devel mailing list
>> Xen-devel@lists.xensource.com
>> http://lists.xensource.com/xen-devel
>>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel
--
/*
Michael R. Hines
http://www.cs.binghamton.edu/~mhines/
Live long and prosper...
*/
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: update_va_mapping_otherdomain
2007-09-08 18:27 ` update_va_mapping_otherdomain Michael R. Hines
@ 2007-09-09 8:17 ` Keir Fraser
2007-09-09 18:24 ` update_va_mapping_otherdomain Michael R. Hines
0 siblings, 1 reply; 6+ messages in thread
From: Keir Fraser @ 2007-09-09 8:17 UTC (permalink / raw)
To: mhines; +Cc: xen-devel
There is currently no way to modify active page tables of another domain.
-- Keir
On 8/9/07 19:27, "Michael R. Hines" <mhines@cs.binghamton.edu> wrote:
>
> So, if I would like to use dom0 to modify a specific L1 PTE belonging
> to another unprivileged domain, what's the best way to go about it?
>
> Grant references? (on L1 page tables?)
>
> Might I be able to get a quick pointer on the right sequence of hypercalls?
>
> Much appreciated,
> - Michael
>
> Michael R. Hines wrote:
>> ooooh, ok. I understand now.
>>
>> Thank you very much for your response. =)
>>
>> - Michael
>>
>> Keir Fraser wrote:
>>> On 8/9/07 02:29, "Michael R. Hines" <mhines@cs.binghamton.edu> wrote:
>>>
>>>> Upon successful return from update_va_mapping (i.e. return code == zero),
>>>> my problem involves the last step mentioned above. The present bit still
>>>> remains unchanged (is still one), although update_va_mapping return true.
>>>>
>>>> What might cause such a strange problem to occur?
>>> That hypercall allows you to update a *local* va mapping to map *another*
>>> domain's memory page. So you've mapped the guest's page somewhere random in
>>> your own address space.
>>>
>>> -- Keir
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> Xen-devel mailing list
>>> Xen-devel@lists.xensource.com
>>> http://lists.xensource.com/xen-devel
>>>
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Xen-devel mailing list
>> Xen-devel@lists.xensource.com
>> http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: update_va_mapping_otherdomain
2007-09-09 8:17 ` update_va_mapping_otherdomain Keir Fraser
@ 2007-09-09 18:24 ` Michael R. Hines
0 siblings, 0 replies; 6+ messages in thread
From: Michael R. Hines @ 2007-09-09 18:24 UTC (permalink / raw)
To: Keir Fraser; +Cc: xen-devel
[-- Attachment #1.1: Type: text/plain, Size: 1862 bytes --]
Thank you.
- Michael
Keir Fraser wrote:
> There is currently no way to modify active page tables of another domain.
>
> -- Keir
>
>
> On 8/9/07 19:27, "Michael R. Hines" <mhines@cs.binghamton.edu> wrote:
>
>> So, if I would like to use dom0 to modify a specific L1 PTE belonging
>> to another unprivileged domain, what's the best way to go about it?
>>
>> Grant references? (on L1 page tables?)
>>
>> Might I be able to get a quick pointer on the right sequence of hypercalls?
>>
>> Much appreciated,
>> - Michael
>>
>> Michael R. Hines wrote:
>>> ooooh, ok. I understand now.
>>>
>>> Thank you very much for your response. =)
>>>
>>> - Michael
>>>
>>> Keir Fraser wrote:
>>>> On 8/9/07 02:29, "Michael R. Hines" <mhines@cs.binghamton.edu> wrote:
>>>>
>>>>> Upon successful return from update_va_mapping (i.e. return code == zero),
>>>>> my problem involves the last step mentioned above. The present bit still
>>>>> remains unchanged (is still one), although update_va_mapping return true.
>>>>>
>>>>> What might cause such a strange problem to occur?
>>>> That hypercall allows you to update a *local* va mapping to map *another*
>>>> domain's memory page. So you've mapped the guest's page somewhere random in
>>>> your own address space.
>>>>
>>>> -- Keir
>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> Xen-devel mailing list
>>>> Xen-devel@lists.xensource.com
>>>> http://lists.xensource.com/xen-devel
>>>>
>>>
>>> ------------------------------------------------------------------------
>>>
>>> _______________________________________________
>>> Xen-devel mailing list
>>> Xen-devel@lists.xensource.com
>>> http://lists.xensource.com/xen-devel
>
>
>
--
/*
Michael R. Hines
http://www.cs.binghamton.edu/~mhines/
Live long and prosper...
*/
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2007-09-09 18:24 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-09-08 1:29 update_va_mapping_otherdomain Michael R. Hines
2007-09-08 9:00 ` update_va_mapping_otherdomain Keir Fraser
2007-09-08 15:17 ` update_va_mapping_otherdomain Michael R. Hines
2007-09-08 18:27 ` update_va_mapping_otherdomain Michael R. Hines
2007-09-09 8:17 ` update_va_mapping_otherdomain Keir Fraser
2007-09-09 18:24 ` update_va_mapping_otherdomain Michael R. Hines
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.