RE: [PATCH v2 ] McBSP: Fix the free variable update at remove

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----Original Message-----
> From: Jarkko Nikula [mailto:jhnikula@xxxxxxxxx]
> Sent: Wednesday, November 03, 2010 2:58 PM
> To: Datta, Shubhrajyoti
> Cc: linux-omap@xxxxxxxxxxxxxxx
> Subject: Re: [PATCH v2 ] McBSP: Fix the free variable update at remove
> 
> On Tue,  2 Nov 2010 16:33:34 +0530
> shubhrajyoti@xxxxxx wrote:
> 
> > From: Shubhrajyoti D <shubhrajyoti@xxxxxx>
> >
> > At remove the free variable is wrongly updated.Attempting to solve the
> same.
> >
> > Signed-off-by: Shubhrajyoti D <shubhrajyoti@xxxxxx>
> > Reported-by: Vikram Pandita <vikram.pandita@xxxxxx>
> > ---
> > -[v2] Instead of using 0/1 use true/false
> >  arch/arm/plat-omap/mcbsp.c |   10 +++++-----
> >  1 files changed, 5 insertions(+), 5 deletions(-)
> ...
> > @@ -1845,7 +1845,7 @@ static int __devexit omap_mcbsp_remove(struct
> platform_device *pdev)
> >
> >  		mcbsp->fclk = NULL;
> >  		mcbsp->iclk = NULL;
> > -		mcbsp->free = 0;
> > +		mcbsp->free = true;
> >  		mcbsp->dev = NULL;
> >  	}
> >
> While reviewing this I noticed that mcbsp->free is not problem at all
> but the memory leak as there is no kfree(mcbsp) here and clk_disables
> looked suspicious too.
> 
> I sent a patch fixing these and your patch changing to use true/false
> flags with mcbsp->free looks worth to do as well. Care to send an
> updated patch on top of mine (i.e no changes to omap_mcbsp_remove
> reguired)?

Makes sense. I agree will send a fresh patch.
> 
> 
> --
> Jarkko
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux