diff mbox

[RFC,11/11] kvm tools: ARM: add 8250 console callback to periodic poll

Message ID 1367423416-24640-12-git-send-email-will.deacon@arm.com (mailing list archive)
State New, archived
Headers show

Commit Message

Will Deacon May 1, 2013, 3:50 p.m. UTC
If we're using the 8250 as a fully-fledged console (i.e. not early
console), then we need to allow input as well as output.

Signed-off-by: Will Deacon <will.deacon@arm.com>
---
 tools/kvm/arm/kvm.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/tools/kvm/arm/kvm.c b/tools/kvm/arm/kvm.c
index 1bcfce3..27e6cf4 100644
--- a/tools/kvm/arm/kvm.c
+++ b/tools/kvm/arm/kvm.c
@@ -1,6 +1,7 @@ 
 #include "kvm/kvm.h"
 #include "kvm/term.h"
 #include "kvm/util.h"
+#include "kvm/8250-serial.h"
 #include "kvm/virtio-console.h"
 
 #include "arm-common/gic.h"
@@ -47,8 +48,10 @@  void kvm__arch_delete_ram(struct kvm *kvm)
 
 void kvm__arch_periodic_poll(struct kvm *kvm)
 {
-	if (term_readable(0))
+	if (term_readable(0)) {
+		serial8250__update_consoles(kvm);
 		virtio_console__inject_interrupt(kvm);
+	}
 }
 
 void kvm__arch_set_cmdline(char *cmdline, bool video)