virtio-rng: fixes for device registration/unregistration
authorSasha Levin <sasha.levin@oracle.com>
Fri, 16 May 2014 02:12:43 +0000 (11:42 +0930)
committerRusty Russell <rusty@rustcorp.com.au>
Sun, 18 May 2014 23:56:40 +0000 (09:26 +0930)
There are several fixes in this patch (mostly because it's hard
splitting them up):

 - Revert the name field in struct hwrng back to 'const'. Also, don't
do an extra kmalloc for the name - just wasteful.
 - Deal with allocation failures properly.
 - Use IDA to allocate device number instead of brute forcing one.

Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

No differences found