[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen stable-4.3] watchdog/crash: Always disable watchdog in console_force_unlock()

commit 8294ffb817a795f93e241192c59e34c9da281b8b
Author:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
AuthorDate: Fri Sep 27 11:54:42 2013 +0200
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Fri Sep 27 11:54:42 2013 +0200

    watchdog/crash: Always disable watchdog in console_force_unlock()
    Depending on the state of the conring and serial_tx_buffer,
    console_force_unlock() can be a long running operation, usually because of
    XenServer testing has found a reliable case where console_force_unlock() on
    one PCPU takes long enough for another PCPU to timeout due to the watchdog
    (such as waiting for a tlb flush callin).
    The watchdog timeout causes the second PCPU to repeat the
    console_force_unlock(), at which point the first PCPU typically fails an
    assertion in spin_unlock_irqrestore(&port->tx_lock) (because the tx_lock has
    been unlocked behind itself).
    console_force_unlock() is only on emergency paths, so one way or another the
    host is going down.  Disable the watchdog before forcing the console lock to
    help prevent having pcpus completing with each other to bring the host down.
    Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
    Acked-by: Keir Fraser <keir@xxxxxxx>
    master commit: 7b9fa702ca323164d6b49e8b639a57f880454a8c
    master date: 2013-08-13 14:31:01 +0200
 xen/arch/x86/x86_64/traps.c |    2 --
 xen/drivers/char/console.c  |    3 +++
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/xen/arch/x86/x86_64/traps.c b/xen/arch/x86/x86_64/traps.c
index bcd7609..1054480 100644
--- a/xen/arch/x86/x86_64/traps.c
+++ b/xen/arch/x86/x86_64/traps.c
@@ -226,8 +226,6 @@ void do_double_fault(struct cpu_user_regs *regs)
     unsigned int cpu;
     unsigned long crs[8];
-    watchdog_disable();
     asm ( "lsll %1, %0" : "=r" (cpu) : "rm" (PER_CPU_GDT_ENTRY << 3) );
diff --git a/xen/drivers/char/console.c b/xen/drivers/char/console.c
index bf16d49..110addc 100644
--- a/xen/drivers/char/console.c
+++ b/xen/drivers/char/console.c
@@ -736,6 +736,9 @@ void console_end_log_everything(void)
 void console_force_unlock(void)
+#ifdef CONFIG_X86
+    watchdog_disable();
     console_locks_busted = 1;
generated by git-patchbot for /home/xen/git/xen.git#stable-4.3

Xen-changelog mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.