On 06.03.2020 13:50, Durrant, Paul wrote:
>> -----Original Message-----
>> From: Jan Beulich <[email protected]>
>> Sent: 06 March 2020 12:47
>> To: Durrant, Paul <[email protected]>
>> Cc: [email protected]; [email protected]; Andrew Cooper 
>> <[email protected]>;
>> George Dunlap <[email protected]>; Wei Liu <[email protected]>; Roger Pau 
>> MonnĂ© <[email protected]>
>> Subject: Re: [PATCH v3 2/6] x86 / p2m: remove page_list check in 
>> p2m_alloc_table
>>
>> On 06.03.2020 13:07, Durrant, Paul wrote:
>>>> -----Original Message-----
>>>> From: Jan Beulich <[email protected]>
>>>> Sent: 06 March 2020 11:46
>>>> To: [email protected]
>>>> Cc: [email protected]; Durrant, Paul <[email protected]>; 
>>>> Andrew Cooper
>>>> <[email protected]>; George Dunlap <[email protected]>; Wei 
>>>> Liu <[email protected]>; Roger
>> Pau
>>>> MonnĂ© <[email protected]>
>>>> Subject: Re: [PATCH v3 2/6] x86 / p2m: remove page_list check in 
>>>> p2m_alloc_table
>>>>
>>>> On 05.03.2020 13:45, [email protected] wrote:
>>>>> From: Paul Durrant <[email protected]>
>>>>>
>>>>> There does not seem to be any justification for refusing to create the
>>>>> domain's p2m table simply because it may have assigned pages.
>>>>
>>>> I think there is: If any such allocation had happened before, how
>>>> would it be represented in the domain's p2m?
>>>
>>> Insertion into the p2m is a separate action from page allocation. Why 
>>> should they be linked?
>>
>> They are, because of how XENMEM_populate_physmap works. Yes,
>> they _could_ be separate steps, but that's only a theoretical
>> consideration.
> 
> Then surely the check should be in the XENMEM_populate_physmap code?

How that? populate-physmap can be called any number of times. We
can't refuse a 2nd call there just because a 1st one had happened
already. Or did you mean the inverse check (i.e. that there
already is a p2m)? This surely wouldn't be a bad idea, as
otherwise both ept_get_entry() and p2m_pt_get_entry() would
blindly map MFN 0. But adding such a check wouldn't eliminate
the reason to also have the check that you're proposing to drop.

Jan

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to