Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-16 Thread H. Peter Anvin
On 07/16/2013 02:03 PM, Yinghai Lu wrote: > > Other way could be: > > Detect if it get into misc.c directly from > arch/x86/boot/compressed/head_64.S::startup_64. that is from 64bit > bootloader. > > others go through startup_32 should be 32bit bootloader. > > If it with 64bit boot loader path,

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-16 Thread Yinghai Lu
On Tue, Jul 16, 2013 at 12:41 PM, H. Peter Anvin wrote: > On 07/16/2013 12:40 PM, Kees Cook wrote: >>> >>> I think setting up a dynamic #PF handler is the right thing for the >>> decompressor, we already did for the kernel proper. >> >> I'm not sure how to accomplish this yet. I'm still trying to

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-16 Thread Yinghai Lu
On Tue, Jul 16, 2013 at 12:40 PM, Kees Cook wrote: > On Tue, Jul 16, 2013 at 12:36 PM, H. Peter Anvin wrote: >> On 07/16/2013 12:31 PM, Kees Cook wrote: >>> >>> Could the first step be documenting the limitation? I've found this >>> patch extremely useful for my case already, and I imagine there

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-16 Thread H. Peter Anvin
On 07/16/2013 12:40 PM, Kees Cook wrote: >> >> I think setting up a dynamic #PF handler is the right thing for the >> decompressor, we already did for the kernel proper. > > I'm not sure how to accomplish this yet. I'm still trying to > understand how the page tables are arranged. :) > Look at t

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-16 Thread Kees Cook
On Tue, Jul 16, 2013 at 12:36 PM, H. Peter Anvin wrote: > On 07/16/2013 12:31 PM, Kees Cook wrote: >> >> Could the first step be documenting the limitation? I've found this >> patch extremely useful for my case already, and I imagine there might >> be other people that need the early mmio stuff to

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-16 Thread H. Peter Anvin
On 07/16/2013 12:31 PM, Kees Cook wrote: > > Could the first step be documenting the limitation? I've found this > patch extremely useful for my case already, and I imagine there might > be other people that need the early mmio stuff to. Generally the > compressed boot serial console stuff is goin

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-16 Thread Kees Cook
On Fri, Jul 12, 2013 at 11:47 PM, Yinghai Lu wrote: > On Fri, Jul 12, 2013 at 1:38 PM, Kees Cook wrote: >> Allows "console=uart[8250],mmio[32],0xADDR[,BAUDn8[,BASE_BAUD]]" to >> be recognized during compressed boot early console setup, and during >> boot console setup. Replaces defines with commo

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-13 Thread H. Peter Anvin
I think we will need to map the uart explicitly, which is complex as that in turn implies seeing up something like the fixmap for the decompressor... not impossible but additional complexity to be sure. At least on 64 bits the high half should not conflict with any physical addresses. Either t

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-13 Thread Yinghai Lu
On Sat, Jul 13, 2013 at 7:53 AM, H. Peter Anvin wrote: > On 07/12/2013 11:47 PM, Yinghai Lu wrote: >> >> for 32 bit, that is ok. >> for 64 bit via 32bit bootloader, arch/x86/boot/compressed/head_64.S >> will set page table for first 4G still ok. >> for 64 bit via 64bit loader, like kexec via bzIma

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-13 Thread H. Peter Anvin
On 07/12/2013 11:47 PM, Yinghai Lu wrote: > > for 32 bit, that is ok. > for 64 bit via 32bit bootloader, arch/x86/boot/compressed/head_64.S > will set page table for first 4G still ok. > for 64 bit via 64bit loader, like kexec via bzImage64, First Kernel/Kexec only > set ident mapping for usable r

Re: [PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-12 Thread Yinghai Lu
On Fri, Jul 12, 2013 at 1:38 PM, Kees Cook wrote: > Allows "console=uart[8250],mmio[32],0xADDR[,BAUDn8[,BASE_BAUD]]" to > be recognized during compressed boot early console setup, and during > boot console setup. Replaces defines with common serial defines. Adds > suport for mmio-based serial devi

[PATCH v2 1/3] x86, boot: add mmio serial during compressed boot

2013-07-12 Thread Kees Cook
Allows "console=uart[8250],mmio[32],0xADDR[,BAUDn8[,BASE_BAUD]]" to be recognized during compressed boot early console setup, and during boot console setup. Replaces defines with common serial defines. Adds suport for mmio-based serial devices to compressed-boot early console, and plumbs support fo