Skip to contentSkip to conversation

Fix NX/XD enable on secondary CPUs.

Xen-changelog Gerd Knorr 2 participants 3 messages Jul 13, 2005 1 message not in the archive

lore
Share & tools
lore

Gerd Knorr

author
#1 lore raw
In reply to a message not in the archive
Quoted 2 lines · Xen patchbot -unstable

Fix NX/XD enable on secondary CPUs.

I think I have this problem with PAE as well. Machine is SMP (hyperthreaded). PAE dom0 boots fine on CPU #0. PAE domU is bound to CPU #1 by default and boots to the login prompt as well, but only with NX disabled (and network disabled, but that's another story ...).

With NX-enabled domU boot I get this ...

(XEN) (file=traps.c, line=872) Non-priv domain attempted RDMSR(c0000080,00000000,20100000). (XEN) (file=traps.c, line=864) Non-priv domain attempted WRMSR(c0000080,00000800,00000000).

... and the kernel crashes shortly later, I guess due to NX pte entry without NX being enabled on CPU #1. It crashes right after the first set_fixmap call which creates a pte entry with NX set.

Gerd

Signature · 1 line
panic("it works"); /* avoid being flooded with debug messages */
#2 lore raw

Does EFER_NX need setting for 32-bit PAE?

We don't set it for *any* cpus in x86_32 builds, even cpu0...

-- Keir

Quoted 15 lines · Gerd Knorr

I think I have this problem with PAE as well. Machine is SMP (hyperthreaded). PAE dom0 boots fine on CPU #0. PAE domU is bound to CPU #1 by default and boots to the login prompt as well, but only with NX disabled (and network disabled, but that's another story ...).

With NX-enabled domU boot I get this ...

(XEN) (file=traps.c, line=872) Non-priv domain attempted
RDMSR(c0000080,00000000,20100000).
(XEN) (file=traps.c, line=864) Non-priv domain attempted
WRMSR(c0000080,00000800,00000000).

... and the kernel crashes shortly later, I guess due to NX pte entry without NX being enabled on CPU #1. It crashes right after the first set_fixmap call which creates a pte entry with NX set.

author
#3 lore raw
Quoted 4 lines · Keir Fraser

Does EFER_NX need setting for 32-bit PAE?

We don't set it for *any* cpus in x86_32 builds, even cpu0...

The Dom0 linux kernel probably does for CPU #0 ...

Quoted 4 lines
Quoted 4 lines

(XEN) (file=traps.c, line=872) Non-priv domain attempted
RDMSR(c0000080,00000000,20100000).
(XEN) (file=traps.c, line=864) Non-priv domain attempted
WRMSR(c0000080,00000800,00000000).

... what the DomU kernel isn't allowed to do on CPU #1.

Gerd

Signature · 1 line
panic("it works"); /* avoid being flooded with debug messages */