lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160809151937.GA15447@e104818-lin.cambridge.arm.com>
Date:	Tue, 9 Aug 2016 16:19:37 +0100
From:	Catalin Marinas <catalin.marinas@....com>
To:	Grygorii Strashko <grygorii.strashko@...com>
Cc:	"David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
	Mugunthan V N <mugunthanvnm@...com>,
	Sekhar Nori <nsekhar@...com>, linux-kernel@...r.kernel.org,
	linux-omap@...r.kernel.org
Subject: Re: [PATCH] drivers: net: cpsw: fix kmemleak false-positive reports
 for sk buffers

On Tue, Aug 09, 2016 at 03:09:44PM +0300, Grygorii Strashko wrote:
> diff --git a/drivers/net/ethernet/ti/cpsw.c b/drivers/net/ethernet/ti/cpsw.c
> index 0805855..0456e0e 100644
> --- a/drivers/net/ethernet/ti/cpsw.c
> +++ b/drivers/net/ethernet/ti/cpsw.c
> @@ -732,6 +732,7 @@ static void cpsw_rx_handler(void *token, int len, int status)
>  		netif_receive_skb(skb);
>  		ndev->stats.rx_bytes += len;
>  		ndev->stats.rx_packets++;
> +		kmemleak_not_leak(new_skb);
>  	} else {
>  		ndev->stats.rx_dropped++;
>  		new_skb = skb;
> @@ -1323,6 +1324,7 @@ static int cpsw_ndo_open(struct net_device *ndev)
>  				kfree_skb(skb);
>  				goto err_cleanup;
>  			}
> +			kmemleak_not_leak(skb);

Nitpick: I would add a short comment above the kmemleak_not_leak() calls
on why there is a false positive. Otherwise:

Acked-by: Catalin Marinas <catalin.marinas@....com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ