[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH RFC 1/2] xen/pvh: take the p2m lock when doing logdirty ops from HVM domains



El 15/10/14 a les 13.55, Andrew Cooper ha escrit:
> On 15/10/14 12:52, Roger Pau Monnà wrote:
>> El 15/10/14 a les 13.31, Andrew Cooper ha escrit:
>>> On 15/10/14 11:53, Roger Pau Monne wrote:
>>>> ---
>>>>  xen/arch/x86/mm/paging.c | 8 ++++++++
>>>>  1 file changed, 8 insertions(+)
>>>>
>>>> diff --git a/xen/arch/x86/mm/paging.c b/xen/arch/x86/mm/paging.c
>>>> index 6b788f7..5af6309 100644
>>>> --- a/xen/arch/x86/mm/paging.c
>>>> +++ b/xen/arch/x86/mm/paging.c
>>>> @@ -412,6 +412,8 @@ static int paging_log_dirty_op(struct domain *d,
>>>>  
>>>>      if ( !resuming )
>>>>          domain_pause(d);
>>>> +     if (has_hvm_container_vcpu(current))
>>>> +         p2m_lock(p2m_get_hostp2m(current->domain));
>>> It appears as if there is some indentation issue here.
>> Yes, an extra space.
>>
>>> Also, can you pull current into a struct vcpu *curr on the stack?
>> We only use ->domain from current, would you prefer me to pull
>> current->domain instead?
>>
>> Roger.
> 
> You use current, and current->domain.

The only direct usage of current is for has_hvm_container_vcpu, which
can be replaced with has_hvm_container_domain.

Roger.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.