diff options
author | François Diakhaté <fdiakh@gmail.com> | 2010-03-23 08:53:15 -0400 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2010-04-07 20:16:15 -0400 |
commit | 162a689a13ed61c0752726edb75427b2cd4186c1 (patch) | |
tree | 981e061b36efce8383e8f4334f48aba44c214fc4 /drivers/char/virtio_console.c | |
parent | 9a82446bd269b130a9ac270e720e65c3843d4d0c (diff) |
virtio: console: Fix early_put_chars usage
Currently early_put_chars is not used by virtio_console because it can
only be used once a port has been found, at which point it's too late
because it is no longer needed. This patch should fix it.
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'drivers/char/virtio_console.c')
-rw-r--r-- | drivers/char/virtio_console.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 026ea6c27e07..48306bc733f7 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c | |||
@@ -646,13 +646,13 @@ static int put_chars(u32 vtermno, const char *buf, int count) | |||
646 | { | 646 | { |
647 | struct port *port; | 647 | struct port *port; |
648 | 648 | ||
649 | if (unlikely(early_put_chars)) | ||
650 | return early_put_chars(vtermno, buf, count); | ||
651 | |||
649 | port = find_port_by_vtermno(vtermno); | 652 | port = find_port_by_vtermno(vtermno); |
650 | if (!port) | 653 | if (!port) |
651 | return 0; | 654 | return 0; |
652 | 655 | ||
653 | if (unlikely(early_put_chars)) | ||
654 | return early_put_chars(vtermno, buf, count); | ||
655 | |||
656 | return send_buf(port, (void *)buf, count); | 656 | return send_buf(port, (void *)buf, count); |
657 | } | 657 | } |
658 | 658 | ||