| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Keir Fraser <keir@xen.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Augment watchdog_setup() to be able to possibly return an error, and introduce
watchdog_enabled() as a better alternative to knowing the architectures
internal details.
This patch does not change the x86 implementaion, beyond making it compile.
For header files, some includes of xen/nmi.h were only for the watchdog
functions, so are replaced rather than adding an extra include of
xen/watchdog.h
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Keir Fraser <keir@xen.org>
|
|
|
|
|
|
|
| |
They don't belong into the former.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Keir Fraser <keir@xen.org>
|
|
|
|
|
|
|
|
|
| |
It seems that all current callers have interrupts enabled, making the
code currently safe but dangerous. Also, fix a trailing whitespace
issue.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Committed-by: Keir Fraser <keir@xen.org>
|
|
|
|
|
|
|
|
|
| |
Performance is not an issue with printk(), so let the function do
minimally more work and instead save a byte per affected format
specifier.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Keir Fraser <keir@xen.org>
|
|
|
|
|
|
|
|
| |
This complements c/s 9146:941897e98591, and also replaces a literal
zero with a proper manifest constant.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Keir Fraser <keir@xen.org>
|
|
|
|
|
|
|
|
|
|
| |
Introduce a command parameter to set the watchtog timeout. Manually
specifying "watchdog_timeout=<seconds>" on the command line will also
turn the watchdog on. For consistency, move opt_watchdog into nmi.c
along with opt_watchdog_timeout.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Committed-by: Keir Fraser <keir@xen.org>
|
|
|
|
|
|
|
|
|
|
| |
Since the perf counter that the LAPIC NMI watchdog uses only
runs while the core isn't halted, and all APs are idle at
this point in the boot process, it's possible that remote
CPUs won't see any NMIs during the 10-tick waiting period.
Force all CPUs to busy-wait so we know the timers are running.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
|
|
|
|
|
|
|
| |
With no modular drivers, all CPU notifier setup is supposed to happen
during boot. There also is a respective comment in the function.=20
Signed-off-by: Jan Beulich <jbeulich@novell.com>
|
|
|
|
| |
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mainly this involves getting rid of a bunch of cpumasks and replacing
with a single 'cpu_state' enumeration to track progress and allow
master-slave handshaking.
Cleaning this stuff up is a prerequisite for safely handling slave
failure (e.g., out of memory, invalid slave CPU capabilities,
...). This will get fixed up in a future patch.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
|
|
|
|
|
|
| |
At the same time, the data area starts life zeroed.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
|
|
|
|
| |
Signed-off-by: Mark Langsdorf <mark.langsdorf@amd.com>
|
|
|
|
|
|
|
| |
The significant remaining culprits for x86 are credit2, hpet, and
percpu-area subsystems. To be dealt with in a separate patch.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This attempts to address all the concerns raised in
http://lists.xensource.com/archives/html/xen-devel/2009-11/msg01195.html,
but I'm nevertheless still not convinced that all aspects of the
injection handling really work reliably. In particular, while the
patch here on top of the fixes for the problems menioned in the
referenced mail also adds code to keep send_guest_trap() from
injecting multiple events at a time, I don't think the is the right
mechanism - it should be possible to handle NMI/MCE nested within
each other.
Another fix on top of the ones for the earlier described problems is
that the vCPU affinity restore logic didn't account for software
injected NMIs - these never set cpu_affinity_tmp, but due to it most
likely being different from cpu_affinity it would have got restored
(to a potentially random value) nevertheless.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
|
|
|
|
|
|
|
| |
when the VMEXIT code indicates that an NMI has been raised.
Otherwise we might hit a real NMI while in the handler.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
|
|
|
|
|
|
|
|
|
|
| |
Add a new keyhandler that triggers all the side-effect-free
keyhandlers. This lets automated tests (and users) log the full set
of keyhandlers without having to be aware of which ones might reboot
the host.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
|
|
|
|
|
|
| |
... to be more precise in naming, and also to match Linux.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since the shared info layout is fixed, guests are required to use
VCPUOP_register_vcpu_info prior to booting any vCPU beyond the
traditional limit of 32.
MAX_VIRT_CPUS, being an implemetation detail of the hypervisor, is no
longer being exposed in the public headers.
The tools changes are clearly incomplete (and done only so things
would
build again), and the current state of the tools (using scalar
variables all over the place to represent vCPU bitmaps) very likely
doesn't permit booting DomU-s with more than the traditional number of
vCPU-s. Testing of the extended functionality was done with Dom0 (96
vCPU-s, as well as 128 vCPU-s out of which the kernel elected - by way
of a simple kernel side patch - to use only some, resulting in a
sparse
bitmap).
ia64 changes only to make things build, and build-tested only (and the
tools part only as far as the build would go without encountering
unrelated problems in the blktap code).
Signed-off-by: Jan Beulich <jbeulich@novell.com>
|
|
|
|
|
|
|
|
|
| |
While it is unlikely that a system has a different number of siblings
for different physical CPUs, make this parameter per-CPU for
consistency, and deal with the (so far theoretical) case that this is
different per CPU package.
Signed-off-by: Frank van der Linden <Frank.Vanderlinden@Sun.COM>
|
|
|
|
|
|
|
| |
The way MSR writes of performance counters works means that Intel
CPUs running faster than about 2.1GHz can't set the NMI timer to 1Hz.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
|
|
|
|
|
|
|
| |
The old CPU_CLK_UNHALTED performance counter no longer runs on Core or
Core2 CPUs. Use the new CPU_CLK_UNHALTED.CORE_P one.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
|
|
|
|
|
|
|
|
|
|
| |
This mainly means removing stack variables that (should) depend on
NR_CPUS (other than cpumask_t ones) and adjusting certain array sizes.
There's at least one open tools issue: The 'xm vcpu-pin' path assumes
a maximum of 64 CPU-s in many places.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
|
|
|
|
| |
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
|
|
|
|
| |
Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
|
|
|
|
|
|
|
| |
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Sync up affected files with 2.6.23-rc9.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Need to ensure all the code slice in the wakeup path still
existing. For this purpose, we have to use __devinit instead
of __init, since the former is null for CONFIG_HOTPLUG while
the latter always causes related code to be free-ed after
first boot.
Later when adding __init to some function, be sure to consider
wakeup case and cpu hotplug!
Signed-off-by <Kevin.Tian@intel.com>
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
replaced with unconditional static 'sane' implementations.
Functions relating to interrupt/IPI delivery have been
grouped into two sets: physical delivery and logical-flat
delivery. All subarchitectures use physical delivery except
the basic default subarchitecture.
The main behavioural changes are:
1. Summit no longer uses logical-clustered delivery mode
2. Physical mode no longer makes any pretence to set the
LDR sanely. We never deliver interrupts in logical mode
so this really should not matter.
3. Sanity checking of phys_cpu_present_map is enabled
for all subarchitectures. Really we should have a sane
set of APIC IDs in the system, as we rely on them for
physical delivery mode.
4. We enable 'bigsmp' mode on any system with more than
eight CPUs. The previous xAPIC check was unnecessary,
since our bigsmp mode uses physical delivery, not
logical-clustered.
This all obviously needs testing on some big systems.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
|
|
|
| |
timers. Also, compund updates to APIC ICR and ICR2 registers
must be done with interrupts disabled to ensure local
atomicity.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add 'N' keyhandler to dump the current per CPU NMI counts and the
current NMI mask/pending status.
Add 'n' keyhandler to trigger an NMI by sending an IPI. For some
reason the destination shorthand for self is not valid when used with
the NMI delivery mode so we send the IPI to our own APIC ID
explicitly.
Signed-off-by: Ian Campbell <Ian.Campbell@XenSource.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Bail out of setup_apic_nmi_watchdog() early if watchdog is not
enabled. Is the watchdog is disabled then increment
watchdog_disable_count to prevent it ever becoming enabled.
Unconditionally call setup_apic_nmi_watchdog() from setup_local_APIC()
so that the above is guaranteed to have occurred before the first call
of watchdog_enable().
Signed-off-by: Ian Campbell <Ian.Campbell@XenSource.com>
|
|
|
|
|
|
|
|
|
|
| |
meaningless and unnecessary.
Rename rem_timer -> stop_timer.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
| |
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
| |
Ensure global variables required by get_s_time() are initialised before
first use. Rejuggle bootstrap code slightly.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
| |
Many files:
More include cleanups towards "include where it's used".
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
|
|
|
|
|
|
|
|
|
|
| |
Many files:
More include cleanups towards "include where it's used".
sched.h:
g/c unneeded include.
include xen/spinlock.h once should be enough.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
|
|
|
|
|
|
| |
Clean up NMI watchdog handler. No need to hack into ac_timer structs.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
|
|
| |
Move to Linux's cpumask_t and 'hotplug' multi-processor booting
interfaces. This also brings apic.c and various other files closer to
their Linux 2.6 equivalents. Simplified the scheduler interfaces a
little (particularly per-cpu and idle-domain initialisation).
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
| |
Fix the watchdog disable/enable interface. This cleans up common code
somewhat.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
| |
Phase 1 of upgrading platform code to be derived from Linux 2.6.11
rather than 2.4.x.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
|
|
| |
Renames:
execution_context/xen_regs -> cpu_user_regs
full_execution_context -> vcpu_guest_context
[defined both 'struct xxx' and 'xxx_t' forms]
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
|
| |
NMI watchdog hooks off ac_timer softirq rather than apic timer irq.
In extreme situations we may service ac_timer events without ever
actually taking an apic interrupt.
Signed-off-by: Keir Fraser <keir@xensource.com>
|
|
|
|
|
|
|
| |
Minor cleanup. Removed some duplicate MSRs, fixed some MSR names,
added a few new MSRs and MSR bit fields.
Signed-off-by: michael.fetterman@cl.cam.ac.uk
|