Re: [PATCH v17 08/15] arm64: kexec: configure EL2 vectors for kexec

2021-09-30 Thread Pasha Tatashin
On Thu, Sep 30, 2021 at 4:16 AM Will Deacon wrote: > > On Wed, Sep 29, 2021 at 11:54:55PM -0400, Pasha Tatashin wrote: > > > > +/* Allocates pages for kexec page table */ > > > > +static void *kexec_page_alloc(void *arg) > > > > +{ > > > > + struct kimage *kimage = (struct kimage *)arg; > > >

Re: [PATCH v17 08/15] arm64: kexec: configure EL2 vectors for kexec

2021-09-30 Thread Will Deacon
On Wed, Sep 29, 2021 at 11:54:55PM -0400, Pasha Tatashin wrote: > > > +/* Allocates pages for kexec page table */ > > > +static void *kexec_page_alloc(void *arg) > > > +{ > > > + struct kimage *kimage = (struct kimage *)arg; > > > + struct page *page = kimage_alloc_control_pages(kimage,

Re: [PATCH v17 08/15] arm64: kexec: configure EL2 vectors for kexec

2021-09-29 Thread Pasha Tatashin
> > +/* Allocates pages for kexec page table */ > > +static void *kexec_page_alloc(void *arg) > > +{ > > + struct kimage *kimage = (struct kimage *)arg; > > + struct page *page = kimage_alloc_control_pages(kimage, 0); > > + > > + if (!page) > > + return NULL; > > + > > +

Re: [PATCH v17 08/15] arm64: kexec: configure EL2 vectors for kexec

2021-09-29 Thread Will Deacon
On Thu, Sep 16, 2021 at 07:13:18PM -0400, Pasha Tatashin wrote: > If we have a EL2 mode without VHE, the EL2 vectors are needed in order > to switch to EL2 and jump to new world with hypervisor privileges. > > In preparation to MMU enabled relocation, configure our EL2 table now. > > Kexec uses

[PATCH v17 08/15] arm64: kexec: configure EL2 vectors for kexec

2021-09-16 Thread Pasha Tatashin
If we have a EL2 mode without VHE, the EL2 vectors are needed in order to switch to EL2 and jump to new world with hypervisor privileges. In preparation to MMU enabled relocation, configure our EL2 table now. Kexec uses #HVC_SOFT_RESTART to branch to the new world, so extend el1_sync vector that