From: Constantin Baranov <const@mimas.ru>
To: linux-kernel@vger.kernel.org
Subject: [PATCH] virtio_console: register hvc0 as console
Date: Mon, 22 Feb 2010 14:15:50 +0400 [thread overview]
Message-ID: <20100222141550.67fa46f7.const@mimas.ru> (raw)
Call hvc_instantiate() when probing virtio device.
A console should be registered much earlier but we
cannot ensure hvc0 existence until PCI and virtio
subsystems initialized. After all, console=hvc0 may
be useful even with this limitation.
Signed-off-by: Constantin Baranov <const@mimas.ru>
---
drivers/char/virtio_console.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c
index a035ae3..cf9cb80 100644
--- a/drivers/char/virtio_console.c
+++ b/drivers/char/virtio_console.c
@@ -219,6 +219,9 @@ static int __devinit virtcons_probe(struct virtio_device *dev)
virtio_cons.notifier_del = notifier_del_vio;
virtio_cons.notifier_hangup = notifier_del_vio;
+ /* Attempt to register hvc0 console. Better late then never. */
+ hvc_instantiate(0, 0, &virtio_cons);
+
/* The first argument of hvc_alloc() is the virtual console number, so
* we use zero. The second argument is the parameter for the
* notification mechanism (like irq number). We currently leave this
--
1.7.0
reply other threads:[~2010-02-22 10:15 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100222141550.67fa46f7.const@mimas.ru \
--to=const@mimas.ru \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome