Hi Julien,

On 09/12/2016 11:17 AM, Julien Grall wrote:
> Hello Sergej,
>
> On 16/08/2016 23:17, Sergej Proskurin wrote:
>> This commit makes sure that the page reference count is updated through
>> the function "p2m_put_l3_page" only the entries have been freed from the
>> hosts's p2m.
>>
>> Signed-off-by: Sergej Proskurin <prosku...@sec.in.tum.de>
>> ---
>> Cc: Stefano Stabellini <sstabell...@kernel.org>
>> Cc: Julien Grall <julien.gr...@arm.com>
>> ---
>>  xen/arch/arm/p2m.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/xen/arch/arm/p2m.c b/xen/arch/arm/p2m.c
>> index cef05ed..df2b85b 100644
>> --- a/xen/arch/arm/p2m.c
>> +++ b/xen/arch/arm/p2m.c
>> @@ -754,7 +754,7 @@ static void p2m_free_entry(struct p2m_domain *p2m,
>>      if ( !p2m_valid(entry) || p2m_is_superpage(entry, level) )
>>          return;
>>
>> -    if ( level == 3 )
>> +    if ( level == 3 && p2m_is_hostp2m(p2m) )
>
> This check should be pushed in p2m_put_l3_page as we want to have
> removing reference for all the callers of p2m_put_l3_page.
>

Make sense. Thank you.

>>      {
>>          p2m_put_l3_page(_mfn(entry.p2m.base), entry.p2m.type);
>>          return;
>>

Cheers,
~Sergej

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

Reply via email to