Re: CPUID in amd64/i386 boot code

2016-03-19 Thread Masao Uebayashi
This is the intended use, avoid busy-polling of BIOS PC console if running on HV. Avoid 100% CPU usage at boot prompt on hypervisors. Originally I unconditionally reverted the polling part, which was introduced only for Intel Mac Mini. After brief discussion with mikeb@, I decided to leave that

Re: CPUID in amd64/i386 boot code

2016-03-19 Thread Mike Larkin
On Thu, Mar 17, 2016 at 03:31:45PM +0900, Masao Uebayashi wrote: > On Wed, Mar 16, 2016 at 11:26:39PM -0700, Mike Larkin wrote: > > On Thu, Mar 17, 2016 at 03:15:07PM +0900, Masao Uebayashi wrote: > > > This is the intended use, avoid busy-polling of BIOS PC console if > > > running on HV. Avoid 1

CPUID in amd64/i386 boot code

2016-03-19 Thread Masao Uebayashi
Factor out CPUID code in mdrandom(), invoke it once, then save the result. I'll use it to switch behavior depending on HV or not. efiboot is not tested. Comments? >From 104cb04bbbd0f7e40758938cc3103b2370a2285c Mon Sep 17 00:00:00 2001 From: Masao Uebayashi Date: Thu, 10 Mar 2016 21:03:07 +0900

Re: CPUID in amd64/i386 boot code

2016-03-19 Thread Mike Larkin
On Thu, Mar 17, 2016 at 03:15:07PM +0900, Masao Uebayashi wrote: > This is the intended use, avoid busy-polling of BIOS PC console if > running on HV. Avoid 100% CPU usage at boot prompt on hypervisors. > Which hypervisors have you tested this on? -ml > Originally I unconditionally reverted th

Re: CPUID in amd64/i386 boot code

2016-03-19 Thread Mike Belopuhov
On Wed, Mar 16, 2016 at 23:47 -0700, Mike Larkin wrote: > On Thu, Mar 17, 2016 at 03:31:45PM +0900, Masao Uebayashi wrote: > > On Wed, Mar 16, 2016 at 11:26:39PM -0700, Mike Larkin wrote: > > > On Thu, Mar 17, 2016 at 03:15:07PM +0900, Masao Uebayashi wrote: > > > > This is the intended use, avoid

Re: CPUID in amd64/i386 boot code

2016-03-19 Thread Theo de Raadt
> Factor out CPUID code in mdrandom(), invoke it once, then save the > result. I'll use it to switch behavior depending on HV or not. > > efiboot is not tested. > > Comments? I don't understand the purpose of the refactoring.

Re: CPUID in amd64/i386 boot code

2016-03-19 Thread Theo de Raadt
The process I see here the submission of 2 seperate diffs to the bootblocks, requiring people to take two steps. Then readers of tech@ will realize that the proposition is to test their bootblocks right away, many will balk. The diffs also do not come with a report as to what machines were te

Re: CPUID in amd64/i386 boot code

2016-03-19 Thread Masao Uebayashi
On Wed, Mar 16, 2016 at 11:26:39PM -0700, Mike Larkin wrote: > On Thu, Mar 17, 2016 at 03:15:07PM +0900, Masao Uebayashi wrote: > > This is the intended use, avoid busy-polling of BIOS PC console if > > running on HV. Avoid 100% CPU usage at boot prompt on hypervisors. > > > > Which hypervisors

Re: CPUID in amd64/i386 boot code

2016-03-18 Thread Mike Belopuhov
On Thu, Mar 17, 2016 at 16:39 +0100, Mike Belopuhov wrote: > On Wed, Mar 16, 2016 at 23:47 -0700, Mike Larkin wrote: > > On Thu, Mar 17, 2016 at 03:31:45PM +0900, Masao Uebayashi wrote: > > > On Wed, Mar 16, 2016 at 11:26:39PM -0700, Mike Larkin wrote: > > > > On Thu, Mar 17, 2016 at 03:15:07PM +09