Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 072d3d1a authored by Michael Buesch's avatar Michael Buesch Committed by Linus Torvalds
Browse files

[PATCH] hwrng: fix geode probe error unwind



The geode hwrng leaks an iomapped resource, if hwrng_register() fails.
This fixes it.

Signed-off-by: default avatarMichael Buesch <mb@bu3sch.de>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 58690664
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -107,10 +107,14 @@ static int __init mod_init(void)
	if (err) {
		printk(KERN_ERR PFX "RNG registering failed (%d)\n",
		       err);
		goto out;
		goto err_unmap;
	}
out:
	return err;

err_unmap:
	iounmap(mem);
	goto out;
}

static void __exit mod_exit(void)