diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2014-12-08 16:50:40 +0800 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2014-12-22 23:02:41 +1100 |
commit | 2d2ec0642a85966b6a299bbcd94707982327ace8 (patch) | |
tree | 8145fcdb8eb9e27f3d6c23ba1999d69a92de1e21 /drivers/char | |
parent | ebbbfa248389b176e2e62d8cf91814253849ccc9 (diff) | |
download | op-kernel-dev-2d2ec0642a85966b6a299bbcd94707982327ace8.zip op-kernel-dev-2d2ec0642a85966b6a299bbcd94707982327ace8.tar.gz |
hwrng: don't init list element we're about to add to list.
Another interesting anti-pattern.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/hw_random/core.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/char/hw_random/core.c b/drivers/char/hw_random/core.c index e384ee3..6ec4225 100644 --- a/drivers/char/hw_random/core.c +++ b/drivers/char/hw_random/core.c @@ -485,7 +485,6 @@ int hwrng_register(struct hwrng *rng) goto out_unlock; } } - INIT_LIST_HEAD(&rng->list); list_add_tail(&rng->list, &rng_list); if (old_rng && !rng->init) { |