From: "Christian Bornträger" <borntraeger@de.ibm.com>
To: Paul Brook <paul@codesourcery.com>
Cc: Amit Shah <amit.shah@redhat.com>,
qemu-devel@nongnu.org, kvm@vger.kernel.org,
virtualization@lists.linux-foundation.org
Subject: Re: [Qemu-devel] virtio-serial: A guest <-> host interface for simple communication
Date: Tue, 23 Jun 2009 16:40:30 +0200 [thread overview]
Message-ID: <200906231640.30915.borntraeger@de.ibm.com> (raw)
In-Reply-To: <200906231516.15470.paul@codesourcery.com>
Am Dienstag 23 Juni 2009 16:16:13 schrieb Paul Brook:
> > I did some work on virtio-console, since kvm on s390 does not provide any
> > other. I dont think we should mix two different types of devices into one
> > driver. The only thing that these drivers have in common, is the fact
> > that there are two virtqueues, piping data (single bytes or larger
> > chunks). So you could make the same argument with the first virtio_net
> > driver (the one before GSO) - which is obviously wrong. The common part
> > of the transport is already factored out to virtio_ring and the
> > transports.
>
> virtio-net is packet based, not stream based.
You can argue that virtio-console is also packet based. The input buffer can
accept up to 4K in one buffer and the console code can also submit larger chunks
to virtio_console.
> > In addition there are two ABIs involved: a userspace ABI (/dev/hvc0) and
> > a guest/host ABI for this console. (and virtio was not meant to be a
> > KVM-only interface, that we can change all the time). David A. Wheeler's
> > 'SLOCCount' gives me 141 lines of code for virtio_console.c. I am quite
> > confident that the saving we could achieve by merging these two drivers
> > is not worth the hazzle.
>
> AFAICS the functionality provided is exactly the same. The host API is
> identical, and the guest userspace API only has trivial differences (which
> could be eliminated with a simple udev rule). By my reading virtio-serial
> makes virtio-console entirely redundant.
How can you know, that the userspace API only has trivial differences, if the
question below is not answered?
> > Discussion about merging the console code into this distracts from the
> > main problem: To get the interface and functionality right before it
> > becomes an ABI (is it /dev/ttyS, network like or is it something
> > completely different?).
>
> Ah, now that's a different question. I don't know what the requirements are
> for the higher level vmchannel interface. However I also don't care.
You should care, because it might have an impact if two serial lines are really
the right solution for the vmchannel.
One thing that I forgot:
You should be warned that hvc_console sometimes can be a real PITA. A while ago
I tried to change virtio_console to support more than one console and hotplug
and failed to find a proper solution that can handle all the subtle console/tty
register/unregister combinations. You dont want to adopt new code to fit to
hvc_console - leave it in virtio_console...
next prev parent reply other threads:[~2009-06-23 14:41 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-23 12:42 [Qemu-devel] virtio-serial: A guest <-> host interface for simple communication Amit Shah
2009-06-23 12:42 ` [Qemu-devel] [PATCH] virtio_serial: A char device for simple guest <-> host communication Amit Shah
2009-06-23 12:42 ` [Qemu-devel] [PATCH] virtio-serial: virtio device for simple host <-> guest communication Amit Shah
2009-06-23 15:19 ` Blue Swirl
2009-06-23 15:15 ` [Qemu-devel] [PATCH] virtio_serial: A char device for simple guest <-> host communication Blue Swirl
2009-06-23 12:55 ` [Qemu-devel] virtio-serial: A guest <-> host interface for simple communication Paul Brook
2009-06-23 13:00 ` Amit Shah
2009-06-23 13:09 ` Paul Brook
2009-06-23 13:58 ` Christian Bornträger
2009-06-23 14:16 ` Paul Brook
2009-06-23 14:40 ` Christian Bornträger [this message]
2009-06-23 14:59 ` Daniel P. Berrange
2009-06-24 4:15 ` [Qemu-devel] " Rusty Russell
2009-06-24 12:39 ` Amit Shah
2009-06-25 11:33 ` Rusty Russell
2009-06-25 20:49 ` Amit Shah
2009-06-24 16:40 ` [Qemu-devel] " Jamie Lokier
2009-06-24 17:10 ` Amit Shah
2009-06-24 17:50 ` Jamie Lokier
2009-06-24 18:01 ` Amit Shah
2009-06-24 19:20 ` Jamie Lokier
2009-06-25 4:41 ` Amit Shah
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=200906231640.30915.borntraeger@de.ibm.com \
--to=borntraeger@de.ibm.com \
--cc=amit.shah@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=paul@codesourcery.com \
--cc=qemu-devel@nongnu.org \
--cc=virtualization@lists.linux-foundation.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;
as well as URLs for NNTP newsgroup(s).