All of lore.kernel.org
 help / color / mirror / Atom feed
From: Amos Kong <akong@redhat.com>
To: Amit Shah <amit.shah@redhat.com>
Cc: Herbert Xu <herbert@gondor.apana.org.au>,
	kvm@vger.kernel.org,
	Virtualization List <virtualization@lists.linux-foundation.org>
Subject: Re: When I boot two virtio-rng devices, guest will hang
Date: Tue, 5 Aug 2014 18:28:54 +0800	[thread overview]
Message-ID: <20140805102854.GA7958@z.redhat.com> (raw)
In-Reply-To: <20140728121120.GI2683@z.redhat.com>

3.16 (guest hangs with two rng devices)
3.16 + quick fix (can startup with two rng devices) (hotplug issue 1 + hotplug issue 2 exist)
lates torvalds/linux.git + amit 4 patches (can startup with two rng devices) (only hotplug issue 2 exists)

However, the 4 patches also fixed the hang issue, the hotplug issue was fixed a little.
The hotplug issue is effected by the backend, or maybe it's not a real issue, because
the rng device can be hot-removed after dd process is killed.


Hotplug issue 1:
  1. boot up guest with two rng device (rng0 uses /dev/urandom, rng1 uses /dev/random)
  2. read data by dd in guest
  3 (option 1). hot-remove rng0, then hot-remove rng1 -> result: _only rng1_ can't be removed until dd process is killed
  3 (option 2). hot-remove rng1, then hot-remove rng0 -> result: two devices can be removed successfully, dd process will exit automatically.

  If we use /dev/urandom for rng0 and rng1, _rng0 & rng1_ can be removed, dd process will exit automatically.

Hotplug issue 2:
  If we use /dev/random for rng0 and rng1, _rng0 & rng1_ can't be removed until dd process is killed.

Hotplug issue 3:
  If we use /dev/random for rng0 and rng1, _only rng1_ can't be removed until dd process is killed.


(The difference between /dev/random and /dev/urandom is the speed.)

Thanks, Amos

  reply	other threads:[~2014-08-05 10:28 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-28  7:32 When I boot two virtio-rng devices, guest will hang Amos Kong
2014-07-28  7:55 ` Amit Shah
2014-07-28  7:55   ` Amit Shah
2014-07-28  8:49   ` Amos Kong
2014-07-28  9:12     ` Amit Shah
2014-07-28 12:11       ` Amos Kong
2014-08-05 10:28         ` Amos Kong [this message]
2014-08-05 17:45           ` Amos Kong
2014-07-28  8:49   ` Amos Kong

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=20140805102854.GA7958@z.redhat.com \
    --to=akong@redhat.com \
    --cc=amit.shah@redhat.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=kvm@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.