Huang, Xinmei
2006-Nov-13 09:03 UTC
[Xen-devel] [Patch]Fix Linux smp guest hangs with complaint "BUG: soft lock detected on CPU#0"
Fix Linux smp guest hangs with complaint "BUG: soft lock detected on CPU#0" when console=ttyS0 in guest grub configuration and serial=''pty'' in vmx configure file. The root cause to this bug is the characteristic of PTY emulator in Qemu. PTY has write/read end with some buffer. Write to a buffer will be failed after the buffer is full until read end reads the data from buffer, Previous to changeset 12026, write to serial port would fail quietly when buffer for pty is full. With changeset 12026, write to serial port would retry 3 times in 300ms if failed, even without notifying guest using serial irq. Smp guest will hang, waiting for an interrupt. For SMP guest, a watchdog thread should be executed periodically, otherwise soft lockup is detected. With this patch, an upper threshold of total consecutive retries is added and serial interrupt would be sent after retry 3 times for each write request, even if failed. Signed-off-by: Xinmei Huang <xinmei.huang@intel.com> _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel