lkml.org 
[lkml]   [2020]   [Jan]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] i2c: iop3xx: Fix memory leak in probe error path
On Mon, Jan 13, 2020 at 06:29:54PM +0100, Krzysztof Kozlowski wrote:
> When handling devm_gpiod_get_optional() errors, free the memory already
> allocated. This fixes Smatch warnings:
>
> drivers/i2c/busses/i2c-iop3xx.c:437 iop3xx_i2c_probe() warn: possible memory leak of 'new_adapter'
> drivers/i2c/busses/i2c-iop3xx.c:442 iop3xx_i2c_probe() warn: possible memory leak of 'new_adapter'
>
> Reported-by: kbuild test robot <lkp@intel.com>
> Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>

Applied to for-current, thanks! Please add a 'Fixes' tag next time,
added it for you now.

[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2020-01-15 20:34    [W:0.177 / U:0.328 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site