Commit fdec60d6 authored by Corentin LABBE's avatar Corentin LABBE Committed by Herbert Xu

hwrng: amd - release_region must be called after hwrng_unregister

The driver release the memory region before being sure that nobody use
it.

This patch made hwrng_unregister ran before any release was done.
Signed-off-by: default avatarLABBE Corentin <clabbe.montjoie@gmail.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 055ae890
......@@ -151,8 +151,9 @@ static void __exit mod_exit(void)
{
u32 pmbase = (unsigned long)amd_rng.priv;
release_region(pmbase + 0xF0, 8);
hwrng_unregister(&amd_rng);
release_region(pmbase + 0xF0, 8);
}
module_init(mod_init);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment