Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-09 Thread H. Peter Anvin
On 03/09/2014 11:07 AM, Paolo Bonzini wrote: > > We really should give a loud warning if qemu64 is used with KVM. It > makes no sense with KVM, even less than it does with dynamic translation. > Well, this is dynamic translation. -hpa -- To unsubscribe from this list: send the line "

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-09 Thread Borislav Petkov
On Sun, Mar 09, 2014 at 07:07:02PM +0100, Paolo Bonzini wrote: > tl;dr: do not use qemu64, especially in system emulation mode. In > user mode it should work, user mode programs are less susceptible to > bogus family/member/stepping. When using dynamic translation in > system emulation mode, use

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-09 Thread Paolo Bonzini
Il 07/03/2014 22:38, Borislav Petkov ha scritto: + Paolo. (drop Andreas' old, invalid now email). On Fri, Mar 07, 2014 at 01:01:22PM -0800, H. Peter Anvin wrote: qemu64 triggers this ? That spew comes from amd_k7_smp_check() which should only run on family 6, which was all 32bit. [0.1527

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Borislav Petkov
On Fri, Mar 07, 2014 at 05:27:43PM -0500, Dave Jones wrote: > When I wrote it 10 years or so back it made more sense than it > probably does now, so I'd be ok with just dropping it all too tbh. > Machines of that vintage probably have bigger problems now anyway. Yeah. > I don't recall seeing a re

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Borislav Petkov
On Sat, Mar 08, 2014 at 06:27:50AM +0800, Fengguang Wu wrote: > Yeah I confirmed that it works w/o the warning! > > [0.575854] smpboot: CPU0: Intel Core Processor (Haswell) (fam: 06, model: > 3c, stepping: 01) Hahah, Haswell is just a couple models away from K7: model 6 vs model 3c, same fam

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Fengguang Wu
On Fri, Mar 07, 2014 at 02:11:50PM -0800, H. Peter Anvin wrote: > On 03/07/2014 02:06 PM, Dave Jones wrote: > > On Fri, Mar 07, 2014 at 10:38:56PM +0100, Borislav Petkov wrote: > > > > > * Another option would be if we change the f/m/s of "qemu64" so that > > > the test doesn't fire. > > > > >

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Dave Jones
On Fri, Mar 07, 2014 at 11:20:18PM +0100, Borislav Petkov wrote: > Yeah, I think the test in the kernel is open above as a precaution in > case newer models appeared: > > if (((c->x86_model == 6) && (c->x86_mask >= 2)) || > > I hardly can imagine, though, if anyone is actually boo

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Borislav Petkov
On Fri, Mar 07, 2014 at 05:06:55PM -0500, Dave Jones wrote: > Additionally, fam:6 model:6 stepping 3 never existed in the real > world afaict. I used to keep x86info's stepping db pretty up to date, > and that only has knowledge of stepping 1 & 2.[*] Modelling qemu on > something from the real worl

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Dave Jones
On Fri, Mar 07, 2014 at 02:11:50PM -0800, H. Peter Anvin wrote: > > > * Another option would be if we change the f/m/s of "qemu64" so that > > > the test doesn't fire. > > > > > > What also makes me wonder is why is this thing even called qemu64?? AMD > > > family 6 was 32-bit only CPU

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread H. Peter Anvin
On 03/07/2014 02:06 PM, Dave Jones wrote: > On Fri, Mar 07, 2014 at 10:38:56PM +0100, Borislav Petkov wrote: > > > * Another option would be if we change the f/m/s of "qemu64" so that > > the test doesn't fire. > > > > What also makes me wonder is why is this thing even called qemu64?? AMD >

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Dave Jones
On Fri, Mar 07, 2014 at 10:38:56PM +0100, Borislav Petkov wrote: > * Another option would be if we change the f/m/s of "qemu64" so that > the test doesn't fire. > > What also makes me wonder is why is this thing even called qemu64?? AMD > family 6 was 32-bit only CPUs so 64 is kinda wrong IM

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Borislav Petkov
+ Paolo. (drop Andreas' old, invalid now email). On Fri, Mar 07, 2014 at 01:01:22PM -0800, H. Peter Anvin wrote: > > qemu64 triggers this ? That spew comes from amd_k7_smp_check() > > which should only run on family 6, which was all 32bit. > > [0.152749] smpboot: CPU0: AMD QEMU Virtual CPU

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread H. Peter Anvin
On 03/07/2014 11:10 AM, Dave Jones wrote: > On Fri, Mar 07, 2014 at 10:56:11AM -0800, H. Peter Anvin wrote: > > On 03/06/2014 09:50 PM, Fengguang Wu wrote: > > >> > > >> Unfortunately these things are hard to fix in Qemu. > > > > > > OK. As an alternative, is it possible to pass one of the be

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread Dave Jones
On Fri, Mar 07, 2014 at 10:56:11AM -0800, H. Peter Anvin wrote: > On 03/06/2014 09:50 PM, Fengguang Wu wrote: > >> > >> Unfortunately these things are hard to fix in Qemu. > > > > OK. As an alternative, is it possible to pass one of the below CPUID flags > > in > > the Qemu command line, s

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-07 Thread H. Peter Anvin
On 03/06/2014 09:50 PM, Fengguang Wu wrote: >> >> Unfortunately these things are hard to fix in Qemu. > > OK. As an alternative, is it possible to pass one of the below CPUID flags in > the Qemu command line, so as to quiet the warning? > I don't see the AMD SMP CPUID flag in there. Boris, coul

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-06 Thread Fengguang Wu
On Thu, Mar 06, 2014 at 09:03:50PM -0800, H. Peter Anvin wrote: > On 03/06/2014 05:58 PM, Fengguang Wu wrote: > > Hi all, > > > > I find the below WARNING shows up only in > > > > qemu-system-x86_64 -cpu qemu64,+smep,+smap > > > > Yes, it is because Qemu doesn't show the AMD-specific SM

Re: [qemu64,+smep,+smap] WARNING: CPU: 1 PID: 0 at arch/x86/kernel/cpu/amd.c:220 init_amd()

2014-03-06 Thread H. Peter Anvin
On 03/06/2014 05:58 PM, Fengguang Wu wrote: > Hi all, > > I find the below WARNING shows up only in > > qemu-system-x86_64 -cpu qemu64,+smep,+smap > Yes, it is because Qemu doesn't show the AMD-specific SMP CPUID bit. It's harmless in that sense. Unfortunately these things are hard to