[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH for-4.19? v3 4/6] x86: Make the maximum number of altp2m views configurable



On Sat, May 18, 2024 at 3:18 AM Tamas K Lengyel <tamas@xxxxxxxxxxxxx> wrote:
>
> > -        ap2m = array_access_nospec(d->arch.altp2m_p2m, altp2m_idx);
> > +        ap2m = d->arch.altp2m_p2m[altp2m_idx];
>
> Why is it no longer necessary to use array_access_nospec?
>
> Tamas

I was under the impression that when the domain_create guarantees the
length of the array, and before each access to the altp2m_p2m there is
an explicit check if idx is within bounds of nr_altp2m, that the
array_access_nospec is not needed anymore. But apparently I
misunderstood how speculative execution works, when I now read about
it.

I'll put it back.

P.



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.