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

Re: [Xen-devel] [PATCH v2 3/3] x86/setup: remap Xen image up to PFN_DOWN(__pa(_end))



On Tue, Dec 12, 2017 at 02:42:50AM -0700, Jan Beulich wrote:
> >>> On 11.12.17 at 16:12, <daniel.kiper@xxxxxxxxxx> wrote:
> > On Thu, Dec 07, 2017 at 05:02:02AM -0700, Jan Beulich wrote:
> >> >>> On 04.12.17 at 11:24, <daniel.kiper@xxxxxxxxxx> wrote:
> >> > Current limit, PFN_DOWN(xen_phys_start), introduced by commit b280442
> >> > (x86: make Xen early boot code relocatable) is not reliable. Potentially
> >> > its value may fall below PFN_DOWN(__pa(_end))
> >>
> >> Under what (perhaps just theoretical) conditions? It seems to imply
> >> to me that we'd be moved Xen downwards if this was to happen, in
> >> which case I'd suggest to simply skip the relocation instead (we
> >> really only ever want to move Xen upwards).
> >
> > Not always. If __pa(__image_base__) > xen_phys_start and even
>
> I'm being increasingly confused: Isn't xen_phys_start identical to
> __pa(__image_base__)?

Right, it is confusing and condition is incorrect. I should say:
  NEW_xen_phys_start > __pa_BEFORE_xen_phys_start_CHANGE(__image_base__)...

> > if xen_phys_start < __pa(_end) then we are still moving upwards.
>
> And xen_phys_start always below __pa(_end)?

...and NEW_xen_phys_start < __pa_BEFORE_xen_phys_start_CHANGE(_end).

> > That is why we should change the condition. And we have to reference
> > to something constant not to the moving one.
>
> I also don't understand what would be "the moving one" here:
> xen_phys_start is being updated just once, before any of the

I am referring to this change. And it means that everything between 
NEW_xen_phys_start
and __pa_BEFORE_xen_phys_start_CHANGE(_end) may not be mapped because ramping
condition/limit refers to xen_phys_start which may fall below
__pa_BEFORE_xen_phys_start_CHANGE(_end) (right now in theory due to lack
of relocation if boot loader did it for us).

Daniel

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

 


Rackspace

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