linux_dsm_epyc7002/arch/s390/kernel
Christian Borntraeger 92e6ecf392 [S390] Fix hypervisor detection for KVM
Currently we use the cpuid (via STIDP instruction) to recognize LPAR,
z/VM and KVM.
The architecture states, that bit 0-7 of STIDP returns all zero, and
if STIDP is executed in a virtual machine, the VM operating system
will replace bits 0-7 with FF.

KVM should not use FE to distinguish z/VM from KVM for interested
guests. The proper way to detect the hypervisor is the STSI (Store
System Information) instruction, which return information about the
hypervisors via function code 3, selector1=2, selector2=2.

This patch changes the detection routine of Linux to use STSI instead
of STIDP. This detection is earlier than bootmem, we have to use a
static buffer. Since STSI expects a 4kb block (4kb aligned) this
patch also changes the init.data alignment for s390. As this section
will be freed during boot, this should be no problem.

Patch is tested with LPAR, z/VM, KVM on LPAR, and KVM under z/VM.

Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2009-03-26 15:24:09 +01:00
..
vdso32 [S390] gettimeofday.S: removed duplicated #includes 2009-01-09 12:15:04 +01:00
vdso64 [PATCH] fast vdso implementation for CLOCK_THREAD_CPUTIME_ID 2008-12-31 15:11:49 +01:00
asm-offsets.c [PATCH] fast vdso implementation for CLOCK_THREAD_CPUTIME_ID 2008-12-31 15:11:49 +01:00
audit.c
audit.h
base.S
bitmap.S
compat_audit.c
compat_exec_domain.c
compat_linux.c
compat_linux.h
compat_ptrace.h
compat_signal.c
compat_wrapper.S [S390] Add missing compat system call wrappers. 2009-01-23 16:40:29 +01:00
cpcmd.c [S390] convert cpcmd printks to pr_xxx macros. 2008-12-25 13:39:19 +01:00
crash.c
debug.c [S390] convert s390 debug feature printks to pr_xxx macros. 2008-12-25 13:39:22 +01:00
diag.c
dis.c
early.c [S390] Fix hypervisor detection for KVM 2009-03-26 15:24:09 +01:00
ebcdic.c
entry64.S [PATCH] fast vdso implementation for CLOCK_THREAD_CPUTIME_ID 2008-12-31 15:11:49 +01:00
entry.h [CVE-2009-0029] s390 specific system call wrappers 2009-01-14 14:15:32 +01:00
entry.S [PATCH] improve idle cputime accounting 2008-12-31 15:11:48 +01:00
head31.S [S390] Remove initial kernel stack backchain initialization. 2008-12-25 13:39:13 +01:00
head64.S [PATCH] fast vdso implementation for CLOCK_THREAD_CPUTIME_ID 2008-12-31 15:11:49 +01:00
head.S [S390] Add processor type march=z10 and a processor type safety check. 2008-12-25 13:39:12 +01:00
init_task.c take init_fs to saner place 2008-12-31 18:07:42 -05:00
ipl.c [S390] Automatic IPL after dump 2009-03-26 15:24:03 +01:00
irq.c [S390] Fix init irq proc build break. 2009-02-11 10:37:39 +01:00
kprobes.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2009-01-07 11:31:52 -08:00
machine_kexec.c
Makefile [S390] move sysinfo.c from drivers/s390 to arch/s390/kernel 2009-03-26 15:24:06 +01:00
mcount.S [S390] ftrace/mcount: fix kernel stack backchain 2009-03-18 13:28:12 +01:00
mem_detect.c
module.c
process.c [S390] cputime: initialize per thread timer values on fork 2009-03-26 15:24:07 +01:00
processor.c [S390] convert cpu related printks to pr_xxx macros. 2008-12-25 13:39:25 +01:00
ptrace.c [S390] remove ptrace warning on 31 bit. 2008-12-25 13:39:05 +01:00
reipl64.S
reipl.S
relocate_kernel64.S
relocate_kernel.S
s390_ext.c [PATCH] improve idle cputime accounting 2008-12-31 15:11:48 +01:00
s390_ksyms.c [S390] ftrace: function tracer backend for s390 2008-12-25 13:39:03 +01:00
setup.c [S390] Automatic IPL after dump 2009-03-26 15:24:03 +01:00
signal.c [CVE-2009-0029] s390 specific system call wrappers 2009-01-14 14:15:32 +01:00
smp.c [S390] lockdep: trace hardirq off in smp_send_stop 2009-03-26 15:24:08 +01:00
stacktrace.c
sys_s390.c [CVE-2009-0029] s390 specific system call wrappers 2009-01-14 14:15:32 +01:00
syscalls.S [S390] Add missing compat system call wrappers. 2009-01-23 16:40:29 +01:00
sysinfo.c [S390] move sysinfo.c from drivers/s390 to arch/s390/kernel 2009-03-26 15:24:06 +01:00
time.c [S390] etr/stp: fix possible deadlock 2009-01-23 16:40:29 +01:00
topology.c Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 2008-12-30 08:02:35 +10:30
traps.c [S390] fix dump_stack vs. %p and (null) 2009-03-26 15:24:02 +01:00
vdso.c [S390] vdso: compile fix 2009-01-09 12:15:06 +01:00
vmlinux.lds.S [S390] Fix hypervisor detection for KVM 2009-03-26 15:24:09 +01:00
vtime.c [S390] cputime: fix lowcore initialization on cpu hotplug 2009-01-23 16:40:28 +01:00