Commit-ID: 510489b69b0cedf369ca48aa7c0b5bcdb5509a59 Gitweb: http://git.kernel.org/tip/510489b69b0cedf369ca48aa7c0b5bcdb5509a59 Author: Sasha Levin <levinsasha928@xxxxxxxxx> AuthorDate: Fri, 9 Dec 2011 13:16:17 +0200 Committer: Pekka Enberg <penberg@xxxxxxxxxx> CommitDate: Fri, 9 Dec 2011 13:46:28 +0200 kvm tools: Fix serial port probing The process of probing the 8250 serial port is as follows: 1. Start detecting IRQs 2. Enable the IER register [At this point, the port is supposed to light the INTR]. 3. Stop detecting IRQs [At this point, the driver detects which IRQ belongs to that port]. 4. Disable IER register. Since we weren't enabling and disabling the IRQ based on IER writes, we would often fail the probing since the driver couldn't detect which IRQ is used by the port, and would just default that to 0. This would cause slowness and may have caused hangs. For me there is a significant increase in speed of the terminal after this patch. Signed-off-by: Sasha Levin <levinsasha928@xxxxxxxxx> [ penberg@xxxxxxxxxx: whitspace cleanup ] Signed-off-by: Pekka Enberg <penberg@xxxxxxxxxx> --- tools/kvm/hw/serial.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/tools/kvm/hw/serial.c b/tools/kvm/hw/serial.c index 67a2007..5be81d4 100644 --- a/tools/kvm/hw/serial.c +++ b/tools/kvm/hw/serial.c @@ -233,6 +233,7 @@ static bool serial8250_out(struct ioport *ioport, struct kvm *kvm, u16 port, voi break; case UART_IER: dev->ier = ioport__read8(data) & 0x3f; + kvm__irq_line(kvm, dev->irq, dev->ier ? 1 : 0); break; case UART_LCR: dev->lcr = ioport__read8(data); -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html