Re: [PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-22 Thread Rusty Russell
Amit Shah writes: > On (Mon) 21 Jul 2014 [17:15:51], Amit Shah wrote: >> Instead of calling hwrng_register() in the probe routing, call it in the >> scan routine. This ensures that when hwrng_register() is successful, >> and it requests a few random bytes to seed the kernel's pool at init, >> we'

Re: [PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-22 Thread Amit Shah
On (Mon) 21 Jul 2014 [17:15:51], Amit Shah wrote: > Instead of calling hwrng_register() in the probe routing, call it in the > scan routine. This ensures that when hwrng_register() is successful, > and it requests a few random bytes to seed the kernel's pool at init, > we're ready to service that

Re: [PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-22 Thread Jason Cooper
On Mon, Jul 21, 2014 at 08:41:24PM +0800, Herbert Xu wrote: > On Mon, Jul 21, 2014 at 08:11:16AM -0400, Jason Cooper wrote: > > > > > @@ -136,15 +137,6 @@ static int probe_common(struct virtio_device *vdev) > > > return err; > > > } > > > > > > - err = hwrng_register(&vi->hwrng); > >

Re: [PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-21 Thread Herbert Xu
On Mon, Jul 21, 2014 at 08:11:16AM -0400, Jason Cooper wrote: > > > @@ -136,15 +137,6 @@ static int probe_common(struct virtio_device *vdev) > > return err; > > } > > > > - err = hwrng_register(&vi->hwrng); > > - if (err) { > > - vdev->config->del_vqs(vdev); > > -

Re: [PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-21 Thread Amit Shah
On (Mon) 21 Jul 2014 [08:11:16], Jason Cooper wrote: > On Mon, Jul 21, 2014 at 05:15:51PM +0530, Amit Shah wrote: > > Instead of calling hwrng_register() in the probe routing, call it in the > > scan routine. This ensures that when hwrng_register() is successful, > > and it requests a few random b

Re: [PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-21 Thread Jason Cooper
On Mon, Jul 21, 2014 at 05:15:51PM +0530, Amit Shah wrote: > Instead of calling hwrng_register() in the probe routing, call it in the > scan routine. This ensures that when hwrng_register() is successful, > and it requests a few random bytes to seed the kernel's pool at init, > we're ready to serv

[PATCH v2 3/4] virtio: rng: delay hwrng_register() till driver is ready

2014-07-21 Thread Amit Shah
Instead of calling hwrng_register() in the probe routing, call it in the scan routine. This ensures that when hwrng_register() is successful, and it requests a few random bytes to seed the kernel's pool at init, we're ready to service that request. This will also enable us to remove the workaroun