Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 150075 Details for
Bug 206366
[RHEL5 Beta1]: sysrq-t incurs a bogus softlockup warning
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
RHEL5 fix for this issue
softlockup.patch (text/plain), 9.03 KB, created by
Prarit Bhargava
on 2007-03-14 18:45:40 UTC
(
hide
)
Description:
RHEL5 fix for this issue
Filename:
MIME Type:
Creator:
Prarit Bhargava
Created:
2007-03-14 18:45:40 UTC
Size:
9.03 KB
patch
obsolete
>There are some situations when soft lockup warnings are expected in the >kernel. For example, when doing an alt-sysrq-t on a large number of processes, >the dump to console can take a long time and spinlocks may be held over that >period. This results in a bogus soft lockup warning. > >This patch reworks touch_softlockup_watchdog to touch ALL cpu's >touch_timestamp. It also introduces touch_cpu_softlockup_watchdog to touch >a single cpu's touch_timestamp. This makes it functionally equivalent to >touch_nmi_watchdog. > >touch_nmi_watchdog is not modified -- AFAICT, it was attempting to touch all >cpu's softlockup watchdogs, not just a specific cpu. > >/drivers/ide/ide-iops.c does not need to call touch_softlockup_watchdog as it >is done in the call to touch_nmi_watchdog. > >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/arch/i386/kernel/nmi.c linux-2.6.18.ia64/arch/i386/kernel/nmi.c >--- linux-2.6.18.ia64.orig/arch/i386/kernel/nmi.c 2007-03-12 05:47:49.000000000 -0400 >+++ linux-2.6.18.ia64/arch/i386/kernel/nmi.c 2007-03-14 13:19:34.000000000 -0400 >@@ -566,7 +566,7 @@ void touch_nmi_watchdog (void) > * Just reset the alert counters, (other CPUs might be > * spinning on locks we hold): > */ >- for_each_possible_cpu(i) >+ for_each_online_cpu(i) > alert_counter[i] = 0; > > /* >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/arch/i386/kernel/time-xen.c linux-2.6.18.ia64/arch/i386/kernel/time-xen.c >--- linux-2.6.18.ia64.orig/arch/i386/kernel/time-xen.c 2007-03-12 05:47:49.000000000 -0400 >+++ linux-2.6.18.ia64/arch/i386/kernel/time-xen.c 2007-03-14 10:06:04.000000000 -0400 >@@ -711,7 +711,7 @@ irqreturn_t timer_interrupt(int irq, voi > > /* Offlined for more than a few seconds? Avoid lockup warnings. */ > if (stolen > 5*HZ) >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > > /* Local timer processing (see update_process_times()). */ > run_local_timers(); >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/arch/ia64/kernel/uncached.c linux-2.6.18.ia64/arch/ia64/kernel/uncached.c >--- linux-2.6.18.ia64.orig/arch/ia64/kernel/uncached.c 2007-03-12 05:47:48.000000000 -0400 >+++ linux-2.6.18.ia64/arch/ia64/kernel/uncached.c 2007-03-13 18:17:46.000000000 -0400 >@@ -254,7 +254,7 @@ static int __init uncached_build_memmap( > struct gen_pool *pool = uncached_pools[nid].pool; > size_t size = uc_end - uc_start; > >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > > if (pool != NULL) { > memset((char *)uc_start, 0, size); >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/drivers/ide/ide-iops.c linux-2.6.18.ia64/drivers/ide/ide-iops.c >--- linux-2.6.18.ia64.orig/drivers/ide/ide-iops.c 2007-03-12 05:47:51.000000000 -0400 >+++ linux-2.6.18.ia64/drivers/ide/ide-iops.c 2007-03-14 09:27:41.000000000 -0400 >@@ -1243,7 +1243,6 @@ int ide_wait_not_busy(ide_hwif_t *hwif, > */ > if (stat == 0xff) > return -ENODEV; >- touch_softlockup_watchdog(); > touch_nmi_watchdog(); > } > return -EBUSY; >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/drivers/ide/ide-taskfile.c linux-2.6.18.ia64/drivers/ide/ide-taskfile.c >--- linux-2.6.18.ia64.orig/drivers/ide/ide-taskfile.c 2007-03-12 05:47:51.000000000 -0400 >+++ linux-2.6.18.ia64/drivers/ide/ide-taskfile.c 2007-03-13 18:18:04.000000000 -0400 >@@ -313,7 +313,7 @@ static void ide_pio_datablock(ide_drive_ > if (rq->bio) /* fs request */ > rq->errors = 0; > >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > > switch (drive->hwif->data_phase) { > case TASKFILE_MULTI_IN: >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/drivers/mtd/nand/nand_base.c linux-2.6.18.ia64/drivers/mtd/nand/nand_base.c >--- linux-2.6.18.ia64.orig/drivers/mtd/nand/nand_base.c 2007-03-12 05:47:50.000000000 -0400 >+++ linux-2.6.18.ia64/drivers/mtd/nand/nand_base.c 2007-03-13 18:18:14.000000000 -0400 >@@ -425,7 +425,7 @@ static void nand_wait_ready(struct mtd_i > do { > if (chip->dev_ready(mtd)) > break; >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > } while (time_before(jiffies, timeo)); > led_trigger_event(nand_led_trigger, LED_OFF); > } >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/drivers/mtd/onenand/onenand_base.c linux-2.6.18.ia64/drivers/mtd/onenand/onenand_base.c >--- linux-2.6.18.ia64.orig/drivers/mtd/onenand/onenand_base.c 2007-03-12 05:47:50.000000000 -0400 >+++ linux-2.6.18.ia64/drivers/mtd/onenand/onenand_base.c 2007-03-13 18:18:20.000000000 -0400 >@@ -308,7 +308,7 @@ static int onenand_wait(struct mtd_info > > if (state != FL_READING) > cond_resched(); >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > } > /* To get correct interrupt status in timeout case */ > interrupt = this->read_word(this->base + ONENAND_REG_INTERRUPT); >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/drivers/xen/core/smpboot.c linux-2.6.18.ia64/drivers/xen/core/smpboot.c >--- linux-2.6.18.ia64.orig/drivers/xen/core/smpboot.c 2007-03-12 05:47:50.000000000 -0400 >+++ linux-2.6.18.ia64/drivers/xen/core/smpboot.c 2007-03-13 18:18:32.000000000 -0400 >@@ -148,7 +148,7 @@ static void xen_smp_intr_exit(unsigned i > void cpu_bringup(void) > { > cpu_init(); >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > preempt_disable(); > local_irq_enable(); > } >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/include/linux/sched.h linux-2.6.18.ia64/include/linux/sched.h >--- linux-2.6.18.ia64.orig/include/linux/sched.h 2007-03-12 05:47:49.000000000 -0400 >+++ linux-2.6.18.ia64/include/linux/sched.h 2007-03-13 18:17:38.000000000 -0400 >@@ -215,6 +215,7 @@ extern void scheduler_tick(void); > #ifdef CONFIG_DETECT_SOFTLOCKUP > extern void softlockup_tick(void); > extern void spawn_softlockup_task(void); >+extern void touch_cpu_softlockup_watchdog(void); > extern void touch_softlockup_watchdog(void); > #else > static inline void softlockup_tick(void) >@@ -223,6 +224,9 @@ static inline void softlockup_tick(void) > static inline void spawn_softlockup_task(void) > { > } >+static inline void touch_cpu_softlockup_watchdog(void) >+{ >+} > static inline void touch_softlockup_watchdog(void) > { > } >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/kernel/panic.c linux-2.6.18.ia64/kernel/panic.c >--- linux-2.6.18.ia64.orig/kernel/panic.c 2007-03-12 05:47:49.000000000 -0400 >+++ linux-2.6.18.ia64/kernel/panic.c 2007-03-13 18:18:42.000000000 -0400 >@@ -132,7 +132,7 @@ NORET_TYPE void panic(const char * fmt, > #endif > local_irq_enable(); > for (i = 0;;) { >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > i += panic_blink(i); > mdelay(1); > i++; >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/kernel/power/swsusp.c linux-2.6.18.ia64/kernel/power/swsusp.c >--- linux-2.6.18.ia64.orig/kernel/power/swsusp.c 2007-03-12 05:47:49.000000000 -0400 >+++ linux-2.6.18.ia64/kernel/power/swsusp.c 2007-03-13 18:18:49.000000000 -0400 >@@ -274,7 +274,7 @@ int swsusp_resume(void) > swsusp_free(); > restore_processor_state(); > restore_highmem(); >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > device_power_up(); > local_irq_enable(); > return error; >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/kernel/sched.c linux-2.6.18.ia64/kernel/sched.c >--- linux-2.6.18.ia64.orig/kernel/sched.c 2007-03-12 05:47:49.000000000 -0400 >+++ linux-2.6.18.ia64/kernel/sched.c 2007-03-14 10:03:17.000000000 -0400 >@@ -4802,6 +4802,7 @@ void show_state(void) > touch_nmi_watchdog(); > show_task(p); > } while_each_thread(g, p); >+ touch_softlockup_watchdog(); > > read_unlock(&tasklist_lock); > debug_show_all_locks(); >diff -urNp -X linux-2.6.18.ia64/Documentation/dontdiff linux-2.6.18.ia64.orig/kernel/softlockup.c linux-2.6.18.ia64/kernel/softlockup.c >--- linux-2.6.18.ia64.orig/kernel/softlockup.c 2007-03-12 05:47:49.000000000 -0400 >+++ linux-2.6.18.ia64/kernel/softlockup.c 2007-03-14 13:27:11.000000000 -0400 >@@ -8,6 +8,7 @@ > */ > #include <linux/mm.h> > #include <linux/cpu.h> >+#include <linux/cpumask.h> > #include <linux/init.h> > #include <linux/delay.h> > #include <linux/kthread.h> >@@ -34,11 +35,19 @@ static struct notifier_block panic_block > .notifier_call = softlock_panic, > }; > >-void touch_softlockup_watchdog(void) >+void touch_cpu_softlockup_watchdog(void) > { > __raw_get_cpu_var(touch_timestamp) = jiffies; > } >-EXPORT_SYMBOL(touch_softlockup_watchdog); >+EXPORT_SYMBOL(touch_cpu_softlockup_watchdog); >+ >+void touch_softlockup_watchdog(void) >+{ >+ int cpu; >+ >+ for_each_online_cpu(cpu) >+ per_cpu(touch_timestamp, cpu) = jiffies; >+} > > /* > * This callback runs from the timer interrupt, and checks >@@ -57,7 +66,7 @@ void softlockup_tick(void) > > /* do not print during early bootup: */ > if (unlikely(system_state != SYSTEM_RUNNING)) { >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > return; > } > >@@ -94,7 +103,7 @@ static int watchdog(void * __bind_cpu) > */ > while (!kthread_should_stop()) { > set_current_state(TASK_INTERRUPTIBLE); >- touch_softlockup_watchdog(); >+ touch_cpu_softlockup_watchdog(); > schedule(); > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 206366
:
136213
|
149958
|
149959
|
149961
|
149963
|
150074
|
150075
|
151651
|
161096
|
161097
|
161098
|
161099