On 12/09/2019 08:52, Jan Beulich wrote:
> On 11.09.2019 22:04, Andrew Cooper wrote:
>> update_domain_cpuid_info() currently serves two purposes.  First to merge new
>> CPUID data from the toolstack, and second, to perform any necessary updating
>> of derived domain/vcpu settings.
>>
>> The first part of this is going to be superseded by a new and substantially
>> more efficient hypercall.
>>
>> Carve the second part out into a new domain_cpu_policy_changed() helper, and
>> call this from the remains of update_domain_cpuid_info().
>>
>> This does drop the call_policy_changed, but with the new hypercall hypercall
> duplicate "hypercall"
>
>> in place, the common case will be a single call per domain.  Dropping the
>> optimisation here allows for a cleaner set of following changes.
>>
>> Signed-off-by: Andrew Cooper <andrew.coop...@citrix.com>
> Reviewed-by: Jan Beulich <jbeul...@suse.com>

Thanks.

> with one purely cosmetic remark:
>
>> @@ -317,27 +193,104 @@ static int update_domain_cpuid_info(struct domain *d,
>>  
>>              d->arch.pv.cpuidmasks->e1cd = mask;
>>          }
>> +    }
>> +
>> +    for_each_vcpu( d, v )
> Valid spelling is "for_each_vcpu ( d, v )" (as it was in the original
> code)

The original code had two such loops:

            for_each_vcpu ( d, v )
                vpmu_destroy(v);

and

        for_each_vcpu( d, v )
            cpuid_policy_updated(v);

Guess which one I didn't delete while refactoring (and obviously wasn't
paying enough attention to).

I'll fix the style.

~Andrew

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

Reply via email to