Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-30 Thread Joe Perches
On Thu, 2017-11-30 at 10:31 +0300, Kirill A. Shutemov wrote: > On Wed, Nov 29, 2017 at 05:48:51PM +, Borislav Petkov wrote: > > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > > > We're really early in the boot -- startup_64 in decompression code -- and > > > I don't know

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-30 Thread Joe Perches
On Thu, 2017-11-30 at 10:31 +0300, Kirill A. Shutemov wrote: > On Wed, Nov 29, 2017 at 05:48:51PM +, Borislav Petkov wrote: > > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > > > We're really early in the boot -- startup_64 in decompression code -- and > > > I don't know

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-30 Thread Borislav Petkov
On Thu, Nov 30, 2017 at 10:31:31AM +0300, Kirill A. Shutemov wrote: > On Wed, Nov 29, 2017 at 05:48:51PM +, Borislav Petkov wrote: > > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > > > We're really early in the boot -- startup_64 in decompression code -- and > > > I

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-30 Thread Borislav Petkov
On Thu, Nov 30, 2017 at 10:31:31AM +0300, Kirill A. Shutemov wrote: > On Wed, Nov 29, 2017 at 05:48:51PM +, Borislav Petkov wrote: > > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > > > We're really early in the boot -- startup_64 in decompression code -- and > > > I

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-30 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 03:24:53PM -0800, H. Peter Anvin wrote: > Yes, Grub as a matter of policy(!) does everything in the most braindead > way possible. You have to use "linux16" or "linuxefi" to make it do > something sane. Good to know, thx. > What is text mode? It is hardware that is

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-30 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 03:24:53PM -0800, H. Peter Anvin wrote: > Yes, Grub as a matter of policy(!) does everything in the most braindead > way possible. You have to use "linux16" or "linuxefi" to make it do > something sane. Good to know, thx. > What is text mode? It is hardware that is

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Kirill A. Shutemov
On Wed, Nov 29, 2017 at 05:48:51PM +, Borislav Petkov wrote: > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > > We're really early in the boot -- startup_64 in decompression code -- and > > I don't know a way print a message there. Is there a way? > > > > no_longmode

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Kirill A. Shutemov
On Wed, Nov 29, 2017 at 05:48:51PM +, Borislav Petkov wrote: > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > > We're really early in the boot -- startup_64 in decompression code -- and > > I don't know a way print a message there. Is there a way? > > > > no_longmode

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Konrad Rzeszutek Wilk
On Wed, Nov 29, 2017 at 03:24:53PM -0800, H. Peter Anvin wrote: > On 11/29/17 14:31, Borislav Petkov wrote: > > > > A couple of points: > > > > * so this box here has a normal grub installation and apparently grub > > jumps to some other entry point. Ouch. Perhaps you can report this on

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Konrad Rzeszutek Wilk
On Wed, Nov 29, 2017 at 03:24:53PM -0800, H. Peter Anvin wrote: > On 11/29/17 14:31, Borislav Petkov wrote: > > > > A couple of points: > > > > * so this box here has a normal grub installation and apparently grub > > jumps to some other entry point. Ouch. Perhaps you can report this on

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread H. Peter Anvin
On 11/29/17 14:31, Borislav Petkov wrote: > > A couple of points: > > * so this box here has a normal grub installation and apparently grub > jumps to some other entry point. > Yes, Grub as a matter of policy(!) does everything in the most braindead way possible. You have to use "linux16" or

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread H. Peter Anvin
On 11/29/17 14:31, Borislav Petkov wrote: > > A couple of points: > > * so this box here has a normal grub installation and apparently grub > jumps to some other entry point. > Yes, Grub as a matter of policy(!) does everything in the most braindead way possible. You have to use "linux16" or

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 01:33:28PM -0800, H. Peter Anvin wrote: > You can't dump a message about *anything* if the bootloader bypasses the > checks that happen before we leave the firmware behind. This is what > this is about. For BIOS or EFI boot that go through the proper stub > functions we

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 01:33:28PM -0800, H. Peter Anvin wrote: > You can't dump a message about *anything* if the bootloader bypasses the > checks that happen before we leave the firmware behind. This is what > this is about. For BIOS or EFI boot that go through the proper stub > functions we

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread H. Peter Anvin
On 11/29/17 11:19, Borislav Petkov wrote: > On Wed, Nov 29, 2017 at 11:01:35AM -0800, H. Peter Anvin wrote: >> We can hang the machine, or we can triple-fault it in the hope of >> triggering a reset, and that way if the bootloader has been configured >> with a backup kernel there is a hope of

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread H. Peter Anvin
On 11/29/17 11:19, Borislav Petkov wrote: > On Wed, Nov 29, 2017 at 11:01:35AM -0800, H. Peter Anvin wrote: >> We can hang the machine, or we can triple-fault it in the hope of >> triggering a reset, and that way if the bootloader has been configured >> with a backup kernel there is a hope of

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread hpa
On November 29, 2017 12:58:15 PM PST, Andi Kleen wrote: >> We're really early in the boot -- startup_64 in decompression code -- >and >> I don't know a way print a message there. Is there a way? >> >> no_longmode handled by just hanging the machine. Is it enough for

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread hpa
On November 29, 2017 12:58:15 PM PST, Andi Kleen wrote: >> We're really early in the boot -- startup_64 in decompression code -- >and >> I don't know a way print a message there. Is there a way? >> >> no_longmode handled by just hanging the machine. Is it enough for >no_la57 >> case too? > >The

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Andi Kleen
> We're really early in the boot -- startup_64 in decompression code -- and > I don't know a way print a message there. Is there a way? > > no_longmode handled by just hanging the machine. Is it enough for no_la57 > case too? The way to handle it is to check it early in the real mode boot code

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Andi Kleen
> We're really early in the boot -- startup_64 in decompression code -- and > I don't know a way print a message there. Is there a way? > > no_longmode handled by just hanging the machine. Is it enough for no_la57 > case too? The way to handle it is to check it early in the real mode boot code

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 11:01:35AM -0800, H. Peter Anvin wrote: > We can hang the machine, or we can triple-fault it in the hope of > triggering a reset, and that way if the bootloader has been configured > with a backup kernel there is a hope of recovery. Well, it triple-faults right now and

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 11:01:35AM -0800, H. Peter Anvin wrote: > We can hang the machine, or we can triple-fault it in the hope of > triggering a reset, and that way if the bootloader has been configured > with a backup kernel there is a hope of recovery. Well, it triple-faults right now and

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread H. Peter Anvin
On 11/29/17 09:48, Borislav Petkov wrote: > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: >> We're really early in the boot -- startup_64 in decompression code -- and >> I don't know a way print a message there. Is there a way? >> >> no_longmode handled by just hanging the

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread H. Peter Anvin
On 11/29/17 09:48, Borislav Petkov wrote: > On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: >> We're really early in the boot -- startup_64 in decompression code -- and >> I don't know a way print a message there. Is there a way? >> >> no_longmode handled by just hanging the

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > We're really early in the boot -- startup_64 in decompression code -- and > I don't know a way print a message there. Is there a way? > > no_longmode handled by just hanging the machine. Is it enough for no_la57 > case too?

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Wed, Nov 29, 2017 at 08:08:31PM +0300, Kirill A. Shutemov wrote: > We're really early in the boot -- startup_64 in decompression code -- and > I don't know a way print a message there. Is there a way? > > no_longmode handled by just hanging the machine. Is it enough for no_la57 > case too?

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Kirill A. Shutemov
On Wed, Nov 29, 2017 at 05:40:32PM +0100, Thomas Gleixner wrote: > On Wed, 29 Nov 2017, Kirill A. Shutemov wrote: > > > On Wed, Nov 29, 2017 at 04:49:08PM +0100, Borislav Petkov wrote: > > > On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > > > > Hi Ingo, > > > > > > > >

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Kirill A. Shutemov
On Wed, Nov 29, 2017 at 05:40:32PM +0100, Thomas Gleixner wrote: > On Wed, 29 Nov 2017, Kirill A. Shutemov wrote: > > > On Wed, Nov 29, 2017 at 04:49:08PM +0100, Borislav Petkov wrote: > > > On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > > > > Hi Ingo, > > > > > > > >

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Thomas Gleixner
On Wed, 29 Nov 2017, Kirill A. Shutemov wrote: > On Wed, Nov 29, 2017 at 04:49:08PM +0100, Borislav Petkov wrote: > > On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > > > Hi Ingo, > > > > > > Here's updated changes that prepare the code to boot-time switching > > > between

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Thomas Gleixner
On Wed, 29 Nov 2017, Kirill A. Shutemov wrote: > On Wed, Nov 29, 2017 at 04:49:08PM +0100, Borislav Petkov wrote: > > On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > > > Hi Ingo, > > > > > > Here's updated changes that prepare the code to boot-time switching > > > between

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Kirill A. Shutemov
On Wed, Nov 29, 2017 at 04:49:08PM +0100, Borislav Petkov wrote: > On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > > Hi Ingo, > > > > Here's updated changes that prepare the code to boot-time switching between > > paging modes and handle booting in 5-level mode when

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Kirill A. Shutemov
On Wed, Nov 29, 2017 at 04:49:08PM +0100, Borislav Petkov wrote: > On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > > Hi Ingo, > > > > Here's updated changes that prepare the code to boot-time switching between > > paging modes and handle booting in 5-level mode when

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > Hi Ingo, > > Here's updated changes that prepare the code to boot-time switching between > paging modes and handle booting in 5-level mode when bootloader put kernel > image above 4G, but haven't enabled 5-level paging for us.

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-29 Thread Borislav Petkov
On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > Hi Ingo, > > Here's updated changes that prepare the code to boot-time switching between > paging modes and handle booting in 5-level mode when bootloader put kernel > image above 4G, but haven't enabled 5-level paging for us.

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-22 Thread Kirill A. Shutemov
On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > Hi Ingo, > > Here's updated changes that prepare the code to boot-time switching between > paging modes and handle booting in 5-level mode when bootloader put kernel > image above 4G, but haven't enabled 5-level paging for us.

Re: [PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-22 Thread Kirill A. Shutemov
On Sat, Nov 11, 2017 at 01:06:41AM +0300, Kirill A. Shutemov wrote: > Hi Ingo, > > Here's updated changes that prepare the code to boot-time switching between > paging modes and handle booting in 5-level mode when bootloader put kernel > image above 4G, but haven't enabled 5-level paging for us.

[PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-10 Thread Kirill A. Shutemov
Hi Ingo, Here's updated changes that prepare the code to boot-time switching between paging modes and handle booting in 5-level mode when bootloader put kernel image above 4G, but haven't enabled 5-level paging for us. I've updated patches based on your feedback. Please review and consider

[PATCHv2 0/4] x86: 5-level related changes into decompression code

2017-11-10 Thread Kirill A. Shutemov
Hi Ingo, Here's updated changes that prepare the code to boot-time switching between paging modes and handle booting in 5-level mode when bootloader put kernel image above 4G, but haven't enabled 5-level paging for us. I've updated patches based on your feedback. Please review and consider