qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paul Brook <paul@codesourcery.com>
To: qemu-devel@nongnu.org
Cc: Ian Molton <ian.molton@collabora.co.uk>,
	Gerd Hoffmann <kraxel@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 2/2] VirtIO RNG
Date: Sat, 3 Apr 2010 16:06:26 +0100	[thread overview]
Message-ID: <201004031606.26893.paul@codesourcery.com> (raw)
In-Reply-To: <4BB5C332.7080207@collabora.co.uk>

> Paul Brook wrote:
> >>>>        This patch adds support for virtio-rng. Data is read from a
> >>>> chardev and can be either raw entropy or received via the EGD
> >>>> protocol.
> >>>
> >>> I still don't get why you need this at all. It seems like
> >>> virtio-serial would already provides everything you need.
> >>
> >> I guess when virtio-rng was first written, virtio-serial wasn't
> >> flexible enough because it didn't support multiple devices
> >
> > That argument no longer holds.
> 
> So now everything that looks like a stream of bytes has to use the
> virtio-serial code...

IMO, yes. That's the whole point of virtio-serial.

You can handle it however you like in your in your favourite guest OS, but I 
object to qemu having multiple virtio devices that look and smell exactly like 
a serial port.

>Why? Its not like it'll make the rng device any simpler, smaller,
>faster, or reduce its dependencies. Virtio is simple enough to begin with!

I disagree. Past experience shows that it's more than possible to completely 
screw up something as simple as a serial port. If everything that looks like a 
serial port provides their own implementation then the chances are they'll all 
be missing something, and broken in different ways.

Take rate limiting as an example: Your implementation has at least one 
outright bug (using gettimeofday), and various questionable characteristics 
(is a 1-second token bucket appropriate).

The EGD protocol bits are another example. You aren't exposing any of the 
interesting bits of this protocol to the guest, so it seems entirely 
reasonable to connect this to a serial port. That allows it to be used by 
guests that don't have a virtio-rng driver.

Paul

  reply	other threads:[~2010-04-03 15:06 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-30 14:05 [Qemu-devel] [PATCH 0/2] VirtIO RNG Ian Molton
2010-03-30 14:12 ` [Qemu-devel] [PATCH 1/2] " Ian Molton
2010-03-30 14:13 ` [Qemu-devel] [PATCH 2/2] " Ian Molton
2010-04-01 12:17   ` Paul Brook
2010-04-01 12:30     ` Jamie Lokier
2010-04-01 14:03       ` Paul Brook
2010-04-02 10:13         ` Ian Molton
2010-04-03 15:06           ` Paul Brook [this message]
2010-04-13 14:41             ` Ian Molton
2010-04-13 15:01               ` Paul Brook
2010-04-13 15:32               ` Paul Brook
2010-04-20 15:15                 ` Ian Molton
2010-04-20 16:13                   ` Jamie Lokier
2010-04-20 19:52                     ` Ian Molton
2010-04-20 20:11                       ` Blue Swirl
2010-04-20 20:56                       ` Jamie Lokier
2010-04-20 21:31                         ` Ian Molton
2010-04-20 21:55                           ` Jamie Lokier
2010-04-21  7:43                           ` Gerd Hoffmann
2010-04-21  9:40                             ` Jamie Lokier
2010-04-21 12:34                               ` Ian Molton
2010-04-21 13:55                                 ` Gerd Hoffmann
2010-04-22 19:06                                   ` Ian Molton
2010-04-22 21:05                                     ` Jamie Lokier
2010-04-23 10:17                                       ` Ian Molton
2010-04-24  1:37                                         ` Jamie Lokier
2010-04-24  8:58                                           ` Ian Molton
2010-04-23  8:27                                     ` Gerd Hoffmann
2010-04-23  9:28                                       ` Ian Molton
2010-04-23 14:07                                         ` Gerd Hoffmann
2010-04-23 15:49                                           ` Ian Molton
2010-04-23 17:32                                             ` Jamie Lokier
2010-04-24  9:16                                               ` Ian Molton
2010-04-02 10:15       ` Ian Molton
2010-04-02 10:07     ` Ian Molton
2010-05-03 17:56   ` Anthony Liguori

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=201004031606.26893.paul@codesourcery.com \
    --to=paul@codesourcery.com \
    --cc=ian.molton@collabora.co.uk \
    --cc=kraxel@redhat.com \
    --cc=qemu-devel@nongnu.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).