Hi Michal,
Thank you for reviewing the patch.
> > + /* Zeroing the region will also zero the region enable */
> > + memset(&xen_mpumap[index], 0, sizeof(pr_t));
> Is it ok that for a fast case (i.e. 0-31) our representation of prbar/prlar will
> be different from the HW i.e. xen_mpumap[index] is 0 vs only .en bit of prlar
> being 0 in HW?
I think this should not matter - there is nothing reading registers directly and
all the decisions are taken looking into xen_mpumap.
However, if you would prefer, we could alter the logic here to only clear the .en
bit in xen_mpumap[index] in the fast case, so that things remain consistent? Alternatively we could always directly zero the entirety of the registers, but then we would remove the
use of the fast case entirely.
Many thanks,
Hari