2018-12-29 12:53:34

by Peng Hao

[permalink] [raw]
Subject: [PATCH 2/2] arm/plat-pxa/ssp : unneeded to free devm_ allocated data

devm_ allocated data will be automatically freed. The free
of devm_ allocated data is invalid.

Signed-off-by: Peng Hao <[email protected]>
---
arch/arm/plat-pxa/ssp.c | 3 ---
1 file changed, 3 deletions(-)

diff --git a/arch/arm/plat-pxa/ssp.c b/arch/arm/plat-pxa/ssp.c
index ed36dca..f519199 100644
--- a/arch/arm/plat-pxa/ssp.c
+++ b/arch/arm/plat-pxa/ssp.c
@@ -190,8 +190,6 @@ static int pxa_ssp_remove(struct platform_device *pdev)
if (ssp == NULL)
return -ENODEV;

- iounmap(ssp->mmio_base);
-
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(res->start, resource_size(res));

@@ -201,7 +199,6 @@ static int pxa_ssp_remove(struct platform_device *pdev)
list_del(&ssp->node);
mutex_unlock(&ssp_lock);

- kfree(ssp);
return 0;
}

--
1.8.3.1



2019-01-04 03:19:39

by Robert Jarzmik

[permalink] [raw]
Subject: Re: [PATCH 2/2] arm/plat-pxa/ssp : unneeded to free devm_ allocated data

Peng Hao <[email protected]> writes:

> devm_ allocated data will be automatically freed. The free
> of devm_ allocated data is invalid.
>
> Signed-off-by: Peng Hao <[email protected]>

Hi Peng Hao,

Thanks for the patch. I changed your title to fit my tree, ie. :
"ARM: pxa: ssp: unneeded to free devm_ allocated data"

If you have other patches please check what is the commit subject's prefix for
the file(s) you're touching.

Queued to pxa/fixes.

Cheers.

--
Robert