Re: [PATCH] x86/shadow: replace stale literal numbers in hash_{vcpu,domain}_foreach()

2021-01-27 Thread Jan Beulich
On 25.01.2021 12:07, Jan Beulich wrote: > --- a/xen/arch/x86/mm/shadow/common.c > +++ b/xen/arch/x86/mm/shadow/common.c > @@ -1623,6 +1623,9 @@ void shadow_hash_delete(struct domain *d > typedef int (*hash_vcpu_callback_t)(struct vcpu *v, mfn_t smfn, mfn_t > other_mfn); > typedef int (*hash_doma

Re: [PATCH] x86/shadow: replace stale literal numbers in hash_{vcpu,domain}_foreach()

2021-01-25 Thread Tim Deegan
At 12:07 +0100 on 25 Jan (1611576438), Jan Beulich wrote: > 15 apparently once used to be the last valid type to request a callback > for, and the dimension of the respective array. The arrays meanwhile are > larger than this (in a benign way, i.e. no caller ever sets a mask bit > higher than 15),

[PATCH] x86/shadow: replace stale literal numbers in hash_{vcpu,domain}_foreach()

2021-01-25 Thread Jan Beulich
15 apparently once used to be the last valid type to request a callback for, and the dimension of the respective array. The arrays meanwhile are larger than this (in a benign way, i.e. no caller ever sets a mask bit higher than 15), dimensioned by SH_type_unused. Have the ASSERT()s follow suit and