Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-17 Thread Ard Biesheuvel
On 16 January 2017 at 15:15, Bhupesh Sharma wrote: > Thanks Dave. > > On Fri, Jan 13, 2017 at 3:03 AM, Dave Young wrote: >> On 01/12/17 at 04:20pm, Ard Biesheuvel wrote: >>> On 12 January 2017 at 09:41, Dave Young wrote: >>> > Before invoking the arch specific handler, efi_mem_reserve() reserves

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-16 Thread Bhupesh Sharma
Thanks Dave. On Fri, Jan 13, 2017 at 3:03 AM, Dave Young wrote: > On 01/12/17 at 04:20pm, Ard Biesheuvel wrote: >> On 12 January 2017 at 09:41, Dave Young wrote: >> > Before invoking the arch specific handler, efi_mem_reserve() reserves >> > the given memory region through memblock. >> > >> > ef

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-15 Thread Dave Young
On 01/13/17 at 01:21pm, Nicolai Stange wrote: > On Fri, Jan 13 2017, Dave Young wrote: > > > On 01/13/17 at 10:21am, Dave Young wrote: > >> On 01/13/17 at 12:11am, Nicolai Stange wrote: > >> > On Fri, Jan 13 2017, Dave Young wrote: > >> > > >> > > On 01/12/17 at 12:54pm, Nicolai Stange wrote: > >

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-13 Thread Nicolai Stange
On Fri, Jan 13 2017, Dave Young wrote: > On 01/13/17 at 10:21am, Dave Young wrote: >> On 01/13/17 at 12:11am, Nicolai Stange wrote: >> > On Fri, Jan 13 2017, Dave Young wrote: >> > >> > > On 01/12/17 at 12:54pm, Nicolai Stange wrote: >> > >> On Thu, Jan 12 2017, Dave Young wrote: >> > >> >> > >>

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Dave Young
On 01/13/17 at 10:21am, Dave Young wrote: > On 01/13/17 at 12:11am, Nicolai Stange wrote: > > On Fri, Jan 13 2017, Dave Young wrote: > > > > > On 01/12/17 at 12:54pm, Nicolai Stange wrote: > > >> On Thu, Jan 12 2017, Dave Young wrote: > > >> > > >> > -void __init efi_bgrt_init(void) > > >> > +voi

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Dave Young
On 01/13/17 at 12:11am, Nicolai Stange wrote: > On Fri, Jan 13 2017, Dave Young wrote: > > > On 01/12/17 at 12:54pm, Nicolai Stange wrote: > >> On Thu, Jan 12 2017, Dave Young wrote: > >> > >> > -void __init efi_bgrt_init(void) > >> > +void __init efi_bgrt_init(struct acpi_table_header *table) >

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Nicolai Stange
On Fri, Jan 13 2017, Dave Young wrote: > On 01/12/17 at 12:54pm, Nicolai Stange wrote: >> On Thu, Jan 12 2017, Dave Young wrote: >> >> > -void __init efi_bgrt_init(void) >> > +void __init efi_bgrt_init(struct acpi_table_header *table) >> > { >> > - acpi_status status; >> >void *image; >> >

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Dave Young
On 01/12/17 at 12:54pm, Nicolai Stange wrote: > On Thu, Jan 12 2017, Dave Young wrote: > > > -void __init efi_bgrt_init(void) > > +void __init efi_bgrt_init(struct acpi_table_header *table) > > { > > - acpi_status status; > > void *image; > > struct bmp_header bmp_header; > > > >

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Dave Young
On 01/12/17 at 04:20pm, Ard Biesheuvel wrote: > On 12 January 2017 at 09:41, Dave Young wrote: > > Before invoking the arch specific handler, efi_mem_reserve() reserves > > the given memory region through memblock. > > > > efi_bgrt_init will call efi_mem_reserve after mm_init(), at that time > > m

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Ard Biesheuvel
On 12 January 2017 at 09:41, Dave Young wrote: > Before invoking the arch specific handler, efi_mem_reserve() reserves > the given memory region through memblock. > > efi_bgrt_init will call efi_mem_reserve after mm_init(), at that time > memblock is dead and it should not be used any more. > > ef

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Nicolai Stange
On Thu, Jan 12 2017, Dave Young wrote: > -void __init efi_bgrt_init(void) > +void __init efi_bgrt_init(struct acpi_table_header *table) > { > - acpi_status status; > void *image; > struct bmp_header bmp_header; > > if (acpi_disabled) > return; > > - sta

Re: [PATCH 2/4] efi/x86: move efi bgrt init code to early init code

2017-01-12 Thread Dave Young
[snip] > --- linux-x86.orig/drivers/acpi/bgrt.c > +++ linux-x86/drivers/acpi/bgrt.c [snip] > > @@ -84,9 +85,17 @@ static int __init bgrt_init(void) > { > int ret; > > - if (!bgrt_image) > + if (!bgrt_tab.image_address) > return -ENODEV; > > + bgrt_image = mem