Fix a "Trying to vfree() nonexistent vm area" error when unloading the CAAM
controller module by providing the correct pointer value to iounmap().

Signed-off-by: Victoria Milhoan <vicki.milh...@freescale.com>
---
 drivers/crypto/caam/ctrl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/crypto/caam/ctrl.c b/drivers/crypto/caam/ctrl.c
index 3226eb8..8a4b239 100644
--- a/drivers/crypto/caam/ctrl.c
+++ b/drivers/crypto/caam/ctrl.c
@@ -301,7 +301,7 @@ static int caam_remove(struct platform_device *pdev)
 #endif
 
        /* Unmap controller region */
-       iounmap(&ctrl);
+       iounmap(ctrl);
 
 #ifdef CONFIG_ARM
        /* shut clocks off before finalizing shutdown */
@@ -577,7 +577,7 @@ static int caam_probe(struct platform_device *pdev)
                                        sizeof(struct platform_device *) * 
rspec,
                                        GFP_KERNEL);
        if (ctrlpriv->jrpdev == NULL) {
-               iounmap(&ctrl);
+               iounmap(ctrl);
                return -ENOMEM;
        }
 
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe linux-crypto" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to